From: Chen Pei <cp0613@linux.alibaba.com>
To: alison.schofield@intel.com, nvdimm@lists.linux.dev
Cc: linux-cxl@vger.kernel.org, guoren@kernel.org,
Chen Pei <cp0613@linux.alibaba.com>
Subject: [ndctl PATCH 0/2] daxctl, util/sysfs: fix builtin-driver false failure on enable
Date: Thu, 14 May 2026 14:32:32 +0800 [thread overview]
Message-ID: <20260514063234.86439-1-cp0613@linux.alibaba.com> (raw)
When a DAX / ndctl driver is builtin (not a loadable module),
daxctl_insert_kmod_for_mode() and __util_bind() still call
kmod_module_probe_insert_module() unconditionally. libkmod only
short-circuits builtin modules when it can find the modules.builtin
index; otherwise it falls through to init_module() and returns -ENOENT,
surfacing as a spurious "insert failure".
Pre-check kmod_module_get_initstate() and skip probe-insert when the
module is already BUILTIN or LIVE, matching the pattern used by ndctl's
own test/core.c.
Chen Pei (2):
daxctl: fix kmod reference leak on probe-insert failure
daxctl, util/sysfs: skip module probe-insert when driver is builtin or
live
daxctl/lib/libdaxctl.c | 19 +++++++++++++++++--
util/sysfs.c | 17 +++++++++++------
2 files changed, 28 insertions(+), 8 deletions(-)
--
2.43.0
next reply other threads:[~2026-05-14 6:32 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-05-14 6:32 Chen Pei [this message]
2026-05-14 6:32 ` [ndctl PATCH 1/2] daxctl: fix kmod reference leak on probe-insert failure Chen Pei
2026-05-14 17:16 ` Dave Jiang
2026-05-14 22:14 ` Alison Schofield
2026-05-15 2:27 ` Guo Ren
2026-05-14 6:32 ` [ndctl PATCH 2/2] daxctl, util/sysfs: skip module probe-insert when driver is builtin or live Chen Pei
2026-05-14 17:17 ` Dave Jiang
2026-05-14 18:37 ` Jonathan Cameron
2026-05-14 22:13 ` Alison Schofield
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=20260514063234.86439-1-cp0613@linux.alibaba.com \
--to=cp0613@linux.alibaba.com \
--cc=alison.schofield@intel.com \
--cc=guoren@kernel.org \
--cc=linux-cxl@vger.kernel.org \
--cc=nvdimm@lists.linux.dev \
/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.