Re: staging: r8188eu: how to handle nested mutex under spinlock

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

 



On 4/3/22 13:56, Fabio M. De Francesco wrote:
On domenica 3 aprile 2022 13:48:31 CEST Pavel Skripkin wrote:
Hi Michael,

msleep() cannot be called in atomic context:

drivers/staging/r8188eu/core/rtw_pwrctrl.c:379

   	if (pwrpriv->ps_processing) {
   		while (pwrpriv->ps_processing && rtw_get_passing_time_ms(start) <= 3000)
   			msleep(10);
   	}

Ah, just another issue...


I wanted to use mdelay() (allowed under spinlocks because it does not
sleep) but Dan said to leave it as it is. You might easily find this
discussion on this list. I cannot remember why Dan was against replacing
msleep() with mdelay(). Please try to find that thread.


I'll take a breath and look further into it later. Seems a solution like
the one Larry mentioned is reasonable here.

Thank you both,
Michael




[Index of Archives]     [Linux Driver Development]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux