mirror of
https://github.com/acidanthera/audk.git
synced 2025-07-28 16:14:04 +02:00
ArmPlatformPkg/PL061Gpio: fix the offset value in Get function
When call PL061GetPins() or PL061SetPins(), should use GPIO_PIN_MASK(offset) as parameter, not offset. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Haojian Zhuang <haojian.zhuang@linaro.org> Reviewed-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
This commit is contained in:
parent
d164a0e31b
commit
d176bb3c5c
@ -186,7 +186,7 @@ Get (
|
|||||||
return EFI_INVALID_PARAMETER;
|
return EFI_INVALID_PARAMETER;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (PL061GetPins (RegisterBase, Offset)) {
|
if (PL061GetPins (RegisterBase, GPIO_PIN_MASK(Offset))) {
|
||||||
*Value = 1;
|
*Value = 1;
|
||||||
} else {
|
} else {
|
||||||
*Value = 0;
|
*Value = 0;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user