freebsd32: take the _umtx_op struct definitions back
Providing these in freebsd32.h facilitates local testing/measuring of the structs rather than forcing one to locally recreate them. Sanity checking offsets/sizes remains in kern_umtx.c where these are typically used.
This commit is contained in:
parent
f96078b8fe
commit
60e60e73fd
@ -94,6 +94,27 @@ struct itimerval32 {
|
|||||||
struct timeval32 it_value;
|
struct timeval32 it_value;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
struct umtx_time32 {
|
||||||
|
struct timespec32 _timeout;
|
||||||
|
uint32_t _flags;
|
||||||
|
uint32_t _clockid;
|
||||||
|
};
|
||||||
|
|
||||||
|
struct umtx_robust_lists_params_compat32 {
|
||||||
|
uint32_t robust_list_offset;
|
||||||
|
uint32_t robust_priv_list_offset;
|
||||||
|
uint32_t robust_inact_offset;
|
||||||
|
};
|
||||||
|
|
||||||
|
struct umutex32 {
|
||||||
|
volatile __lwpid_t m_owner; /* Owner of the mutex */
|
||||||
|
__uint32_t m_flags; /* Flags of the mutex */
|
||||||
|
__uint32_t m_ceilings[2]; /* Priority protect ceiling */
|
||||||
|
__uint32_t m_rb_lnk; /* Robust linkage */
|
||||||
|
__uint32_t m_pad;
|
||||||
|
__uint32_t m_spare[2];
|
||||||
|
};
|
||||||
|
|
||||||
#define FREEBSD4_MFSNAMELEN 16
|
#define FREEBSD4_MFSNAMELEN 16
|
||||||
#define FREEBSD4_MNAMELEN (88 - 2 * sizeof(int32_t))
|
#define FREEBSD4_MNAMELEN (88 - 2 * sizeof(int32_t))
|
||||||
|
|
||||||
|
@ -232,27 +232,6 @@ struct umtx_copyops {
|
|||||||
const bool compat32;
|
const bool compat32;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct umtx_time32 {
|
|
||||||
struct timespec32 _timeout;
|
|
||||||
uint32_t _flags;
|
|
||||||
uint32_t _clockid;
|
|
||||||
};
|
|
||||||
|
|
||||||
struct umtx_robust_lists_params_compat32 {
|
|
||||||
uint32_t robust_list_offset;
|
|
||||||
uint32_t robust_priv_list_offset;
|
|
||||||
uint32_t robust_inact_offset;
|
|
||||||
};
|
|
||||||
|
|
||||||
struct umutex32 {
|
|
||||||
volatile __lwpid_t m_owner; /* Owner of the mutex */
|
|
||||||
__uint32_t m_flags; /* Flags of the mutex */
|
|
||||||
__uint32_t m_ceilings[2]; /* Priority protect ceiling */
|
|
||||||
__uint32_t m_rb_lnk; /* Robust linkage */
|
|
||||||
__uint32_t m_pad;
|
|
||||||
__uint32_t m_spare[2];
|
|
||||||
};
|
|
||||||
|
|
||||||
_Static_assert(sizeof(struct umutex) == sizeof(struct umutex32), "umutex32");
|
_Static_assert(sizeof(struct umutex) == sizeof(struct umutex32), "umutex32");
|
||||||
_Static_assert(__offsetof(struct umutex, m_spare[0]) ==
|
_Static_assert(__offsetof(struct umutex, m_spare[0]) ==
|
||||||
__offsetof(struct umutex32, m_spare[0]), "m_spare32");
|
__offsetof(struct umutex32, m_spare[0]), "m_spare32");
|
||||||
|
Loading…
x
Reference in New Issue
Block a user