diff options
author | 2024-07-03 20:44:25 +0200 | |
---|---|---|
committer | 2024-07-04 11:52:32 +0200 | |
commit | 0d3603acffe294ffacaf75b18b46f182b68a50df (patch) | |
tree | 37db27a0fa40ee6489a07b36d09f2830fbdceb16 /include/linux/libata.h | |
parent | ata: libata-core: Reuse available ata_port print_ids (diff) | |
download | wireguard-linux-0d3603acffe294ffacaf75b18b46f182b68a50df.tar.xz wireguard-linux-0d3603acffe294ffacaf75b18b46f182b68a50df.zip |
ata,scsi: Remove wrapper ata_sas_port_alloc()
The ata_sas_port_alloc() wrapper mainly exists in order to export the
internal libata function which it wraps. The secondary reason is that
it initializes some ata_port struct members.
However, ata_sas_port_alloc() is only used in a single location,
sas_ata_init(), which already performs some ata_port struct member
initialization, so it does not make sense to spread this initialization
out over two separate locations.
Thus, remove the wrapper and instead export the libata function directly,
and move the libsas specific ata_port initialization to sas_ata_init(),
which already does some ata_port initialization.
Reviewed-by: Hannes Reinecke <hare@suse.de>
Reviewed-by: John Garry <john.g.garry@oracle.com>
Reviewed-by: Martin K. Petersen <martin.petersen@oracle.com>
Link: https://lore.kernel.org/r/20240703184418.723066-19-cassel@kernel.org
Signed-off-by: Niklas Cassel <cassel@kernel.org>
Diffstat (limited to '')
-rw-r--r-- | include/linux/libata.h | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/include/linux/libata.h b/include/linux/libata.h index 84a7bfbac9fa..17394098bee9 100644 --- a/include/linux/libata.h +++ b/include/linux/libata.h @@ -1244,9 +1244,8 @@ extern int sata_link_debounce(struct ata_link *link, extern int sata_link_scr_lpm(struct ata_link *link, enum ata_lpm_policy policy, bool spm_wakeup); extern int ata_slave_link_init(struct ata_port *ap); -extern struct ata_port *ata_sas_port_alloc(struct ata_host *, - struct ata_port_info *, struct Scsi_Host *); extern void ata_port_probe(struct ata_port *ap); +extern struct ata_port *ata_port_alloc(struct ata_host *host); extern void ata_port_free(struct ata_port *ap); extern int ata_tport_add(struct device *parent, struct ata_port *ap); extern void ata_tport_delete(struct ata_port *ap); |