Temporarily release the mutex while calling sensor_task_register() as it
authoranton <anton@openbsd.org>
Tue, 11 May 2021 16:40:57 +0000 (16:40 +0000)
committeranton <anton@openbsd.org>
Tue, 11 May 2021 16:40:57 +0000 (16:40 +0000)
commit2daff7cd998682c91211d93da1d8947f3197e396
tree455e59f3df3792b0b0d87fa5b96c2d313b1d7b54
parent50cb9313b3f918161119099aed6b9402fa9ac97d
Temporarily release the mutex while calling sensor_task_register() as it
might end up sleeping in malloc(). This can only happen if uhidpp is the
first one calling the aforementioned routine which causes the sensors
task queue to be allocated.

Thanks to Justin Yang <linuxjustin at gmail dot com> for the report.
sys/dev/usb/uhidpp.c