Commit 518c66b9 authored by Jens Axboe's avatar Jens Axboe Committed by sanglipeng
Browse files

ia64: don't call handle_signal() unless there's actually a signal queued

stable inclusion
from stable-v5.10.162
commit a1240cc413ebb3ec15ee156d3f18f2d5bf1dfe1f
category: bugfix
bugzilla: https://gitee.com/openeuler/kernel/issues/I7P7OH

Reference: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=a1240cc413ebb3ec15ee156d3f18f2d5bf1dfe1f



--------------------------------

[ Upstream commit f5f4fc46 ]

Sergei and John both reported that ia64 failed to boot in 5.11, and it
was related to signals. Turns out the ia64 signal handling is a bit odd,
it doesn't check the return value of get_signal() for whether there's a
signal to deliver or not. With the introduction of TIF_NOTIFY_SIGNAL,
then task_work could trigger it.

Fix it by only calling handle_signal() if we actually have a real signal
to deliver. This brings it in line with all other archs, too.

Fixes: b269c229 ("ia64: add support for TIF_NOTIFY_SIGNAL")
Reported-by: default avatarSergei Trofimovich <slyich@gmail.com>
Reported-by: default avatarJohn Paul Adrian Glaubitz <glaubitz@physik.fu-berlin.de>
Tested-by: default avatarSergei Trofimovich <slyich@gmail.com>
Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: default avatarsanglipeng <sanglipeng1@jd.com>
parent 4629ecaf
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment