From: thierry.reding@gmail.com (Thierry Reding)
To: linus-amlogic@lists.infradead.org
Subject: [PATCH -next] pwm: meson: Fix missing spin_lock_init()
Date: Fri, 21 Oct 2016 09:11:28 +0200 [thread overview]
Message-ID: <20161021071128.GA2670@ulmo.ba.sec> (raw)
In-Reply-To: <57D41083.3060109@baylibre.com>
On Sat, Sep 10, 2016 at 03:54:11PM +0200, Neil Armstrong wrote:
> Le 10/09/2016 08:38, Wei Yongjun a ?crit :
> > From: Wei Yongjun <weiyongjun1@huawei.com>
> >
> > The driver allocates the spinlock but not initialize it.
> > Use spin_lock_init() on it to initialize it correctly.
> >
> > This is detected by Coccinelle semantic patch.
> >
> > Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
> > ---
> > drivers/pwm/pwm-meson.c | 1 +
> > 1 file changed, 1 insertion(+)
> >
> > diff --git a/drivers/pwm/pwm-meson.c b/drivers/pwm/pwm-meson.c
> > index bfbbe7f..778d088 100644
> > --- a/drivers/pwm/pwm-meson.c
> > +++ b/drivers/pwm/pwm-meson.c
> > @@ -465,6 +465,7 @@ static int meson_pwm_probe(struct platform_device *pdev)
> > if (IS_ERR(meson->base))
> > return PTR_ERR(meson->base);
> >
> > + spin_lock_init(&meson->lock);
> > meson->chip.dev = &pdev->dev;
> > meson->chip.ops = &meson_pwm_ops;
> > meson->chip.base = -1;
> >
>
> Thanks for the fix, but it was already posted earlier by Axel Lin <axel.lin@ingics.com>
>
> Thierry will decide which one to merge.
>
> Acked-by: Neil Armstrong <narmstrong@baylibre.com>
I've applied Axel's patch.
Thanks,
Thierry
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 801 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-amlogic/attachments/20161021/c8c0227d/attachment.sig>
WARNING: multiple messages have this Message-ID (diff)
From: Thierry Reding <thierry.reding@gmail.com>
To: Neil Armstrong <narmstrong@baylibre.com>
Cc: Wei Yongjun <weiyj.lk@gmail.com>, Carlo Caione <carlo@caione.org>,
Kevin Hilman <khilman@baylibre.com>,
Wei Yongjun <weiyongjun1@huawei.com>,
linux-pwm@vger.kernel.org, linux-arm-kernel@lists.infradead.org,
linux-amlogic@lists.infradead.org
Subject: Re: [PATCH -next] pwm: meson: Fix missing spin_lock_init()
Date: Fri, 21 Oct 2016 09:11:28 +0200 [thread overview]
Message-ID: <20161021071128.GA2670@ulmo.ba.sec> (raw)
In-Reply-To: <57D41083.3060109@baylibre.com>
[-- Attachment #1: Type: text/plain, Size: 1229 bytes --]
On Sat, Sep 10, 2016 at 03:54:11PM +0200, Neil Armstrong wrote:
> Le 10/09/2016 08:38, Wei Yongjun a écrit :
> > From: Wei Yongjun <weiyongjun1@huawei.com>
> >
> > The driver allocates the spinlock but not initialize it.
> > Use spin_lock_init() on it to initialize it correctly.
> >
> > This is detected by Coccinelle semantic patch.
> >
> > Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
> > ---
> > drivers/pwm/pwm-meson.c | 1 +
> > 1 file changed, 1 insertion(+)
> >
> > diff --git a/drivers/pwm/pwm-meson.c b/drivers/pwm/pwm-meson.c
> > index bfbbe7f..778d088 100644
> > --- a/drivers/pwm/pwm-meson.c
> > +++ b/drivers/pwm/pwm-meson.c
> > @@ -465,6 +465,7 @@ static int meson_pwm_probe(struct platform_device *pdev)
> > if (IS_ERR(meson->base))
> > return PTR_ERR(meson->base);
> >
> > + spin_lock_init(&meson->lock);
> > meson->chip.dev = &pdev->dev;
> > meson->chip.ops = &meson_pwm_ops;
> > meson->chip.base = -1;
> >
>
> Thanks for the fix, but it was already posted earlier by Axel Lin <axel.lin@ingics.com>
>
> Thierry will decide which one to merge.
>
> Acked-by: Neil Armstrong <narmstrong@baylibre.com>
I've applied Axel's patch.
Thanks,
Thierry
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 801 bytes --]
WARNING: multiple messages have this Message-ID (diff)
From: thierry.reding@gmail.com (Thierry Reding)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH -next] pwm: meson: Fix missing spin_lock_init()
Date: Fri, 21 Oct 2016 09:11:28 +0200 [thread overview]
Message-ID: <20161021071128.GA2670@ulmo.ba.sec> (raw)
In-Reply-To: <57D41083.3060109@baylibre.com>
On Sat, Sep 10, 2016 at 03:54:11PM +0200, Neil Armstrong wrote:
> Le 10/09/2016 08:38, Wei Yongjun a ?crit :
> > From: Wei Yongjun <weiyongjun1@huawei.com>
> >
> > The driver allocates the spinlock but not initialize it.
> > Use spin_lock_init() on it to initialize it correctly.
> >
> > This is detected by Coccinelle semantic patch.
> >
> > Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
> > ---
> > drivers/pwm/pwm-meson.c | 1 +
> > 1 file changed, 1 insertion(+)
> >
> > diff --git a/drivers/pwm/pwm-meson.c b/drivers/pwm/pwm-meson.c
> > index bfbbe7f..778d088 100644
> > --- a/drivers/pwm/pwm-meson.c
> > +++ b/drivers/pwm/pwm-meson.c
> > @@ -465,6 +465,7 @@ static int meson_pwm_probe(struct platform_device *pdev)
> > if (IS_ERR(meson->base))
> > return PTR_ERR(meson->base);
> >
> > + spin_lock_init(&meson->lock);
> > meson->chip.dev = &pdev->dev;
> > meson->chip.ops = &meson_pwm_ops;
> > meson->chip.base = -1;
> >
>
> Thanks for the fix, but it was already posted earlier by Axel Lin <axel.lin@ingics.com>
>
> Thierry will decide which one to merge.
>
> Acked-by: Neil Armstrong <narmstrong@baylibre.com>
I've applied Axel's patch.
Thanks,
Thierry
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 801 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20161021/c8c0227d/attachment.sig>
next prev parent reply other threads:[~2016-10-21 7:11 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-09-10 6:38 [PATCH -next] pwm: meson: Fix missing spin_lock_init() Wei Yongjun
2016-09-10 6:38 ` Wei Yongjun
2016-09-10 6:38 ` Wei Yongjun
2016-09-10 13:54 ` Neil Armstrong
2016-09-10 13:54 ` Neil Armstrong
2016-09-10 13:54 ` Neil Armstrong
2016-10-21 7:11 ` Thierry Reding [this message]
2016-10-21 7:11 ` Thierry Reding
2016-10-21 7:11 ` Thierry Reding
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=20161021071128.GA2670@ulmo.ba.sec \
--to=thierry.reding@gmail.com \
--cc=linus-amlogic@lists.infradead.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.