From: Bjorn Andersson <bjorn.andersson@linaro.org>
To: Stephen Boyd <stephen.boyd@linaro.org>,
Linus Walleij <linus.walleij@linaro.org>
Cc: John Crispin <john@phrozen.org>,
linux-gpio@vger.kernel.org,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] pinctrl: qcom: fix masking of pinmux functions
Date: Mon, 26 Sep 2016 08:52:09 -0700 [thread overview]
Message-ID: <20160926155209.GC7509@tuxbot> (raw)
In-Reply-To: <CAJOFmgx3Y01DZvUU=wF68HLWRrUoiHAcOYtVjw6LsqvE3+Ds8w@mail.gmail.com>
On Sun 25 Sep 23:36 PDT 2016, Stephen Boyd wrote:
> On Mon, Sep 12, 2016 at 2:36 AM, John Crispin <john@phrozen.org> wrote:
> > The following commit introduced a regression by not properly masking the
> > calculated value.
> >
> > commit 47a01ee9a6c39fe1 ("pinctrl: qcom: Clear all function selection bits")
Please use the format: Fixes: %h (\"%s\")
> >
> > Signed-off-by: John Crispin <john@phrozen.org>
>
> Now I'm confused how it ever worked.... but agreed, the code looks wrong.
I agree, we should have seen some issues based on this, I presume we
where "lucky".
>
> Reviewed-by: Stephen Boyd <stephen.boyd@linaro.org>
>
Reviewed-by: Bjorn Andersson <bjorn.andersson@linaro.org>
@Linus, the corrected patch appeared in v4.8-rc1, would you mind
including this in a pull for v4.8?
Regards,
Bjorn
> > ---
> > drivers/pinctrl/qcom/pinctrl-msm.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/drivers/pinctrl/qcom/pinctrl-msm.c b/drivers/pinctrl/qcom/pinctrl-msm.c
> > index 51c42d7..775c883 100644
> > --- a/drivers/pinctrl/qcom/pinctrl-msm.c
> > +++ b/drivers/pinctrl/qcom/pinctrl-msm.c
> > @@ -156,7 +156,7 @@ static int msm_pinmux_set_mux(struct pinctrl_dev *pctldev,
> > spin_lock_irqsave(&pctrl->lock, flags);
> >
> > val = readl(pctrl->regs + g->ctl_reg);
> > - val &= mask;
> > + val &= ~mask;
> > val |= i << g->mux_bit;
> > writel(val, pctrl->regs + g->ctl_reg);
> >
next prev parent reply other threads:[~2016-09-26 15:52 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-09-12 9:36 [PATCH] pinctrl: qcom: fix masking of pinmux functions John Crispin
2016-09-26 6:36 ` Stephen Boyd
2016-09-26 15:52 ` Bjorn Andersson [this message]
2016-10-03 13:31 ` Linus Walleij
2016-10-03 14:24 ` John Crispin
2016-10-03 22:38 ` Linus Walleij
2016-10-03 20:53 ` Stephen Boyd
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=20160926155209.GC7509@tuxbot \
--to=bjorn.andersson@linaro.org \
--cc=john@phrozen.org \
--cc=linus.walleij@linaro.org \
--cc=linux-gpio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=stephen.boyd@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).