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 4238E457C0; Wed, 14 Aug 2024 12:50:42 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id AB67742D76; Wed, 14 Aug 2024 12:50:28 +0200 (CEST) Received: from mgamail.intel.com (mgamail.intel.com [198.175.65.9]) by mails.dpdk.org (Postfix) with ESMTP id CFFEA427E1 for ; Wed, 14 Aug 2024 12:50:25 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1723632626; x=1755168626; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=W0/cSgOkquWz7axNybt8MM8q0O37h/YqBaBk67VpJyE=; b=TR/j/03LcmMUZnJ8z7aPvPKuAwatRvjbqHxsxgUx7+DqY9zKOkRHfIOn 3QPrCI7YyjVFUy+oueXMbKrW+2tt8IKSh5MZsS/Wp12LaBQSPKt0vW3qv RGKT2YiD/qNvn0eT9BdyZKbhVOKHrIM/81VAHrwHRAoBb4KI+Pf8Y2WzF k7pyYjXlAlMaGvNrmS41kN/o7LhYO3dV5SnsRKuAWkXkika5Rqsragn4l mba+506xW3YFi61HTV+eQ+FUJY9P7n7fr8+iHifb2oKXpL4LukiJESwEt WEG0mJws5PqWuI+kqbF1nyeYDolVL83oCmdHdWcOZiy+yXrQhbF2Vdr2I A==; X-CSE-ConnectionGUID: Jr4baivlS66BfUtXW7W+Qg== X-CSE-MsgGUID: sq7Kt3oXTNyQFw8pUEiGLA== X-IronPort-AV: E=McAfee;i="6700,10204,11163"; a="44360267" X-IronPort-AV: E=Sophos;i="6.09,145,1716274800"; d="scan'208";a="44360267" Received: from orviesa001.jf.intel.com ([10.64.159.141]) by orvoesa101.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 14 Aug 2024 03:50:25 -0700 X-CSE-ConnectionGUID: maCiFxwfRze+qW7xmqUlgw== X-CSE-MsgGUID: OA+Vsby7RvO8aGDxTq/b9A== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.09,145,1716274800"; d="scan'208";a="96481677" Received: from unknown (HELO silpixa00401385.ir.intel.com) ([10.237.214.25]) by orviesa001.jf.intel.com with ESMTP; 14 Aug 2024 03:50:24 -0700 From: Bruce Richardson To: dev@dpdk.org Cc: ferruh.yigit@amd.com, thomas@monjalon.net, mb@smartsharesystems.com, Bruce Richardson Subject: [PATCH v3 06/26] bpf: use separate Rx and Tx queue limits Date: Wed, 14 Aug 2024 11:49:12 +0100 Message-ID: <20240814104933.14062-7-bruce.richardson@intel.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240814104933.14062-1-bruce.richardson@intel.com> References: <20240812132910.162252-1-bruce.richardson@intel.com> <20240814104933.14062-1-bruce.richardson@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 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 Update library to use the new defines RTE_MAX_ETHPORT_TX_QUEUES and RTE_MAX_ETHPORT_RX_QUEUES rather than the old define RTE_MAX_QUEUES_PER_PORT. Signed-off-by: Bruce Richardson Acked-by: Morten Brørup --- lib/bpf/bpf_pkt.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/bpf/bpf_pkt.c b/lib/bpf/bpf_pkt.c index aaca935f2d..2c6b0e18f7 100644 --- a/lib/bpf/bpf_pkt.c +++ b/lib/bpf/bpf_pkt.c @@ -503,7 +503,8 @@ bpf_eth_elf_load(struct bpf_eth_cbh *cbh, uint16_t port, uint16_t queue, ftx = NULL; if (prm == NULL || rte_eth_dev_is_valid_port(port) == 0 || - queue >= RTE_MAX_QUEUES_PER_PORT) + queue >= (cbh->type == BPF_ETH_RX ? + RTE_MAX_ETHPORT_RX_QUEUES : RTE_MAX_ETHPORT_TX_QUEUES)) return -EINVAL; if (cbh->type == BPF_ETH_RX) -- 2.43.0