* [PATCH] mtd: spi-nor: add explicit fallthrough
@ 2025-03-25 15:55 Jules Maselbas
2025-03-27 7:43 ` Sascha Hauer
0 siblings, 1 reply; 2+ messages in thread
From: Jules Maselbas @ 2025-03-25 15:55 UTC (permalink / raw)
To: barebox; +Cc: Jules Maselbas
Add the fallthrough pseudo keyword: the case sets `need_wren = true;`
which is used (only read and never written) in the case below.
Signed-off-by: Jules Maselbas <jmaselbas@zdiv.net>
---
drivers/mtd/spi-nor/spi-nor.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/mtd/spi-nor/spi-nor.c b/drivers/mtd/spi-nor/spi-nor.c
index b9b2c7f6e5..6fcb8f38fa 100644
--- a/drivers/mtd/spi-nor/spi-nor.c
+++ b/drivers/mtd/spi-nor/spi-nor.c
@@ -316,6 +316,7 @@ static inline int set_4byte(struct spi_nor *nor, struct flash_info *info,
case CFI_MFR_ST: /* Micron, actually */
/* Some Micron need WREN command; all will accept it */
need_wren = true;
+ fallthrough;
case CFI_MFR_MACRONIX:
case 0xEF /* winbond */:
if (need_wren)
--
2.48.1
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] mtd: spi-nor: add explicit fallthrough
2025-03-25 15:55 [PATCH] mtd: spi-nor: add explicit fallthrough Jules Maselbas
@ 2025-03-27 7:43 ` Sascha Hauer
0 siblings, 0 replies; 2+ messages in thread
From: Sascha Hauer @ 2025-03-27 7:43 UTC (permalink / raw)
To: barebox, Jules Maselbas
On Tue, 25 Mar 2025 16:55:39 +0100, Jules Maselbas wrote:
> Add the fallthrough pseudo keyword: the case sets `need_wren = true;`
> which is used (only read and never written) in the case below.
>
>
Applied, thanks!
[1/1] mtd: spi-nor: add explicit fallthrough
https://git.pengutronix.de/cgit/barebox/commit/?id=323be0d02510 (link may not be stable)
Best regards,
--
Sascha Hauer <s.hauer@pengutronix.de>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2025-03-27 7:45 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-03-25 15:55 [PATCH] mtd: spi-nor: add explicit fallthrough Jules Maselbas
2025-03-27 7:43 ` Sascha Hauer
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox