"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "src/sdparm_data.c" between
sdparm-1.11.tgz and sdparm-1.12.tgz

About: sdparm let you access SCSI modes pages, read VPD pages, send simple SCSI commands (similar functionality for SCSI disks like "hdparm" for ATA disks).

sdparm_data.c  (sdparm-1.11.tgz):sdparm_data.c  (sdparm-1.12.tgz)
/* /*
* Copyright (c) 2005-2020, Douglas Gilbert * Copyright (c) 2005-2021, Douglas Gilbert
* All rights reserved. * All rights reserved.
* *
* Redistribution and use in source and binary forms, with or without * Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met: * modification, are permitted provided that the following conditions are met:
* *
* 1. Redistributions of source code must retain the above copyright notice, * 1. Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer. * this list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above copyright * 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the * notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution. * documentation and/or other materials provided with the distribution.
skipping to change at line 100 skipping to change at line 100
Note that all standard peripheral device types are included in this array. Note that all standard peripheral device types are included in this array.
The pages are listed in acronym alphabetical order. */ The pages are listed in acronym alphabetical order. */
struct sdparm_mode_page_t sdparm_gen_mode_pg[] = { struct sdparm_mode_page_t sdparm_gen_mode_pg[] = {
{ADC_MP, MSP_ADC_DT_DPP, PDT_ADC, 0, "addp", {ADC_MP, MSP_ADC_DT_DPP, PDT_ADC, 0, "addp",
"DT device primary port (ADC)", NULL}, "DT device primary port (ADC)", NULL},
{ADC_MP, MSP_ADC_LU, PDT_ADC, 0, "adlu", "logical unit (ADC)", NULL}, {ADC_MP, MSP_ADC_LU, PDT_ADC, 0, "adlu", "logical unit (ADC)", NULL},
{ADC_MP, MSP_ADC_TGT_DEV, PDT_ADC, 0, "adtd", "Target device (ADC)", {ADC_MP, MSP_ADC_TGT_DEV, PDT_ADC, 0, "adtd", "Target device (ADC)",
NULL}, NULL},
{ADC_MP, MSP_ADC_TD_SN, PDT_ADC, 0, "adts", {ADC_MP, MSP_ADC_TD_SN, PDT_ADC, 0, "adts",
"Target device serial number (ADC)", NULL}, "Target device serial number (ADC)", NULL},
{CONTROL_MP, MSP_SAT_AFC, -1, 0, "afc", "SAT ATA Feature control", NULL},
{POWER_MP, MSP_SAT_POWER, -1, 0, "apo", "SAT ATA Power condition", NULL}, {POWER_MP, MSP_SAT_POWER, -1, 0, "apo", "SAT ATA Power condition", NULL},
{CONTROL_MP, MSP_SBC_APP_TAG, PDT_DISK_ZBC, 0, "atag", "Application tag " {CONTROL_MP, MSP_SBC_APP_TAG, PDT_DISK_ZBC, 0, "atag", "Application tag "
"(SBC)", &sbc_atag_desc}, "(SBC)", &sbc_atag_desc},
{IEC_MP, MSP_BACK_CTL, PDT_DISK_ZBC, 0, "bc", "Background control (SBC)", {IEC_MP, MSP_BACK_CTL, PDT_DISK_ZBC, 0, "bc", "Background control (SBC)",
NULL}, NULL},
{CONTROL_MP, MSP_SBC_BACK_OP, PDT_DISK, 0, "bop", {CONTROL_MP, MSP_SBC_BACK_OP, PDT_DISK, 0, "bop",
"Background operation control (SBC)", NULL}, "Background operation control (SBC)", NULL},
{CACHING_MP, 0, PDT_DISK_ZBC, 0, "ca", "Caching (SBC)", NULL}, {CACHING_MP, 0, PDT_DISK_ZBC, 0, "ca", "Caching (SBC)", NULL},
{CONTROL_MP, MSP_SPC_CDLA, -1, 0, "cdla", "Command duration limit A", {CONTROL_MP, MSP_SPC_CDLA, -1, 0, "cdla", "Command duration limit A",
&spc_cdl_desc}, &spc_cdl_desc},
{CONTROL_MP, MSP_SPC_CDLB, -1, 0, "cdlb", "Command duration limit B", {CONTROL_MP, MSP_SPC_CDLB, -1, 0, "cdlb", "Command duration limit B",
&spc_cdl_desc}, &spc_cdl_desc},
{CONTROL_MP, MSP_SPC_CDT2A, -1, 0, "cdt2a", "Command duration limit T2A", {CONTROL_MP, MSP_SPC_CDLT2A, -1, 0, "cdt2a", "Command duration limit T2A",
NULL /* spc6r? */ }, NULL /* spc6r01 */ },
{CONTROL_MP, MSP_SPC_CDT2B, -1, 0, "cdt2b", "Command duration limit T2B", {CONTROL_MP, MSP_SPC_CDLT2B, -1, 0, "cdt2b", "Command duration limit T2B",
NULL /* spc6r? */ }, NULL /* spc6r01 */ },
{MMCMS_MP, 0, PDT_MMC, 1, "cms", "CD/DVD (MM) capabilities and " {MMCMS_MP, 0, PDT_MMC, 1, "cms", "CD/DVD (MM) capabilities and "
"mechanical status (MMC)", NULL}, /* read only */ "mechanical status (MMC)", NULL}, /* read only */
{CONTROL_MP, 0, -1, 0, "co", "Control", NULL}, {CONTROL_MP, 0, -1, 0, "co", "Control", NULL},
{CONTROL_MP, MSP_SPC_CE, -1, 0, "coe", "Control extension", NULL}, {CONTROL_MP, MSP_SPC_CE, -1, 0, "coe", "Control extension", NULL},
{CONTROL_MP, MSP_SSC_CDP, -1, 0, "cdp", "Control data protection (SSC)", {CONTROL_MP, MSP_SSC_CDP, -1, 0, "cdp", "Control data protection (SSC)",
NULL}, NULL},
{DATA_COMPR_MP, 0, PDT_TAPE, 0, "dac", "Data compression (SSC)", NULL}, {DATA_COMPR_MP, 0, PDT_TAPE, 0, "dac", "Data compression (SSC)", NULL},
{DEV_CONF_MP, 0, PDT_TAPE, 0, "dc", "Device configuration (SSC)", NULL}, {DEV_CONF_MP, 0, PDT_TAPE, 0, "dc", "Device configuration (SSC)", NULL},
{DEV_CAP_MP, 0, PDT_MCHANGER, 0, "dca", "Device capabilities (SMC)", {DEV_CAP_MP, 0, PDT_MCHANGER, 0, "dca", "Device capabilities (SMC)",
NULL}, NULL},
skipping to change at line 169 skipping to change at line 170
/* since in SBC, SSC and MMC treat RW_ERR_RECOVERY_MP as if in SPC */ /* since in SBC, SSC and MMC treat RW_ERR_RECOVERY_MP as if in SPC */
{TRANS_GEO_PAR_MP, 0, PDT_MCHANGER, 0, "tgp", "Transport geometry " {TRANS_GEO_PAR_MP, 0, PDT_MCHANGER, 0, "tgp", "Transport geometry "
"parameters (SMC)", &smc_tg_desc}, "parameters (SMC)", &smc_tg_desc},
{TIMEOUT_PROT_MP, 0, PDT_MMC, 0, "tp", "Timeout and protect (MMC)", NULL}, {TIMEOUT_PROT_MP, 0, PDT_MMC, 0, "tp", "Timeout and protect (MMC)", NULL},
{V_ERR_RECOVERY_MP, 0, PDT_DISK_ZBC, 0, "ve", {V_ERR_RECOVERY_MP, 0, PDT_DISK_ZBC, 0, "ve",
"Verify error recovery (SBC)", NULL}, "Verify error recovery (SBC)", NULL},
{WRITE_PARAM_MP, 0, PDT_MMC, 0, "wp", "Write parameters (MMC)", NULL}, {WRITE_PARAM_MP, 0, PDT_MMC, 0, "wp", "Write parameters (MMC)", NULL},
{XOR_MP, 0, PDT_DISK, 0, "xo", "XOR control (SBC)", NULL}, {XOR_MP, 0, PDT_DISK, 0, "xo", "XOR control (SBC)", NULL},
/* XOR control mode page made obsolete in sbc3r32 */ /* XOR control mode page made obsolete in sbc3r32 */
{CONTROL_MP, MSP_ZB_D_CTL, PDT_DISK_ZBC, 0, "zbdct", {CONTROL_MP, MSP_ZB_D_CTL, PDT_DISK_ZBC, 0, "zbdct",
"Zoned block device control (ZBC)", NULL}, "Zoned block device control (ZBC)", NULL},
{0, 0, 0, 0, NULL, NULL, NULL}, {0, 0, 0, 0, NULL, NULL, NULL},
}; };
/* Array for transport id and corresponding acronyms. The /* Array for transport id and corresponding acronyms. The
* sg_get_trans_proto_str() function from the sg3_utils' library provides * sg_get_trans_proto_str() function from the sg3_utils' library provides
* the full protocol (transport) name. Those transports commented with * the full protocol (transport) name. Those transports commented with
* "none" don't have transport specific mode pages at this time. */ * "none" don't have transport specific mode pages at this time. */
struct sdparm_val_desc_t sdparm_transport_id[] = { struct sdparm_val_desc_t sdparm_transport_id[] = {
{TPROTO_FCP, "fcp"}, {TPROTO_FCP, "fcp"},
{TPROTO_SPI, "spi"}, {TPROTO_SPI, "spi"},
skipping to change at line 248 skipping to change at line 249
}; };
static struct sdparm_mode_descriptor_t sas_pcd_desc = { /* desc SAS/SPL */ static struct sdparm_mode_descriptor_t sas_pcd_desc = { /* desc SAS/SPL */
7, 1, 0, 8, 48, -1, -1, false, "SAS phy" 7, 1, 0, 8, 48, -1, -1, false, "SAS phy"
}; };
static struct sdparm_mode_descriptor_t sas_e_phy_desc = { /* desc SAS/SPL */ static struct sdparm_mode_descriptor_t sas_e_phy_desc = { /* desc SAS/SPL */
7, 1, 0, 8, -1, 2, 2, false, "Enhanced phy" 7, 1, 0, 8, -1, 2, 2, false, "Enhanced phy"
}; };
/* This one has a strange format, no number of descriptors and each
* descriptor can have a variable size. */
static struct sdparm_mode_descriptor_t sas_oob_m_c_desc = { /* desc SAS/SPL */ static struct sdparm_mode_descriptor_t sas_oob_m_c_desc = { /* desc SAS/SPL */
-1, -1, 0, 8, -1, 2, 2, true, "Attribute control" -1, -1, 0, 8, -1, 2, 2, true, "Attribute control"
}; };
/* N.B. In SAS 2.1 the spec was split with the upper levels going into the /* N.B. In SAS 2.1 the spec was split with the upper levels going into the
* SAS Protocol Layer (SPL) document. So now the SPL drafts are the * SAS Protocol Layer (SPL) document. So now the SPL drafts are the
* relevant SAS references. */ * relevant SAS references. */
static struct sdparm_mode_page_t sdparm_sas_mode_pg[] = { /* SAS/SPL */ static struct sdparm_mode_page_t sdparm_sas_mode_pg[] = { /* SAS/SPL */
{DISCONNECT_MP, 0, -1, 0, "dr", "Disconnect-reconnect (SAS)", NULL}, {DISCONNECT_MP, 0, -1, 0, "dr", "Disconnect-reconnect (SAS)", NULL},
{PROT_SPEC_PORT_MP, MSP_SAS_OOB_M_C, -1, 0, "oobm", /* spl5r01 */ {PROT_SPEC_PORT_MP, MSP_SAS_OOB_M_C, -1, 0, "oobm", /* spl5r01 */
skipping to change at line 287 skipping to change at line 290
{VPD_AUTOMATION_DEV_SN, 0, PDT_TAPE, "adsn", "Automation device serial " {VPD_AUTOMATION_DEV_SN, 0, PDT_TAPE, "adsn", "Automation device serial "
"number (SSC)"}, "number (SSC)"},
{VPD_BLOCK_DEV_CHARS, 0, PDT_DISK, "bdc", "Block device characteristics " {VPD_BLOCK_DEV_CHARS, 0, PDT_DISK, "bdc", "Block device characteristics "
"(SBC)"}, "(SBC)"},
{VPD_BLOCK_DEV_C_EXTENS, 0, PDT_DISK, "bdce", "Block device " {VPD_BLOCK_DEV_C_EXTENS, 0, PDT_DISK, "bdce", "Block device "
"characteristics extension (SBC)"}, "characteristics extension (SBC)"},
{VPD_BLOCK_LIMITS, 0, PDT_DISK, "bl", "Block limits (SBC)"}, {VPD_BLOCK_LIMITS, 0, PDT_DISK, "bl", "Block limits (SBC)"},
{VPD_BLOCK_LIMITS_EXT, 0, PDT_DISK, "ble", {VPD_BLOCK_LIMITS_EXT, 0, PDT_DISK, "ble",
"Block limits extension (SBC)"}, "Block limits extension (SBC)"},
{VPD_CFA_PROFILE_INFO, 0, -1, "cfa", "CFA profile information"}, {VPD_CFA_PROFILE_INFO, 0, -1, "cfa", "CFA profile information"},
{VPD_CON_POS_RANGE, 0, 0, "cpr", "Concurrent positioning ranges (SBC)"},
{VPD_DEVICE_CONSTITUENTS, 0, -1, "dc", "Device constituents"}, {VPD_DEVICE_CONSTITUENTS, 0, -1, "dc", "Device constituents"},
{VPD_DEVICE_ID, 0, -1, "di", "Device identification"}, {VPD_DEVICE_ID, 0, -1, "di", "Device identification"},
{VPD_DEVICE_ID, VPD_DI_SEL_AS_IS, -1, "di_asis", "Like 'di' " {VPD_DEVICE_ID, VPD_DI_SEL_AS_IS, -1, "di_asis", "Like 'di' "
"but designators ordered as found"}, "but designators ordered as found"},
{VPD_DEVICE_ID, VPD_DI_SEL_LU, -1, "di_lu", "Device identification, " {VPD_DEVICE_ID, VPD_DI_SEL_LU, -1, "di_lu", "Device identification, "
"lu only"}, "lu only"},
{VPD_DEVICE_ID, VPD_DI_SEL_TPORT, -1, "di_port", "Device " {VPD_DEVICE_ID, VPD_DI_SEL_TPORT, -1, "di_port", "Device "
"identification, target port only"}, "identification, target port only"},
{VPD_DEVICE_ID, VPD_DI_SEL_TARGET, -1, "di_target", "Device " {VPD_DEVICE_ID, VPD_DI_SEL_TARGET, -1, "di_target", "Device "
"identification, target device only"}, "identification, target device only"},
{VPD_DTDE_ADDRESS, 0, 1, "dtde", {VPD_DTDE_ADDRESS, 0, 1, "dtde",
"Data transfer device element address (SSC)"}, "Data transfer device element address (SSC)"},
{VPD_EXT_INQ, 0, -1, "ei", "Extended inquiry data"}, {VPD_EXT_INQ, 0, -1, "ei", "Extended inquiry data"},
{VPD_FORMAT_PRESETS, 0, 0, "fp", "Format presets"}, {VPD_FORMAT_PRESETS, 0, 0, "fp", "Format presets (SBC)"},
{VPD_IMP_OP_DEF, 0, -1, "iod", {VPD_IMP_OP_DEF, 0, -1, "iod",
"Implemented operating definition (obs)"}, "Implemented operating definition (obs)"},
{VPD_LB_PROTECTION, 0, PDT_TAPE, "lbpro", "Logical block protection " {VPD_LB_PROTECTION, 0, PDT_TAPE, "lbpro", "Logical block protection "
"(SSC)"}, "(SSC)"},
{VPD_LB_PROVISIONING, 0, PDT_DISK, "lbpv", "Logical block provisioning " {VPD_LB_PROVISIONING, 0, PDT_DISK, "lbpv", "Logical block provisioning "
"(SBC)"}, "(SBC)"},
{VPD_MAN_ASS_SN, 0, PDT_TAPE, "mas", {VPD_MAN_ASS_SN, 0, PDT_TAPE, "mas",
"Manufacturer assigned serial number (SSC)"}, "Manufacturer assigned serial number (SSC)"},
{VPD_MAN_ASS_SN, 0, PDT_ADC, "masa", {VPD_MAN_ASS_SN, 0, PDT_ADC, "masa",
"Manufacturer assigned serial number (ADC)"}, "Manufacturer assigned serial number (ADC)"},
skipping to change at line 496 skipping to change at line 500
{"TST_W", WRITE_PARAM_MP, 0, PDT_MMC, 2, 4, 1, 0, {"TST_W", WRITE_PARAM_MP, 0, PDT_MMC, 2, 4, 1, 0,
"Test write", NULL}, "Test write", NULL},
{"WR_T", WRITE_PARAM_MP, 0, PDT_MMC, 2, 3, 4, MF_COMMON, {"WR_T", WRITE_PARAM_MP, 0, PDT_MMC, 2, 3, 4, MF_COMMON,
"Write type", "Write type",
"0: packet/incremental; 1: track-at-once\t" "0: packet/incremental; 1: track-at-once\t"
"2: session-at-once; 3: raw; 4: layer jump recording"}, "2: session-at-once; 3: raw; 4: layer jump recording"},
{"MULTI_S", WRITE_PARAM_MP, 0, PDT_MMC, 3, 7, 2, MF_COMMON, {"MULTI_S", WRITE_PARAM_MP, 0, PDT_MMC, 3, 7, 2, MF_COMMON,
"Multi session", "Multi session",
"0: next session not allowed (no BO pointer)\t" "0: next session not allowed (no BO pointer)\t"
"1: next session not allowed\t" "1: next session not allowed\t"
"3: next seesion allowed (indicated by BO pointer)"}, "3: next session allowed (indicated by BO pointer)"},
{"FP", WRITE_PARAM_MP, 0, PDT_MMC, 3, 5, 1, 0, {"FP", WRITE_PARAM_MP, 0, PDT_MMC, 3, 5, 1, 0,
"Fixed packet type", NULL}, "Fixed packet type", NULL},
{"COPY", WRITE_PARAM_MP, 0, PDT_MMC, 3, 4, 1, 0, {"COPY", WRITE_PARAM_MP, 0, PDT_MMC, 3, 4, 1, 0,
"Serial copy management system (SCMS) enable", NULL}, "Serial copy management system (SCMS) enable", NULL},
{"TRACK_M", WRITE_PARAM_MP, 0, PDT_MMC, 3, 3, 4, 0, {"TRACK_M", WRITE_PARAM_MP, 0, PDT_MMC, 3, 3, 4, 0,
"Track mode", NULL}, "Track mode", NULL},
{"DBT", WRITE_PARAM_MP, 0, PDT_MMC, 4, 3, 4, 0, {"DBT", WRITE_PARAM_MP, 0, PDT_MMC, 4, 3, 4, 0,
"Data block type", NULL}, "Data block type", NULL},
{"LINK_S", WRITE_PARAM_MP, 0, PDT_MMC, 5, 7, 8, 0, {"LINK_S", WRITE_PARAM_MP, 0, PDT_MMC, 5, 7, 8, 0,
"Link size", NULL}, "Link size", NULL},
skipping to change at line 688 skipping to change at line 692
"Timestamp changeable by methods outside standard", NULL}, "Timestamp changeable by methods outside standard", NULL},
{"SCSIP", CONTROL_MP, MSP_SPC_CE, -1, 4, 1, 1, 0, {"SCSIP", CONTROL_MP, MSP_SPC_CE, -1, 4, 1, 1, 0,
"SCSI timestamp commands take precedence over other methods", NULL}, "SCSI timestamp commands take precedence over other methods", NULL},
{"IALUAE", CONTROL_MP, MSP_SPC_CE, -1, 4, 0, 1, 0, {"IALUAE", CONTROL_MP, MSP_SPC_CE, -1, 4, 0, 1, 0,
"Implicit asymmetric logical unit access enabled", NULL}, "Implicit asymmetric logical unit access enabled", NULL},
{"INIT_PR", CONTROL_MP, MSP_SPC_CE, -1, 5, 3, 4, 0, {"INIT_PR", CONTROL_MP, MSP_SPC_CE, -1, 5, 3, 4, 0,
"Initial command priority", "0: none or vendor; 1: highest; " "Initial command priority", "0: none or vendor; 1: highest; "
"15: lowest"}, "15: lowest"},
{"MSDL", CONTROL_MP, MSP_SPC_CE, -1, 6, 7, 8, 0, /* spc4r34 */ {"MSDL", CONTROL_MP, MSP_SPC_CE, -1, 6, 7, 8, 0, /* spc4r34 */
"Maximum sense data length", "0: unlimited"}, "Maximum sense data length", "0: unlimited"},
{"NSQCC", CONTROL_MP, MSP_SPC_CE, -1, 7, 7, 8, 0, /* spc6r05 */
"Non-sequestered command count", NULL},
{"SQCO", CONTROL_MP, MSP_SPC_CE, -1, 8, 7, 8, 0, /* spc6r05 */
"Sequestered command order",
"0: oldest\t1: best IOPS\t2: IOPS and other sources"},
/* Application tag mode subpage: atag [0xa,0x2] sbc3r25 */ /* Application tag mode subpage: atag [0xa,0x2] sbc3r25 */
/* descriptor starts here, <start_byte> is relative to start of mode /* descriptor starts here, <start_byte> is relative to start of mode
* page (i.e. 16 more than shown in t10's descriptor format table) */ * page (i.e. 16 more than shown in t10's descriptor format table) */
{"AT_LAST", CONTROL_MP, MSP_SBC_APP_TAG, PDT_DISK_ZBC, 16, 7, 1, 0, {"AT_LAST", CONTROL_MP, MSP_SBC_APP_TAG, PDT_DISK_ZBC, 16, 7, 1, 0,
"Last", NULL}, "Last", NULL},
{"AT_LBAT", CONTROL_MP, MSP_SBC_APP_TAG, PDT_DISK_ZBC, 22, 7, 16, MF_HEX, {"AT_LBAT", CONTROL_MP, MSP_SBC_APP_TAG, PDT_DISK_ZBC, 22, 7, 16, MF_HEX,
"Logical block application tag", NULL}, "Logical block application tag", NULL},
{"AT_LBA", CONTROL_MP, MSP_SBC_APP_TAG, PDT_DISK_ZBC, 24, 7, 64, MF_HEX, {"AT_LBA", CONTROL_MP, MSP_SBC_APP_TAG, PDT_DISK_ZBC, 24, 7, 64, MF_HEX,
"Logical block address", "start LBA for this application tag"}, "Logical block address", "start LBA for this application tag"},
skipping to change at line 771 skipping to change at line 780
"Operating System Initialization (OSI) proximity", "Operating System Initialization (OSI) proximity",
"0: unknown; 1: improbable; 2: probable"}, "0: unknown; 1: improbable; 2: probable"},
/* Background operation control mode subpage: bop [0xa,0x6] sbc4 */ /* Background operation control mode subpage: bop [0xa,0x6] sbc4 */
{"BO_MODE", CONTROL_MP, MSP_SBC_BACK_OP, PDT_DISK, 4, 7, 2, 0, {"BO_MODE", CONTROL_MP, MSP_SBC_BACK_OP, PDT_DISK, 4, 7, 2, 0,
"Background operation mode", "host initiated advanced background " "Background operation mode", "host initiated advanced background "
"operations:\t" "operations:\t"
"0: suspended during IO\t" "0: suspended during IO\t"
"1: continue during IO"}, "1: continue during IO"},
/* Command duration limit T2A mode subpage: cdt2a [0xa,0x7] spc6 */
{"PVCDG", CONTROL_MP, MSP_SPC_CDLT2A, -1, 7, 7, 4, 0,
"Perf versus command duration guidelines",
"Maximium percentage increase in average command completion times:\t"
"0: 0%\t1: 0.5%\t...\t6: 3%\t7: 4%\t8: 5%\t9: 8%\t10: 10%"
"11: 15%\t12: 20%"},
/* descriptor starts here, <start_byte> is relative to start of mode
* page (i.e. 8 more than shown in t10's descriptor format table) */
{"T2CDLU", CONTROL_MP, MSP_SPC_CDLT2A, -1, 8, 3, 4, MF_CLASH_OK,
"T2 command duration limit units", "0: none\t6: 500 nanoseconds\t"
"8: 1 microsecond\t10: 10 milliseconds\t14: 500 milliseconds"},
{"MXINATI", CONTROL_MP, MSP_SPC_CDLT2A, -1, 10, 7, 16, MF_CLASH_OK,
"Max inactive time", NULL},
{"MXACTTI", CONTROL_MP, MSP_SPC_CDLT2A, -1, 12, 7, 16, MF_CLASH_OK,
"Max active time", NULL},
{"MXINATP", CONTROL_MP, MSP_SPC_CDLT2A, -1, 14, 7, 4, MF_CLASH_OK,
"Max inactive time policy", "0: asap\t"
"13: good, completed, data currently unavailable\t"
"15: terminate, aborted command, command timeout before processing"},
{"MXACTTP", CONTROL_MP, MSP_SPC_CDLT2A, -1, 14, 3, 4, MF_CLASH_OK,
"Max active time policy", "0: asap\t"
"13: good, completed, data currently unavailable\t"
"14: as per 15, may report largest LBA processed"
"15: terminate, aborted command, command timeout before processing"},
{"CDGUID", CONTROL_MP, MSP_SPC_CDLT2A, -1, 18, 7, 16, MF_CLASH_OK,
"Command duration guideline",
"0: ignore\t>0: preferred command duration"},
{"CDGUPOL", CONTROL_MP, MSP_SPC_CDLT2A, -1, 22, 7, 16, MF_CLASH_OK,
"Command duration guideline policy", "0: asap\t"
"1: next highest CDL descriptor\t"
"2: continue as if no CDL\t"
"13: good, completed, data currently unavailable\t"
"15: terminate, aborted command, command timeout before processing"},
{"BYP_SEQ", CONTROL_MP, MSP_SPC_CDLT2A, -1, 23, 0, 1, MF_CLASH_OK,
"Bypass sequestration", NULL},
/* Command duration limit T2B mode subpage: cdt2b [0xa,0x8] spc6 */
{"PVLC", CONTROL_MP, MSP_SPC_CDLT2B, -1, 7, 3, 4, 0,
"Perf versus latency control",
"This field is not defined in SPC6r05??\t"
"Maximium percentage increase in average command completion times:\t"
"0: 0%\t1: 0.5%\t...\t6: 3%\t7: 4%\t8: 5%\t9: 8%\t10: 10%"
"11: 15%\t12: 20%"},
/* descriptor starts here, <start_byte> is relative to start of mode
* page (i.e. 8 more than shown in t10's descriptor format table) */
{"T2CDLU", CONTROL_MP, MSP_SPC_CDLT2B, -1, 8, 3, 4, MF_CLASH_OK,
"T2 command duration limit units", "0: none\t6: 500 nanoseconds\t"
"8: 1 microsecond\t10: 10 milliseconds\t14: 500 milliseconds"},
{"MXINATI", CONTROL_MP, MSP_SPC_CDLT2B, -1, 10, 7, 16, MF_CLASH_OK,
"Max inactive time", NULL},
{"MXACTTI", CONTROL_MP, MSP_SPC_CDLT2B, -1, 12, 7, 16, MF_CLASH_OK,
"Max active time", NULL},
{"MXINATP", CONTROL_MP, MSP_SPC_CDLT2B, -1, 14, 7, 4, MF_CLASH_OK,
"Max inactive time policy", "0: asap\t"
"13: good, completed, data currently unavailable\t"
"15: terminate, aborted command, command timeout before processing"},
{"MXACTTP", CONTROL_MP, MSP_SPC_CDLT2B, -1, 14, 3, 4, MF_CLASH_OK,
"Max active time policy", "0: asap\t"
"13: good, completed, data currently unavailable\t"
"14: as per 15, may report largest LBA processed"
"15: terminate, aborted command, command timeout before processing"},
{"CDGUID", CONTROL_MP, MSP_SPC_CDLT2B, -1, 18, 7, 16, MF_CLASH_OK,
"Command duration guideline",
"0: ignore\t>0: preferred command duration"},
{"CDGUPOL", CONTROL_MP, MSP_SPC_CDLT2B, -1, 22, 7, 16, MF_CLASH_OK,
"Command duration guideline policy", "0: asap\t"
"1: next highest CDL descriptor\t"
"2: continue as if no CDL\t"
"13: good, completed, data currently unavailable\t"
"15: terminate, aborted command, command timeout before processing"},
{"BYP_SEQ", CONTROL_MP, MSP_SPC_CDLT2B, -1, 23, 0, 1, MF_CLASH_OK,
"Bypass sequestration", NULL},
/* Zoned Block device Control mode subpage: zbcc [0xa,0x9] zbc2r04a */ /* Zoned Block device Control mode subpage: zbcc [0xa,0x9] zbc2r04a */
/* Probably only applies to host-managed ZBC (pdt=0x14) but set pdt=-1 /* Probably only applies to host-managed ZBC (pdt=0x14) but set pdt=-1
* in these entries in case it could apply to host-aware (pdt=0x0) */ * in these entries in case it could apply to host-aware (pdt=0x0) */
{"URSWRZ_M", CONTROL_MP, MSP_ZB_D_CTL, PDT_DISK_ZBC, 4, 0, 1, 0, {"URSWRZ_M", CONTROL_MP, MSP_ZB_D_CTL, PDT_DISK_ZBC, 4, 0, 1, 0,
"Unrestricted read in sequential write required management", "Unrestricted read in sequential write required management",
"0: not configure to support reading unwritten blocks\t" "0: not configure to support reading unwritten blocks\t"
"1: configure to support reading unwritten blocks"}, "1: configure to support reading unwritten blocks"},
{"U_UA_CTL", CONTROL_MP, MSP_ZB_D_CTL, PDT_DISK_ZBC, 5, 0, 1, 0, {"U_UA_CTL", CONTROL_MP, MSP_ZB_D_CTL, PDT_DISK_ZBC, 5, 0, 1, 0,
"Unrestricted read in sequential write required zone unit " "Unrestricted read in sequential write required zone unit "
"attention control", "attention control",
skipping to change at line 824 skipping to change at line 906
"Ultra DMA bit 4", NULL}, "Ultra DMA bit 4", NULL},
{"UDMA3", CONTROL_MP, MSP_SAT_PATA, -1, 5, 3, 1, 0, {"UDMA3", CONTROL_MP, MSP_SAT_PATA, -1, 5, 3, 1, 0,
"Ultra DMA bit 3", NULL}, "Ultra DMA bit 3", NULL},
{"UDMA2", CONTROL_MP, MSP_SAT_PATA, -1, 5, 2, 1, 0, {"UDMA2", CONTROL_MP, MSP_SAT_PATA, -1, 5, 2, 1, 0,
"Ultra DMA bit 2", NULL}, "Ultra DMA bit 2", NULL},
{"UDMA1", CONTROL_MP, MSP_SAT_PATA, -1, 5, 1, 1, 0, {"UDMA1", CONTROL_MP, MSP_SAT_PATA, -1, 5, 1, 1, 0,
"Ultra DMA bit 1", NULL}, "Ultra DMA bit 1", NULL},
{"UDMA0", CONTROL_MP, MSP_SAT_PATA, -1, 5, 0, 1, 0, {"UDMA0", CONTROL_MP, MSP_SAT_PATA, -1, 5, 0, 1, 0,
"Ultra DMA bit 0", NULL}, "Ultra DMA bit 0", NULL},
/* SAT: ATA feature control mode subpage: afc [0xa,0xf2] 20-085r4 */
/* treat as spc since could be disk or ATAPI */
{"CDL_CTRL", CONTROL_MP, MSP_SAT_AFC, -1, 4, 1, 2, 0,
"Command duration limits control",
"0: ATA 0->cdl_action, no CDL mpages supported\t"
"1: ATA 0->cdl_action, CDL A mpage supported, maybe CDL B\t"
"2: ATA 1->cdl_action, CDL T2A mpage supported, maybe CDL T2B"},
/* Notch and partition mode page [0xc] sbc2 (obsolete in sbc2r14) */ /* Notch and partition mode page [0xc] sbc2 (obsolete in sbc2r14) */
{"ND", NOTCH_MP, 0, PDT_DISK, 2, 7, 1, 0, {"ND", NOTCH_MP, 0, PDT_DISK, 2, 7, 1, 0,
"Notched device", NULL}, "Notched device", NULL},
{"LPN", NOTCH_MP, 0, PDT_DISK, 2, 6, 1, 0, {"LPN", NOTCH_MP, 0, PDT_DISK, 2, 6, 1, 0,
"Logical or physical notch", "0: physical; 1: logical"}, "Logical or physical notch", "0: physical; 1: logical"},
{"MNN", NOTCH_MP, 0, PDT_DISK, 4, 7, 16, 0, {"MNN", NOTCH_MP, 0, PDT_DISK, 4, 7, 16, 0,
"Maximum number of notches", NULL}, "Maximum number of notches", NULL},
{"ANOT", NOTCH_MP, 0, PDT_DISK, 6, 7, 16, 0, {"ANOT", NOTCH_MP, 0, PDT_DISK, 6, 7, 16, 0,
"Active notch", "origin 1, 0 for all"}, "Active notch", "origin 1, 0 for all"},
{"SBOU", NOTCH_MP, 0, PDT_DISK, 8, 7, 32, MF_HEX, {"SBOU", NOTCH_MP, 0, PDT_DISK, 8, 7, 32, MF_HEX,
skipping to change at line 1624 skipping to change at line 1714
{"MRAO", PROT_SPEC_PORT_MP, MSP_SPI_RTC, -1, 8, 7, 8, 0, {"MRAO", PROT_SPEC_PORT_MP, MSP_SPI_RTC, -1, 8, 7, 8, 0,
"Maximum REQ/ACK offset", NULL}, "Maximum REQ/ACK offset", NULL},
{"MTWE", PROT_SPEC_PORT_MP, MSP_SPI_RTC, -1, 9, 7, 8, 0, {"MTWE", PROT_SPEC_PORT_MP, MSP_SPI_RTC, -1, 9, 7, 8, 0,
"Maximum transfer width exponent", NULL}, "Maximum transfer width exponent", NULL},
{"POBS", PROT_SPEC_PORT_MP, MSP_SPI_RTC, -1, 10, 7, 8, 0, {"POBS", PROT_SPEC_PORT_MP, MSP_SPI_RTC, -1, 10, 7, 8, 0,
"Protocol option bits supported", NULL}, "Protocol option bits supported", NULL},
{NULL, 0, 0, 0, 0, 0, 0, 0, NULL, NULL}, {NULL, 0, 0, 0, 0, 0, 0, 0, NULL, NULL},
}; };
/* SRP == SCSI RDMA protocol */
static struct sdparm_mode_page_item sdparm_mitem_srp_arr[] = { static struct sdparm_mode_page_item sdparm_mitem_srp_arr[] = {
/* disconnect-reconnect mode page [0x2] srp */ /* disconnect-reconnect mode page [0x2] srp */
{"MBS", DISCONNECT_MP, 0, -1, 10, 7, 16, MF_COMMON | MF_CLASH_OK, {"MBS", DISCONNECT_MP, 0, -1, 10, 7, 16, MF_COMMON | MF_CLASH_OK,
"Maximum burst size (512 bytes)", NULL}, "Maximum burst size (512 bytes)", NULL},
{"EMDP", DISCONNECT_MP, 0, -1, 12, 7, 1, MF_CLASH_OK, {"EMDP", DISCONNECT_MP, 0, -1, 12, 7, 1, MF_CLASH_OK,
"Enable modify data pointers", NULL}, "Enable modify data pointers", NULL},
{"FBS", DISCONNECT_MP, 0, -1, 14, 7, 16, MF_CLASH_OK, {"FBS", DISCONNECT_MP, 0, -1, 14, 7, 16, MF_CLASH_OK,
"First burst size (512 bytes)", NULL}, /* srp2r00 */ "First burst size (512 bytes)", NULL}, /* srp2r00 */
{NULL, 0, 0, 0, 0, 0, 0, 0, NULL, NULL}, {NULL, 0, 0, 0, 0, 0, 0, 0, NULL, NULL},
}; };
/* SAS == Serial Attached SCSI */
static struct sdparm_mode_page_item sdparm_mitem_sas_arr[] = { static struct sdparm_mode_page_item sdparm_mitem_sas_arr[] = {
/* disconnect-reconnect mode page [0x2] sas/spl */ /* disconnect-reconnect mode page [0x2] sas/spl */
/* spl3r6 dropped the "time" from the name of BITL, keep acronym */ /* spl3r6 dropped the "time" from the name of BITL, keep acronym */
{"BITL", DISCONNECT_MP, 0, -1, 4, 7, 16, MF_COMMON, {"BITL", DISCONNECT_MP, 0, -1, 4, 7, 16, MF_COMMON,
"Bus inactivity (time) limit (100us)", "Bus inactivity (time) limit (100us or see BILUNIT)",
"0: no bus inactivity time limit\t" "0: no bus inactivity time limit\t"
"1-65535: limit in units of 100 us"}, "1-65535: limit in units of 100 us"},
{"MCTL", DISCONNECT_MP, 0, -1, 8, 7, 16, MF_COMMON, {"MCTL", DISCONNECT_MP, 0, -1, 8, 7, 16, MF_COMMON,
"Connect time limit (100us)", "Connect time limit (100us or see CTLUNIT)",
"0: no maximum connection time limit\t" "0: no maximum connection time limit\t"
"1-65535: limit in units of 100 us"}, "1-65535: limit in units of 100 us"},
{"MBS", DISCONNECT_MP, 0, -1, 10, 7, 16, MF_COMMON | MF_CLASH_OK, {"MBS", DISCONNECT_MP, 0, -1, 10, 7, 16, MF_COMMON | MF_CLASH_OK,
"Maximum burst size (512 bytes)", "Maximum burst size (512 bytes)",
"0: no maximum burst size\t" "0: no maximum burst size\t"
"1-65535: limit in units of 512 bytes\t" "1-65535: limit in units of 512 bytes\t"
"Ignored by persistent connections"}, "Ignored by persistent connections"},
/* obsoleted spl3r2, re-instated spl3r3 */ /* obsoleted spl3r2, re-instated spl3r3 */
{"FBS", DISCONNECT_MP, 0, -1, 14, 7, 16, MF_CLASH_OK, {"CTLUNIT", DISCONNECT_MP, 0, -1, 13, 3, 2, MF_CLASH_OK,
"Connect time limit unit",
"0: 100 microsecond unit\t"
"1: 1 microsecond unit\t"},
{"BILUNIT", DISCONNECT_MP, 0, -1, 13, 1, 2, MF_CLASH_OK, /* 21-021r3 */
"Bus inactivity (time) limit unit",
"0: 100 microsecond unit\t"
"1: 1 microsecond unit\t"},
{"FBS", DISCONNECT_MP, 0, -1, 14, 7, 16, MF_CLASH_OK, /* 21-021r3 */
"First burst size (512 bytes)", "First burst size (512 bytes)",
"0: no first burst size (no data-out before xfer_ready)\t" "0: no first burst size (no data-out before xfer_ready)\t"
"1-65535: maximum first burst size in units of 512 bytes"}, "1-65535: maximum first burst size in units of 512 bytes"},
/* protocol specific logical unit mode page [0x18] sas/spl */ /* protocol specific logical unit mode page [0x18] sas/spl */
{"LUPID", PROT_SPEC_LU_MP, 0, -1, 2, 3, 4, MF_COMMON | MF_CLASH_OK, {"LUPID", PROT_SPEC_LU_MP, 0, -1, 2, 3, 4, MF_COMMON | MF_CLASH_OK,
"Logical unit's (transport) protocol identifier", "Logical unit's (transport) protocol identifier",
PROTO_IDENT_STR }, PROTO_IDENT_STR },
{"TLR", PROT_SPEC_LU_MP, 0, -1, 2, 4, 1, MF_COMMON, {"TLR", PROT_SPEC_LU_MP, 0, -1, 2, 4, 1, MF_COMMON,
"Transport layer retries", "0: disabled; 1: enabled (on target)"}, "Transport layer retries", "0: disabled; 1: enabled (on target)"},
skipping to change at line 1845 skipping to change at line 1945
"Out of band protocol revision code", "Out of band protocol revision code",
"example: SFF-8609 revison 1.2 is code 0x102"}, "example: SFF-8609 revison 1.2 is code 0x102"},
{"OOB_D_ID", PROT_SPEC_PORT_MP, MSP_SAS_OOB_M_C, -1, 8, 3, 4, {"OOB_D_ID", PROT_SPEC_PORT_MP, MSP_SAS_OOB_M_C, -1, 8, 3, 4,
0, "Out of band descriptor identifier", 0, "Out of band descriptor identifier",
"0: temperature attribute; 1-15: restricted for SFF-8209"}, "0: temperature attribute; 1-15: restricted for SFF-8209"},
/* MF_DESC_ID_B0-3 bits are all zero for Temperature attribute */ /* MF_DESC_ID_B0-3 bits are all zero for Temperature attribute */
{"TA_TRE", PROT_SPEC_PORT_MP, MSP_SAS_OOB_M_C, -1, 12, 0, 1, MF_CLASH_OK, {"TA_TRE", PROT_SPEC_PORT_MP, MSP_SAS_OOB_M_C, -1, 12, 0, 1, MF_CLASH_OK,
"Temperature attribute, temperature reporting enabled", NULL}, "Temperature attribute, temperature reporting enabled", NULL},
{"TA_RI", PROT_SPEC_PORT_MP, MSP_SAS_OOB_M_C, -1, 13, 7, 8, MF_CLASH_OK, {"TA_RI", PROT_SPEC_PORT_MP, MSP_SAS_OOB_M_C, -1, 13, 7, 8, MF_CLASH_OK,
"Temperature attribute, reporting interval (seconds)", NULL}, "Temperature attribute, reporting interval (seconds)", NULL},
{"TA_MRI", PROT_SPEC_PORT_MP, MSP_SAS_OOB_M_C, -1, 14, 7, 8, MF_CLASH_OK,
"Temperature attribute, minimum reporting interval (seconds)", NULL},
{"TA_C_UP", PROT_SPEC_PORT_MP, MSP_SAS_OOB_M_C, -1, 15, 7, 4, MF_CLASH_OK,
"Temperature attribute, change up (Celsius)", NULL},
{"TA_C_DO", PROT_SPEC_PORT_MP, MSP_SAS_OOB_M_C, -1, 15, 3, 4, MF_CLASH_OK,
"Temperature attribute, change down (Celsius)", NULL},
{"TA_TM", PROT_SPEC_PORT_MP, MSP_SAS_OOB_M_C, -1, 16, 1, 2, MF_CLASH_OK, {"TA_TM", PROT_SPEC_PORT_MP, MSP_SAS_OOB_M_C, -1, 16, 1, 2, MF_CLASH_OK,
"Temperature attribute, test mode", "Temperature attribute, test mode",
"0: test mode disabled, transfer actual temperature\t" "0: test mode disabled, transfer actual temperature\t"
"1: TM enabled, send incrementing sequence of temps\t" "1: TM enabled, send incrementing sequence of temps\t"
"2: TM enabled, send decrementing sequence of temps\t" "2: TM enabled, send decrementing sequence of temps\t"
"3: TM enabled, send value in TA_TM_T every interval"}, "3: TM enabled, send value in TA_TM_T every interval"},
{"TA_TM_T", PROT_SPEC_PORT_MP, MSP_SAS_OOB_M_C, -1, 18, 7, 8, {"TA_TM_T", PROT_SPEC_PORT_MP, MSP_SAS_OOB_M_C, -1, 18, 7, 8,
MF_CLASH_OK | MF_TWOS_COMP, MF_CLASH_OK | MF_TWOS_COMP,
"Temperature attribute test mode temperature", NULL}, "Temperature attribute test mode temperature", NULL},
#if 0 #if 0
 End of changes. 17 change blocks. 
11 lines changed or deleted 117 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)