File tree Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -7204,18 +7204,18 @@ void perf_event_wakeup(struct perf_event *event)
72047204static void perf_sigtrap (struct perf_event * event )
72057205{
72067206 /*
7207- * We'd expect this to only occur if the irq_work is delayed and either
7208- * ctx->task or current has changed in the meantime. This can be the
7209- * case on architectures that do not implement arch_irq_work_raise().
7207+ * Both perf_pending_task() and perf_pending_irq() can race with the
7208+ * task exiting.
72107209 */
7211- if (WARN_ON_ONCE ( event -> ctx -> task != current ) )
7210+ if (current -> flags & PF_EXITING )
72127211 return ;
72137212
72147213 /*
7215- * Both perf_pending_task() and perf_pending_irq() can race with the
7216- * task exiting.
7214+ * We'd expect this to only occur if the irq_work is delayed and either
7215+ * ctx->task or current has changed in the meantime. This can be the
7216+ * case on architectures that do not implement arch_irq_work_raise().
72177217 */
7218- if (current -> flags & PF_EXITING )
7218+ if (WARN_ON_ONCE ( event -> ctx -> task != current ) )
72197219 return ;
72207220
72217221 send_sig_perf ((void __user * )event -> pending_addr ,
You can’t perform that action at this time.
0 commit comments