libata: implement ata_host_detach()
Implement ata_host_detach() which calls ata_port_detach() for each port in the host and export it. ata_port_detach() is now internal and thus un-exported. ata_host_detach() will be used as the 'deregister from libata layer' function after devres conversion. Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
This commit is contained in:
@@ -1792,8 +1792,7 @@ static void ahci_remove_one (struct pci_dev *pdev)
|
||||
unsigned int i;
|
||||
int have_msi;
|
||||
|
||||
for (i = 0; i < host->n_ports; i++)
|
||||
ata_port_detach(host->ports[i]);
|
||||
ata_host_detach(host);
|
||||
|
||||
have_msi = hpriv->flags & AHCI_FLAG_MSI;
|
||||
free_irq(host->irq, host);
|
||||
|
Reference in New Issue
Block a user