From patchwork Thu Nov 7 22:48:55 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Martin Wilck X-Patchwork-Id: 11233871 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id D35CE13BD for ; Thu, 7 Nov 2019 22:50:55 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id B09DE21D82 for ; Thu, 7 Nov 2019 22:50:55 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727609AbfKGWuz convert rfc822-to-8bit (ORCPT ); Thu, 7 Nov 2019 17:50:55 -0500 Received: from m4a0040g.houston.softwaregrp.com ([15.124.2.86]:40435 "EHLO m4a0040g.houston.softwaregrp.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725992AbfKGWuz (ORCPT ); Thu, 7 Nov 2019 17:50:55 -0500 Received: FROM m4a0040g.houston.softwaregrp.com (15.120.17.147) BY m4a0040g.houston.softwaregrp.com WITH ESMTP; Thu, 7 Nov 2019 22:49:09 +0000 Received: from M9W0068.microfocus.com (2002:f79:bf::f79:bf) by M4W0335.microfocus.com (2002:f78:1193::f78:1193) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1591.10; Thu, 7 Nov 2019 22:48:56 +0000 Received: from NAM01-SN1-obe.outbound.protection.outlook.com (15.124.72.14) by M9W0068.microfocus.com (15.121.0.191) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1591.10 via Frontend Transport; Thu, 7 Nov 2019 22:48:56 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=LrkRjSpBEA+foeVxG/7DsIXDyRGzo41b9GMAONoP8lgXPUh2CcfqdeKsf7K4WtukJevzkJnHfggjUPBf0fXgoBqs6xz6ODYwDIvOBP8VSXyEkxnHcASZSo42t8eCqurmBp9avpNIcsWpWtoAyTlPPkaKNjcyDD30Er0EdiFJwX5uAOyyidCsqwrNHem1PflQRpfAtd1bQisSAh4LWPAcv78gel0X33tXI75yRTUESJm2LXAXgQP/91UFUyGXD6KcwoJQg/jqoxTV1eQ2JjNjtBuniELv+NdvgIfSu9SlcounIqJNveFNNdfPuaLtyzT6h1gzOxcmkvr2MKCFYxYaNg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=v4TogJAexhu64Nvn3N3GUPKxKoi/TUF0EQsDCs5oxhU=; b=m+mPwcp1bxTxnTkdpVjzZ+qSoxeJT8yud6nTF7m4LY1EtANbZpXNIu+7kw/ePZbiy41phP5SZ8zycaA3UXq6XrMYD6gQ9bG8vU3EMN/kzDJYHPY9pWcQDhGM7MW3PlBI5Khn3QsWsiy7zVjnCwDgADHfgjnssG+03bG4n6gQEDdBusrGSja2CdUpF3t6uFl5pxD/svIdkOYAkVQ8f12UcmgvAiM3AQ7KBnZbmVVTO9g2hUxZDQv7ufz1kk77WoA1fgEMLqBX7K6Z62UlBOLKQdqliuYpK/tEwvb9BivwdvnvR8klJsvADP8pXX1FKwzCwKVpuEo1ABbN1cdAxNoq1g== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=suse.com; dmarc=pass action=none header.from=suse.com; dkim=pass header.d=suse.com; arc=none Received: from DM5PR18MB1355.namprd18.prod.outlook.com (10.175.223.16) by DM5PR18MB1116.namprd18.prod.outlook.com (10.168.113.141) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2430.20; Thu, 7 Nov 2019 22:48:55 +0000 Received: from DM5PR18MB1355.namprd18.prod.outlook.com ([fe80::d1db:c70a:b831:8150]) by DM5PR18MB1355.namprd18.prod.outlook.com ([fe80::d1db:c70a:b831:8150%5]) with mapi id 15.20.2408.024; Thu, 7 Nov 2019 22:48:55 +0000 From: Martin Wilck To: "Martin K. Petersen" , Himanshu Madhani , Michael Hernandez , "Bart Van Assche" CC: James Bottomley , "linux-scsi@vger.kernel.org" , Martin Wilck , "David Bond" , Bart Van Assche Subject: [PATCH v2 1/2] scsi: qla2xxx: initialize fc4_type_priority Thread-Topic: [PATCH v2 1/2] scsi: qla2xxx: initialize fc4_type_priority Thread-Index: AQHVlb2IT0UWn/slXkOlmVuw91WWFg== Date: Thu, 7 Nov 2019 22:48:55 +0000 Message-ID: <20191107224839.32417-2-martin.wilck@suse.com> References: <20191107224839.32417-1-martin.wilck@suse.com> In-Reply-To: <20191107224839.32417-1-martin.wilck@suse.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-clientproxiedby: AM0PR04CA0010.eurprd04.prod.outlook.com (2603:10a6:208:122::23) To DM5PR18MB1355.namprd18.prod.outlook.com (2603:10b6:3:14a::16) authentication-results: spf=none (sender IP is ) smtp.mailfrom=Martin.Wilck@suse.com; x-ms-exchange-messagesentrepresentingtype: 1 x-mailer: git-send-email 2.23.0 x-originating-ip: [2.206.153.8] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 031f5cc3-327a-49b5-a383-08d763d4ab44 x-ms-traffictypediagnostic: DM5PR18MB1116:|DM5PR18MB1116: x-ld-processed: 856b813c-16e5-49a5-85ec-6f081e13b527,ExtFwd,ExtAddr x-ms-exchange-transport-forked: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:478; x-forefront-prvs: 0214EB3F68 x-forefront-antispam-report: SFV:NSPM;SFS:(10019020)(4636009)(136003)(39860400002)(366004)(346002)(396003)(376002)(199004)(189003)(2906002)(316002)(52116002)(86362001)(8936002)(66066001)(1076003)(486006)(476003)(6512007)(71200400001)(71190400001)(6486002)(36756003)(44832011)(76176011)(386003)(6506007)(186003)(50226002)(1691005)(14454004)(66946007)(256004)(8676002)(478600001)(5660300002)(25786009)(4326008)(6436002)(99286004)(54906003)(7736002)(66476007)(3846002)(66556008)(64756008)(26005)(81156014)(66446008)(6116002)(11346002)(81166006)(102836004)(2616005)(305945005)(446003)(110136005);DIR:OUT;SFP:1102;SCL:1;SRVR:DM5PR18MB1116;H:DM5PR18MB1355.namprd18.prod.outlook.com;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;A:1;MX:1; received-spf: None (protection.outlook.com: suse.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: /jtu9AITLyMkDcnXUZbi9i4KvQEXrU4xEENcPpIEOT3ccJmSLFvYT9EY7CcG8gUanxJr/KRAJmU4a2waVDlaYcIi/HUKktzrbRpvzcgMhqYApJnVax17+aAYm0BYpGYAUYeYWScYo6qx3Eb/lhactBjr2eHUxNS7r3zryHjtTNgL1sZCBGUP0EOHK16FD4JNCwmGFuH+j3GnUTLDsSzpBKMivtXI0mXDGBXBivKmghA0KFWyxdTPTJSjqNxTEirqgwRBeFjX8Lm1m5qpbdFChpTt7NvZUofjr3HDlmFr5KuGeEujLyiPrb+4g2khY79pfqomffZo+QeIoCUc4+mom6ISVLCn+beMgoEWD1+uhCe0R4jF0wAM0PyB38SH6y+h70dwO0cJ7rXNPoNzNTrASHktvliIVNAg+p0itroryOJG6vpS9ezsFqgzw5A1iLc2 MIME-Version: 1.0 X-MS-Exchange-CrossTenant-Network-Message-Id: 031f5cc3-327a-49b5-a383-08d763d4ab44 X-MS-Exchange-CrossTenant-originalarrivaltime: 07 Nov 2019 22:48:55.6202 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 856b813c-16e5-49a5-85ec-6f081e13b527 X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: 55R/Z5V5TziT137zj7b6aTW4Qk1Xzd899THSoSVVpS+9WGq90R0jVFeASIuz7rqsg/YDPXo6tT5FhDBQJPPrkg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR18MB1116 X-OriginatorOrg: suse.com Sender: linux-scsi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-scsi@vger.kernel.org From: Martin Wilck ha->fc4_type_priority is currently initialized only in qla81xx_nvram_config(). That makes it default to NVMe for other adapters. Fix it. Fixes: 84ed362ac40c ("scsi: qla2xxx: Dual FCP-NVMe target port support") Signed-off-by: Martin Wilck Tested-by: David Bond Acked-by: Himanshu Madhani Reviewed-by: Bart Van Assche --- drivers/scsi/qla2xxx/qla_init.c | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/drivers/scsi/qla2xxx/qla_init.c b/drivers/scsi/qla2xxx/qla_init.c index 7cb7545..2a016a8 100644 --- a/drivers/scsi/qla2xxx/qla_init.c +++ b/drivers/scsi/qla2xxx/qla_init.c @@ -2214,8 +2214,18 @@ qla2x00_initialize_adapter(scsi_qla_host_t *vha) ql_dbg(ql_dbg_init, vha, 0x0061, "Configure NVRAM parameters...\n"); + /* Let priority default to FCP, can be overridden by nvram_config */ + ha->fc4_type_priority = FC4_PRIORITY_FCP; + ha->isp_ops->nvram_config(vha); + if (ha->fc4_type_priority != FC4_PRIORITY_FCP && + ha->fc4_type_priority != FC4_PRIORITY_NVME) + ha->fc4_type_priority = FC4_PRIORITY_FCP; + + ql_log(ql_log_info, vha, 0xffff, "FC4 priority set to %s\n", + ha->fc4_type_priority == FC4_PRIORITY_FCP ? "FCP" : "NVMe"); + if (ha->flags.disable_serdes) { /* Mask HBA via NVRAM settings? */ ql_log(ql_log_info, vha, 0x0077, @@ -8521,8 +8531,6 @@ qla81xx_nvram_config(scsi_qla_host_t *vha) /* Determine NVMe/FCP priority for target ports */ ha->fc4_type_priority = qla2xxx_get_fc4_priority(vha); - ql_log(ql_log_info, vha, 0xffff, "FC4 priority set to %s\n", - ha->fc4_type_priority & BIT_0 ? "FCP" : "NVMe"); if (rval) { ql_log(ql_log_warn, vha, 0x0076, From patchwork Thu Nov 7 22:48:57 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Martin Wilck X-Patchwork-Id: 11233869 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 5689613BD for ; Thu, 7 Nov 2019 22:50:18 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 3301321D7B for ; Thu, 7 Nov 2019 22:50:18 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728156AbfKGWuS convert rfc822-to-8bit (ORCPT ); Thu, 7 Nov 2019 17:50:18 -0500 Received: from m9a0001g.houston.softwaregrp.com ([15.124.64.66]:40588 "EHLO m9a0001g.houston.softwaregrp.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728051AbfKGWuR (ORCPT ); Thu, 7 Nov 2019 17:50:17 -0500 Received: FROM m9a0001g.houston.softwaregrp.com (15.121.0.191) BY m9a0001g.houston.softwaregrp.com WITH ESMTP; Thu, 7 Nov 2019 22:49:37 +0000 Received: from M9W0067.microfocus.com (2002:f79:be::f79:be) by M9W0068.microfocus.com (2002:f79:bf::f79:bf) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1591.10; Thu, 7 Nov 2019 22:48:58 +0000 Received: from NAM01-SN1-obe.outbound.protection.outlook.com (15.124.72.14) by M9W0067.microfocus.com (15.121.0.190) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1591.10 via Frontend Transport; Thu, 7 Nov 2019 22:48:58 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=ZzpzBivzlzeaxzQWXQ7EiTrXGo5UnM7wnu4DqZ5+q6RMVSPOmNC433l5Lo7S6nKi25kFi5qPAJw7BWeIRWZ54pSt44Td9DVBcn/AZoo7G6Mg6N0FzZEBiu3dZL/l8tTijpiPgD+xUdW2oIQPJLMTRMMETUjG3jlxPrQIFx+P6islIa41CEPZzzV17q27zD5HZ4Vx55RL8f7nXb8pdHxcrxcJwKvJQ/zS//sZ2fT+DzU/Hmq2lpL4jlP3P2tooI3q2b5RSwIhuY+kzDraKSSt+gsYMfyIoslft91y0X7SGp2OGzegZlGAP6NR9N4Qc3ae8YYHbk+ByfU6R7byaev9fw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=lv0W1mXVHH4U7RpmDMygWa4QOaVqxqTc/EwgEqYUMJ0=; b=iWXRabtRAFgzRip+x5O7JLiBMG2Q9JqqhVMYptaj23HTsf4mB4mRf26rstj8kDdU9pYtOgqyZU7XKUCMHqaSYhae0cBHorILC+b6+1VxzXghcFNTbJe9S+KGPLXpeQwgy7lgMCPswb61+JeUxIqBoPmkYfnbq0QQB/7UnLxP+SFMns6ZVd4HRDczISDtdVXc2c89dYrWoEJiuQpYvMGUAOU0L5EJ6yH0y5wcJvFN9UaqFrZwL9N70G6NxXAMyugSul38UfehmpEz0UEdcSDEW2zO64qa1MLauBnqyLvL5cQr6H3Fkz2GL7fGMfqHXvwqDLwk6jkkn37nsMVyadQkng== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=suse.com; dmarc=pass action=none header.from=suse.com; dkim=pass header.d=suse.com; arc=none Received: from DM5PR18MB1355.namprd18.prod.outlook.com (10.175.223.16) by DM5PR18MB1116.namprd18.prod.outlook.com (10.168.113.141) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2430.20; Thu, 7 Nov 2019 22:48:57 +0000 Received: from DM5PR18MB1355.namprd18.prod.outlook.com ([fe80::d1db:c70a:b831:8150]) by DM5PR18MB1355.namprd18.prod.outlook.com ([fe80::d1db:c70a:b831:8150%5]) with mapi id 15.20.2408.024; Thu, 7 Nov 2019 22:48:57 +0000 From: Martin Wilck To: "Martin K. Petersen" , Himanshu Madhani , Michael Hernandez , "Bart Van Assche" CC: James Bottomley , "linux-scsi@vger.kernel.org" , Martin Wilck , "David Bond" Subject: [PATCH v2 2/2] scsi: qla2xxx: don't use zero for FC4_PRIORITY_NVME Thread-Topic: [PATCH v2 2/2] scsi: qla2xxx: don't use zero for FC4_PRIORITY_NVME Thread-Index: AQHVlb2KYQOt5Eqg+E6o7XqGYh0Xow== Date: Thu, 7 Nov 2019 22:48:57 +0000 Message-ID: <20191107224839.32417-3-martin.wilck@suse.com> References: <20191107224839.32417-1-martin.wilck@suse.com> In-Reply-To: <20191107224839.32417-1-martin.wilck@suse.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-clientproxiedby: AM0PR04CA0010.eurprd04.prod.outlook.com (2603:10a6:208:122::23) To DM5PR18MB1355.namprd18.prod.outlook.com (2603:10b6:3:14a::16) authentication-results: spf=none (sender IP is ) smtp.mailfrom=Martin.Wilck@suse.com; x-ms-exchange-messagesentrepresentingtype: 1 x-mailer: git-send-email 2.23.0 x-originating-ip: [2.206.153.8] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 1d928693-85fc-4317-b723-08d763d4ac5f x-ms-traffictypediagnostic: DM5PR18MB1116:|DM5PR18MB1116: x-ld-processed: 856b813c-16e5-49a5-85ec-6f081e13b527,ExtFwd,ExtAddr x-ms-exchange-transport-forked: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:5797; x-forefront-prvs: 0214EB3F68 x-forefront-antispam-report: SFV:NSPM;SFS:(10019020)(4636009)(136003)(39860400002)(366004)(346002)(396003)(376002)(199004)(189003)(2906002)(316002)(52116002)(86362001)(8936002)(66066001)(1076003)(486006)(476003)(6512007)(71200400001)(71190400001)(6486002)(36756003)(44832011)(76176011)(386003)(6506007)(186003)(50226002)(1691005)(14454004)(66946007)(256004)(8676002)(478600001)(5660300002)(25786009)(4326008)(6436002)(99286004)(54906003)(7736002)(66476007)(3846002)(66556008)(64756008)(26005)(107886003)(81156014)(66446008)(6116002)(11346002)(81166006)(102836004)(2616005)(305945005)(446003)(110136005);DIR:OUT;SFP:1102;SCL:1;SRVR:DM5PR18MB1116;H:DM5PR18MB1355.namprd18.prod.outlook.com;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;A:1;MX:1; received-spf: None (protection.outlook.com: suse.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: NlnhfPmVrPavc1USJLAfsTDRm6HkKa0CeSlp0/pNVaMSAYEsxMNgrF7s37qLryZN3zAg0t6gQww0Xshcc6Gguiv09rG8Sf3f7p6w1XDNBpGjoLI/5GBRceai3AJY3lLIIYIQuNbog/L8Fnlx+LLUQAaViVPbdRnijpQUAXR0TseZeoQoath0iI/U/EqQCagkh5WDs1LikpmBk35DQ6y7d3HfmBv03Gyg68zEnc2jlX3fh8VVBZpS0WGcA9NsmzawP35xgZpIyEebrQ3Jbsky6aZmJqBdjjlPREnJICjx2xbTGW5WsVDmuy4U879lFL82VBttlPF+2KlyDYlswpFIr2foJnH3h/HW+scqNNOnvnXYnVdRgAlr7diwYjbzllW7Whda6kSzAxJYo5IpUvYGnZOkiRsSC2Cj1epVPqKMYN4eY6JZkl/6zS30ycsIwB6+ MIME-Version: 1.0 X-MS-Exchange-CrossTenant-Network-Message-Id: 1d928693-85fc-4317-b723-08d763d4ac5f X-MS-Exchange-CrossTenant-originalarrivaltime: 07 Nov 2019 22:48:57.4414 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 856b813c-16e5-49a5-85ec-6f081e13b527 X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: OIWEGRMqcD7VPat+TwNLHxPtC/mNZm23qYf3mIlEVovRWo69/BOBxySeHezRJxf/FbdmddvB7aLGc/ylzvBpxg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR18MB1116 X-OriginatorOrg: suse.com Sender: linux-scsi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-scsi@vger.kernel.org From: Martin Wilck Avoid an uninitialized value (0) for ha->fc4_type_priority being falsely interpreted as NVMe priority. Not strictly needed any more after the previous patch, but makes the fc4_type_priority handling more explicit. Signed-off-by: Martin Wilck Tested-by: David Bond Acked-by: Himanshu Madhani Reviewed-by: Bart Van Assche --- drivers/scsi/qla2xxx/qla_def.h | 6 ++++-- drivers/scsi/qla2xxx/qla_inline.h | 2 +- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/drivers/scsi/qla2xxx/qla_def.h b/drivers/scsi/qla2xxx/qla_def.h index 721ee7f..86c5155 100644 --- a/drivers/scsi/qla2xxx/qla_def.h +++ b/drivers/scsi/qla2xxx/qla_def.h @@ -2476,8 +2476,10 @@ typedef struct fc_port { u16 n2n_chip_reset; } fc_port_t; -#define FC4_PRIORITY_NVME 0 -#define FC4_PRIORITY_FCP 1 +enum { + FC4_PRIORITY_NVME = 1, + FC4_PRIORITY_FCP = 2, +}; #define QLA_FCPORT_SCAN 1 #define QLA_FCPORT_FOUND 2 diff --git a/drivers/scsi/qla2xxx/qla_inline.h b/drivers/scsi/qla2xxx/qla_inline.h index d728b17..352aba4 100644 --- a/drivers/scsi/qla2xxx/qla_inline.h +++ b/drivers/scsi/qla2xxx/qla_inline.h @@ -317,5 +317,5 @@ qla2xxx_get_fc4_priority(struct scsi_qla_host *vha) ((uint8_t *)vha->hw->nvram)[NVRAM_DUAL_FCP_NVME_FLAG_OFFSET]; - return ((data >> 6) & BIT_0); + return (data >> 6) & BIT_0 ? FC4_PRIORITY_FCP : FC4_PRIORITY_NVME; }