From: Philipp Zabel <p.zabel@pengutronix.de>
To: Jerome Brunet <jbrunet@baylibre.com>
Cc: Martin Blumenstingl <martin.blumenstingl@googlemail.com>,
linux-kernel@vger.kernel.org, linux-amlogic@lists.infradead.org
Subject: Re: [PATCH] reset: fix shared reset triggered_count decrement on error
Date: Thu, 16 Feb 2017 10:52:17 +0100 [thread overview]
Message-ID: <1487238737.2377.3.camel@pengutronix.de> (raw)
In-Reply-To: <1487182551-31517-1-git-send-email-jbrunet@baylibre.com>
On Wed, 2017-02-15 at 19:15 +0100, Jerome Brunet wrote:
> For a shared reset, when the reset is successful, the triggered_count is
> incremented when trying to call the reset callback, so that another device
> sharing the same reset line won't trigger it again. If the reset has not
> been triggered successfully, the trigger_count should be decremented.
>
> The code does the opposite, and decrements the trigger_count on success.
> As a consequence, another device sharing the reset will be able to trigger
> it again.
>
> Fixed be removing negation in from of the error code of the reset function.
>
> Fixes: 7da33a37b48f ("reset: allow using reset_control_reset with shared reset")
>
> Signed-off-by: Jerome Brunet <jbrunet@baylibre.com>
> ---
> Hi Philipp,
>
> I found this issue while testing your patch [0]
> It fixes a regression we have been having with usb. On meson-gxbb
> platforms, usb0 and usb1 share the same reset line. Martin had
> reports that usb0 recently got broken. In fact usb1 was able to
> trigger the reset again because the issue mentioned above.
Thanks, applied with Martin's Acked-by. I'll send a pull request for
this later today.
regards
Philipp
prev parent reply other threads:[~2017-02-16 9:52 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-02-15 18:15 Jerome Brunet
2017-02-15 20:09 ` Martin Blumenstingl
2017-02-16 9:52 ` Philipp Zabel [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=1487238737.2377.3.camel@pengutronix.de \
--to=p.zabel@pengutronix.de \
--cc=jbrunet@baylibre.com \
--cc=linux-amlogic@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=martin.blumenstingl@googlemail.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®