Whamcloud - gitweb
LU-18516 quota: use wait_woken for qsd_op_begin0()
Kernels with debugging enabled report for Lustre quota handling:
do not call blocking ops when !TASK_RUNNING;
? __might_sleep+0x9d/0xc0
down_read_nested+0x2e/0x4b0
lquota_disk_read+0x46e/0x800 [lquota]
qsd_refresh_usage+0x105/0x3d0 [lquota]
qsd_acquire+0xbe/0x7c0 [lquota]
qsd_op_begin0+0x5f8/0xc80 [lquota]
This is due to qsd_acquire() performing operations that can sleep while
the kthread is in an idle state. The Linux kernel solution for this
is wait_woken(). Move the function qsd_op_begin0() from using
wait_event_idle_timeout() to wait_woken(). This will resolve the
potential sleeping issues.
Test-Parameters: trivial testlist=sanity-quota
Change-Id: Id2b7a5886869bf0ed3d560e159524dcda841d8b0
Signed-off-by: James Simmons <jsimmons@infradead.org>
Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/58156
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Timothy Day <timday@amazon.com>
Reviewed-by: Sergey Cheremencev <scherementsev@ddn.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>