aboutsummaryrefslogtreecommitdiff
path: root/sys/dev/isp/isp_freebsd.h
diff options
context:
space:
mode:
authorMatt Jacob <mjacob@FreeBSD.org>2006-02-02 21:31:34 +0000
committerMatt Jacob <mjacob@FreeBSD.org>2006-02-02 21:31:34 +0000
commit53af7d226e5da532f1557cf6b3479d736326e21c (patch)
tree52e570d14870a49bb56aecb56e5d225ddcdfac8e /sys/dev/isp/isp_freebsd.h
parent56db7f4cc636b8ac9d4e4731e6f15356bf990df0 (diff)
downloadsrc-53af7d226e5da532f1557cf6b3479d736326e21c.tar.gz
src-53af7d226e5da532f1557cf6b3479d736326e21c.zip
Remove use of inlines and use the functions as a library.
Larger code space, possibly performance hit, but more portable. Certainly less questionable use of inlining. Suggested by: des
Notes
Notes: svn path=/head/; revision=155228
Diffstat (limited to 'sys/dev/isp/isp_freebsd.h')
-rw-r--r--sys/dev/isp/isp_freebsd.h27
1 files changed, 10 insertions, 17 deletions
diff --git a/sys/dev/isp/isp_freebsd.h b/sys/dev/isp/isp_freebsd.h
index 8497c2ba8c1c..bc9d218de8ad 100644
--- a/sys/dev/isp/isp_freebsd.h
+++ b/sys/dev/isp/isp_freebsd.h
@@ -74,13 +74,6 @@
#define ISP_SBUS_SUPPORTED 0
#endif
-/*
- * Hackery- remove TARGET MODE when compiling as a module on sparc64
- */
-#if defined(__sparc64__) && defined(KLD_MODULE) && defined(ISP_TARGET_MODE)
-#undef ISP_TARGET_MODE
-#endif
-
#define HANDLE_LOOPSTATE_IN_OUTER_LAYERS 1
/* #define ISP_SMPLOCK 1 */
@@ -189,8 +182,6 @@ struct isposinfo {
* Required Macros/Defines
*/
-#define INLINE __inline
-
#define ISP2100_SCRLEN 0x800
#define MEMZERO bzero
@@ -414,12 +405,13 @@ extern int isp_announced;
#define XS_CMD_DONE_P(sccb) ((sccb)->ccb_h.spriv_field0 & ISP_SPRIV_DONE)
#define XS_CMD_S_CLEAR(sccb) (sccb)->ccb_h.spriv_field0 = 0
+
/*
* Platform specific inline functions
*/
-static INLINE void isp_mbox_wait_complete(struct ispsoftc *);
-static INLINE void
+static __inline void isp_mbox_wait_complete(struct ispsoftc *);
+static __inline void
isp_mbox_wait_complete(struct ispsoftc *isp)
{
if (isp->isp_osinfo.intsok) {
@@ -463,8 +455,8 @@ isp_mbox_wait_complete(struct ispsoftc *isp)
}
}
-static INLINE u_int64_t nanotime_sub(struct timespec *, struct timespec *);
-static INLINE u_int64_t
+static __inline u_int64_t nanotime_sub(struct timespec *, struct timespec *);
+static __inline u_int64_t
nanotime_sub(struct timespec *b, struct timespec *a)
{
u_int64_t elapsed;
@@ -476,8 +468,8 @@ nanotime_sub(struct timespec *b, struct timespec *a)
return (elapsed);
}
-static INLINE char *strncat(char *, const char *, size_t);
-static INLINE char *
+static __inline char *strncat(char *, const char *, size_t);
+static __inline char *
strncat(char *d, const char *s, size_t c)
{
char *t = d;
@@ -496,8 +488,9 @@ strncat(char *d, const char *s, size_t c)
}
/*
- * Common inline functions
+ * ISP Library functions
*/
-#include <dev/isp/isp_inline.h>
+#include <dev/isp/isp_library.h>
+
#endif /* _ISP_FREEBSD_H */