From: "Jan Kundrát" <jan.kundrat@cesnet.cz>
To: Andy Shevchenko <andy.shevchenko@gmail.com>,
Mark Brown <broonie@kernel.org>
Cc: Cosmin Tanislav <cosmin.tanislav@analog.com>,
<linux-serial@vger.kernel.org>, <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] tty: max310x: work around regmap->regcache data corruption
Date: Sat, 02 Dec 2023 11:29:15 +0100 [thread overview]
Message-ID: <430727d2-7e88-4de2-97ab-e841656d7915@cesnet.cz> (raw)
In-Reply-To: <CAHp75Vc4tB_CuT-e+gofanWK=mss-k_A-mqPo-8+Rv-aQ8tu_w@mail.gmail.com>
On pátek 1. prosince 2023 18:02:32 CET, Andy Shevchenko wrote:
> On Fri, Dec 1, 2023 at 6:21 PM Mark Brown <broonie@kernel.org> wrote:
>> On Fri, Dec 01, 2023 at 03:51:51PM +0100, Jan Kundrát wrote:
>>
>>> The TL;DR summary is that the regmap_noinc_write spills over the data
>>> that are correctly written to the HW also to the following registers in
>>> the regcache. As a result, regcache then contains user-controlled
>>> garbage which will be used later for bit updates on unrelated registers.
>>
>>> I was investigating a regression that happened somewhere between 5.12.4
>>> (plus 14 of our patches) and v6.5.9 (plus 7 of our patches). Our
>>
>> Can you reproduce this with current kernels? That's not even an up to
>> date v6.5 - we're up to v6.5.13 now from the looks of things including
>> one upstream fix that looks potentially relevant.
>
> Indeed, the 984a4afdc87a ("regmap: prevent noinc writes from
> clobbering cache") seems quite relevant.
Thank you, Andy, this is indeed the real fix.
Sorry that I missed it, Mark. I spent many days on this one over a longer
period of time, so I haven't noticed that a fix was merged in the
meanwhile. I was just very happy that I debugged something which looked
like a real puzzle at the beginning :).
Cheers,
Jan
next prev parent reply other threads:[~2023-12-02 10:29 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-12-01 14:51 Jan Kundrát
2023-12-01 16:14 ` Andy Shevchenko
2023-12-01 16:23 ` Mark Brown
2023-12-01 16:21 ` Mark Brown
2023-12-01 17:02 ` Andy Shevchenko
2023-12-02 10:29 ` Jan Kundrát [this message]
2023-12-01 18:27 ` Hugo Villeneuve
2023-12-01 18:34 ` Mark Brown
2023-12-01 21:38 ` Hugo Villeneuve
2023-12-01 21:41 ` Mark Brown
2023-12-01 22:16 ` Hugo Villeneuve
2023-12-04 16:29 ` Hugo Villeneuve
2023-12-04 16:35 ` Mark Brown
2023-12-04 17:01 ` Hugo Villeneuve
2023-12-04 17:19 ` Mark Brown
2023-12-04 18:59 ` Hugo Villeneuve
2023-12-04 19:16 ` Mark Brown
2023-12-04 19:41 ` Hugo Villeneuve
2023-12-04 19:48 ` Mark Brown
2023-12-04 20:02 ` Hugo Villeneuve
2023-12-04 22:09 ` Mark Brown
2023-12-05 15:52 ` Hugo Villeneuve
2023-12-05 16:00 ` Mark Brown
2023-12-01 21:40 ` Hugo Villeneuve
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=430727d2-7e88-4de2-97ab-e841656d7915@cesnet.cz \
--to=jan.kundrat@cesnet.cz \
--cc=andy.shevchenko@gmail.com \
--cc=broonie@kernel.org \
--cc=cosmin.tanislav@analog.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-serial@vger.kernel.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
all inboxes | Powered by JetHome®