From: Charles Keepax <ckeepax@opensource.cirrus.com>
To: Dan Carpenter <dan.carpenter@oracle.com>
Cc: <broonie@kernel.org>, <linux-kernel@vger.kernel.org>,
<patches@opensource.cirrus.com>
Subject: Re: [PATCH] regmap: debugfs: Add back in erroneously removed initialisation of ret
Date: Fri, 18 Sep 2020 14:43:13 +0000 [thread overview]
Message-ID: <20200918144313.GO10899@ediswmail.ad.cirrus.com> (raw)
In-Reply-To: <20200918123843.GS18329@kadam>
On Fri, Sep 18, 2020 at 03:38:43PM +0300, Dan Carpenter wrote:
> On Fri, Sep 18, 2020 at 12:20:02PM +0100, Charles Keepax wrote:
> > Fixes: 94cc89eb8fa5 ("regmap: debugfs: Fix handling of name string for debugfs init delays")
> > Reported-by: kernel test robot <lkp@intel.com>
> > Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
> > Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com>
> > ---
> > drivers/base/regmap/regmap.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/drivers/base/regmap/regmap.c b/drivers/base/regmap/regmap.c
> > index d0f7cc574ff34..b24f14ea96d8a 100644
> > --- a/drivers/base/regmap/regmap.c
> > +++ b/drivers/base/regmap/regmap.c
> > @@ -706,9 +706,9 @@ struct regmap *__regmap_init(struct device *dev,
> > const char *lock_name)
> > {
> > struct regmap *map;
> > + int ret = -EINVAL;
> > enum regmap_endian reg_endian, val_endian;
> > int i, j;
> > - int ret;
> >
> > if (!config)
> > goto err;
>
> Hi Charles, this isn't enough. There are several goto err_map; paths
> were "ret" is zero. That will result in an Oops in the caller. It has
> to be an error code.
>
Aye, sorry thought it was just cause I removed the initialisation
but yeah there is more fall out. Apologies for mucking this up,
third time lucky hopefully.
Thanks,
Charles
prev parent reply other threads:[~2020-09-18 14:43 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-18 11:20 Charles Keepax
2020-09-18 12:09 ` Mark Brown
2020-09-18 12:38 ` Dan Carpenter
2020-09-18 14:43 ` Charles Keepax [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=20200918144313.GO10899@ediswmail.ad.cirrus.com \
--to=ckeepax@opensource.cirrus.com \
--cc=broonie@kernel.org \
--cc=dan.carpenter@oracle.com \
--cc=linux-kernel@vger.kernel.org \
--cc=patches@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®