ArmPkg/BdsLib: Update FDT CPU node format

- Based on Doc here:
  Repo: http://www.linux-arm.org/git?p=linux-2.6-lp.git
  Branch: dt-cpus-bindings
  File:   Documentation/devicetree/bindings/arm/cpus.txt

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Olivier Martin <olivier.martin@arm.com>


git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@14434 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
Olivier Martin 2013-06-19 18:09:19 +00:00 committed by oliviermartin
parent e703b085f6
commit 86d75840ab
1 changed files with 4 additions and 3 deletions

View File

@ -535,7 +535,9 @@ PrepareFdt (
ArmCoreInfoTable = ArmProcessorTable->ArmCpus;
for (Index = 0; Index < ArmProcessorTable->NumberOfEntries; Index++) {
AsciiSPrint (Name, 10, "cpu@%d", Index);
CoreMpId = (UINTN) GET_MPID (ArmCoreInfoTable[Index].ClusterId,
ArmCoreInfoTable[Index].CoreId);
AsciiSPrint (Name, 10, "cpu@%x", CoreMpId);
// If the 'cpus' node did not exist then create all the 'cpu' nodes.
// In case 'cpus' node is provided in the original FDT then we do not add
@ -549,8 +551,7 @@ PrepareFdt (
}
fdt_setprop_string (fdt, cpu_node, "device_type", "cpu");
CoreMpId = (UINTN) GET_MPID (ArmCoreInfoTable[Index].ClusterId,
ArmCoreInfoTable[Index].CoreId);
CoreMpId = cpu_to_fdtn (CoreMpId);
fdt_setprop (fdt, cpu_node, "reg", &CoreMpId, sizeof (CoreMpId));
if (PsciSmcSupported) {