From: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
To: Huacai Chen <chenhuacai@kernel.org>
Cc: Huacai Chen <chenhuacai@loongson.cn>,
Xuerui Wang <kernel@xen0n.name>,
loongarch@lists.linux.dev, Clark Williams <clrkwllms@kernel.org>,
Steven Rostedt <rostedt@goodmis.org>,
linux-rt-devel@lists.linux.dev, Guo Ren <guoren@kernel.org>,
Jiaxun Yang <jiaxun.yang@flygoat.com>,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH 3/3] LoongArch: Allow to enable PREEMPT_RT
Date: Thu, 14 Nov 2024 14:29:56 +0100 [thread overview]
Message-ID: <20241114132956.wafcHvaB@linutronix.de> (raw)
In-Reply-To: <CAAhV-H4jDNG8nsW30U9zE1-c6dHwy2fSjy5hkZhpWWu3=og64A@mail.gmail.com>
On 2024-11-14 19:36:38 [+0800], Huacai Chen wrote:
> On Thu, Nov 14, 2024 at 7:30 PM Sebastian Andrzej Siewior
> <bigeasy@linutronix.de> wrote:
> >
> > On 2024-11-14 19:19:26 [+0800], Huacai Chen wrote:
> > > > > > Why is ntpd/chronyd service affecting this? Is it running at prio 99?
> > > > > > Otherwise it should not be noticed.
> > > > > No, ntpd/chronyd doesn't affect latency. But they may trigger RTC
> > > > > synchronization every 11 minutes, and RTC synchronization affects
> > > > > latency. We can keep ntpd/chronyd running but disable RTC
> > > > > synchronization by configuration, this is the least aggressive method.
> > > >
> > > > What is "RTC synchronization" in this context?
> > > Means the sync_hw_clock() function in kernel/time/ntp.c, it can be
> > > enabled/disabled by chronyd configuration:
> >
> > But what exactly is sync_hw_clock() doing that is causing a problem
> > here? The clock on HW is updated. The access to the RTC clock is
> > preemptible.
> This is a platform-specific problem, our RTC driver is
> drivers/rtc/rtc-loongson.c, the write operation to RTC register is
> slow.
Ach okay. So the pure read on the slow bus causes a delay because the
CPU is stalled. That is not limited to chrony but should also have an
affect if the user uses hwclock to read/ write the time.
> Huacai
Sebastian
next prev parent reply other threads:[~2024-11-14 13:29 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-11-08 9:15 [PATCH 0/3] LoongArch: Add PREEMPT_RT support Huacai Chen
2024-11-08 9:15 ` [PATCH 1/3] LoongArch: Reduce min_delta for the arch clockevent device Huacai Chen
2024-11-14 10:21 ` Sebastian Andrzej Siewior
2024-11-14 11:46 ` Huacai Chen
2024-11-14 13:27 ` Sebastian Andrzej Siewior
2024-11-15 6:44 ` Huacai Chen
2024-11-08 9:15 ` [PATCH 2/3] LoongArch: Select HAVE_POSIX_CPU_TIMERS_TASK_WORK Huacai Chen
2024-11-08 9:15 ` [PATCH 3/3] LoongArch: Allow to enable PREEMPT_RT Huacai Chen
2024-11-08 15:05 ` Steven Rostedt
2024-11-14 10:31 ` Sebastian Andrzej Siewior
2024-11-14 11:07 ` Huacai Chen
2024-11-14 11:14 ` Sebastian Andrzej Siewior
2024-11-14 11:19 ` Huacai Chen
2024-11-14 11:30 ` Sebastian Andrzej Siewior
2024-11-14 11:36 ` Huacai Chen
2024-11-14 13:29 ` Sebastian Andrzej Siewior [this message]
2024-11-14 14:43 ` Clark Williams
2024-11-18 7:36 ` Sebastian Andrzej Siewior
[not found] ` <CAPAFJkp_MQ8rNsTTY3xfYMhdtiWQunN65Yfft1SqZLptG2J5cw@mail.gmail.com>
2024-11-20 7:36 ` Sebastian Andrzej Siewior
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=20241114132956.wafcHvaB@linutronix.de \
--to=bigeasy@linutronix.de \
--cc=chenhuacai@kernel.org \
--cc=chenhuacai@loongson.cn \
--cc=clrkwllms@kernel.org \
--cc=guoren@kernel.org \
--cc=jiaxun.yang@flygoat.com \
--cc=kernel@xen0n.name \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rt-devel@lists.linux.dev \
--cc=loongarch@lists.linux.dev \
--cc=rostedt@goodmis.org \
/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
Powered by JetHome