On 5/11/22 10:44, Luis Chamberlain wrote:
I suspect you ran into the issue of the refcnt being bumped by anything multipathd tried, and not being able to remove the module, but if it is adding *new* mpath devices that would seem like a bug which we'd need to address. The point to the patient module removal is to keep on trying until the recnt is 0 and if that fails wait and keep trying, until the the timeout. Anytihng userspace does, say multipathd does, like bdev_open(), would be yielded to. So I'd like to keep this change as it is exactly the sort of hack I am chasing after with this crusade. Let me know how you'd like to proceed so I can punt a v3.
Please implement the patient module removal and the stop_srp_ini() behavior changes as separate patches such that the stop_srp_ini() behavioral changes can be reverted easily in case these would trigger a regression. Thanks, Bart.