Commit a93755cf authored by Chad Dupuis's avatar Chad Dupuis Committed by Martin K. Petersen

scsi: qedf: Sanity check FCoE/FIP priority value to make sure it's between 0 and 7

Signed-off-by: default avatarChad Dupuis <chad.dupuis@cavium.com>
Signed-off-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
parent 766639ca
......@@ -3405,6 +3405,13 @@ static int __init qedf_init(void)
if (qedf_debug == QEDF_LOG_DEFAULT)
qedf_debug = QEDF_DEFAULT_LOG_MASK;
/* Check that default prio for FIP/FCoE traffic is between 0..7 */
if (qedf_default_prio > 7) {
qedf_default_prio = QEDF_DEFAULT_PRIO;
QEDF_ERR(NULL, "FCoE/FIP priority out of range, resetting to %d.\n",
QEDF_DEFAULT_PRIO);
}
/* Print driver banner */
QEDF_INFO(NULL, QEDF_LOG_INFO, "%s v%s.\n", QEDF_DESCR,
QEDF_VERSION);
......
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