Commit 402ba7d3 authored by Jeff Garzik's avatar Jeff Garzik

[libata] add ->host_stop hook, and copy ->private_data from probe_ent

parent 526975bd
......@@ -2849,6 +2849,7 @@ int ata_device_add(struct ata_probe_ent *ent)
host_set->n_ports = ent->n_ports;
host_set->irq = ent->irq;
host_set->mmio_base = ent->mmio_base;
host_set->private_data = ent->private_data;
/* register each port bound to this device */
for (i = 0; i < ent->n_ports; i++) {
......@@ -3191,6 +3192,8 @@ void ata_pci_remove_one (struct pci_dev *pdev)
free_irq(host_set->irq, host_set);
if (host_set->mmio_base)
iounmap(host_set->mmio_base);
if (host_set->ports[0]->ops->host_stop)
host_set->ports[0]->ops->host_stop(host_set);
for (i = 0; i < host_set->n_ports; i++) {
Scsi_Host_Template *sht;
......
......@@ -207,6 +207,7 @@ struct ata_probe_ent {
unsigned int irq_flags;
unsigned long host_flags;
void *mmio_base;
void *private_data;
};
struct ata_host_set {
......@@ -371,6 +372,8 @@ struct ata_port_operations {
int (*port_start) (struct ata_port *ap);
void (*port_stop) (struct ata_port *ap);
void (*host_stop) (struct ata_host_set *host_set);
};
struct ata_port_info {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment