summaryrefslogtreecommitdiffstats
path: root/sys/i386/linux
diff options
context:
space:
mode:
authortjr <tjr@FreeBSD.org>2004-08-16 07:05:44 +0000
committertjr <tjr@FreeBSD.org>2004-08-16 07:05:44 +0000
commite6930a385cee9ccad60b87c385ea268f880443c3 (patch)
tree5bebef9f1facd7f9f53936682e1bf1f2b3535c56 /sys/i386/linux
parentc392760f6f0281b2ed91c22ed695022ad63c4d40 (diff)
downloadFreeBSD-src-e6930a385cee9ccad60b87c385ea268f880443c3.zip
FreeBSD-src-e6930a385cee9ccad60b87c385ea268f880443c3.tar.gz
Add a new type, l_uintptr_t, which is an unsigned integer type with the
same width as a pointer under Linux. Add two new macros, PTRIN and PTROUT, which convert between l_uintptr_t and native pointers.
Diffstat (limited to 'sys/i386/linux')
-rw-r--r--sys/i386/linux/linux.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/sys/i386/linux/linux.h b/sys/i386/linux/linux.h
index 3faded5..fa0ab75 100644
--- a/sys/i386/linux/linux.h
+++ b/sys/i386/linux/linux.h
@@ -47,6 +47,9 @@ extern u_char linux_debug_map[];
MALLOC_DECLARE(M_LINUX);
#endif
+#define PTRIN(v) (void *)(v)
+#define PTROUT(v) (l_uintptr_t)(v)
+
/*
* Provide a separate set of types for the Linux types.
*/
@@ -60,6 +63,7 @@ typedef uint64_t l_ulonglong;
typedef unsigned short l_ushort;
typedef char *l_caddr_t;
+typedef l_ulong l_uintptr_t;
typedef l_long l_clock_t;
typedef l_int l_daddr_t;
typedef l_ushort l_dev_t;
OpenPOWER on IntegriCloud