[PATCH 1/3] driver core: Support asynchronous driver shutdown

Christoph Hellwig hch at lst.de
Mon Dec 18 21:33:18 PST 2023


On Thu, Dec 14, 2023 at 04:03:56PM -0800, Jeremy Allison wrote:
> From: Tanjore Suresh <tansuresh at google.com>
> 
> This changes the bus driver interface with additional entry points
> to enable devices to implement asynchronous shutdown. The existing
> synchronous interface to shutdown is unmodified and retained for
> backward compatibility. shutdown_pre is only called if a matching
> shutdown_post function is also registered, otherwise the synchronous
> synchronous interface is used.
> 
> This changes the common device shutdown code to enable devices to
> participate in asynchronous shutdown implementation.

Is there any reason to have a separate shutdown_pre method?
Especially with all the method wrapping in the driver core, yet
another method just keeps confusing everyone.

And on the post side, might shutdown_wait be a better name to
describe the operation, but I'm open to opinions.



More information about the Linux-nvme mailing list