From patchwork Thu Mar 9 10:38:11 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Liu, Mingxia" X-Patchwork-Id: 124872 X-Patchwork-Delegate: ferruh.yigit@amd.com Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 4678E41E34; Thu, 9 Mar 2023 03:23:09 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 2802740ED7; Thu, 9 Mar 2023 03:23:09 +0100 (CET) Received: from mga17.intel.com (mga17.intel.com [192.55.52.151]) by mails.dpdk.org (Postfix) with ESMTP id 36F1B40A7E for ; Thu, 9 Mar 2023 03:23:07 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1678328587; x=1709864587; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=HUEqqVBqvr+rLqfvf4gAZOl++qQ8ad9IWbG/WOtI3hQ=; b=am3G49ZzCc27LROcLZGUA886diRRBqlQLSZFd3tWYyJqmzDVySlRwS78 Z2sYmh3tJg24jM14bQwaXQURcIMfy7rBV/Rv9b1spIYB1dn5ICnCLoMKs zlLZsazGVgU0LgFYNfiEnGnCsxFYDNXbgN3wAZ2acGAU1zQXIp/ym8tlF OSgOy8UWyqe2Swx9Bfr83Gda9iqPt/NMuXYZlpeBX0NAIpkif2bjIoHJk kUoxWwrBZfVNia8bMhHagi6QhfDLUODX39hnhl0wTZhcHQmvEpftGDHRz vUCBxZ0HbvvEc7nax3hiKlUMi4luaDA68yeCbdMc/fGyj7iR2LbQn4VWC w==; X-IronPort-AV: E=McAfee;i="6500,9779,10643"; a="316727778" X-IronPort-AV: E=Sophos;i="5.98,244,1673942400"; d="scan'208";a="316727778" Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmsmga107.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 08 Mar 2023 18:23:06 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6500,9779,10643"; a="820445679" X-IronPort-AV: E=Sophos;i="5.98,244,1673942400"; d="scan'208";a="820445679" Received: from dpdk-mingxial-ice.sh.intel.com ([10.67.110.153]) by fmsmga001.fm.intel.com with ESMTP; 08 Mar 2023 18:23:03 -0800 From: Mingxia Liu To: dev@dpdk.org, beilei.xing@intel.com, yuying.zhang@intel.com Cc: Mingxia Liu Subject: [PATCH v2] net/cpfl: fix a compiler issue about virtchnl opcode Date: Thu, 9 Mar 2023 10:38:11 +0000 Message-Id: <20230309103811.277553-1-mingxia.liu@intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230309103142.276726-1-mingxia.liu@intel.com> References: <20230309103142.276726-1-mingxia.liu@intel.com> MIME-Version: 1.0 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Comparing an enum virtchnl_ops variable with VIRTCHNL2_OP_EVENT will cause a compiler issue, as VIRTCHNL2_OP_EVENT is not included in enum virtchnl_ops. And the PMD uses virtual msg opcodes prefixed with virtchnl2 or VIRTCHNL2. Fixes: 20618563b81b ("net/cpfl: support device initialization") Signed-off-by: Mingxia Liu Reported-by: Raslan Darawsheh Acked-by: Ferruh Yigit --- drivers/net/cpfl/cpfl_ethdev.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/cpfl/cpfl_ethdev.c b/drivers/net/cpfl/cpfl_ethdev.c index 0940bf1276..54261d5743 100644 --- a/drivers/net/cpfl/cpfl_ethdev.c +++ b/drivers/net/cpfl/cpfl_ethdev.c @@ -1095,8 +1095,8 @@ cpfl_handle_virtchnl_msg(struct cpfl_adapter_ext *adapter) struct idpf_ctlq_msg ctlq_msg; enum idpf_mbx_opc mbx_op; struct idpf_vport *vport; - enum virtchnl_ops vc_op; uint16_t pending = 1; + uint32_t vc_op; int ret; while (pending) {