[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <bb696622-38ee-c582-ce70-5bfa632f8989@kernel.dk>
Date: Mon, 13 Dec 2021 11:43:02 -0700
From: Jens Axboe <axboe@...nel.dk>
To: Dexuan Cui <decui@...rosoft.com>,
"'ming.lei@...hat.com'" <ming.lei@...hat.com>,
'Christoph Hellwig' <hch@....de>,
"'linux-block@...r.kernel.org'" <linux-block@...r.kernel.org>
Cc: Long Li <longli@...rosoft.com>,
"Michael Kelley (LINUX)" <mikelley@...rosoft.com>,
"'linux-kernel@...r.kernel.org'" <linux-kernel@...r.kernel.org>
Subject: Re: Random high CPU utilization in blk-mq with the none scheduler
On 12/11/21 11:54 AM, Dexuan Cui wrote:
>> From: Jens Axboe <axboe@...nel.dk>
>> Sent: Saturday, December 11, 2021 6:21 AM
>>
>> Sorry, can you do:
>>
>> # perf report -g --no-children
>>
>> instead?
>
> Attached.
I wonder if this will help, SCSI artifact making us hit the
mod delayed work path all the time. Might be a race in there,
but should be fine for testing.
diff --git a/block/blk-core.c b/block/blk-core.c
index 4d8f5fe91588..cb2f4d604bad 100644
--- a/block/blk-core.c
+++ b/block/blk-core.c
@@ -1625,7 +1625,9 @@ EXPORT_SYMBOL(kblockd_schedule_work);
int kblockd_mod_delayed_work_on(int cpu, struct delayed_work *dwork,
unsigned long delay)
{
- return mod_delayed_work_on(cpu, kblockd_workqueue, dwork, delay);
+ if (!work_pending(&dwork->work))
+ return mod_delayed_work_on(cpu, kblockd_workqueue, dwork, delay);
+ return true;
}
EXPORT_SYMBOL(kblockd_mod_delayed_work_on);
--
Jens Axboe
Powered by blists - more mailing lists