Re: [PATCH v2] bcache: fix panic due to cache_set is null

2020-12-03 Thread Yi Li
On 12/3/20, Coly Li wrote: > On 12/3/20 5:47 PM, Yi Li wrote: >> bcache_device_detach will release the cache_set after hotunplug cache >> disk. >> >> Here is how the issue happens. >> 1) cached_dev_free do cancel_writeback_rate_update_dwork >>without bch_register_lock. >> 2) Wirting the

Re: [PATCH v2] bcache: fix panic due to cache_set is null

2020-12-03 Thread Coly Li
On 12/3/20 5:47 PM, Yi Li wrote: > bcache_device_detach will release the cache_set after hotunplug cache > disk. > > Here is how the issue happens. > 1) cached_dev_free do cancel_writeback_rate_update_dwork >without bch_register_lock. > 2) Wirting the writeback_percent by sysfs with >

[PATCH v2] bcache: fix panic due to cache_set is null

2020-12-03 Thread Yi Li
bcache_device_detach will release the cache_set after hotunplug cache disk. Here is how the issue happens. 1) cached_dev_free do cancel_writeback_rate_update_dwork without bch_register_lock. 2) Wirting the writeback_percent by sysfs with bch_register_lock will insert a writeback_rate_update