aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ata
diff options
context:
space:
mode:
authorDan Williams <dan.j.williams@intel.com>2012-07-10 00:06:08 -0400
committerJames Bottomley <JBottomley@Parallels.com>2012-08-24 05:10:24 -0400
commit8d8e7d13146eb6be8b98dbd58ac30421a4f8edf3 (patch)
treed00645c868455e957fc79d61e8bdd07dfe920516 /drivers/ata
parente468dc112f38220ee78bc0de64190eca9812749b (diff)
[SCSI] libsas, ipr: cleanup ata_host flags initialization via ata_host_init
libsas and ipr pass flags to ata_host_init that are meant for the port. ata_host flags: ATA_HOST_SIMPLEX = (1 << 0), /* Host is simplex, one DMA channel per host only */ ATA_HOST_STARTED = (1 << 1), /* Host started */ ATA_HOST_PARALLEL_SCAN = (1 << 2), /* Ports on this host can be scanned in parallel */ ATA_HOST_IGNORE_ATA = (1 << 3), /* Ignore ATA devices on this host. */ flags passed by libsas: ATA_FLAG_SATA = (1 << 1), ATA_FLAG_PIO_DMA = (1 << 7), /* PIO cmds via DMA */ ATA_FLAG_NCQ = (1 << 10), /* host supports NCQ */ The only one that aliases is ATA_HOST_STARTED which is a 'don't care' in the libsas and ipr cases since ata_hosts from these sources are not registered with libata. Reported-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Dan Williams <dan.j.williams@intel.com> Acked-by: Brian King <brking@us.ibm.com> Acked-by: Jeff Garzik <jgarzik@redhat.com> Signed-off-by: James Bottomley <JBottomley@Parallels.com>
Diffstat (limited to 'drivers/ata')
-rw-r--r--drivers/ata/libata-core.c10
1 files changed, 2 insertions, 8 deletions
diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c
index 09657c372d3b..2d479b67d0b4 100644
--- a/drivers/ata/libata-core.c
+++ b/drivers/ata/libata-core.c
@@ -5960,24 +5960,18 @@ int ata_host_start(struct ata_host *host)
5960} 5960}
5961 5961
5962/** 5962/**
5963 * ata_sas_host_init - Initialize a host struct 5963 * ata_sas_host_init - Initialize a host struct for sas (ipr, libsas)
5964 * @host: host to initialize 5964 * @host: host to initialize
5965 * @dev: device host is attached to 5965 * @dev: device host is attached to
5966 * @flags: host flags
5967 * @ops: port_ops 5966 * @ops: port_ops
5968 * 5967 *
5969 * LOCKING:
5970 * PCI/etc. bus probe sem.
5971 *
5972 */ 5968 */
5973/* KILLME - the only user left is ipr */
5974void ata_host_init(struct ata_host *host, struct device *dev, 5969void ata_host_init(struct ata_host *host, struct device *dev,
5975 unsigned long flags, struct ata_port_operations *ops) 5970 struct ata_port_operations *ops)
5976{ 5971{
5977 spin_lock_init(&host->lock); 5972 spin_lock_init(&host->lock);
5978 mutex_init(&host->eh_mutex); 5973 mutex_init(&host->eh_mutex);
5979 host->dev = dev; 5974 host->dev = dev;
5980 host->flags = flags;
5981 host->ops = ops; 5975 host->ops = ops;
5982} 5976}
5983 5977