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 D71D142FFF for ; Mon, 7 Aug 2023 21:40:28 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 80A1C410D3; Mon, 7 Aug 2023 21:40:27 +0200 (CEST) Received: from mail-pj1-f41.google.com (mail-pj1-f41.google.com [209.85.216.41]) by mails.dpdk.org (Postfix) with ESMTP id 6BBD740A8B for ; Mon, 7 Aug 2023 21:40:25 +0200 (CEST) Received: by mail-pj1-f41.google.com with SMTP id 98e67ed59e1d1-2681223aaacso3231903a91.0 for ; Mon, 07 Aug 2023 12:40:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20221208.gappssmtp.com; s=20221208; t=1691437224; x=1692042024; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:subject:cc:to:from:date:from:to:cc:subject:date :message-id:reply-to; bh=u1Q+MZNrv4h926cmEWcDckQUC+zakXP45N+U/8mHOXI=; b=0mlc6qtJh2mVL5tMbW96cf7VIES+0kpS1nGrYB/4UwEVYWz/oa3DmYdeCAv9wvnYU+ 5E9wNB/Jqw8ySkC/kkvyG1h3+f5FGpsdOknZrW8Twm1xqxthdD8d/cvF7E3uxyWIqRJ3 403C+b+TZhoNXupDcsVBGghZUWz4uqnaah6d5f1FJk9KX3gKncNRifd5mvt6hYeWlCKb i8Tk1LRuZSRbOMMhX/55HRMGDKNAY+H1s9qN41g1QttfdM1+1uKbD3xsvp3vlxOy7HPe oFU1ViIR8aR46iECziE9JG7FjjvMIetEJ5q2KJVKuzGrJLCBHVknUdeHX9Htv2DTfpwt Y0ZA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691437224; x=1692042024; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:subject:cc:to:from:date:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=u1Q+MZNrv4h926cmEWcDckQUC+zakXP45N+U/8mHOXI=; b=IjwB2sUW3F+5/iPSR7aINTIvNA83JWqlv5LWMeefPglVcVYAUYm6Eb6+VapWv4tvsy hPqQrpU+sr6HF2P/7YocwMvgByo7QK4pr1vSqn8O5Kw9M0ZPHQQ5riVna7LIS7pWT/Yg nlXk+PJWVepv3YjEeAUoOnkO90vyICXMlNxsdhexaxCLJcv+jm+MlAfNHrP2UJVRROw1 yszuOO4qUL4PjYVyi4/3wjTmHZGIiNK188a3KfWDXBD7o0S0YZFF0Px+EsZBb70jjiyk IjRBEOCGae8oG8bkPzdevvvIdcFnV2/xFa98IeElTHUhiazJCUqEHVIEHuZO8npFvWCb p1Qw== X-Gm-Message-State: AOJu0Yy5xsosd7ZqINzqUFCQ9RsSoUVMESbEDBlC18YJskLgbpG4cs8J T5yUPO8ZN0Zw4pSgzffEHC3H3Q== X-Google-Smtp-Source: AGHT+IEX82Q9oUiv8FedTdpFpnS4kEpzRoS+0cfy08pIskJdiY2DCKkzP5C/iiL+L725rlCJVC7q0A== X-Received: by 2002:a17:90a:6e05:b0:268:409:e795 with SMTP id b5-20020a17090a6e0500b002680409e795mr9474852pjk.22.1691437224107; Mon, 07 Aug 2023 12:40:24 -0700 (PDT) Received: from hermes.local (204-195-127-207.wavecable.com. [204.195.127.207]) by smtp.gmail.com with ESMTPSA id 2-20020a17090a01c200b00256b67208b1sm9681779pjd.56.2023.08.07.12.40.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 07 Aug 2023 12:40:23 -0700 (PDT) Date: Mon, 7 Aug 2023 12:40:21 -0700 From: Stephen Hemminger To: Alan Beadle Cc: users@dpdk.org Subject: Re: Help Running Example Message-ID: <20230807124021.325b6d68@hermes.local> In-Reply-To: References: MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-BeenThere: users@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK usage discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: users-bounces@dpdk.org On Sun, 6 Aug 2023 11:33:43 -0400 Alan Beadle wrote: > Hi, > > I need some help getting DPDK working. I am running Ubuntu 20.04 with > a modified Linux 5.4 kernel, but I have also tried the stock Ubuntu > 5.15 kernel with the same results. > > Here is my NIC info from lspci: > 00:1f.6 Ethernet controller: Intel Corporation Ethernet Connection (3) > I219-LM (rev 09) > > I built and installed DPDK from source, and applied the following boot > flags: "intel_iommu=on iommu=pt" > > After booting I did the following as root: > echo 1024 > /sys/kernel/mm/hugepages/hugepages-2048kB/nr_hugepages > ifconfig enp0s31f6 down > dpdk-devbind.py --bind=vfio-pci 0000:00:1f.6 > > All of this appeared to work. > > I tried running the "skeleton" example program and got the following output: > sudo ./build/basicfwd > EAL: Detected CPU lcores: 16 > EAL: Detected NUMA nodes: 1 > EAL: Detected shared linkage of DPDK > EAL: Multi-process socket /var/run/dpdk/rte/mp_socket > EAL: Selected IOVA mode 'VA' > EAL: VFIO support initialized > EAL: 0000:00:1f.6 VFIO group is not viable! Not all devices in IOMMU > group bound to VFIO or unbound > EAL: Requested device 0000:00:1f.6 cannot be used > TELEMETRY: No legacy callbacks, legacy socket not created > EAL: Error - exiting with code: 1 > Cause: Error: number of ports must be even > > I'm not at all familiar with DPDK or VFIO. What might the problem be? > > -Alan IOMMU groups are when multiple PCI devices share the same channel in the IOMMU. The group is used to determine what mapping to use when device does DMA. Since this is a security thing, devices in same IOMMU group can not be shared between kernel and non-kernel usage. The IOMMU group is determined by wiring on the motherboard. Usually it is things like multiple Ethernet ports sharing the same group. But can be much more confused. The only option is to unbind all devices in the group before using one with DPDK.