mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Jules Maselbas <jmaselbas@zdiv.net>
To: barebox@lists.infradead.org
Cc: Jules Maselbas <jmaselbas@zdiv.net>
Subject: [PATCH 2/2] eeprom: at25: add explicit fallthrough
Date: Fri, 14 Mar 2025 11:45:02 +0100	[thread overview]
Message-ID: <20250314104502.14851-2-jmaselbas@zdiv.net> (raw)
In-Reply-To: <20250314104502.14851-1-jmaselbas@zdiv.net>

Signed-off-by: Jules Maselbas <jmaselbas@zdiv.net>
---
 drivers/eeprom/at25.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/drivers/eeprom/at25.c b/drivers/eeprom/at25.c
index 43e72677c9..f58e554616 100644
--- a/drivers/eeprom/at25.c
+++ b/drivers/eeprom/at25.c
@@ -87,8 +87,10 @@ static ssize_t at25_ee_read(struct cdev *cdev,
 	switch (at25->addrlen) {
 	default:	/* case 3 */
 		*cp++ = offset >> 16;
+		fallthrough;
 	case 2:
 		*cp++ = offset >> 8;
+		fallthrough;
 	case 1:
 	case 0:	/* can't happen: for better codegen */
 		*cp++ = offset >> 0;
@@ -168,8 +170,10 @@ static ssize_t at25_ee_write(struct cdev *cdev,
 		switch (at25->addrlen) {
 		default:	/* case 3 */
 			*cp++ = offset >> 16;
+			fallthrough;
 		case 2:
 			*cp++ = offset >> 8;
+			fallthrough;
 		case 1:
 		case 0:	/* can't happen: for better codegen */
 			*cp++ = offset >> 0;
-- 
2.48.1




      reply	other threads:[~2025-03-14 11:04 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-03-14 10:45 [PATCH 1/2] eeprom: at25: replace strncpy with strlcpy Jules Maselbas
2025-03-14 10:45 ` Jules Maselbas [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20250314104502.14851-2-jmaselbas@zdiv.net \
    --to=jmaselbas@zdiv.net \
    --cc=barebox@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox