From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 9E736440F2; Tue, 28 May 2024 10:18:52 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 5780840ED6; Tue, 28 May 2024 10:18:02 +0200 (CEST) Received: from mgamail.intel.com (mgamail.intel.com [198.175.65.13]) by mails.dpdk.org (Postfix) with ESMTP id 9A95F40E28 for ; Tue, 28 May 2024 10:17:57 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1716884278; x=1748420278; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=f2OjvKG1oKWasXQI+It4QNfbclmv7pUc6Wvp55k1v9E=; b=Kk2lO9wFbe4vGWnadv6Hn5eG7YcIUM5+Q/WT2J7P49Sl40TqrSCEDAD5 Pl3sUMghB0N9h9oJCxYwCqdJD225crRW2h3UNFHPU4G7FPbaHXsvyqIfz HcFXeapes/BqU3QXE9Z4ery+lfl5PriKyn91DidE7A848iD57NJnaE1M+ S7NKmxv+TfVBOzEVtBPmOSNqZM+4E8V8foU2KpuRctPDgKPrjD3Jbb8Gb XYi40SkiPnKn05W3n4OnCnpWs24+u2LBiKhcFm6GtrEROCBLB17nIK4vd A0+9dlk3t5QC5qmkMdTAxmMyCjn95+F3DXs3W1fwTsk59w/GDuYAc+kr6 A==; X-CSE-ConnectionGUID: kIaJUNUtR+qLRgo/HEsJ5w== X-CSE-MsgGUID: dq+qdfacRW+zKt7uVrGcUg== X-IronPort-AV: E=McAfee;i="6600,9927,11085"; a="24341025" X-IronPort-AV: E=Sophos;i="6.08,194,1712646000"; d="scan'208";a="24341025" Received: from fmviesa001.fm.intel.com ([10.60.135.141]) by orvoesa105.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 28 May 2024 01:17:57 -0700 X-CSE-ConnectionGUID: aojiezVPRJao7xNF4WMRVw== X-CSE-MsgGUID: 1uKLmTK+R5qTCBV8CcP4Jg== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,194,1712646000"; d="scan'208";a="66199153" Received: from unknown (HELO npf-hyd-clx-03..) ([10.145.170.182]) by fmviesa001.fm.intel.com with ESMTP; 28 May 2024 01:17:56 -0700 From: Soumyadeep Hore To: jingjing.wu@intel.com Cc: dev@dpdk.org Subject: [PATCH 23/25] common/idpf: redefining idpf vc queue switch Date: Tue, 28 May 2024 07:36:28 +0000 Message-ID: <20240528073630.867131-4-soumyadeep.hore@intel.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240528073630.867131-1-soumyadeep.hore@intel.com> References: <20240528073630.867131-1-soumyadeep.hore@intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 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 unint32_t type has been introduced in the function idpf_vc_queue_switch(). This helps in providing right queue type while calling the function. Signed-off-by: Soumyadeep Hore --- drivers/common/idpf/idpf_common_virtchnl.c | 8 ++------ drivers/common/idpf/idpf_common_virtchnl.h | 2 +- 2 files changed, 3 insertions(+), 7 deletions(-) diff --git a/drivers/common/idpf/idpf_common_virtchnl.c b/drivers/common/idpf/idpf_common_virtchnl.c index f00202f43c..de511da788 100644 --- a/drivers/common/idpf/idpf_common_virtchnl.c +++ b/drivers/common/idpf/idpf_common_virtchnl.c @@ -769,15 +769,11 @@ idpf_vc_ena_dis_one_queue(struct idpf_vport *vport, uint16_t qid, int idpf_vc_queue_switch(struct idpf_vport *vport, uint16_t qid, - bool rx, bool on) + bool rx, bool on, uint32_t type) { - uint32_t type; int err, queue_id; - /* switch txq/rxq */ - type = rx ? VIRTCHNL2_QUEUE_TYPE_RX : VIRTCHNL2_QUEUE_TYPE_TX; - - if (type == VIRTCHNL2_QUEUE_TYPE_RX) + if (rx) queue_id = vport->chunks_info.rx_start_qid + qid; else queue_id = vport->chunks_info.tx_start_qid + qid; diff --git a/drivers/common/idpf/idpf_common_virtchnl.h b/drivers/common/idpf/idpf_common_virtchnl.h index 73446ded86..d6555978d5 100644 --- a/drivers/common/idpf/idpf_common_virtchnl.h +++ b/drivers/common/idpf/idpf_common_virtchnl.h @@ -31,7 +31,7 @@ int idpf_vc_cmd_execute(struct idpf_adapter *adapter, struct idpf_cmd_info *args); __rte_internal int idpf_vc_queue_switch(struct idpf_vport *vport, uint16_t qid, - bool rx, bool on); + bool rx, bool on, uint32_t type); __rte_internal int idpf_vc_queues_ena_dis(struct idpf_vport *vport, bool enable); __rte_internal -- 2.43.0