int is not sufficient to hold and test the return from an EFI function call. Use efi_status_t instead so that the test can work as expected.
This issue was found by Smatch. Signed-off-by: Andrew Goodbody <andrew.goodb...@linaro.org> --- drivers/serial/serial_efi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/serial/serial_efi.c b/drivers/serial/serial_efi.c index 5733eaaf9d4..d3cd4de34a2 100644 --- a/drivers/serial/serial_efi.c +++ b/drivers/serial/serial_efi.c @@ -33,7 +33,7 @@ int serial_efi_setbrg(struct udevice *dev, int baudrate) static int serial_efi_get_key(struct serial_efi_priv *priv) { - int ret; + efi_status_t ret; if (priv->have_key) return 0; --- base-commit: 83ce0b483c1680cb39565a9d91c6ef113a309c38 change-id: 20250811-serial_efi-e40053cd0939 Best regards, -- Andrew Goodbody <andrew.goodb...@linaro.org>