1 /* SPDX-License-Identifier: GPL-2.0-or-later */
2 /*
3  *  Copyright 2016-2022 Broadcom Inc. All rights reserved.
4  */
5 #ifndef MPI30_SAS_H
6 #define MPI30_SAS_H     1
7 #define MPI3_SAS_DEVICE_INFO_SSP_TARGET             (0x00000100)
8 #define MPI3_SAS_DEVICE_INFO_STP_SATA_TARGET        (0x00000080)
9 #define MPI3_SAS_DEVICE_INFO_SMP_TARGET             (0x00000040)
10 #define MPI3_SAS_DEVICE_INFO_SSP_INITIATOR          (0x00000020)
11 #define MPI3_SAS_DEVICE_INFO_STP_INITIATOR          (0x00000010)
12 #define MPI3_SAS_DEVICE_INFO_SMP_INITIATOR          (0x00000008)
13 #define MPI3_SAS_DEVICE_INFO_DEVICE_TYPE_MASK       (0x00000007)
14 #define MPI3_SAS_DEVICE_INFO_DEVICE_TYPE_NO_DEVICE  (0x00000000)
15 #define MPI3_SAS_DEVICE_INFO_DEVICE_TYPE_END_DEVICE (0x00000001)
16 #define MPI3_SAS_DEVICE_INFO_DEVICE_TYPE_EXPANDER   (0x00000002)
17 struct mpi3_smp_passthrough_request {
18 	__le16                     host_tag;
19 	u8                         ioc_use_only02;
20 	u8                         function;
21 	__le16                     ioc_use_only04;
22 	u8                         ioc_use_only06;
23 	u8                         msg_flags;
24 	__le16                     change_count;
25 	u8                         reserved0a;
26 	u8                         io_unit_port;
27 	__le32                     reserved0c[3];
28 	__le64                     sas_address;
29 	struct mpi3_sge_common         request_sge;
30 	struct mpi3_sge_common         response_sge;
31 };
32 
33 struct mpi3_smp_passthrough_reply {
34 	__le16                     host_tag;
35 	u8                         ioc_use_only02;
36 	u8                         function;
37 	__le16                     ioc_use_only04;
38 	u8                         ioc_use_only06;
39 	u8                         msg_flags;
40 	__le16                     ioc_use_only08;
41 	__le16                     ioc_status;
42 	__le32                     ioc_log_info;
43 	__le16                     response_data_length;
44 	__le16                     reserved12;
45 };
46 #endif
47