From: "Danilo Krummrich" <dakr@kernel.org>
To: "Uwe Kleine-König" <u.kleine-koenig@baylibre.com>
Cc: "Greg Kroah-Hartman" <gregkh@linuxfoundation.org>,
"Alex Williamson" <alex@shazbot.org>,
"Armin Wolf" <W_Armin@gmx.de>,
"David Lechner" <dlechner@baylibre.com>,
"Luis Chamberlain" <mcgrof@kernel.org>,
"Petr Pavlu" <petr.pavlu@suse.com>,
"Daniel Gomez" <da.gomez@kernel.org>,
"Sami Tolvanen" <samitolvanen@google.com>,
"Aaron Tomlin" <atomlin@atomlin.com>,
"Jonathan Corbet" <corbet@lwn.net>,
"Shuah Khan" <skhan@linuxfoundation.org>,
"Randy Dunlap" <rdunlap@infradead.org>,
"Rafael J. Wysocki" <rafael@kernel.org>,
"Steven Rostedt" <rostedt@goodmis.org>,
"Masami Hiramatsu" <mhiramat@kernel.org>,
"Mathieu Desnoyers" <mathieu.desnoyers@efficios.com>,
"Bradley Morgan" <brads@mainlining.org>,
"Aleksandr Nogikh" <nogikh@google.com>,
<linux-modules@vger.kernel.org>, <linux-kernel@vger.kernel.org>,
<linux-doc@vger.kernel.org>, <linux-usb@vger.kernel.org>,
<driver-core@lists.linux.dev>,
<linux-trace-kernel@vger.kernel.org>,
"Johan Hovold" <johan@kernel.org>,
"Richard Weinberger" <richard@nod.at>,
"Thierry Reding" <thierry.reding@kernel.org>,
"Jason Gunthorpe" <jgg@ziepe.ca>
Subject: Re: [PATCH v4 0/3] driver core: add TAINT_FORCED_BIND for when userspace manually messes with devices and drivers
Date: Sat, 24 Oct 2026 10:03:11 +0200 [thread overview]
Message-ID: <DMCWU4HYYXQ8.3W3UIPO3K16QA@kernel.org> (raw)
In-Reply-To: <atxdQ4vfh-b6GD0B@monoceros>
On Sat Oct 24, 2026 at 9:32 AM CEST, Uwe Kleine-König wrote:
> Why is it false positive? IMHO unless it involves a driver_override it is a
> bug to fix.
In an earlier reply I mentioned that we can leave it as a follow-up to limit
this to buses that do not support hotplug (will send a series soon), as we have
quite some drivers - for devices on buses where it is not expected that they
ever go away - where those drivers don't implement a proper teardown sequence;
for buses that support hotplug we should only taint on driver_override.
One can argue that they should be fixed then, and I would certainly love to have
all drivers to properly implement the full driver lifecycle, but it would also
mean to write a bunch of code that in practice is just dead code.
bind/unbind sysfs attributes (as well as module unload) can break such drivers,
which, under the premise that those drivers don't have to write this "dead code"
in the first place, is a false positive.
But again, I'd still always recommend to properly implement the driver lifecycle
for new drivers for various reasons (portability to other buses, general driver
design, etc.), and I'd love to see existing drivers be "fixed", but I don't see
how it is reasonable to expect this to happen.
(Luckily, in Rust that's at least partially never going to be an issue, as the
core APIs can fully enforce a proper driver lifecycle statically without drivers
having to write extra code for it. It obviously can't enfoce to leave the device
in a defined state though.)
next prev parent reply other threads:[~2026-10-24 8:03 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-14 14:30 [PATCH v4 0/3] driver core: add TAINT_FORCED_BIND for when userspace manually messes with devices and drivers Greg Kroah-Hartman
2026-09-14 14:30 ` [PATCH v4 1/3] module: pull out add_taint_module() to be public Greg Kroah-Hartman
2026-09-14 14:30 ` [PATCH v4 2/3] module: fix up documentation for add_taint() and add_taint_module() Greg Kroah-Hartman
2026-09-14 14:42 ` Bradley Morgan
2026-09-18 15:44 ` Aaron Tomlin
2026-09-14 14:30 ` [PATCH v4 3/3] driver core: add TAINT_FORCED_BIND for when userspace manually messes with devices and drivers Greg Kroah-Hartman
2026-09-18 16:39 ` [PATCH v4 0/3] " Danilo Krummrich
2026-09-18 17:25 ` Greg Kroah-Hartman
2026-09-18 17:29 ` Bradley Morgan
2026-09-22 7:39 ` Uwe Kleine-König
2026-09-22 13:40 ` David Lechner
2026-09-22 21:04 ` Armin Wolf
2026-09-23 6:29 ` Uwe Kleine-König
2026-09-23 9:27 ` Greg Kroah-Hartman
2026-09-23 9:54 ` Uwe Kleine-König
2026-09-23 10:29 ` Greg Kroah-Hartman
2026-10-24 0:13 ` Alex Williamson
2026-10-24 4:56 ` Greg Kroah-Hartman
2026-10-24 7:32 ` Uwe Kleine-König
2026-10-24 8:03 ` Danilo Krummrich [this message]
2026-09-23 20:52 ` Armin Wolf
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=DMCWU4HYYXQ8.3W3UIPO3K16QA@kernel.org \
--to=dakr@kernel.org \
--cc=W_Armin@gmx.de \
--cc=alex@shazbot.org \
--cc=atomlin@atomlin.com \
--cc=brads@mainlining.org \
--cc=corbet@lwn.net \
--cc=da.gomez@kernel.org \
--cc=dlechner@baylibre.com \
--cc=driver-core@lists.linux.dev \
--cc=gregkh@linuxfoundation.org \
--cc=jgg@ziepe.ca \
--cc=johan@kernel.org \
--cc=linux-doc@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-modules@vger.kernel.org \
--cc=linux-trace-kernel@vger.kernel.org \
--cc=linux-usb@vger.kernel.org \
--cc=mathieu.desnoyers@efficios.com \
--cc=mcgrof@kernel.org \
--cc=mhiramat@kernel.org \
--cc=nogikh@google.com \
--cc=petr.pavlu@suse.com \
--cc=rafael@kernel.org \
--cc=rdunlap@infradead.org \
--cc=richard@nod.at \
--cc=rostedt@goodmis.org \
--cc=samitolvanen@google.com \
--cc=skhan@linuxfoundation.org \
--cc=thierry.reding@kernel.org \
--cc=u.kleine-koenig@baylibre.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