From: Peter Zijlstra <peterz@infradead.org>
To: Ruipeng Qi <qiruipeng@lixiang.com>
Cc: mingo@redhat.com, juri.lelli@redhat.com,
vincent.guittot@linaro.org, dietmar.eggemann@arm.com,
rostedt@goodmis.org, bsegall@google.com, mgorman@suse.de,
bristot@redhat.com, vschneid@redhat.com,
linux-kernel@vger.kernel.org, ruipengqi7@gmail.com
Subject: Re: [PATCH] sched/fair: Change mode of period_timer to HRTIMER_MODE_ABS_PINNED_HARD
Date: Thu, 20 Oct 2022 18:39:12 +0200 [thread overview]
Message-ID: <Y1F5sDVGen7ZVW+U@hirez.programming.kicks-ass.net> (raw)
In-Reply-To: <20221020091742.2962-1-qiruipeng@lixiang.com>
On Thu, Oct 20, 2022 at 05:17:46PM +0800, Ruipeng Qi wrote:
> Previous mode of period_timer is HRTIMER_MODE_ABS_PINNED,which means
> timer callback function will be executed in soft irq context.
>
> When one task group runs out of quota in a period,but holding lock of
> softirq_ctrl,the task will be rescheduled later,and then a system stall
> occurs:
> - next period comes,
> - __do_softirq can't acquire lock of softirq_ctrl,
> - __do_softirq will not be invoked,
> - callback of period_timer will not be invoked,
> - task group will not get any quota in any new period.
> - a system stall occurs.
>
> Changing mode of period_timer to HRTIMER_MODE_ABS_PINNED_HARD,which mean
> timer callback function executed in hard irq context fix this problem.
What I'm missing here is a statement about how the runtime complexity of
that timer function is sufficiently bounded to run in hardirq context on
RT kernels.
next parent reply other threads:[~2022-10-20 16:39 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20221020091742.2962-1-qiruipeng@lixiang.com>
2022-10-20 16:39 ` Peter Zijlstra [this message]
2022-10-31 10:35 ` Valentin Schneider
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=Y1F5sDVGen7ZVW+U@hirez.programming.kicks-ass.net \
--to=peterz@infradead.org \
--cc=bristot@redhat.com \
--cc=bsegall@google.com \
--cc=dietmar.eggemann@arm.com \
--cc=juri.lelli@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mgorman@suse.de \
--cc=mingo@redhat.com \
--cc=qiruipeng@lixiang.com \
--cc=rostedt@goodmis.org \
--cc=ruipengqi7@gmail.com \
--cc=vincent.guittot@linaro.org \
--cc=vschneid@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®