Hi NV:
We add a piece of code used to control GPIO159 in InstallGpioProtocols() on TegraGpioDxe.c in r36.4.3 UEFI version,
The code is below list:
EMBEDDED_GPIO_PIN gpio33 = GPIO(0xF1, 44);
Status = gBS->LocateProtocol (&gEmbeddedGpioProtocolGuid,NULL,(VOID **)&mGpioProtocol);
if (EFI_ERROR(Status)) {
DEBUG ((DEBUG_ERROR, “Locate GPIO protocol failed: %r\n”, Status));
return Status;
}
Status = mGpioProtocol->Set(mGpioProtocol, gpio33, GPIO_MODE_OUTPUT_0) ;
gBS->Stall(50 * 1000);
Status = mGpioProtocol->Set(mGpioProtocol, gpio33, GPIO_MODE_OUTPUT_1) ;
if (EFI_ERROR(Status)) {
DEBUG ((DEBUG_ERROR, “Set GPIO failed: %r\n”, Status));
return Status;
}
It can work correctly on Jetpack 6.2 with this UEFI bin.
However , we want to port this code into latest UEFI with Jetpack 7.2.
But it show error message below list:
Set GPIO failed: Not Found
TegraGpioDxe:
ASSERT_EFI_ERROR (Status = Not Found)
ASSERT [DebugStatusCodeDxe] [TegraGpioDxe] DeviceDiscoveryDriverLib.c(873): !(((RETURN_STATUS)(Status)) >= 0x8000000000000000ULL)
We have confirmed that the phandle value of gpio@2200000 in JetPack 7.2 is 0xF1, and the corresponding DTSI has been updated to configure this GPIO as an output.
However, the GPIO still does not behave as expected with the latest UEFI source.
Is there any additional GPIO initialization, configuration, or UEFI-specific procedure that needs to be added for this setting to take effect?
Please advise if there is anything else we need to configure in the latest UEFI implementation.
Thanks
Rolance