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.)
