Commit de958436 authored by Josua Mayer's avatar Josua Mayer

linux: fix bug in serdes driver breaking all SFPs of Honeycomb board

parent b94fc621
From 6ed01309ffc501a37084fc61f38eea95601e9c77 Mon Sep 17 00:00:00 2001
From: Josua Mayer <josua@solid-run.com>
Date: Sat, 25 Nov 2023 15:36:56 +0100
Subject: [PATCH] phy: lynx-28g: fix probe when fsl,unmanaged-lanes isn't
specified
The recently added fsl,unmanaged-lanes property is intended to be
optional. In case of_property_read_u32 returns -EINVAL, the property
does not exist and probe may continue.
Fixes: "phy: lynx-28g: add support for specifying unmanaged lanes"
Signed-off-by: Josua Mayer <josua@solid-run.com>
---
drivers/phy/freescale/phy-fsl-lynx-28g.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/phy/freescale/phy-fsl-lynx-28g.c b/drivers/phy/freescale/phy-fsl-lynx-28g.c
index 7e088fa4efce..b050fdf68b40 100644
--- a/drivers/phy/freescale/phy-fsl-lynx-28g.c
+++ b/drivers/phy/freescale/phy-fsl-lynx-28g.c
@@ -661,7 +661,7 @@ static int lynx_28g_probe(struct platform_device *pdev)
fwnode = dev_fwnode(dev);
if (fwnode && is_of_node(fwnode)) {
ret = of_property_read_u32(to_of_node(fwnode), "fsl,unmanaged-lanes", &unmanaged_lanes);
- if (ret) {
+ if (ret && ret != -EINVAL) {
dev_info(dev, "failed to read fsl,unmanaged-lanes property: %d\n", ret);
return ret;
}
--
2.35.3
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment