mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Gustavo A. R. Silva" <gustavo@embeddedor.com>
To: Charles Keepax <ckeepax@opensource.cirrus.com>
Cc: Richard Fitzgerald <rf@opensource.cirrus.com>,
	Linus Walleij <linus.walleij@linaro.org>,
	alsa-devel@alsa-project.org, patches@opensource.cirrus.com,
	linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] pinctrl: madera: Fix uninitialized variable issue in madera_mux_set_mux
Date: Wed, 10 Oct 2018 16:58:05 +0200	[thread overview]
Message-ID: <69b40c51-b9db-4193-81ec-3e1970ced983@embeddedor.com> (raw)
In-Reply-To: <20181010143340.GA1653@imbe.wolfsonmicro.main>

Hi Charles,

> I don't believe this would fully address the issue since if you
> initialise ret to -1 you will still drop into the if statement
> and you will use the reg variable which should also be
> uninitialised on that code path.
> 
> Feels like initialising to 0 would probably be better anyway
> since the code path looks like the case were you have n_pins == 0
> and nothing really failed in that case just nothing needed to be
> done.
> 

You're right. I got confused with another similar issue I fixed, recently.

I'll send v2 shortly.

Thanks for the feedback.
--
Gustavo


      reply	other threads:[~2018-10-10 14:58 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-10-10 14:13 Gustavo A. R. Silva
2018-10-10 14:33 ` Charles Keepax
2018-10-10 14:58   ` Gustavo A. R. Silva [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=69b40c51-b9db-4193-81ec-3e1970ced983@embeddedor.com \
    --to=gustavo@embeddedor.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=ckeepax@opensource.cirrus.com \
    --cc=linus.walleij@linaro.org \
    --cc=linux-gpio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=patches@opensource.cirrus.com \
    --cc=rf@opensource.cirrus.com \
    /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®