linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] x86/intel: Disable HPET on Intel Coffe Lake platforms
@ 2019-10-16 10:38 Kai-Heng Feng
  2019-10-30  8:06 ` Kai-Heng Feng
  2019-11-12 15:00 ` [tip: x86/urgent] x86/quirks: " tip-bot2 for Kai-Heng Feng
  0 siblings, 2 replies; 3+ messages in thread
From: Kai-Heng Feng @ 2019-10-16 10:38 UTC (permalink / raw)
  To: tglx, mingo, bp
  Cc: hpa, harry.pan, feng.tang, x86, linux-kernel, Kai-Heng Feng, stable

Some Coffee Lake platforms have skewed HPET timer once the SoCs entered
PC10, and marked TSC as unstable clocksource as result.

Harry Pan identified it's a firmware bug [1].

To prevent creating a circular dependency between HPET and TSC, let's
disable HPET on affected platforms.

[1]: https://lore.kernel.org/lkml/20190516090651.1396-1-harry.pan@intel.com/
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=203183

Cc: <stable@vger.kernel.org>
Suggested-by: Feng Tang <feng.tang@intel.com>
Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
---
 arch/x86/kernel/early-quirks.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/arch/x86/kernel/early-quirks.c b/arch/x86/kernel/early-quirks.c
index 6f6b1d04dadf..4cba91ec8049 100644
--- a/arch/x86/kernel/early-quirks.c
+++ b/arch/x86/kernel/early-quirks.c
@@ -710,6 +710,8 @@ static struct chipset early_qrk[] __initdata = {
 	 */
 	{ PCI_VENDOR_ID_INTEL, 0x0f00,
 		PCI_CLASS_BRIDGE_HOST, PCI_ANY_ID, 0, force_disable_hpet},
+	{ PCI_VENDOR_ID_INTEL, 0x3ec4,
+		PCI_CLASS_BRIDGE_HOST, PCI_ANY_ID, 0, force_disable_hpet},
 	{ PCI_VENDOR_ID_BROADCOM, 0x4331,
 	  PCI_CLASS_NETWORK_OTHER, PCI_ANY_ID, 0, apple_airport_reset},
 	{}
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] x86/intel: Disable HPET on Intel Coffe Lake platforms
  2019-10-16 10:38 [PATCH] x86/intel: Disable HPET on Intel Coffe Lake platforms Kai-Heng Feng
@ 2019-10-30  8:06 ` Kai-Heng Feng
  2019-11-12 15:00 ` [tip: x86/urgent] x86/quirks: " tip-bot2 for Kai-Heng Feng
  1 sibling, 0 replies; 3+ messages in thread
From: Kai-Heng Feng @ 2019-10-30  8:06 UTC (permalink / raw)
  To: Thomas Gleixner, mingo, Borislav Petkov
  Cc: H. Peter Anvin, Harry Pan, feng.tang, x86, linux-kernel, stable

Hi Thomas,

> On Oct 16, 2019, at 18:38, Kai-Heng Feng <kai.heng.feng@canonical.com> wrote:
> 
> Some Coffee Lake platforms have skewed HPET timer once the SoCs entered
> PC10, and marked TSC as unstable clocksource as result.
> 
> Harry Pan identified it's a firmware bug [1].
> 
> To prevent creating a circular dependency between HPET and TSC, let's
> disable HPET on affected platforms.
> 
> [1]: https://lore.kernel.org/lkml/20190516090651.1396-1-harry.pan@intel.com/
> Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=203183

Do you think it's a sane approach?

Kai-Heng

> 
> Cc: <stable@vger.kernel.org>
> Suggested-by: Feng Tang <feng.tang@intel.com>
> Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
> ---
> arch/x86/kernel/early-quirks.c | 2 ++
> 1 file changed, 2 insertions(+)
> 
> diff --git a/arch/x86/kernel/early-quirks.c b/arch/x86/kernel/early-quirks.c
> index 6f6b1d04dadf..4cba91ec8049 100644
> --- a/arch/x86/kernel/early-quirks.c
> +++ b/arch/x86/kernel/early-quirks.c
> @@ -710,6 +710,8 @@ static struct chipset early_qrk[] __initdata = {
> 	 */
> 	{ PCI_VENDOR_ID_INTEL, 0x0f00,
> 		PCI_CLASS_BRIDGE_HOST, PCI_ANY_ID, 0, force_disable_hpet},
> +	{ PCI_VENDOR_ID_INTEL, 0x3ec4,
> +		PCI_CLASS_BRIDGE_HOST, PCI_ANY_ID, 0, force_disable_hpet},
> 	{ PCI_VENDOR_ID_BROADCOM, 0x4331,
> 	  PCI_CLASS_NETWORK_OTHER, PCI_ANY_ID, 0, apple_airport_reset},
> 	{}
> -- 
> 2.17.1
> 


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [tip: x86/urgent] x86/quirks: Disable HPET on Intel Coffe Lake platforms
  2019-10-16 10:38 [PATCH] x86/intel: Disable HPET on Intel Coffe Lake platforms Kai-Heng Feng
  2019-10-30  8:06 ` Kai-Heng Feng
@ 2019-11-12 15:00 ` tip-bot2 for Kai-Heng Feng
  1 sibling, 0 replies; 3+ messages in thread
From: tip-bot2 for Kai-Heng Feng @ 2019-11-12 15:00 UTC (permalink / raw)
  To: linux-tip-commits
  Cc: Feng Tang, Kai-Heng Feng, Thomas Gleixner, stable, Ingo Molnar,
	Borislav Petkov, linux-kernel

The following commit has been merged into the x86/urgent branch of tip:

Commit-ID:     fc5db58539b49351e76f19817ed1102bf7c712d0
Gitweb:        https://git.kernel.org/tip/fc5db58539b49351e76f19817ed1102bf7c712d0
Author:        Kai-Heng Feng <kai.heng.feng@canonical.com>
AuthorDate:    Wed, 16 Oct 2019 18:38:16 +08:00
Committer:     Thomas Gleixner <tglx@linutronix.de>
CommitterDate: Tue, 12 Nov 2019 15:55:20 +01:00

x86/quirks: Disable HPET on Intel Coffe Lake platforms

Some Coffee Lake platforms have a skewed HPET timer once the SoCs entered
PC10, which in consequence marks TSC as unstable because HPET is used as
watchdog clocksource for TSC.

Harry Pan tried to work around it in the clocksource watchdog code [1]
thereby creating a circular dependency between HPET and TSC. This also
ignores the fact, that HPET is not only unsuitable as watchdog clocksource
on these systems, it becomes unusable in general.

Disable HPET on affected platforms.

Suggested-by: Feng Tang <feng.tang@intel.com>
Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Cc: stable@vger.kernel.org
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=203183
Link: https://lore.kernel.org/lkml/20190516090651.1396-1-harry.pan@intel.com/ [1]
Link: https://lkml.kernel.org/r/20191016103816.30650-1-kai.heng.feng@canonical.com
---
 arch/x86/kernel/early-quirks.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/arch/x86/kernel/early-quirks.c b/arch/x86/kernel/early-quirks.c
index 6f6b1d0..4cba91e 100644
--- a/arch/x86/kernel/early-quirks.c
+++ b/arch/x86/kernel/early-quirks.c
@@ -710,6 +710,8 @@ static struct chipset early_qrk[] __initdata = {
 	 */
 	{ PCI_VENDOR_ID_INTEL, 0x0f00,
 		PCI_CLASS_BRIDGE_HOST, PCI_ANY_ID, 0, force_disable_hpet},
+	{ PCI_VENDOR_ID_INTEL, 0x3ec4,
+		PCI_CLASS_BRIDGE_HOST, PCI_ANY_ID, 0, force_disable_hpet},
 	{ PCI_VENDOR_ID_BROADCOM, 0x4331,
 	  PCI_CLASS_NETWORK_OTHER, PCI_ANY_ID, 0, apple_airport_reset},
 	{}

^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2019-11-12 15:00 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-10-16 10:38 [PATCH] x86/intel: Disable HPET on Intel Coffe Lake platforms Kai-Heng Feng
2019-10-30  8:06 ` Kai-Heng Feng
2019-11-12 15:00 ` [tip: x86/urgent] x86/quirks: " tip-bot2 for Kai-Heng Feng

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).