On Thu, Nov 8, 2018 at 10:06 AM Alexander Duyck <[email protected]> wrote: > > Try to consolidate all of the locking and unlocking of both the parent and > device when attaching or removing a driver from a given device. > > To do that I first consolidated the lock pattern into two functions > __device_driver_lock and __device_driver_unlock. After doing that I then > created functions specific to attaching and detaching the driver while > acquiring these locks. By doing this I was able to reduce the number of > spots where we touch need_parent_lock from 12 down to 4. > > Reviewed-by: Bart Van Assche <[email protected]> > Reviewed-by: Rafael J. Wysocki <[email protected]> > Signed-off-by: Alexander Duyck <[email protected]>
I was going to complain about the new addition of "This function" in the kernel-doc, but there are other occurrences in the file so that can wait for some future cleanup. I missed the __device_driver_unlock comment that Jane caught. With that fixed up. Reviewed-by: Dan Williams <[email protected]> _______________________________________________ Linux-nvdimm mailing list [email protected] https://lists.01.org/mailman/listinfo/linux-nvdimm
