Commit a76f1b63 authored by Hannes Reinecke's avatar Hannes Reinecke Committed by Damien Le Moal
Browse files

ata,scsi: cleanup __ata_port_probe()



Rename __ata_port_probe() to ata_port_probe() and drop the wrapper
ata_sas_async_probe().

Signed-off-by: default avatarHannes Reinecke <hare@suse.de>
Signed-off-by: default avatarNiklas Cassel <niklas.cassel@wdc.com>
Reviewed-by: default avatarJason Yan <yanaijie@huawei.com>
Reviewed-by: default avatarJohn Garry <john.g.garry@oracle.com>
Reviewed-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
Signed-off-by: default avatarDamien Le Moal <dlemoal@kernel.org>
parent 77461a3f
Loading
Loading
Loading
Loading
+3 −2
Original line number Diff line number Diff line
@@ -5865,7 +5865,7 @@ void ata_host_init(struct ata_host *host, struct device *dev,
}
EXPORT_SYMBOL_GPL(ata_host_init);

void __ata_port_probe(struct ata_port *ap)
void ata_port_probe(struct ata_port *ap)
{
	struct ata_eh_info *ehi = &ap->link.eh_info;
	unsigned long flags;
@@ -5883,6 +5883,7 @@ void __ata_port_probe(struct ata_port *ap)

	spin_unlock_irqrestore(ap->lock, flags);
}
EXPORT_SYMBOL_GPL(ata_port_probe);

static void async_port_probe(void *data, async_cookie_t cookie)
{
@@ -5898,7 +5899,7 @@ static void async_port_probe(void *data, async_cookie_t cookie)
	if (!(ap->host->flags & ATA_HOST_PARALLEL_SCAN) && ap->port_no != 0)
		async_synchronize_cookie(cookie);

	__ata_port_probe(ap);
	ata_port_probe(ap);
	ata_port_wait_eh(ap);

	/* in order to keep device order, we need to synchronize at this point */
+0 −13
Original line number Diff line number Diff line
@@ -1144,19 +1144,6 @@ struct ata_port *ata_sas_port_alloc(struct ata_host *host,
}
EXPORT_SYMBOL_GPL(ata_sas_port_alloc);

/**
 * ata_sas_async_probe - simply schedule probing and return
 * @ap: Port to probe
 *
 * For batch scheduling of probe for sas attached ata devices, assumes
 * the port has already been through ata_sas_port_init()
 */
void ata_sas_async_probe(struct ata_port *ap)
{
	__ata_port_probe(ap);
}
EXPORT_SYMBOL_GPL(ata_sas_async_probe);

/**
 *	ata_sas_port_init - Initialize a SATA device
 *	@ap: SATA port to initialize
+0 −2
Original line number Diff line number Diff line
@@ -78,8 +78,6 @@ extern int ata_task_ioctl(struct scsi_device *scsidev, void __user *arg);
extern int ata_cmd_ioctl(struct scsi_device *scsidev, void __user *arg);
extern struct ata_port *ata_port_alloc(struct ata_host *host);
extern const char *sata_spd_string(unsigned int spd);
extern int ata_port_probe(struct ata_port *ap);
extern void __ata_port_probe(struct ata_port *ap);
extern unsigned int ata_read_log_page(struct ata_device *dev, u8 log,
				      u8 page, void *buf, unsigned int sectors);

+1 −1
Original line number Diff line number Diff line
@@ -787,7 +787,7 @@ static int hisi_sas_init_device(struct domain_device *device)
		 * However we don't need to issue a hard reset here for these
		 * reasons:
		 * a. When probing the device, libsas/libata already issues a
		 * hard reset in sas_probe_sata() -> ata_sas_async_probe().
		 * hard reset in sas_probe_sata() -> ata_port_probe().
		 * Note that in hisi_sas_debug_I_T_nexus_reset() we take care
		 * to issue a hard reset by checking the dev status (== INIT).
		 * b. When resetting the controller, this is simply unnecessary.
+1 −1
Original line number Diff line number Diff line
@@ -653,7 +653,7 @@ void sas_probe_sata(struct asd_sas_port *port)
		if (!dev_is_sata(dev))
			continue;

		ata_sas_async_probe(dev->sata_dev.ap);
		ata_port_probe(dev->sata_dev.ap);
	}
	mutex_unlock(&port->ha->disco_mutex);

Loading