diff options
author | Eric W. Biederman <ebiederm@xmission.com> | 2018-01-13 18:25:09 -0600 |
---|---|---|
committer | Eric W. Biederman <ebiederm@xmission.com> | 2018-01-15 17:42:35 -0600 |
commit | 71ee78d538a7bcb7a876dcbd65eb73627425df6f (patch) | |
tree | 8f68f79851b83c3b1f28c9a523cbd4126ea7cccd /kernel/signal.c | |
parent | 753e5a8543dae136142751961bb18ff25b0062dc (diff) | |
download | lwn-71ee78d538a7bcb7a876dcbd65eb73627425df6f.tar.gz lwn-71ee78d538a7bcb7a876dcbd65eb73627425df6f.zip |
signal/blackfin: Move the blackfin specific si_codes to asm-generic/siginfo.h
Having si_codes in many different files simply encourages duplicate definitions
that can cause problems later. To avoid that merge the blackfin specific si_codes
into uapi/asm-generic/siginfo.h
Update copy_siginfo_to_user to copy with the absence of BUS_MCEERR_AR that blackfin
defines to be something else.
Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Diffstat (limited to 'kernel/signal.c')
-rw-r--r-- | kernel/signal.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/kernel/signal.c b/kernel/signal.c index 47c87b1d0b8a..4c3f4448c5f1 100644 --- a/kernel/signal.c +++ b/kernel/signal.c @@ -2770,13 +2770,16 @@ int copy_siginfo_to_user(siginfo_t __user *to, const siginfo_t *from) err |= __put_user(from->si_flags, &to->si_flags); err |= __put_user(from->si_isr, &to->si_isr); #endif -#ifdef BUS_MCEERR_AO /* * Other callers might not initialize the si_lsb field, * so check explicitly for the right codes here. */ - if (from->si_signo == SIGBUS && - (from->si_code == BUS_MCEERR_AR || from->si_code == BUS_MCEERR_AO)) +#ifdef BUS_MCEERR_AR + if (from->si_signo == SIGBUS && from->si_code == BUS_MCEERR_AR) + err |= __put_user(from->si_addr_lsb, &to->si_addr_lsb); +#endif +#ifdef BUS_MCEERR_AO + if (from->si_signo == SIGBUS && from->si_code == BUS_MCEERR_AO) err |= __put_user(from->si_addr_lsb, &to->si_addr_lsb); #endif #ifdef SEGV_BNDERR |