On Mon, Apr 14, 2025 at 07:26:57PM -0500, Mario Limonciello wrote: > From: Mario Limonciello <mario.limonciello@xxxxxxx> > > The s2idle mmio quirk uses a scratch register in the FCH. > Adjust the code to clarify that. > > Signed-off-by: Mario Limonciello <mario.limonciello@xxxxxxx> > --- > v4: > * Use fch.h instead > --- > arch/x86/include/asm/amd/fch.h | 1 + > drivers/platform/x86/amd/pmc/pmc-quirks.c | 3 ++- > 2 files changed, 3 insertions(+), 1 deletion(-) > > diff --git a/arch/x86/include/asm/amd/fch.h b/arch/x86/include/asm/amd/fch.h > index a5fd91ff92df3..9b32e8a03193e 100644 > --- a/arch/x86/include/asm/amd/fch.h > +++ b/arch/x86/include/asm/amd/fch.h > @@ -8,5 +8,6 @@ > /* register offsets from PM base */ > #define FCH_PM_DECODEEN 0x00 > #define FCH_PM_DECODEEN_SMBUS0SEL GENMASK(20, 19) > +#define FCH_PM_SCRATCH 0x80 > > #endif > diff --git a/drivers/platform/x86/amd/pmc/pmc-quirks.c b/drivers/platform/x86/amd/pmc/pmc-quirks.c > index b4f49720c87f6..3c680d2029f62 100644 > --- a/drivers/platform/x86/amd/pmc/pmc-quirks.c > +++ b/drivers/platform/x86/amd/pmc/pmc-quirks.c > @@ -8,6 +8,7 @@ > * Author: Mario Limonciello <mario.limonciello@xxxxxxx> > */ > > +#include <asm/amd/fch.h> Arch headers should go after linux headers, I think. So that arch stuff can override generic stuff. > #include <linux/dmi.h> > #include <linux/io.h> > #include <linux/ioport.h> Thanks, Yazen