Re: [PATCH v2 2/2] RAS/AMD/ATL: Translate normalized to system physical addresses using PRM
From: Borislav Petkov
Date: Wed Jul 03 2024 - 18:46:51 EST
On Wed, Jul 03, 2024 at 03:14:53PM -0500, John Allen wrote:
> I'm not sure this works the way we need it to. If ACPI_PRMT is not
> enabled, then the norm to sys translation function will be referenced by
> the base AMD ATL, but will the symbol will not be found since the the
> PRM file doesn't get compiled.
So you don't delete the stub but you put it in the internal.h header:
#ifndef CONFIG_AMD_ATL_PRM
+unsigned long prm_umc_norm_to_sys_addr(u8 socket_id, u64 umc_bank_inst_id, unsigned long addr)
+{
+ return -ENODEV;
+}
+
+#endif
Don't be afraid to grep the tree - there are gazillion examples how stuff like
that is usually done.
--
Regards/Gruss,
Boris.
https://people.kernel.org/tglx/notes-about-netiquette