From: Greg KH <greg@kroah.com>
To: Jean-Francois Dagenais <jeff.dagenais@gmail.com>
Cc: linux-kernel@vger.kernel.org, zbr@ioremap.net, manio@skyboo.net
Subject: Re: [PATCH v3] w1: ds2408: reset on output_write retry with readback
Date: Thu, 28 Mar 2019 17:22:33 +0100 [thread overview]
Message-ID: <20190328162233.GB2173@kroah.com> (raw)
In-Reply-To: <20190328122244.32126-1-jeff.dagenais@gmail.com>
On Thu, Mar 28, 2019 at 08:22:44AM -0400, Jean-Francois Dagenais wrote:
> When we have success in 'Channel Access Write' but reading back latch
> states fails, a write is retried without doing a proper slave reset.
> This leads to protocol errors as the slave treats the next 'Channel
> Access Write' as the continuation of previous command.
>
> This commit is fixing this by making sure if the retry loop re-runs, a
> reset is performed, whatever the failure (CONFIRM_BYTE or the read
> back).
>
> The loop was quite due for a cleanup and this change mandated it. By
> isolating the CONFIG_W1_SLAVE_DS2408_READBACK case into it's own
> function, we vastly reduce the visual and branching(runtime and
> compile-time) noise.
>
> Reported-by: Mariusz Bialonczyk <manio@skyboo.net>
> Tested-by: Mariusz Bialonczyk <manio@skyboo.net>
> Signed-off-by: Jean-Francois Dagenais <jeff.dagenais@gmail.com>
> ---
> drivers/w1/slaves/w1_ds2408.c | 76 ++++++++++++++++++++++---------------------
> 1 file changed, 39 insertions(+), 37 deletions(-)
What changed from previous versions? That information always goes below
the --- line.
v4 please.
thanks,
greg k-h
prev parent reply other threads:[~2019-03-28 16:28 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-03-28 12:22 Jean-Francois Dagenais
2019-03-28 16:22 ` Greg KH [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=20190328162233.GB2173@kroah.com \
--to=greg@kroah.com \
--cc=jeff.dagenais@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=manio@skyboo.net \
--cc=zbr@ioremap.net \
/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®