mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Tzung-Bi Shih <tzungbi@google.com>
To: bleung@chromium.org
Cc: groeck@chromium.org, tzungbi@google.com, linux-kernel@vger.kernel.org
Subject: [PATCH 4/6] platform/chrome: cros_ec: don't initialize `err` in cros_ec_register()
Date: Tue, 25 Jan 2022 18:15:25 +0800	[thread overview]
Message-ID: <20220125101527.1812887-5-tzungbi@google.com> (raw)
In-Reply-To: <20220125101527.1812887-1-tzungbi@google.com>

`err` in cros_ec_register() doesn't need to be initialized.

Signed-off-by: Tzung-Bi Shih <tzungbi@google.com>
---
 drivers/platform/chrome/cros_ec.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/platform/chrome/cros_ec.c b/drivers/platform/chrome/cros_ec.c
index abbe71309e40..c2c7a748e48f 100644
--- a/drivers/platform/chrome/cros_ec.c
+++ b/drivers/platform/chrome/cros_ec.c
@@ -182,7 +182,7 @@ static int cros_ec_ready_event(struct notifier_block *nb,
 int cros_ec_register(struct cros_ec_device *ec_dev)
 {
 	struct device *dev = ec_dev->dev;
-	int err = 0;
+	int err;
 
 	BLOCKING_INIT_NOTIFIER_HEAD(&ec_dev->event_notifier);
 
-- 
2.35.0.rc0.227.g00780c9af4-goog


  parent reply	other threads:[~2022-01-25 10:21 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-01-25 10:15 [PATCH 0/6] platform/chrome: cros_ec: miscellaneous cleanups Tzung-Bi Shih
2022-01-25 10:15 ` [PATCH 1/6] platform/chrome: cros_ec: fix error handling in cros_ec_register() Tzung-Bi Shih
2022-01-25 10:15 ` [PATCH 2/6] platform/chrome: cros_ec: remove unused variable `was_wake_device` Tzung-Bi Shih
2022-01-25 10:15 ` [PATCH 3/6] platform/chrome: cros_ec: determine `wake_enabled` in cros_ec_suspend() Tzung-Bi Shih
2022-01-25 10:15 ` Tzung-Bi Shih [this message]
2022-01-25 10:15 ` [PATCH 5/6] platform/chrome: cros_ec: sort header inclusion alphabetically Tzung-Bi Shih
2022-01-25 10:15 ` [PATCH 6/6] platform/chrome: cros_ec: append newline to all logs Tzung-Bi Shih

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=20220125101527.1812887-5-tzungbi@google.com \
    --to=tzungbi@google.com \
    --cc=bleung@chromium.org \
    --cc=groeck@chromium.org \
    --cc=linux-kernel@vger.kernel.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

all inboxes | Powered by JetHome®