]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
parisc: fix off by one in setup_sigcontext32
authorKyle McMartin <kyle@minerva.i.cabal.ca>
Tue, 27 May 2008 05:56:29 +0000 (01:56 -0400)
committerKyle McMartin <kyle@minerva.i.cabal.ca>
Fri, 13 Jun 2008 14:49:55 +0000 (10:49 -0400)
Thankfully, the values were irrelevant... Spotted by
newer gcc.

Signed-off-by: Kyle McMartin <kyle@mcmartin.ca>
arch/parisc/kernel/signal32.c

index db94affe5c713a4692a08c73a6ac07e0fde5f2bc..fb59852006defd58fbf9b035c8b3ec49455c5cfe 100644 (file)
@@ -289,7 +289,7 @@ setup_sigcontext32(struct compat_sigcontext __user *sc, struct compat_regfile __
                                &sc->sc_iaoq[0], compat_reg);
                
                /* Store upper half */
-               compat_reg = (compat_uint_t)(regs->gr[32] >> 32);
+               compat_reg = (compat_uint_t)(regs->gr[31] >> 32);
                err |= __put_user(compat_reg, &rf->rf_iaoq[0]);
                DBG(2,"setup_sigcontext32: upper half iaoq[0] = %#x\n", compat_reg);
                
@@ -299,7 +299,7 @@ setup_sigcontext32(struct compat_sigcontext __user *sc, struct compat_regfile __
                DBG(2,"setup_sigcontext32: sc->sc_iaoq[1] = %p <= %#x\n",
                                &sc->sc_iaoq[1], compat_reg);
                /* Store upper half */
-               compat_reg = (compat_uint_t)((regs->gr[32]+4) >> 32);
+               compat_reg = (compat_uint_t)((regs->gr[31]+4) >> 32);
                err |= __put_user(compat_reg, &rf->rf_iaoq[1]);
                DBG(2,"setup_sigcontext32: upper half iaoq[1] = %#x\n", compat_reg);