On Tue, Jan 25, 2022 at 05:24:41PM +0100, mwilck@xxxxxxxx wrote: > From: Martin Wilck <mwilck@xxxxxxxx> > > If a SCSI device handler module is loaded after some SCSI devices > have already been probed (e.g. via request_module() by dm-multipath), > the "access_state" and "preferred_path" sysfs attributes remain invisible for > these devices, although the handler is attached and live. The reason is > that the visibility is only checked when the sysfs attribute group is > first created. This results in an inconsistent user experience depending > on the load order of SCSI low-level drivers vs. device handler modules. > > This patch changes user space API: attempting to read the "access_state" > or "preferred_path" attributes will now result in -EINVAL rather than > -ENODEV for devices that have no device handler, and tests for the existence > of these attributes will have a different result. Sounds fine: Reviewed-by: Christoph Hellwig <hch@xxxxxx>