From: Thadeu Lima de Souza Cascardo <cascardo@igalia.com>
To: Arnd Bergmann <arnd@arndb.de>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Andrew Morton <akpm@linux-foundation.org>,
Dirk VanDerMerwe <dirk.vandermerwe@sophos.com>,
Vimal Agrawal <vimal.agrawal@sophos.com>,
linux-kernel@vger.kernel.org,
Thadeu Lima de Souza Cascardo <cascardo@igalia.com>,
kernel-dev@igalia.com
Subject: [PATCH v3 0/2] char: misc: improve test and dynamic allocation
Date: Tue, 18 Mar 2025 14:24:17 -0300 [thread overview]
Message-ID: <20250318-misc-dynrange-v3-0-5c6507cbc2e2@igalia.com> (raw)
This includes a change that prevents dynamic allocation from using a minor
number that belongs to the historically static reserved range, which is
still used by some drivers.
It also improves the test, including a lot of corner cases, specially ones
that would fail before past fixes.
Signed-off-by: Thadeu Lima de Souza Cascardo <cascardo@igalia.com>
---
Changes in v3:
- remove code around DYNAMIC_MINORS and the backwards allocation
- try to open devices in tests by using init_mknod plus filp_open
- Link to v2: https://lore.kernel.org/r/20250307-misc-dynrange-v2-0-6fe19032ef76@igalia.com
---
Thadeu Lima de Souza Cascardo (2):
char: misc: restrict the dynamic range to exclude reserved minors
char: misc: add test cases
drivers/char/misc.c | 28 +-
drivers/misc/misc_minor_kunit.c | 578 +++++++++++++++++++++++++++++++++++++++-
2 files changed, 581 insertions(+), 25 deletions(-)
---
base-commit: 2dc25093218f5d42391549de6fe45e1aa9325676
change-id: 20250307-misc-dynrange-d54c92a5e319
prerequisite-change-id: 20250317-misc-chrdev-b26b572a47fc:v1
prerequisite-patch-id: d60dd6f7235bae2a8707c3169969b534be60de52
Best regards,
--
Thadeu Lima de Souza Cascardo <cascardo@igalia.com>
next reply other threads:[~2025-03-18 17:24 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-03-18 17:24 Thadeu Lima de Souza Cascardo [this message]
2025-03-18 17:24 ` [PATCH v3 1/2] char: misc: restrict the dynamic range to exclude reserved minors Thadeu Lima de Souza Cascardo
2025-03-18 17:24 ` [PATCH v3 2/2] char: misc: add test cases Thadeu Lima de Souza Cascardo
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=20250318-misc-dynrange-v3-0-5c6507cbc2e2@igalia.com \
--to=cascardo@igalia.com \
--cc=akpm@linux-foundation.org \
--cc=arnd@arndb.de \
--cc=dirk.vandermerwe@sophos.com \
--cc=gregkh@linuxfoundation.org \
--cc=kernel-dev@igalia.com \
--cc=linux-kernel@vger.kernel.org \
--cc=vimal.agrawal@sophos.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®