On Fri, Sep 06, 2024 at 10:58:46AM +0900, Damien Le Moal wrote: > Introduce the function ata_dev_free_resources() to free the resources > allocated to support a device features. For now, this function is > reduced to calling zpodd_exit() for devices that have this feature > enabled. > > ata_dev_free_resources() is called from ata_eh_dev_disable() as this > function is always called for all devices attached to a port that is > being detached and for devices that are being disabled due to being > removed (detached) from the system or due to errors. > > With this change, the call to zpodd_exit() done in ata_port_detach() is > removed as that function starts by removing all devices attached to the > port using libata EH, thus resulting in ata_eh_dev_disable() being > called and the zpodd_exit() function being executed. > > Signed-off-by: Damien Le Moal <dlemoal@xxxxxxxxxx> > --- Reviewed-by: Niklas Cassel <cassel@xxxxxxxxxx>