|
@@ -154,11 +154,12 @@ static long setup_sigcontext(struct sigcontext __user *sc, struct pt_regs *regs,
|
|
* As above, but Transactional Memory is in use, so deliver sigcontexts
|
|
* As above, but Transactional Memory is in use, so deliver sigcontexts
|
|
* containing checkpointed and transactional register states.
|
|
* containing checkpointed and transactional register states.
|
|
*
|
|
*
|
|
- * To do this, we treclaim to gather both sets of registers and set up the
|
|
|
|
- * 'normal' sigcontext registers with rolled-back register values such that a
|
|
|
|
- * simple signal handler sees a correct checkpointed register state.
|
|
|
|
- * If interested, a TM-aware sighandler can examine the transactional registers
|
|
|
|
- * in the 2nd sigcontext to determine the real origin of the signal.
|
|
|
|
|
|
+ * To do this, we treclaim (done before entering here) to gather both sets of
|
|
|
|
+ * registers and set up the 'normal' sigcontext registers with rolled-back
|
|
|
|
+ * register values such that a simple signal handler sees a correct
|
|
|
|
+ * checkpointed register state. If interested, a TM-aware sighandler can
|
|
|
|
+ * examine the transactional registers in the 2nd sigcontext to determine the
|
|
|
|
+ * real origin of the signal.
|
|
*/
|
|
*/
|
|
static long setup_tm_sigcontexts(struct sigcontext __user *sc,
|
|
static long setup_tm_sigcontexts(struct sigcontext __user *sc,
|
|
struct sigcontext __user *tm_sc,
|
|
struct sigcontext __user *tm_sc,
|
|
@@ -184,16 +185,6 @@ static long setup_tm_sigcontexts(struct sigcontext __user *sc,
|
|
|
|
|
|
BUG_ON(!MSR_TM_ACTIVE(regs->msr));
|
|
BUG_ON(!MSR_TM_ACTIVE(regs->msr));
|
|
|
|
|
|
- /* tm_reclaim rolls back all reg states, saving checkpointed (older)
|
|
|
|
- * GPRs to thread.ckpt_regs and (if used) FPRs to (newer)
|
|
|
|
- * thread.transact_fp and/or VRs to (newer) thread.transact_vr.
|
|
|
|
- * THEN we save out FP/VRs, if necessary, to the checkpointed (older)
|
|
|
|
- * thread.fr[]/vr[]s. The transactional (newer) GPRs are on the
|
|
|
|
- * stack, in *regs.
|
|
|
|
- */
|
|
|
|
- tm_enable();
|
|
|
|
- tm_reclaim(¤t->thread, msr, TM_CAUSE_SIGNAL);
|
|
|
|
-
|
|
|
|
flush_fp_to_thread(current);
|
|
flush_fp_to_thread(current);
|
|
|
|
|
|
#ifdef CONFIG_ALTIVEC
|
|
#ifdef CONFIG_ALTIVEC
|
|
@@ -711,7 +702,7 @@ int handle_rt_signal64(int signr, struct k_sigaction *ka, siginfo_t *info,
|
|
unsigned long newsp = 0;
|
|
unsigned long newsp = 0;
|
|
long err = 0;
|
|
long err = 0;
|
|
|
|
|
|
- frame = get_sigframe(ka, regs, sizeof(*frame), 0);
|
|
|
|
|
|
+ frame = get_sigframe(ka, get_tm_stackpointer(regs), sizeof(*frame), 0);
|
|
if (unlikely(frame == NULL))
|
|
if (unlikely(frame == NULL))
|
|
goto badframe;
|
|
goto badframe;
|
|
|
|
|