Commit bd7de0b1 authored by Joe Carnuccio's avatar Joe Carnuccio Committed by Martin K. Petersen

scsi: qla2xxx: Add ql2xrdpenable module parameter for RDP

This patch provides separate module parameter ql2xrdpenable to turn on/off
RDP capability in the driver. However, if ql2xsmartsan parameter is
enabled, it will also turn on ql2xfdmienable parameter since it is required
for RDP to work.

Link: https://lore.kernel.org/r/20200212214436.25532-9-hmadhani@marvell.comSigned-off-by: default avatarJoe Carnuccio <joe.carnuccio@qlogic.com>
Signed-off-by: default avatarHimanshu Madhani <hmadhani@marvell.com>
Signed-off-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
parent d83a80ee
......@@ -144,6 +144,7 @@ extern int qlport_down_retry;
extern int ql2xplogiabsentdevice;
extern int ql2xloginretrycount;
extern int ql2xfdmienable;
extern int ql2xrdpenable;
extern int ql2xsmartsan;
extern int ql2xallocfwdump;
extern int ql2xextended_error_logging;
......
......@@ -2270,6 +2270,12 @@ qla2x00_initialize_adapter(scsi_qla_host_t *vha)
ql_dbg(ql_dbg_init, vha, 0x0078,
"Verifying loaded RISC code...\n");
/* If smartsan enabled then require fdmi and rdp enabled */
if (ql2xsmartsan) {
ql2xfdmienable = 1;
ql2xrdpenable = 1;
}
if (qla2x00_isp_firmware(vha) != QLA_SUCCESS) {
rval = ha->isp_ops->chip_diag(vha);
if (rval)
......@@ -3710,7 +3716,7 @@ qla2x00_setup_chip(scsi_qla_host_t *vha)
}
/* Enable PUREX PASSTHRU */
if (ql2xsmartsan)
if (ql2xrdpenable)
qla25xx_set_els_cmds_supported(vha);
} else
goto failed;
......@@ -3945,7 +3951,7 @@ qla24xx_update_fw_options(scsi_qla_host_t *vha)
}
enable_purex:
if (ql2xsmartsan)
if (ql2xrdpenable)
ha->fw_options[1] |= ADD_FO1_ENABLE_PUREX_IOCB;
qla2x00_set_fw_options(vha, ha->fw_options);
......@@ -8682,7 +8688,7 @@ qla83xx_update_fw_options(scsi_qla_host_t *vha)
{
struct qla_hw_data *ha = vha->hw;
if (ql2xsmartsan)
if (ql2xrdpenable)
ha->fw_options[1] |= ADD_FO1_ENABLE_PUREX_IOCB;
qla2x00_set_fw_options(vha, ha->fw_options);
......
......@@ -113,7 +113,8 @@ module_param(ql2xfdmienable, int, S_IRUGO|S_IWUSR);
module_param_named(fdmi, ql2xfdmienable, int, S_IRUGO|S_IWUSR);
MODULE_PARM_DESC(ql2xfdmienable,
"Enables FDMI registrations. "
"0 - no FDMI. Default is 1 - perform FDMI.");
"0 - no FDMI registrations. "
"1 - provide FDMI registrations (default).");
#define MAX_Q_DEPTH 64
static int ql2xmaxqdepth = MAX_Q_DEPTH;
......@@ -314,6 +315,13 @@ MODULE_PARM_DESC(ql2xsmartsan,
" Default is 0 - No SmartSAN registration,"
" 1 - Register SmartSAN Management Attributes.");
int ql2xrdpenable;
module_param(ql2xrdpenable, int, 0444);
module_param_named(rdpenable, ql2xrdpenable, int, 0444);
MODULE_PARM_DESC(ql2xrdpenable,
"Enables RDP responses. "
"0 - no RDP responses (default). "
"1 - provide RDP responses.");
static void qla2x00_clear_drv_active(struct qla_hw_data *);
static void qla2x00_free_device(scsi_qla_host_t *);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment