[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20220509071652.GE76023@worktop.programming.kicks-ass.net>
Date: Mon, 9 May 2022 09:16:52 +0200
From: Peter Zijlstra <peterz@...radead.org>
To: Feng Tang <feng.tang@...el.com>
Cc: Thomas Gleixner <tglx@...utronix.de>,
Ingo Molnar <mingo@...hat.com>, Borislav Petkov <bp@...en8.de>,
Dave Hansen <dave.hansen@...el.com>,
"H . Peter Anvin" <hpa@...or.com>,
Jonathan Corbet <corbet@....net>, x86@...nel.org,
linux-kernel@...r.kernel.org, paulmck@...nel.org,
rui.zhang@...el.com, len.brown@...el.com, tim.c.chen@...el.com
Subject: Re: [PATCH] x86/tsc: Add option to force HW timer based recalibration
On Mon, May 09, 2022 at 12:58:39PM +0800, Feng Tang wrote:
> Sorry, just spotted some typos, here is the updated version
>
>
> From ee8e3d772c623d27d79c43da5a76fb6252175aba Mon Sep 17 00:00:00 2001
> From: Feng Tang <feng.tang@...el.com>
> Date: Sun, 8 May 2022 20:22:12 +0800
> Subject: [PATCH] x86/tsc: Add option to force HW timer based recalibration
>
> Currently when HW provides the tsc freq info through MSR or CPUID(0x15),
> the info will be taken as the 'best guess', and kernel will set the
> X86_FEATURE_TSC_KNOWN_FREQ flag and skip the HW timer based recalibration,
> which works pretty well.
>
> And there is still very few corner case that the freq info is not
> accurate enough with small deviation from the actual value, like on
> a product with early buggy version of firmware or on some
> pre-production hardware.
>
> Add an option 'recalibrate' for 'tsc' kernel parameter to force the
> tsc freq recalibration with HPET/PM_TIMER, and warn if the deviation
> from previous value is more than about 500 PPM.
>
> Signed-off-by: Feng Tang <feng.tang@...el.com>
Why isn't 'tsc_early_khz=' not working for you? Afaict that will
override calibrate_tsc() when provided and as such can be used on these
early platforms for provide the right value until such time that the
firmware is fixed.
Powered by blists - more mailing lists