Skip to content
Commit a3ce6f8d authored by Leif Lindholm's avatar Leif Lindholm
Browse files

Silicon/Qemu: Move SbsaQemu MPIDR-retrieval function to FdtHelperLib



Commit 822634fc ("SbsaQemu: Update SbsaQemuAcpiDxe to use FdtHelperLib")
replaced the CountCpusFromFdt() function in SbsaQemuAcpiDxe with a call to
FdtHelperCountCpus() in FdtHelperLib. This ended up leaving static variables
FdtFirstCpuOffset and FdtCpuNodeSize uninitialised, such that the GetMpidr()
function kept returning the value for cpu 0.

Resolve this by moving the GetMpidr() function over to FdtHelperLib, where
it can again share these variables with FdtHelperCountCpus().

Fix up coding style issues as part of copy:
- Add m prefix to module-global variables.
- Add doxygen function comment header.

Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Graeme Gregory <graeme@nuviainc.com>
Cc: Radoslaw Biernacki <rad@semihalf.com>
Cc: Tanmay Jagdale <tanmay.jagdale@linaro.org>
Cc: Rebecca Cran <rebecca@nuviainc.com>
Reported-by: default avatarMarcin Juszkiewicz <marcin.juszkiewicz@linaro.org>
Signed-off-by: default avatarLeif Lindholm <leif@nuviainc.com>
Acked-by: default avatarArd Biesheuvel <ardb@kernel.org>
Tested-By: default avatarGraeme Gregory <graeme@nuviainc.com>
Tested-by: default avatarMarcin Juszkiewicz <marcin.juszkiewicz@linaro.org>
parent d2235657
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment