[RESEND PATCH v2 0/2] Update the watchdog period according to real CPU frequency

Andrew Morton akpm at linux-foundation.org
Mon Jun 23 16:30:28 PDT 2025


On Thu, 19 Jun 2025 19:48:03 +0800 Yicong Yang <yangyicong at huawei.com> wrote:

> watchdog perf needs architecture to provide method for converting the watchdog
> thresh to counter period. For arm64 we're using the max CPU frequency for
> doing the conversion which is from cpufreq driver. But some cpufreq driver
> are registered lately, for example cppc_cpufreq will be registered at late
> initcall which is after the initialization of watchdog perf (initialized in
> armv8_pmuv3 of device initcall). In such case the period of watchdog will not
> be accurate enough. Fix this by registering a cpufreq notifier and update the
> watchdog period once the cpufreq driver is initialized.

Great, thanks.  I'll add these to mm.git for testing.

> arch/arm64/kernel/watchdog_hld.c | 58 ++++++++++++++++++++++++++++++++
> include/linux/nmi.h              |  2 ++
> kernel/watchdog_perf.c           | 23 +++++++++++++

This is not exactly my comfort zone so additional review would be
appreciated, please.  Even though it doesn't touch drivers/cpufreq,
perhaps the developers over there could take a look?



More information about the linux-arm-kernel mailing list