diff options
Diffstat (limited to 'include/linux')
| -rw-r--r-- | include/linux/compat.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/include/linux/compat.h b/include/linux/compat.h index 5e58d705ac7c..e1e78bb971aa 100644 --- a/include/linux/compat.h +++ b/include/linux/compat.h @@ -132,5 +132,15 @@ asmlinkage long compat_sys_select(int n, compat_ulong_t __user *inp, compat_ulong_t __user *outp, compat_ulong_t __user *exp, struct compat_timeval __user *tvp); +#define BITS_PER_COMPAT_LONG (8*sizeof(compat_long_t)) + +#define BITS_TO_COMPAT_LONGS(bits) \ + (((bits)+BITS_PER_COMPAT_LONG-1)/BITS_PER_COMPAT_LONG) + +long compat_get_bitmap(unsigned long *mask, compat_ulong_t __user *umask, + unsigned long bitmap_size); +long compat_put_bitmap(compat_ulong_t __user *umask, unsigned long *mask, + unsigned long bitmap_size); + #endif /* CONFIG_COMPAT */ #endif /* _LINUX_COMPAT_H */ |
