Source-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: src/sys/dev/sysmon



Module Name:    src
Committed By:   bouyer
Date:           Thu Oct 15 13:35:30 UTC 2015

Modified Files:
        src/sys/dev/sysmon: sysmon_envsys_events.c

Log Message:
As proposed in
https://mail-index.netbsd.org/tech-kern/2015/10/14/msg019511.html
don't sleep on sme->sme_mtx in the callout but use mutex_tryenter()
and just reschedule the callout if we can't get the mutex now.
This fixes a deadlock which can happen if the backed wants to
sleep with timeout (e.g. cv_timedwait()) as the backed is called with
sme->sme_mtx held.

This is a stopgap measure for netbsd-7; sysmon should be changed to not
sleep (or call a backend which will sleep) with mutexes held.


To generate a diff of this commit:
cvs rdiff -u -r1.117 -r1.118 src/sys/dev/sysmon/sysmon_envsys_events.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.




Home | Main Index | Thread Index | Old Index