mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Ahmad Fatoum <>
Cc: Ahmad Fatoum <>
Subject: [PATCH] I2C: i.MX: early: replace zero-valued variable use with zero directly
Date: Sat, 30 Oct 2021 16:19:54 +0200	[thread overview]
Message-ID: <> (raw)

There is a if (ret) return -EAGAIN a few lines above, so if we reach the
final return, ret must be zero.

Signed-off-by: Ahmad Fatoum <>
 drivers/i2c/busses/i2c-imx-early.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/i2c/busses/i2c-imx-early.c b/drivers/i2c/busses/i2c-imx-early.c
index 472e4be83a70..b381f99f4003 100644
--- a/drivers/i2c/busses/i2c-imx-early.c
+++ b/drivers/i2c/busses/i2c-imx-early.c
@@ -126,7 +126,7 @@ static int i2c_fsl_start(struct fsl_i2c *fsl_i2c)
 	temp |= I2CR_MTX | I2CR_TXAK;
 	fsl_i2c_write_reg(temp, fsl_i2c, FSL_I2C_I2CR);
-	return ret;
+	return 0;
 static void i2c_fsl_stop(struct fsl_i2c *fsl_i2c)

barebox mailing list

             reply	other threads:[~2021-10-30 14:21 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-10-30 14:19 Ahmad Fatoum [this message]
2021-11-01  9:10 ` Sascha Hauer

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:

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

  git send-email \ \ \ \

* 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