[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
port-xen/48873: xbdback kernel thread created with wrong priority
>Synopsis: xbdback kernel thread created with wrong priority
>Arrival-Date: Thu Jun 05 00:00:00 +0000 2014
>Originator: Andy Tucker
I noticed that the xbdback_xenbus driver (the backend driver for the Xen
virtual block device) is passing the wrong value for the thread priority when
creating a worker thread. It has:
if (kthread_create(IPL_NONE, KTHREAD_MPSAFE, NULL,
xbdback_thread, xbdi, NULL, "%s", xbdi->xbdi_name) == 0)
but the first argument of kthread_create is a thread priority, not an IPL.
IPL_NONE evaluates to 0 on amd64, which results in a priority of 0. I assume
that what was intended was PRI_NONE, which will result in a priority of
PRI_KTHREAD or 96.
A priority of 0 could result in a priority inversion problem with user threads,
where a spinning user level process prevents the xbdback thread from running
and processing block I/O requests.
Change IPL_NONE to PRI_NONE.
Main Index |
Thread Index |