* [PATCH] net: efi-snp: fix mac address change when it is not supported.
@ 2025-09-27 16:33 chalianis1
2025-09-29 13:51 ` Sascha Hauer
0 siblings, 1 reply; 2+ messages in thread
From: chalianis1 @ 2025-09-27 16:33 UTC (permalink / raw)
To: s.hauer; +Cc: barebox, Chali Anis
From: Chali Anis <chalianis1@gmail.com>
continue interface open if the efiret is unsupported since the mac address
change is not always supported, this permits to not fail when the network
could be used since it already has a network mac address configured, this
is at least the case on qemu with certain versions of EDK2.
Signed-off-by: Chali Anis <chalianis1@gmail.com>
---
drivers/net/efi-snp.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/efi-snp.c b/drivers/net/efi-snp.c
index 119358b6c880..b4d2abfecf77 100644
--- a/drivers/net/efi-snp.c
+++ b/drivers/net/efi-snp.c
@@ -219,7 +219,7 @@ static int efi_snp_eth_open(struct eth_device *edev)
efiret = priv->snp->station_address(priv->snp, false,
(struct efi_mac_address *)priv->snp->Mode->PermanentAddress.Addr );
- if (EFI_ERROR(efiret)) {
+ if (EFI_ERROR(efiret) && efiret != EFI_UNSUPPORTED) {
dev_err(priv->dev, "failed to set MAC address: %s\n",
efi_strerror(efiret));
return -efi_errno(efiret);
--
2.34.1
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2025-09-29 13:52 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-09-27 16:33 [PATCH] net: efi-snp: fix mac address change when it is not supported chalianis1
2025-09-29 13:51 ` Sascha Hauer
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox