Commit d523f2eb authored by Michael Walle's avatar Michael Walle Committed by David S. Miller

net: phy: mxl-gpy: print firmware in human readable form

Now having a major and a minor number, also print the firmware in
human readable form "major.minor". Still keep the 4-digit hexadecimal
representation because that form is used in the firmware changelog
documents. Also, drop the "release" string assuming that most common
case, but make it clearer that the user is running a test version.
Signed-off-by: default avatarMichael Walle <michael@walle.cc>
Reviewed-by: default avatarAndrew Lunn <andrew@lunn.ch>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 1e9aa7ba
...@@ -230,8 +230,9 @@ static int gpy_probe(struct phy_device *phydev) ...@@ -230,8 +230,9 @@ static int gpy_probe(struct phy_device *phydev)
return ret; return ret;
/* Show GPY PHY FW version in dmesg */ /* Show GPY PHY FW version in dmesg */
phydev_info(phydev, "Firmware Version: 0x%04X (%s)\n", fw_version, phydev_info(phydev, "Firmware Version: %d.%d (0x%04X%s)\n",
(fw_version & PHY_FWV_REL_MASK) ? "release" : "test"); priv->fw_major, priv->fw_minor, fw_version,
fw_version & PHY_FWV_REL_MASK ? "" : " test version");
return 0; return 0;
} }
......
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