Skip to contentSkip to conversation

platform/x86: p2sb: Cache correct PCI bar for P2SB on Denverton and Gemini Lake

PATCH Superseded Hans de Goede 2 participants 2 messages Nov 14, 2024 x86 platform drivers

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 platform/x86: p2sb: Cache correct PCI bar for P2SB on Denverton and Gemini Lake

Gemine Lake (Goldmont Plus) is an Apollo Lake (Goldmont) derived design and as such has the P2SB at device.function 13.0, rather then at the default 31.1, just like Apollo Lake.

At a mapping to P2SB_DEVFN_GOLDMONT to p2sb_cpu_ids[] for Goldmont Plus, so that the correct PCI bar gets cached.

This fixes P2SB unhiding not working on these devices, which fixes SPI support for the bootrom SPI controller not working.

Fixes 2841631a0365 ("platform/x86: p2sb: Allow p2sb_bar() calls during PCI device probe")
---
 drivers/platform/x86/p2sb.c | 1 +
 1 file changed, 1 insertion(+)
drivers/platform/x86/p2sb.c +1 -0
index 31f38309b389..d51eb0db0626 100644
@@ -25,6 +25,7 @@
 
 static const struct x86_cpu_id p2sb_cpu_ids[] = {
 	X86_MATCH_VFM(INTEL_ATOM_GOLDMONT, P2SB_DEVFN_GOLDMONT),
+	X86_MATCH_VFM(INTEL_ATOM_GOLDMONT_PLUS, P2SB_DEVFN_GOLDMONT),
 	{}
 };
 
Signature · 1 line
2.47.0
Reviewed-by on v1 1/1
#1 lore raw
Quoted 2 lines · Hans de Goede

Gemine Lake (Goldmont Plus) is an Apollo Lake (Goldmont) derived design and

Gemini

Quoted 8 lines

as such has the P2SB at device.function 13.0, rather then at the default 31.1, just like Apollo Lake.

At a mapping to P2SB_DEVFN_GOLDMONT to p2sb_cpu_ids[] for Goldmont Plus, so that the correct PCI bar gets cached.

This fixes P2SB unhiding not working on these devices, which fixes SPI support for the bootrom SPI controller not working.

--
With Best Regards,
Andy Shevchenko