summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorpaul <paul@FreeBSD.org>1994-08-23 13:41:37 +0000
committerpaul <paul@FreeBSD.org>1994-08-23 13:41:37 +0000
commit351b3a5a9acdd9c18ca8248a5a71f8f6007ae2b1 (patch)
tree9c8f7b8b02b331190f9703f57c2f68613e686280
parent42b0369dee94a99e593555c54ebd793c9518cf7f (diff)
downloadFreeBSD-src-351b3a5a9acdd9c18ca8248a5a71f8f6007ae2b1.zip
FreeBSD-src-351b3a5a9acdd9c18ca8248a5a71f8f6007ae2b1.tar.gz
Re-enabled inlining of inb.
Changed u_int_inb to just inb and deleted define. The code generated is identical to that generated with the cast so the problem was obviously fixed at some point after gcc 1.4 Reviewed by: Submitted by:
-rw-r--r--sys/amd64/include/cpufunc.h14
-rw-r--r--sys/i386/include/cpufunc.h14
2 files changed, 6 insertions, 22 deletions
diff --git a/sys/amd64/include/cpufunc.h b/sys/amd64/include/cpufunc.h
index 12d1585..4100833 100644
--- a/sys/amd64/include/cpufunc.h
+++ b/sys/amd64/include/cpufunc.h
@@ -30,7 +30,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: cpufunc.h,v 1.17 1994/08/18 22:34:46 wollman Exp $
+ * $Id: cpufunc.h,v 1.18 1994/08/23 11:57:19 paul Exp $
*/
/*
@@ -70,16 +70,8 @@ enable_intr(void)
__asm __volatile("sti");
}
-/*
- * This roundabout method of returning a u_char helps stop gcc-1.40 from
- * generating unnecessary movzbl's.
- */
-#ifdef disable_for_gcc-2_6_0
-#define inb(port) ((u_char) u_int_inb(port))
-#endif
-
-static inline u_int
-u_int_inb(u_int port)
+static inline u_char
+inb(u_int port)
{
u_char data;
/*
diff --git a/sys/i386/include/cpufunc.h b/sys/i386/include/cpufunc.h
index 12d1585..4100833 100644
--- a/sys/i386/include/cpufunc.h
+++ b/sys/i386/include/cpufunc.h
@@ -30,7 +30,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: cpufunc.h,v 1.17 1994/08/18 22:34:46 wollman Exp $
+ * $Id: cpufunc.h,v 1.18 1994/08/23 11:57:19 paul Exp $
*/
/*
@@ -70,16 +70,8 @@ enable_intr(void)
__asm __volatile("sti");
}
-/*
- * This roundabout method of returning a u_char helps stop gcc-1.40 from
- * generating unnecessary movzbl's.
- */
-#ifdef disable_for_gcc-2_6_0
-#define inb(port) ((u_char) u_int_inb(port))
-#endif
-
-static inline u_int
-u_int_inb(u_int port)
+static inline u_char
+inb(u_int port)
{
u_char data;
/*
OpenPOWER on IntegriCloud