Message ID | 20250109182117.3971075-2-robh@kernel.org (mailing list archive) |
---|---|
State | Accepted |
Commit | 9007d911f6d2a99d3dd1dbf2097de35727cc665a |
Delegated to: | Netdev Maintainers |
Headers | show |
Series | [net-next] net: dsa: qca8k: Use of_property_present() for non-boolean properties | expand |
On Thu, Jan 09, 2025 at 12:21:17PM -0600, Rob Herring (Arm) wrote: > The use of of_property_read_bool() for non-boolean properties is > deprecated in favor of of_property_present() when testing for property > presence. > > Signed-off-by: Rob Herring (Arm) <robh@kernel.org> Reviewed-by: Andrew Lunn <andrew@lunn.ch> Andrew
Hello: This patch was applied to netdev/net-next.git (main) by David S. Miller <davem@davemloft.net>: On Thu, 9 Jan 2025 12:21:17 -0600 you wrote: > The use of of_property_read_bool() for non-boolean properties is > deprecated in favor of of_property_present() when testing for property > presence. > > Signed-off-by: Rob Herring (Arm) <robh@kernel.org> > --- > drivers/net/dsa/qca/qca8k-8xxx.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) Here is the summary with links: - [net-next] net: dsa: qca8k: Use of_property_present() for non-boolean properties https://git.kernel.org/netdev/net-next/c/9007d911f6d2 You are awesome, thank you!
diff --git a/drivers/net/dsa/qca/qca8k-8xxx.c b/drivers/net/dsa/qca/qca8k-8xxx.c index 2d56a8152420..750fc76a6e11 100644 --- a/drivers/net/dsa/qca/qca8k-8xxx.c +++ b/drivers/net/dsa/qca/qca8k-8xxx.c @@ -1019,7 +1019,7 @@ qca8k_setup_mdio_bus(struct qca8k_priv *priv) of_get_phy_mode(port, &mode); - if (of_property_read_bool(port, "phy-handle") && + if (of_property_present(port, "phy-handle") && mode != PHY_INTERFACE_MODE_INTERNAL) external_mdio_mask |= BIT(reg); else
The use of of_property_read_bool() for non-boolean properties is deprecated in favor of of_property_present() when testing for property presence. Signed-off-by: Rob Herring (Arm) <robh@kernel.org> --- drivers/net/dsa/qca/qca8k-8xxx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)