Thread (42 messages) 42 messages, 5 authors, 2024-11-24

Re: [PATCH v5 07/16] net: dwmac-intel-plat: Use helper rgmii_clock

From: "Russell King (Oracle)" <linux@armlinux.org.uk>
Date: 2024-11-19 16:45:09
Also in: imx, linux-arm-kernel, linux-arm-msm, linux-devicetree, lkml

On Tue, Nov 19, 2024 at 04:00:13PM +0100, Jan Petrous via B4 Relay wrote:
quoted hunk ↗ jump to hunk
@@ -31,27 +31,15 @@ struct intel_dwmac_data {
 static void kmb_eth_fix_mac_speed(void *priv, unsigned int speed, unsigned int mode)
 {
 	struct intel_dwmac *dwmac = priv;
-	unsigned long rate;
+	long rate;
 	int ret;
So the following becomes:
 
 	rate = clk_get_rate(dwmac->tx_clk);
 
+	rate = rgmii_clock(speed);
+	if (rate < 0) {
 		dev_err(dwmac->dev, "Invalid speed\n");
+		return;
 	}
Now that I've removed the deleted lines, we can see that the
clk_get_rate() call there is now redundant. Please remove in
this change.

Thanks.

-- 
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTP is here! 80Mbps down 10Mbps up. Decent connectivity at last!
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help