All of lore.kernel.org
 help / color / mirror / Atom feed
From: Dmitry Torokhov <dmitry.torokhov@gmail.com>
To: Jeff LaBundy <jeff@labundy.com>
Cc: linux-input@vger.kernel.org
Subject: Re: [PATCH] Input: iqs7222 - preserve system status register
Date: Mon, 10 Mar 2025 09:54:25 -0700	[thread overview]
Message-ID: <Z88ZQcJ78NJg-A-1@google.com> (raw)
In-Reply-To: <Z85Alw+d9EHKXx2e@nixie71>

On Sun, Mar 09, 2025 at 08:29:59PM -0500, Jeff LaBundy wrote:
> Some register groups reserve a byte at the end of their continuous
> address space. Depending on the variant of silicon, this field may
> share the same memory space as the lower byte of the system status
> register (0x10).
> 
> In these cases, caching the reserved byte and writing it later may
> effectively reset the device depending on what happened in between
> the read and write operations.
> 
> Solve this problem by avoiding any access to this last byte within
> offending register groups. This method replaces a workaround which
> attempted to write the reserved byte with up-to-date contents, but
> left a small window in which updates by the device could have been
> clobbered.
> 
> Now that the driver does not touch these reserved bytes, the order
> in which the device's registers are written no longer matters, and
> they can be written in their natural order. The new method is also
> much more generic, and can be more easily extended to new variants
> of silicon with different register maps.
> 
> As part of this change, the register read and write functions must
> be gently updated to support byte access instead of word access.
> 
> Fixes: 2e70ef525b73 ("Input: iqs7222 - acknowledge reset before writing registers")
> Signed-off-by: Jeff LaBundy <jeff@labundy.com>

Applied, thank you.

-- 
Dmitry

      reply	other threads:[~2025-03-10 16:54 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-03-10  1:29 [PATCH] Input: iqs7222 - preserve system status register Jeff LaBundy
2025-03-10 16:54 ` Dmitry Torokhov [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=Z88ZQcJ78NJg-A-1@google.com \
    --to=dmitry.torokhov@gmail.com \
    --cc=jeff@labundy.com \
    --cc=linux-input@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 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.