1 From 1f5669efca65564c7533704917f79003c6b36c9c Mon Sep 17 00:00:00 2001
2 From: =?UTF-8?q?Ar=C4=B1n=C3=A7=20=C3=9CNAL?= <arinc.unal@arinc9.com>
3 Date: Mon, 22 Apr 2024 10:15:15 +0300
4 Subject: [PATCH 08/15] net: dsa: mt7530: return mt7530_setup_mdio &
5 mt7531_setup_common on error
7 Content-Type: text/plain; charset=UTF-8
8 Content-Transfer-Encoding: 8bit
10 The mt7530_setup_mdio() and mt7531_setup_common() functions should be
11 checked for errors. Return if the functions return a non-zero value.
13 Signed-off-by: Arınç ÜNAL <arinc.unal@arinc9.com>
15 drivers/net/dsa/mt7530.c | 6 +++++-
16 1 file changed, 5 insertions(+), 1 deletion(-)
18 --- a/drivers/net/dsa/mt7530.c
19 +++ b/drivers/net/dsa/mt7530.c
20 @@ -2667,7 +2667,9 @@ mt7531_setup(struct dsa_switch *ds)
24 - mt7531_setup_common(ds);
25 + ret = mt7531_setup_common(ds);
29 /* Setup VLAN ID 0 for VLAN-unaware bridges */
30 ret = mt7530_setup_vlan0(priv);
31 @@ -3020,6 +3022,8 @@ mt753x_setup(struct dsa_switch *ds)
32 ret = mt7530_setup_mdio(priv);
34 mt7530_free_irq_common(priv);
38 /* Initialise the PCS devices */
39 for (i = 0; i < priv->ds->num_ports; i++) {