All of lore.kernel.org
 help / color / mirror / Atom feed
From: William Qiu <william.qiu@starfivetech.com>
To: <devicetree@vger.kernel.org>, <linux-mmc@vger.kernel.org>,
	<linux-kernel@vger.kernel.org>
Cc: Rob Herring <robh+dt@kernel.org>,
	Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>,
	Jaehoon Chung <jh80.chung@samsung.com>,
	Ulf Hansson <ulf.hansson@linaro.org>,
	William Qiu <william.qiu@starfivetech.com>,
	Conor Dooley <conor.dooley@microchip.com>,
	<linux-riscv@lists.infradead.org>
Subject: [PATCH v5 2/2] mmc: starfive: Add initialization of prev_err
Date: Tue, 7 Mar 2023 10:46:46 +0800	[thread overview]
Message-ID: <20230307024646.10216-3-william.qiu@starfivetech.com> (raw)
In-Reply-To: <20230307024646.10216-1-william.qiu@starfivetech.com>

Add a incremental updates to fix a bug that prev_err is uninitialized.

Signed-off-by: William Qiu <william.qiu@starfivetech.com>
Reported-by: Dan Carpenter <error27@gmail.com>
---
 drivers/mmc/host/dw_mmc-starfive.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mmc/host/dw_mmc-starfive.c b/drivers/mmc/host/dw_mmc-starfive.c
index 40f5969b07a6..dab1508bf83c 100644
--- a/drivers/mmc/host/dw_mmc-starfive.c
+++ b/drivers/mmc/host/dw_mmc-starfive.c
@@ -51,7 +51,7 @@ static int dw_mci_starfive_execute_tuning(struct dw_mci_slot *slot,
 	struct dw_mci *host = slot->host;
 	struct starfive_priv *priv = host->priv;
 	int rise_point = -1, fall_point = -1;
-	int err, prev_err;
+	int err, prev_err = 0;
 	int i;
 	bool found = 0;
 	u32 regval;
-- 
2.34.1


WARNING: multiple messages have this Message-ID (diff)
From: William Qiu <william.qiu@starfivetech.com>
To: <devicetree@vger.kernel.org>, <linux-mmc@vger.kernel.org>,
	<linux-kernel@vger.kernel.org>
Cc: Rob Herring <robh+dt@kernel.org>,
	Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>,
	Jaehoon Chung <jh80.chung@samsung.com>,
	Ulf Hansson <ulf.hansson@linaro.org>,
	William Qiu <william.qiu@starfivetech.com>,
	Conor Dooley <conor.dooley@microchip.com>,
	<linux-riscv@lists.infradead.org>
Subject: [PATCH v5 2/2] mmc: starfive: Add initialization of prev_err
Date: Tue, 7 Mar 2023 10:46:46 +0800	[thread overview]
Message-ID: <20230307024646.10216-3-william.qiu@starfivetech.com> (raw)
In-Reply-To: <20230307024646.10216-1-william.qiu@starfivetech.com>

Add a incremental updates to fix a bug that prev_err is uninitialized.

Signed-off-by: William Qiu <william.qiu@starfivetech.com>
Reported-by: Dan Carpenter <error27@gmail.com>
---
 drivers/mmc/host/dw_mmc-starfive.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mmc/host/dw_mmc-starfive.c b/drivers/mmc/host/dw_mmc-starfive.c
index 40f5969b07a6..dab1508bf83c 100644
--- a/drivers/mmc/host/dw_mmc-starfive.c
+++ b/drivers/mmc/host/dw_mmc-starfive.c
@@ -51,7 +51,7 @@ static int dw_mci_starfive_execute_tuning(struct dw_mci_slot *slot,
 	struct dw_mci *host = slot->host;
 	struct starfive_priv *priv = host->priv;
 	int rise_point = -1, fall_point = -1;
-	int err, prev_err;
+	int err, prev_err = 0;
 	int i;
 	bool found = 0;
 	u32 regval;
-- 
2.34.1


_______________________________________________
linux-riscv mailing list
linux-riscv@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-riscv

  parent reply	other threads:[~2023-03-07  2:46 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-03-07  2:46 [PATCH v5 0/2] StarFive's SDIO/eMMC driver support William Qiu
2023-03-07  2:46 ` William Qiu
2023-03-07  2:46 ` [PATCH v5 1/2] dt-bindings: syscon: Add StarFive syscon doc William Qiu
2023-03-07  2:46   ` William Qiu
2023-03-07  9:00   ` Krzysztof Kozlowski
2023-03-07  9:00     ` Krzysztof Kozlowski
2023-03-08  5:59     ` William Qiu
2023-03-08  5:59       ` William Qiu
2023-03-07  2:46 ` William Qiu [this message]
2023-03-07  2:46   ` [PATCH v5 2/2] mmc: starfive: Add initialization of prev_err William Qiu
2023-03-07 12:51   ` Emil Renner Berthing
2023-03-07 12:51     ` Emil Renner Berthing
2023-03-09 15:02   ` Ulf Hansson
2023-03-09 15:02     ` Ulf Hansson

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=20230307024646.10216-3-william.qiu@starfivetech.com \
    --to=william.qiu@starfivetech.com \
    --cc=conor.dooley@microchip.com \
    --cc=devicetree@vger.kernel.org \
    --cc=jh80.chung@samsung.com \
    --cc=krzysztof.kozlowski+dt@linaro.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mmc@vger.kernel.org \
    --cc=linux-riscv@lists.infradead.org \
    --cc=robh+dt@kernel.org \
    --cc=ulf.hansson@linaro.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.