From: Jens Axboe Date: Wed, 24 Aug 2016 21:52:48 +0000 (-0600) Subject: block: add kblockd_schedule_work_on() X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=ee63cfa7fc197b63669623721b8009cce5b0659b;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git block: add kblockd_schedule_work_on() Add a helper to schedule a regular struct work on a particular CPU. Signed-off-by: Jens Axboe --- diff --git a/block/blk-core.c b/block/blk-core.c index 36c7ac328d8c..2d08597533a4 100644 --- a/block/blk-core.c +++ b/block/blk-core.c @@ -3097,6 +3097,12 @@ int kblockd_schedule_work(struct work_struct *work) } EXPORT_SYMBOL(kblockd_schedule_work); +int kblockd_schedule_work_on(int cpu, struct work_struct *work) +{ + return queue_work_on(cpu, kblockd_workqueue, work); +} +EXPORT_SYMBOL(kblockd_schedule_work_on); + int kblockd_schedule_delayed_work(struct delayed_work *dwork, unsigned long delay) { diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h index e79055c8b577..69aae720f4ef 100644 --- a/include/linux/blkdev.h +++ b/include/linux/blkdev.h @@ -1440,8 +1440,8 @@ static inline bool req_gap_front_merge(struct request *req, struct bio *bio) return bio_will_gap(req->q, bio, req->bio); } -struct work_struct; int kblockd_schedule_work(struct work_struct *work); +int kblockd_schedule_work_on(int cpu, struct work_struct *work); int kblockd_schedule_delayed_work(struct delayed_work *dwork, unsigned long delay); int kblockd_schedule_delayed_work_on(int cpu, struct delayed_work *dwork, unsigned long delay);