From f0b067efff3e5a2933033bbc4516eb14cdfc9baf Mon Sep 17 00:00:00 2001 From: Brian Behlendorf Date: Wed, 10 Dec 2008 11:37:45 -0800 Subject: [PATCH 1/2] Add frame definitions for x86+x86_64 arches --- zfs/lib/libspl/include/sys/frame.h | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/zfs/lib/libspl/include/sys/frame.h b/zfs/lib/libspl/include/sys/frame.h index 9e2fa0bb2f..889a5c927e 100644 --- a/zfs/lib/libspl/include/sys/frame.h +++ b/zfs/lib/libspl/include/sys/frame.h @@ -5,4 +5,31 @@ #ifndef _SYS_FRAME_H #define _SYS_FRAME_H +#include + +#if defined(_LP64) || defined(_I32LPx) +typedef long greg_t; +#else +typedef int greg_t; +#endif + +struct frame { + greg_t fr_savfp; /* saved frame pointer */ + greg_t fr_savpc; /* saved program counter */ +}; + +#if defined(_SYSCALL32) + +typedef int32_t greg32_t; +typedef int64_t greg64_t; + +/* + * Kernel's view of a 32-bit stack frame. + */ +struct frame32 { + greg32_t fr_savfp; /* saved frame pointer */ + greg32_t fr_savpc; /* saved program counter */ +}; + +#endif /* _SYSCALL32 */ #endif /* _SYS_FRAME_H */ From 0ef22717d23db37c8c755cd56bfd5740c41f6c56 Mon Sep 17 00:00:00 2001 From: Brian Behlendorf Date: Wed, 10 Dec 2008 11:39:16 -0800 Subject: [PATCH 2/2] Use stack_t defined in /usr/include/bits/sigstack.h --- zfs/lib/libspl/include/sys/stack.h | 6 ------ 1 file changed, 6 deletions(-) diff --git a/zfs/lib/libspl/include/sys/stack.h b/zfs/lib/libspl/include/sys/stack.h index a8f5a921d3..496605f956 100644 --- a/zfs/lib/libspl/include/sys/stack.h +++ b/zfs/lib/libspl/include/sys/stack.h @@ -9,12 +9,6 @@ #define STACK_BIAS 0 -typedef struct { - void *ss_sp; - size_t ss_size; - int ss_flags; -} stack_t; - #ifdef __USE_GNU static inline int