summaryrefslogtreecommitdiffstats
path: root/kernel/entry
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2020-10-23 19:06:38 +0200
committerLinus Torvalds <torvalds@linux-foundation.org>2020-10-23 19:06:38 +0200
commit4a22709e21c2b1bedf90f68c823daf65d8e6b491 (patch)
treeb480c70465c11cb6b4d9e4f47b8e1824df2d5eea /kernel/entry
parentMerge tag 'arc-5.10-rc1-fixes' of git://git.kernel.org/pub/scm/linux/kernel/g... (diff)
parenttask_work: cleanup notification modes (diff)
downloadlinux-4a22709e21c2b1bedf90f68c823daf65d8e6b491.tar.xz
linux-4a22709e21c2b1bedf90f68c823daf65d8e6b491.zip
Merge tag 'arch-cleanup-2020-10-22' of git://git.kernel.dk/linux-block
Pull arch task_work cleanups from Jens Axboe: "Two cleanups that don't fit other categories: - Finally get the task_work_add() cleanup done properly, so we don't have random 0/1/false/true/TWA_SIGNAL confusing use cases. Updates all callers, and also fixes up the documentation for task_work_add(). - While working on some TIF related changes for 5.11, this TIF_NOTIFY_RESUME cleanup fell out of that. Remove some arch duplication for how that is handled" * tag 'arch-cleanup-2020-10-22' of git://git.kernel.dk/linux-block: task_work: cleanup notification modes tracehook: clear TIF_NOTIFY_RESUME in tracehook_notify_resume()
Diffstat (limited to 'kernel/entry')
-rw-r--r--kernel/entry/common.c1
-rw-r--r--kernel/entry/kvm.c4
2 files changed, 1 insertions, 4 deletions
diff --git a/kernel/entry/common.c b/kernel/entry/common.c
index 0a1e20f8d4e8..2b8366693d5c 100644
--- a/kernel/entry/common.c
+++ b/kernel/entry/common.c
@@ -161,7 +161,6 @@ static unsigned long exit_to_user_mode_loop(struct pt_regs *regs,
arch_do_signal(regs);
if (ti_work & _TIF_NOTIFY_RESUME) {
- clear_thread_flag(TIF_NOTIFY_RESUME);
tracehook_notify_resume(regs);
rseq_handle_notify_resume(NULL, regs);
}
diff --git a/kernel/entry/kvm.c b/kernel/entry/kvm.c
index eb1a8a4c867c..b6678a5e3cf6 100644
--- a/kernel/entry/kvm.c
+++ b/kernel/entry/kvm.c
@@ -16,10 +16,8 @@ static int xfer_to_guest_mode_work(struct kvm_vcpu *vcpu, unsigned long ti_work)
if (ti_work & _TIF_NEED_RESCHED)
schedule();
- if (ti_work & _TIF_NOTIFY_RESUME) {
- clear_thread_flag(TIF_NOTIFY_RESUME);
+ if (ti_work & _TIF_NOTIFY_RESUME)
tracehook_notify_resume(NULL);
- }
ret = arch_xfer_to_guest_mode_handle_work(vcpu, ti_work);
if (ret)