The branch main has been updated by trasz: URL: https://cgit.FreeBSD.org/src/commit/?id=14c40d2c292deff44be5591add7fdad5f9b371aa
commit 14c40d2c292deff44be5591add7fdad5f9b371aa Author: shu <[email protected]> AuthorDate: 2021-02-03 19:10:58 +0000 Commit: Edward Tomasz Napierala <[email protected]> CommitDate: 2021-02-03 19:47:38 +0000 linux: remove locks around callout_drain in timerfd_close() The lock around callout_drain() is unnecessary and may cause deadlock when one closes a timer descriptor during timer execution. Reviewed By: delphij Submitted By: ankohuu_outlook.com (Shunchao Hu) Differential Revision: https://reviews.freebsd.org/D28148 --- sys/compat/linux/linux_event.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/sys/compat/linux/linux_event.c b/sys/compat/linux/linux_event.c index 54f6b083adf3..f6cd9304f5cd 100644 --- a/sys/compat/linux/linux_event.c +++ b/sys/compat/linux/linux_event.c @@ -736,9 +736,7 @@ timerfd_close(struct file *fp, struct thread *td) timespecclear(&tfd->tfd_time.it_value); timespecclear(&tfd->tfd_time.it_interval); - mtx_lock(&tfd->tfd_lock); callout_drain(&tfd->tfd_callout); - mtx_unlock(&tfd->tfd_lock); seldrain(&tfd->tfd_sel); knlist_destroy(&tfd->tfd_sel.si_note); _______________________________________________ [email protected] mailing list https://lists.freebsd.org/mailman/listinfo/dev-commits-src-main To unsubscribe, send any mail to "[email protected]"
