diff options
author | Linus Walleij <linus.walleij@linaro.org> | 2015-12-17 14:57:46 +0100 |
---|---|---|
committer | Linus Walleij <linus.walleij@linaro.org> | 2015-12-17 14:57:46 +0100 |
commit | 4dccc93f1e7f4e2fd92a48c40a7ac9211a029352 (patch) | |
tree | 717a183f0dba200a882126cf095f38e319302c51 /arch/powerpc/kernel/signal_64.c | |
parent | pinctrl: fixup problematic flag (diff) | |
parent | Linux 4.4-rc5 (diff) | |
download | linux-4dccc93f1e7f4e2fd92a48c40a7ac9211a029352.tar.xz linux-4dccc93f1e7f4e2fd92a48c40a7ac9211a029352.zip |
Merge tag 'v4.4-rc5' into devel
Linux 4.4-rc5
Diffstat (limited to 'arch/powerpc/kernel/signal_64.c')
-rw-r--r-- | arch/powerpc/kernel/signal_64.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/arch/powerpc/kernel/signal_64.c b/arch/powerpc/kernel/signal_64.c index 20756dfb9f34..c676ecec0869 100644 --- a/arch/powerpc/kernel/signal_64.c +++ b/arch/powerpc/kernel/signal_64.c @@ -438,6 +438,10 @@ static long restore_tm_sigcontexts(struct pt_regs *regs, /* get MSR separately, transfer the LE bit if doing signal return */ err |= __get_user(msr, &sc->gp_regs[PT_MSR]); + /* Don't allow reserved mode. */ + if (MSR_TM_RESV(msr)) + return -EINVAL; + /* pull in MSR TM from user context */ regs->msr = (regs->msr & ~MSR_TS_MASK) | (msr & MSR_TS_MASK); |