diff options
author | Damien Le Moal <damien.lemoal@opensource.wdc.com> | 2022-06-09 11:24:56 +0900 |
---|---|---|
committer | Martin K. Petersen <martin.petersen@oracle.com> | 2022-06-10 13:08:06 -0400 |
commit | 3dafe0648ddd9c40666069e90b8a8a6162c452aa (patch) | |
tree | 2848a1c20c82225e57799eb70f0e076ab1b4cc8b /include/scsi | |
parent | 44f2bfe9ef082f76184d4a048c995729d14ec45d (diff) | |
download | lwn-3dafe0648ddd9c40666069e90b8a8a6162c452aa.tar.gz lwn-3dafe0648ddd9c40666069e90b8a8a6162c452aa.zip |
scsi: libsas: Introduce struct smp_rps_resp
Similarly to sas report general and discovery responses, define the
structure struct smp_rps_resp to handle SATA PHY report responses using a
structure with a size that is exactly equal to the sas defined response
size.
With this change, struct smp_resp becomes unused and is removed.
Link: https://lore.kernel.org/r/20220609022456.409087-4-damien.lemoal@opensource.wdc.com
Reviewed-by: John Garry <john.garry@huawei.com>
Signed-off-by: Damien Le Moal <damien.lemoal@opensource.wdc.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'include/scsi')
-rw-r--r-- | include/scsi/libsas.h | 2 | ||||
-rw-r--r-- | include/scsi/sas.h | 8 |
2 files changed, 3 insertions, 7 deletions
diff --git a/include/scsi/libsas.h b/include/scsi/libsas.h index ff04eb6d250b..2dbead74a2af 100644 --- a/include/scsi/libsas.h +++ b/include/scsi/libsas.h @@ -145,7 +145,7 @@ struct sata_device { struct ata_port *ap; struct ata_host *ata_host; - struct smp_resp rps_resp ____cacheline_aligned; /* report_phy_sata_resp */ + struct smp_rps_resp rps_resp ____cacheline_aligned; /* report_phy_sata_resp */ u8 fis[ATA_RESP_FIS_SIZE]; }; diff --git a/include/scsi/sas.h b/include/scsi/sas.h index a8f9743ed6fc..71b749bed3b0 100644 --- a/include/scsi/sas.h +++ b/include/scsi/sas.h @@ -712,16 +712,12 @@ struct smp_disc_resp { struct discover_resp disc; } __attribute__ ((packed)); -struct smp_resp { +struct smp_rps_resp { u8 frame_type; u8 function; u8 result; u8 reserved; - union { - struct report_general_resp rg; - struct discover_resp disc; - struct report_phy_sata_resp rps; - }; + struct report_phy_sata_resp rps; } __attribute__ ((packed)); #endif /* _SAS_H_ */ |