Skip to contentSkip to conversation

i3c: master: dw-i3c-master: mark expected switch fall-through

PATCH In review Gustavo A. R. Silva 3 participants 5 messages Feb 11, 2019 – Feb 27, 2019

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 i3c: master: dw-i3c-master: mark expected switch fall-through

In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through.

This patch fixes the following warning:

drivers/i3c/master/dw-i3c-master.c: In function ‘dw_i3c_master_bus_init’:
drivers/i3c/master/dw-i3c-master.c:603:6: warning: this statement may fall through [-Wimplicit-fallthrough=]
if (ret)

      ^

drivers/i3c/master/dw-i3c-master.c:605:2: note: here
case I3C_BUS_MODE_PURE:
^~~~

Warning level 3 was used: -Wimplicit-fallthrough=3

This patch is part of the ongoing efforts to enable -Wimplicit-fallthrough.

---
 drivers/i3c/master/dw-i3c-master.c | 1 +
 1 file changed, 1 insertion(+)
drivers/i3c/master/dw-i3c-master.c +1 -0
index bb03079fbade..59279224e07f 100644
@@ -602,6 +602,7 @@ static int dw_i3c_master_bus_init(struct i3c_master_controller *m)
 		ret = dw_i2c_clk_cfg(master);
 		if (ret)
 			return ret;
+		/* fall through */
 	case I3C_BUS_MODE_PURE:
 		ret = dw_i3c_clk_cfg(master);
 		if (ret)
Signature · 1 line
2.20.1
#1 lore raw

Hi all,

Friendly ping:

Who can ack or review this, please?

Thanks
--
Gustavo

Quoted 36 lines · Gustavo A. R. Silva

In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through.

This patch fixes the following warning:

drivers/i3c/master/dw-i3c-master.c: In function ‘dw_i3c_master_bus_init’:
drivers/i3c/master/dw-i3c-master.c:603:6: warning: this statement may fall through [-Wimplicit-fallthrough=]
if (ret)

      ^

drivers/i3c/master/dw-i3c-master.c:605:2: note: here
case I3C_BUS_MODE_PURE:
^~~~

Warning level 3 was used: -Wimplicit-fallthrough=3

This patch is part of the ongoing efforts to enable -Wimplicit-fallthrough.

---
 drivers/i3c/master/dw-i3c-master.c | 1 +
 1 file changed, 1 insertion(+)
drivers/i3c/master/dw-i3c-master.c +1 -0
index bb03079fbade..59279224e07f 100644
@@ -602,6 +602,7 @@ static int dw_i3c_master_bus_init(struct i3c_master_controller *m)
 		ret = dw_i2c_clk_cfg(master);
 		if (ret)
 			return ret;
+		/* fall through */
 	case I3C_BUS_MODE_PURE:
 		ret = dw_i3c_clk_cfg(master);
 		if (ret)
#2 lore raw
Quoted 5 lines · On Tue, 26 Feb 2019 21:53:16 -0600 "Gustavo A. R. Silva"…

Hi all,

Friendly ping:

Who can ack or review this, please?

Will be queued for the next release. Please be patient.

Quoted 42 lines

Thanks
--
Gustavo

Quoted 36 lines · Gustavo A. R. Silva

In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through.

This patch fixes the following warning:

drivers/i3c/master/dw-i3c-master.c: In function ‘dw_i3c_master_bus_init’:
drivers/i3c/master/dw-i3c-master.c:603:6: warning: this statement may fall through [-Wimplicit-fallthrough=]
if (ret)

      ^

drivers/i3c/master/dw-i3c-master.c:605:2: note: here
case I3C_BUS_MODE_PURE:
^~~~

Warning level 3 was used: -Wimplicit-fallthrough=3

This patch is part of the ongoing efforts to enable -Wimplicit-fallthrough.

---
 drivers/i3c/master/dw-i3c-master.c | 1 +
 1 file changed, 1 insertion(+)
drivers/i3c/master/dw-i3c-master.c +1 -0
index bb03079fbade..59279224e07f 100644
@@ -602,6 +602,7 @@ static int dw_i3c_master_bus_init(struct i3c_master_controller *m)
 		ret = dw_i2c_clk_cfg(master);
 		if (ret)
 			return ret;
+		/* fall through */
 	case I3C_BUS_MODE_PURE:
 		ret = dw_i3c_clk_cfg(master);
 		if (ret)
Acked-by
#4 lore raw
In reply to Gustavo A. R. Silva

Hi Gustavo,

Sorry for the delay.

Quoted 34 lines · Gustavo A. R. Silva

Hi all,

Friendly ping:

Who can ack or review this, please?

Thanks
--
Gustavo

Quoted 23 lines · Gustavo A. R. Silva

In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through.

This patch fixes the following warning:

drivers/i3c/master/dw-i3c-master.c: In function ‘dw_i3c_master_bus_init’:
drivers/i3c/master/dw-i3c-master.c:603:6: warning: this statement may fall through [-Wimplicit-fallthrough=]
if (ret)

      ^

drivers/i3c/master/dw-i3c-master.c:605:2: note: here
case I3C_BUS_MODE_PURE:
^~~~

Warning level 3 was used: -Wimplicit-fallthrough=3

This patch is part of the ongoing efforts to enable -Wimplicit-fallthrough.

---
 drivers/i3c/master/dw-i3c-master.c | 1 +
 1 file changed, 1 insertion(+)
Quoted 13 lines

drivers/i3c/master/dw-i3c-master.c static int dw_i3c_master_bus_init(struct i3c_master_controller *m) · line 608

Quoted 13 lines
drivers/i3c/master/dw-i3c-master.c +1 -0
index bb03079fbade..59279224e07f 100644
@@ -602,6 +602,7 @@ static int dw_i3c_master_bus_init(struct i3c_master_controller *m)
 		ret = dw_i2c_clk_cfg(master);
 		if (ret)
 			return ret;
+		/* fall through */
 	case I3C_BUS_MODE_PURE:
 		ret = dw_i3c_clk_cfg(master);
 		if (ret)

Best regards,
Vitor Soares

#3 lore raw
In reply to Boris Brezillon

Hi Boris,

Quoted 11 lines · Boris Brezillon
Quoted 5 lines · On Tue, 26 Feb 2019 21:53:16 -0600 "Gustavo A. R. Silva"…

Hi all,

Friendly ping:

Who can ack or review this, please?

Will be queued for the next release. Please be patient.

Great. Good to know. :)

Sure thing. I waited for two weeks before pinging.

Thanks
--
Gustavo

_______________________________________________
linux-i3c mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-i3c