Back to home page

OSCL-LXR

 
 

    


0001 /* SPDX-License-Identifier: GPL-2.0 */
0002 #ifndef __ASM_COMPAT_SIGNAL_H
0003 #define __ASM_COMPAT_SIGNAL_H
0004 
0005 #include <linux/bug.h>
0006 #include <linux/compat.h>
0007 #include <linux/compiler.h>
0008 
0009 #include <asm/signal.h>
0010 #include <asm/siginfo.h>
0011 
0012 #include <linux/uaccess.h>
0013 
0014 static inline int __copy_conv_sigset_to_user(compat_sigset_t __user *d,
0015     const sigset_t *s)
0016 {
0017     BUILD_BUG_ON(sizeof(*d) != sizeof(*s));
0018     BUILD_BUG_ON(_NSIG_WORDS != 2);
0019 
0020     return put_compat_sigset(d, s, sizeof(*d));
0021 }
0022 
0023 static inline int __copy_conv_sigset_from_user(sigset_t *d,
0024     const compat_sigset_t __user *s)
0025 {
0026     return get_compat_sigset(d, s);
0027 }
0028 
0029 #endif /* __ASM_COMPAT_SIGNAL_H */