Re: [PATCH V2] libcfs: Fix a sleep-in-atomic bug in cfs_wi_exit

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

 



On Wed, May 31, 2017 at 04:00:41PM +0800, Jia-Ju Bai wrote:
> The driver may sleep under a spin lock, and the function call path is:
> cfs_wi_exit (acquire the lock by spin_lock)
>   LASSERT
>     lbug_with_loc
>       libcfs_debug_dumplog
>         schedule and kthread_run --> may sleep
> 
> To fix it, all "LASSERT" is placed out of the spin_lock and spin_unlock.
> 
> Signed-off-by: Jia-Ju Bai <baijiaju1990@xxxxxxx>
> ---
>  drivers/staging/lustre/lnet/libcfs/workitem.c |   13 +++++++------
>  1 file changed, 7 insertions(+), 6 deletions(-)

What changed from v1?  You have to always tell us that.

Please redo all of these, if they are still valid patches, and send them
as a patch series, so I know what order they should be applied in.

thanks,

greg k-h
_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel



[Index of Archives]     [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