Skip to content
Commit ee4a36f4 authored by Coly Li's avatar Coly Li Committed by Jens Axboe
Browse files

bcache: use delayed kworker fo asynchronous devices registration

This patch changes the asynchronous registration kworker to a delayed
kworker. There is probability queue_work() queues the async registration
kworker to the same CPU (even though very little), then the process
which writing sysfs interface to reigster bcache device may won't return
immeidately. queue_delayed_work() in this patch will delay 10 jiffies
before insert the kworker to run queue, which makes sure the registering
process may always returns to user space in time.

Fixes: 9e23ccf8

 ("bcache: asynchronous devices registration")
Signed-off-by: default avatarColy Li <colyli@suse.de>
Cc: Hannes Reinecke <hare@suse.de>
Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>
parent dcacbc12
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment