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 08DCE45B14; Fri, 11 Oct 2024 19:30:46 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 7706240DD3; Fri, 11 Oct 2024 19:30:41 +0200 (CEST) Received: from mail-pj1-f43.google.com (mail-pj1-f43.google.com [209.85.216.43]) by mails.dpdk.org (Postfix) with ESMTP id 8BA0840C35 for ; Fri, 11 Oct 2024 19:30:38 +0200 (CEST) Received: by mail-pj1-f43.google.com with SMTP id 98e67ed59e1d1-2e2ed59a35eso1088839a91.0 for ; Fri, 11 Oct 2024 10:30:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1728667838; x=1729272638; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=XislDraq5yOpmlJm3LViZHTrSGLdD8Dp0bzOmifZie4=; b=uFUwJpzVNndl2nAKCUMuv6XPeg3/Mz6xLwnJl5ezGjiwhRUdTUecf0xhAzPO++5lWj dWAE6HSs5y/HTnblSgUatZCY9mVgHlEj9A2VvEHhZjf14HRV8Hfak9YzUMB+Q8kgVllZ nK1wwMdgpJ7bTBTzWZ7R6B7xccNXHG7zr/n6eiNC/Awe2LAnS5SynqReOLihuZ8pT1PW iYSmNtSzf9LykdWd2yIwgj7aHzn4Dm7PitIvht065ZEr2pRIfhFPKlcSJ7BaiWEzvVZV yUvlch2XUsF3PFNFyMqJ5kN8jS4ZaSrr42WLE6Vdl4DIrWmihl7u13EqYW0U4+Kqd1+S yC8g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1728667838; x=1729272638; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=XislDraq5yOpmlJm3LViZHTrSGLdD8Dp0bzOmifZie4=; b=c9vfTCn3ikhwoB8GJ43aLYf6hpfQsVbT3JEYAdMQsBQMcEZjGG4LTNBRuniMUPpUWe DjVdbUWrIXGt8Hom63VLq7/usmivHeVb5IIxE4P7+18COgveJcyaTzBKpHAI4qHpd2ED dvj1a6OYMcXzhBmT/niZJGf9etE34+mWsOEie8lrPZ7BrOStIU/BgzX8t0Ii+0oxzZ0M DiKCbta+JEX7/OkmGGtBhMy0Y7KhugCG9CM49AoCMCSMY13ibpOMS21IVtzisoVRAzNE 50/eQmYpjmZH2Zbig0ZtIa0ydSNPBmUmAkF7tA+QA/mkLLuKUTzry9XZCtK0zDfuortN OWcw== X-Gm-Message-State: AOJu0YwfEucv1WPN//4ds1Y4BcKzuqRwajLAJppSvAGmD1qsoXMY6cT0 vrWptN8hQkS4uW1qx3rqFLoGy2L0RdcG2FKkEixDZeAOLPHVcG+JAVVLvkMBaXPM+PHxkvPWx39 j X-Google-Smtp-Source: AGHT+IE4uv1xzOvTHBjrTVKhpuZ8VPnw35nGRzzHk3GEVMkDRdIh2PpBJABeD9jUUEK8VU1DLQq4lw== X-Received: by 2002:a17:90a:d808:b0:2e2:f04d:9f0c with SMTP id 98e67ed59e1d1-2e2f0a68396mr5198200a91.13.1728667837778; Fri, 11 Oct 2024 10:30:37 -0700 (PDT) Received: from hermes.local (204-195-96-226.wavecable.com. [204.195.96.226]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-2e2a5aaae34sm5768328a91.46.2024.10.11.10.30.37 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 11 Oct 2024 10:30:37 -0700 (PDT) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger Subject: [PATCH 2/3] net/tap: add static assert to make sure max queues less than fd limit Date: Fri, 11 Oct 2024 10:29:24 -0700 Message-ID: <20241011173026.170884-3-stephen@networkplumber.org> X-Mailer: git-send-email 2.45.2 In-Reply-To: <20241011173026.170884-1-stephen@networkplumber.org> References: <20241011173026.170884-1-stephen@networkplumber.org> 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 Since tap needs to pass fd's between primary and secondary process. The number of tap queues must be less than the limit. Signed-off-by: Stephen Hemminger --- drivers/net/tap/rte_eth_tap.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/net/tap/rte_eth_tap.c b/drivers/net/tap/rte_eth_tap.c index c486c6f073..a7aa034a55 100644 --- a/drivers/net/tap/rte_eth_tap.c +++ b/drivers/net/tap/rte_eth_tap.c @@ -20,6 +20,7 @@ #include #include +#include #include #include #include @@ -71,6 +72,8 @@ #define TAP_MP_KEY "tap_mp_sync_queues" #define TAP_MP_REQ_START_RXTX "tap_mp_req_start_rxtx" +static_assert(RTE_PMD_TAP_MAX_QUEUES <= RTE_MP_MAX_FD_NUM, "TAP max queues exceeds MP fd limit"); + #define TAP_IOV_DEFAULT_MAX 1024 #define TAP_RX_OFFLOAD (RTE_ETH_RX_OFFLOAD_SCATTER | \ -- 2.45.2