mirror of https://github.com/acidanthera/audk.git
ArmPkg/ArmLib: rename AArch64 variant of ArmReadIdPfr0
ArmReadIdPfr0 is now used only inside ArmLib. Rename the AArch64 variant ArmReadIdAA64Pfr0 and add a declaration of that only into local header AArch64/AArch64Lib.h. Cc: Ard Biesheuvel <ard.biesheuvel@arm.com> Signed-off-by: Leif Lindholm <leif@nuviainc.com> Reviewed-by: Ard Biesheuvel <ard.biesheuvel@arm.com>
This commit is contained in:
parent
982b0a5778
commit
bb56ce816b
|
@ -85,5 +85,5 @@ ArmHasGicSystemRegisters (
|
||||||
VOID
|
VOID
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
return ((ArmReadIdPfr0 () & AARCH64_PFR0_GIC) != 0);
|
return ((ArmReadIdAA64Pfr0 () & AARCH64_PFR0_GIC) != 0);
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,6 +2,7 @@
|
||||||
|
|
||||||
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
|
Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
|
||||||
Portions Copyright (c) 2011 - 2013, ARM Ltd. All rights reserved.<BR>
|
Portions Copyright (c) 2011 - 2013, ARM Ltd. All rights reserved.<BR>
|
||||||
|
Copyright (c) 2020, NUVIA Inc. All rights reserved.<BR>
|
||||||
|
|
||||||
SPDX-License-Identifier: BSD-2-Clause-Patent
|
SPDX-License-Identifier: BSD-2-Clause-Patent
|
||||||
|
|
||||||
|
@ -35,5 +36,10 @@ ArmCleanInvalidateDataCacheEntryBySetWay (
|
||||||
IN UINTN SetWayFormat
|
IN UINTN SetWayFormat
|
||||||
);
|
);
|
||||||
|
|
||||||
|
UINTN
|
||||||
|
EFIAPI
|
||||||
|
ArmReadIdAA64Pfr0 (
|
||||||
|
VOID
|
||||||
|
);
|
||||||
#endif // __AARCH64_LIB_H__
|
#endif // __AARCH64_LIB_H__
|
||||||
|
|
||||||
|
|
|
@ -3,6 +3,7 @@
|
||||||
# Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
|
# Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
|
||||||
# Copyright (c) 2011 - 2017, ARM Limited. All rights reserved.
|
# Copyright (c) 2011 - 2017, ARM Limited. All rights reserved.
|
||||||
# Copyright (c) 2016, Linaro Limited. All rights reserved.
|
# Copyright (c) 2016, Linaro Limited. All rights reserved.
|
||||||
|
# Copyright (c) 2020, NUVIA Inc. All rights reserved.
|
||||||
#
|
#
|
||||||
# SPDX-License-Identifier: BSD-2-Clause-Patent
|
# SPDX-License-Identifier: BSD-2-Clause-Patent
|
||||||
#
|
#
|
||||||
|
@ -395,7 +396,7 @@ ASM_FUNC(ArmReadVBar)
|
||||||
ASM_FUNC(ArmEnableVFP)
|
ASM_FUNC(ArmEnableVFP)
|
||||||
// Check whether floating-point is implemented in the processor.
|
// Check whether floating-point is implemented in the processor.
|
||||||
mov x1, x30 // Save LR
|
mov x1, x30 // Save LR
|
||||||
bl ArmReadIdPfr0 // Read EL1 Processor Feature Register (PFR0)
|
bl ArmReadIdAA64Pfr0 // Read EL1 Processor Feature Register (PFR0)
|
||||||
mov x30, x1 // Restore LR
|
mov x30, x1 // Restore LR
|
||||||
ubfx x0, x0, #16, #4 // Extract the FP bits 16:19
|
ubfx x0, x0, #16, #4 // Extract the FP bits 16:19
|
||||||
cmp x0, #0xF // Check if FP bits are '1111b',
|
cmp x0, #0xF // Check if FP bits are '1111b',
|
||||||
|
@ -448,7 +449,7 @@ ASM_FUNC(ArmIsArchTimerImplemented)
|
||||||
ret
|
ret
|
||||||
|
|
||||||
|
|
||||||
ASM_FUNC(ArmReadIdPfr0)
|
ASM_FUNC(ArmReadIdAA64Pfr0)
|
||||||
mrs x0, id_aa64pfr0_el1 // Read ID_AA64PFR0 Register
|
mrs x0, id_aa64pfr0_el1 // Read ID_AA64PFR0 Register
|
||||||
ret
|
ret
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue