mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Mark Brown <broonie@kernel.org>
To: Mark Brown <broonie@kernel.org>
Cc: linux-kernel@vger.kernel.org
Subject: [PATCH 0/2] regcache: Validate bounds of regcache drop requests
Date: Mon, 26 Oct 2026 23:32:06 +0000	[thread overview]
Message-ID: <20261026-regmap-drop-region-min-max-v1-0-2c28637ede23@kernel.org> (raw)

It is not valid for a caller to try to drop a range of registers from
the cache where the minimum register is greater than the maximum register,
and doing so is likely to trigger bugs in the caches.  Reject such
invalid inputs and add a KUnit test for it.

---
Mark Brown (2):
      regcache: Validate bounds of regcache drop requests
      regcache: Add test for bounds checking of regcache drop requests

 drivers/base/regmap/regcache.c     |  3 +++
 drivers/base/regmap/regmap-kunit.c | 21 +++++++++++++++++++++
 2 files changed, 24 insertions(+)
---
base-commit: 2dee91ee94eec85d09c13c7ca83e3005906d3732
base-tree: git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regmap.git for-7.4
change-id: 20261026-regmap-drop-region-min-max-b1ff4cc203b3

Best regards,
--  
Mark Brown <broonie@kernel.org>


             reply	other threads:[~2026-10-26 23:32 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-26 23:32 Mark Brown [this message]
2026-10-26 23:32 ` [PATCH 1/2] " Mark Brown
2026-10-26 23:32 ` [PATCH 2/2] regcache: Add test for bounds checking " Mark Brown

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=20261026-regmap-drop-region-min-max-v1-0-2c28637ede23@kernel.org \
    --to=broonie@kernel.org \
    --cc=linux-kernel@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®