diff options
author | Javed Hasan | 2021-06-03 05:16:23 -0700 |
---|---|---|
committer | Martin K. Petersen | 2021-06-10 00:03:56 -0400 |
commit | 49d3e5996155a3067782748b0c4edf0309e951b6 (patch) | |
tree | 3d2e5fdb56d4eb7c40d2fa9989b46713ef553d59 /include/scsi/fc | |
parent | 974db67a518b4f2ca690c29923abbbd9d5f1abfd (diff) |
scsi: fc: FDMI enhancement
Added RHBA and RPA attributes type and length.
As per FC_GC_7 document section "Table 400 – Attribute Entry Types and
associated Values" ASCII type attributes length can be vary from "4 to 256
byte". If we keep all RHBA ASCII attributes length 256 then total length
is going upto 2750, which is far more than 2048 (max frame size).
In libfc we do have logic to split FCP commands but not for CT commands.
Practically all version/names get covered with in 64 bytes except OS name,
for that we need 128 bytes. Hence length of all RBHA ASCII attributes
is reduced to 64 bytes and 128 bytes in case of OS name.
RPA attributes total length is within frame size.
Link: https://lore.kernel.org/r/20210603121623.10084-6-jhasan@marvell.com
Reviewed-by: Himanshu Madhani <himanshu.madhani@oracle.com>
Signed-off-by: Javed Hasan <jhasan@marvell.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'include/scsi/fc')
-rw-r--r-- | include/scsi/fc/fc_ms.h | 55 |
1 files changed, 48 insertions, 7 deletions
diff --git a/include/scsi/fc/fc_ms.h b/include/scsi/fc/fc_ms.h index 800d53dc9470..00191695233a 100644 --- a/include/scsi/fc/fc_ms.h +++ b/include/scsi/fc/fc_ms.h @@ -25,6 +25,12 @@ #define FC_FDMI_SUBTYPE 0x10 /* fs_ct_hdr.ct_fs_subtype */ /* + * Management server FDMI specifications. + */ +#define FDMI_V1 1 /* FDMI version 1 specifications */ +#define FDMI_V2 2 /* FDMI version 2 specifications */ + +/* * Management server FDMI Requests. */ enum fc_fdmi_req { @@ -57,6 +63,13 @@ enum fc_fdmi_hba_attr_type { FC_FDMI_HBA_ATTR_FIRMWAREVERSION = 0x0009, FC_FDMI_HBA_ATTR_OSNAMEVERSION = 0x000A, FC_FDMI_HBA_ATTR_MAXCTPAYLOAD = 0x000B, + FC_FDMI_HBA_ATTR_NODESYMBLNAME = 0x000C, + FC_FDMI_HBA_ATTR_VENDORSPECIFICINFO = 0x000D, + FC_FDMI_HBA_ATTR_NUMBEROFPORTS = 0x000E, + FC_FDMI_HBA_ATTR_FABRICNAME = 0x000F, + FC_FDMI_HBA_ATTR_BIOSVERSION = 0x0010, + FC_FDMI_HBA_ATTR_BIOSSTATE = 0x0011, + FC_FDMI_HBA_ATTR_VENDORIDENTIFIER = 0x00E0, }; /* @@ -65,14 +78,21 @@ enum fc_fdmi_hba_attr_type { #define FC_FDMI_HBA_ATTR_NODENAME_LEN 8 #define FC_FDMI_HBA_ATTR_MANUFACTURER_LEN 64 #define FC_FDMI_HBA_ATTR_SERIALNUMBER_LEN 64 -#define FC_FDMI_HBA_ATTR_MODEL_LEN 256 -#define FC_FDMI_HBA_ATTR_MODELDESCR_LEN 256 -#define FC_FDMI_HBA_ATTR_HARDWAREVERSION_LEN 256 -#define FC_FDMI_HBA_ATTR_DRIVERVERSION_LEN 256 -#define FC_FDMI_HBA_ATTR_OPTIONROMVERSION_LEN 256 -#define FC_FDMI_HBA_ATTR_FIRMWAREVERSION_LEN 256 -#define FC_FDMI_HBA_ATTR_OSNAMEVERSION_LEN 256 +#define FC_FDMI_HBA_ATTR_MODEL_LEN 64 +#define FC_FDMI_HBA_ATTR_MODELDESCR_LEN 64 +#define FC_FDMI_HBA_ATTR_HARDWAREVERSION_LEN 64 +#define FC_FDMI_HBA_ATTR_DRIVERVERSION_LEN 64 +#define FC_FDMI_HBA_ATTR_OPTIONROMVERSION_LEN 64 +#define FC_FDMI_HBA_ATTR_FIRMWAREVERSION_LEN 64 +#define FC_FDMI_HBA_ATTR_OSNAMEVERSION_LEN 128 #define FC_FDMI_HBA_ATTR_MAXCTPAYLOAD_LEN 4 +#define FC_FDMI_HBA_ATTR_NODESYMBLNAME_LEN 64 +#define FC_FDMI_HBA_ATTR_VENDORSPECIFICINFO_LEN 4 +#define FC_FDMI_HBA_ATTR_NUMBEROFPORTS_LEN 4 +#define FC_FDMI_HBA_ATTR_FABRICNAME_LEN 8 +#define FC_FDMI_HBA_ATTR_BIOSVERSION_LEN 64 +#define FC_FDMI_HBA_ATTR_BIOSSTATE_LEN 4 +#define FC_FDMI_HBA_ATTR_VENDORIDENTIFIER_LEN 8 /* * Port Attribute Type @@ -84,6 +104,16 @@ enum fc_fdmi_port_attr_type { FC_FDMI_PORT_ATTR_MAXFRAMESIZE = 0x0004, FC_FDMI_PORT_ATTR_OSDEVICENAME = 0x0005, FC_FDMI_PORT_ATTR_HOSTNAME = 0x0006, + FC_FDMI_PORT_ATTR_NODENAME = 0x0007, + FC_FDMI_PORT_ATTR_PORTNAME = 0x0008, + FC_FDMI_PORT_ATTR_SYMBOLICNAME = 0x0009, + FC_FDMI_PORT_ATTR_PORTTYPE = 0x000A, + FC_FDMI_PORT_ATTR_SUPPORTEDCLASSSRVC = 0x000B, + FC_FDMI_PORT_ATTR_FABRICNAME = 0x000C, + FC_FDMI_PORT_ATTR_CURRENTFC4TYPE = 0x000D, + FC_FDMI_PORT_ATTR_PORTSTATE = 0x101, + FC_FDMI_PORT_ATTR_DISCOVEREDPORTS = 0x102, + FC_FDMI_PORT_ATTR_PORTID = 0x103, }; /* @@ -95,6 +125,17 @@ enum fc_fdmi_port_attr_type { #define FC_FDMI_PORT_ATTR_MAXFRAMESIZE_LEN 4 #define FC_FDMI_PORT_ATTR_OSDEVICENAME_LEN 256 #define FC_FDMI_PORT_ATTR_HOSTNAME_LEN 256 +#define FC_FDMI_PORT_ATTR_NODENAME_LEN 8 +#define FC_FDMI_PORT_ATTR_PORTNAME_LEN 8 +#define FC_FDMI_PORT_ATTR_SYMBOLICNAME_LEN 256 +#define FC_FDMI_PORT_ATTR_PORTTYPE_LEN 4 +#define FC_FDMI_PORT_ATTR_SUPPORTEDCLASSSRVC_LEN 4 +#define FC_FDMI_PORT_ATTR_FABRICNAME_LEN 8 +#define FC_FDMI_PORT_ATTR_CURRENTFC4TYPE_LEN 32 +#define FC_FDMI_PORT_ATTR_PORTSTATE_LEN 4 +#define FC_FDMI_PORT_ATTR_DISCOVEREDPORTS_LEN 4 +#define FC_FDMI_PORT_ATTR_PORTID_LEN 4 + /* * HBA Attribute ID |