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 F13A341CE2; Sun, 19 Feb 2023 18:50:29 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 16E4842D3B; Sun, 19 Feb 2023 18:50:24 +0100 (CET) Received: from mail-pj1-f43.google.com (mail-pj1-f43.google.com [209.85.216.43]) by mails.dpdk.org (Postfix) with ESMTP id 57E5440698 for ; Sun, 19 Feb 2023 18:50:18 +0100 (CET) Received: by mail-pj1-f43.google.com with SMTP id cp9so211383pjb.0 for ; Sun, 19 Feb 2023 09:50:18 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20210112.gappssmtp.com; s=20210112; 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=YlQk95R+o2GZ1yE7eW56Qjn3lhaJLbMjvt10+rGFfQY=; b=06RHnDzcv2r6Amldvj40fyghKPt1vAIVr1lon7pHMvrq8myxP0WIIlz7eADC9mqDdD Y7c8PAFmHvVOCUQVWE7H5DiNrxT07j04Qn/SuqBlLb3x7qQgsb02z2yhTQ6RszVVmtmA wFs66sOpcaBquCFHs8X3ObSo6qckc0rlywGA51JpXkDtMiYaOLZ789G+j+QbkPMNZHo9 A9u/iLqEtYAZ5dtkPVkbhhiBHJ/las1Ec3lXW663Q2wOV2/5yULEnK2sF7+8kdDkXoOg SZWRcWybChIBNZVRE9uEnIzAU5EvLIIzEi225S/+szCK1RHwvtOdB26HftC4TCfmsPnf lpAQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; 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=YlQk95R+o2GZ1yE7eW56Qjn3lhaJLbMjvt10+rGFfQY=; b=BokexdOFWmmZZLnERxPkFKtZX7VwMOyULX8vQX0gHNd1gRc0GO37DXTS1jffZGWfhO yP16aJH+scvldIHXdrTpRotXoqlW+dgTsR6chPcr7jzWCXemw/7oTr7HS4oxWWysmMAJ 33YIALMs6YhdM8NtD07uB18jU/mQitylv0dI0oLtSHmTC4qySQJerVDdYFUpCSqnGyIP bxBsi8Kdir/YcwbR9XsQcAiAbG/whXTtnKTGh+r4lnjX8iJFrHuoxeQ+gvzXE/L5IDl0 EDN/G4Ewh6Bt4Xdh5BhtU+aY7X+3TB3LxBOk68S1zAo4z8r7MUjHdhjOJp9kzpKUfZ4i Hmjg== X-Gm-Message-State: AO0yUKWXauT0SQKG8m4E8IOHCEYfV+rOCtmuRWqqU9h+7FLsWiTERUrF +dkKDwLH8bm3nfqkmSYrXjy1b4KnZA+1uOMwfeY= X-Google-Smtp-Source: AK7set9cGysENj7MjiOl1H0d2qKRpuPqoYQL5HBQLq7rFLje1OHtDuM9q0G42kYggEdc1VlQTN69KQ== X-Received: by 2002:a17:902:da91:b0:19a:f02c:a05b with SMTP id j17-20020a170902da9100b0019af02ca05bmr2238943plx.3.1676829017548; Sun, 19 Feb 2023 09:50:17 -0800 (PST) Received: from hermes.local (204-195-120-218.wavecable.com. [204.195.120.218]) by smtp.gmail.com with ESMTPSA id a13-20020a170902b58d00b001991e4e0bdcsm6238408pls.233.2023.02.19.09.50.16 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 19 Feb 2023 09:50:17 -0800 (PST) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger , Tyler Retzlaff , Bruce Richardson Subject: [PATCH v3 2/8] net/ring: build on Windows Date: Sun, 19 Feb 2023 09:50:07 -0800 Message-Id: <20230219175013.10057-3-stephen@networkplumber.org> X-Mailer: git-send-email 2.39.1 In-Reply-To: <20230219175013.10057-1-stephen@networkplumber.org> References: <20230207001937.875608-1-stephen@networkplumber.org> <20230219175013.10057-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 The command line arguments are stored in node_action_pair and the name[] was sized to PATH_MAX which does not exist on Windows. Since the name is either "CREATE" or "ATTACH" it is not related to PATH_MAX (4096). With this fix driver builds ok on windows, but need to modify the test meson build to skip the eventdev test on Windows. Signed-off-by: Stephen Hemminger Acked-by: Tyler Retzlaff --- app/test/meson.build | 2 +- drivers/net/ring/meson.build | 6 ------ drivers/net/ring/rte_eth_ring.c | 4 +++- 3 files changed, 4 insertions(+), 8 deletions(-) diff --git a/app/test/meson.build b/app/test/meson.build index f34d19e3c3cb..a713f0382280 100644 --- a/app/test/meson.build +++ b/app/test/meson.build @@ -390,7 +390,7 @@ if dpdk_conf.has('RTE_NET_BOND') driver_test_names += 'link_bonding_mode4_autotest' endif endif -if dpdk_conf.has('RTE_NET_RING') +if dpdk_conf.has('RTE_LIB_EVENTDEV') and dpdk_conf.has('RTE_NET_RING') test_deps += 'net_ring' test_sources += 'test_pmd_ring_perf.c' test_sources += 'test_pmd_ring.c' diff --git a/drivers/net/ring/meson.build b/drivers/net/ring/meson.build index 72792e26b05a..3534a3cc2287 100644 --- a/drivers/net/ring/meson.build +++ b/drivers/net/ring/meson.build @@ -1,12 +1,6 @@ # SPDX-License-Identifier: BSD-3-Clause # Copyright(c) 2017 Intel Corporation -if is_windows - build = false - reason = 'not supported on Windows' - subdir_done() -endif - sources = files('rte_eth_ring.c') headers = files('rte_eth_ring.h') pmd_supports_disable_iova_as_pa = true diff --git a/drivers/net/ring/rte_eth_ring.c b/drivers/net/ring/rte_eth_ring.c index bd5a47dd9017..e8bc9b627102 100644 --- a/drivers/net/ring/rte_eth_ring.c +++ b/drivers/net/ring/rte_eth_ring.c @@ -9,6 +9,7 @@ #include #include #include +#include #include #include #include @@ -17,6 +18,7 @@ #define ETH_RING_NUMA_NODE_ACTION_ARG "nodeaction" #define ETH_RING_ACTION_CREATE "CREATE" #define ETH_RING_ACTION_ATTACH "ATTACH" +#define ETH_RING_ACTION_MAX_LEN 8 /* CREATE | ACTION */ #define ETH_RING_INTERNAL_ARG "internal" #define ETH_RING_INTERNAL_ARG_MAX_LEN 19 /* "0x..16chars..\0" */ @@ -539,7 +541,7 @@ eth_dev_ring_create(const char *name, } struct node_action_pair { - char name[PATH_MAX]; + char name[ETH_RING_ACTION_MAX_LEN]; unsigned int node; enum dev_action action; }; -- 2.39.1