Whamcloud - gitweb
LU-4249 quota: race in qsd_upd_thread() 88/10988/1
authorNiu Yawei <yawei.niu@intel.com>
Fri, 4 Jul 2014 03:51:10 +0000 (23:51 -0400)
committerNiu Yawei <yawei.niu@intel.com>
Fri, 4 Jul 2014 03:51:10 +0000 (23:51 -0400)
commitf8f7c34a7bbcf22aeca7699ce76254e41e3e95b7
tree753f4011a4bb59f7ef8fcd3a1b4f5ec08451df9b
parent7ae1cb98b33c21e0ae1d17deb9bb59565a8ecdb0
LU-4249 quota: race in qsd_upd_thread()

qsd_upd_thread() uses list_for_each_entry_safe() to process
list items one by one, however, it has to drop lock while
processing each item, that'll race with other list processing
thread.

The proper way is to check list head each time when it acquired
lock.

Signed-off-by: Niu Yawei <yawei.niu@intel.com>
Change-Id: I55dfe3f65cc214c5d0fd8a9afdda795af94bbdce
lustre/quota/qsd_writeback.c