提交 5e071e2b 编写于 作者: A Al Viro 提交者: Paul Mundt

sh: Fix up TIF_NOTIFY_RESUME sans TIF_SIGPENDING handling.

As Al notes, we missed a TIF_NOTIFY_RESUME check which caused any
handlers without TIF_SIGPENDING also set to skip the notification:

	Looks like while it is in the relevant masks *and* checked in
	do_notify_resume() both on 32bit and 64bit variants since commit
	ab99c733 ("sh: Make syscall tracer
	use tracehook notifiers, add TIF_NOTIFY_RESUME.") they are
	actually *not* reached without simulataneous SIGPENDING, since
	the actual glue in the callers had not been updated back then and
	still checks for _TIF_SIGPENDING alone when deciding whether to
	hit do_notify_resume() or not.
Reported-by: NNobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com>
Signed-off-by: NAl Viro <viro@zeniv.linux.org.uk>
Tested-by: NNobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com>
Signed-off-by: NPaul Mundt <lethal@linux-sh.org>
上级 077664a2
...@@ -933,7 +933,7 @@ ret_with_reschedule: ...@@ -933,7 +933,7 @@ ret_with_reschedule:
pta restore_all, tr1 pta restore_all, tr1
movi _TIF_SIGPENDING, r8 movi (_TIF_SIGPENDING|_TIF_NOTIFY_RESUME), r8
and r8, r7, r8 and r8, r7, r8
pta work_notifysig, tr0 pta work_notifysig, tr0
bne r8, ZERO, tr0 bne r8, ZERO, tr0
......
...@@ -139,7 +139,7 @@ work_pending: ...@@ -139,7 +139,7 @@ work_pending:
! r8: current_thread_info ! r8: current_thread_info
! t: result of "tst #_TIF_NEED_RESCHED, r0" ! t: result of "tst #_TIF_NEED_RESCHED, r0"
bf/s work_resched bf/s work_resched
tst #_TIF_SIGPENDING, r0 tst #(_TIF_SIGPENDING | _TIF_NOTIFY_RESUME), r0
work_notifysig: work_notifysig:
bt/s __restore_all bt/s __restore_all
mov r15, r4 mov r15, r4
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册