From: "John W. Linville" <linville@tuxdriver.com>
To: Bruce Richardson <bruce.richardson@intel.com>
Cc: dev@dpdk.org
Subject: Re: [dpdk-dev] [PATCH] librte_pmd_packet: add PMD for AF_PACKET-based virtual devices
Date: Mon, 14 Jul 2014 09:48:33 -0400 [thread overview]
Message-ID: <20140714134832.GD27848@tuxdriver.com> (raw)
In-Reply-To: <20140711225108.GA9381@sivswdev02.ir.intel.com>
On Fri, Jul 11, 2014 at 11:51:08PM +0100, Bruce Richardson wrote:
> On Thu, Jul 10, 2014 at 04:32:49PM -0400, John W. Linville wrote:
> > This is a Linux-specific virtual PMD driver backed by an AF_PACKET
> > socket. This implementation uses mmap'ed ring buffers to limit copying
> > and user/kernel transitions. The PACKET_FANOUT_HASH behavior of
> > AF_PACKET is used for frame reception. In the current implementation,
> > Tx and Rx queues are always paired, and therefore are always equal
> > in number -- changing this would be a Simple Matter Of Programming.
> >
> > Interfaces of this type are created with a command line option like
> > "--vdev=eth_packet0,iface=...". There are a number of options availabe
> > as arguments:
> >
> > - Interface is chosen by "iface" (required)
> > - Number of queue pairs set by "qpairs" (optional, default: 16)
> > - AF_PACKET MMAP block size set by "blocksz" (optional, default: 4096)
> > - AF_PACKET MMAP frame size set by "framesz" (optional, default: 2048)
> > - AF_PACKET MMAP frame count set by "framecnt" (optional, default: 512)
> >
> > Signed-off-by: John W. Linville <linville@tuxdriver.com>
> > ---
> > This PMD is intended to provide a means for using DPDK on a broad
> > range of hardware without hardware-specific PMDs and (hopefully)
> > with better performance than what PCAP offers in Linux. This might
> > be useful as a development platform for DPDK applications when
> > DPDK-supported hardware is expensive or unavailable.
> >
> Hi John,
>
> I'm just trying this out now on a Fedora 20 machine, using kernel 3.14.9-200.fc20.x86_64. However, while the first packet PMD port initializes correctly, the subsequent ones do not. Please see output from my test run below. All four ports are of the same type.
Thanks I'll check into it. I'm not sure why you would only be able
to set the fanout on the first port...
>
> Regards,
> /Bruce
>
> bruce@silpixa00372841:dpdk.org$ sudo ./x86_64-native-linuxapp-gcc/app/testpmd -c 600 -n 4 --vdev=eth_packet0,iface=eth0,qpairs=1 --vdev=eth_packet1,iface=eth1,qpairs=1 --vdev=eth_packet2,iface=p802p1,qpairs=1 --vdev=eth_packet3,iface=p9p3,qpairs=1 -- --mbcache=250 --burst=32 --total-num-mbufs=65536EAL: Detected lcore 0 as core 0 on socket 0
> EAL: Detected lcore 1 as core 1 on socket 0
> EAL: Detected lcore 2 as core 2 on socket 0
> EAL: Detected lcore 3 as core 3 on socket 0
> EAL: Detected lcore 4 as core 4 on socket 0
> EAL: Detected lcore 5 as core 5 on socket 0
> EAL: Detected lcore 6 as core 6 on socket 0
> EAL: Detected lcore 7 as core 7 on socket 0
> EAL: Detected lcore 8 as core 0 on socket 1
> EAL: Detected lcore 9 as core 1 on socket 1
> EAL: Detected lcore 10 as core 2 on socket 1
> EAL: Detected lcore 11 as core 3 on socket 1
> EAL: Detected lcore 12 as core 4 on socket 1
> EAL: Detected lcore 13 as core 5 on socket 1
> EAL: Detected lcore 14 as core 6 on socket 1
> EAL: Detected lcore 15 as core 7 on socket 1
> EAL: Detected lcore 16 as core 0 on socket 0
> EAL: Detected lcore 17 as core 1 on socket 0
> EAL: Detected lcore 18 as core 2 on socket 0
> EAL: Detected lcore 19 as core 3 on socket 0
> EAL: Detected lcore 20 as core 4 on socket 0
> EAL: Detected lcore 21 as core 5 on socket 0
> EAL: Detected lcore 22 as core 6 on socket 0
> EAL: Detected lcore 23 as core 7 on socket 0
> EAL: Detected lcore 24 as core 0 on socket 1
> EAL: Detected lcore 25 as core 1 on socket 1
> EAL: Detected lcore 26 as core 2 on socket 1
> EAL: Detected lcore 27 as core 3 on socket 1
> EAL: Detected lcore 28 as core 4 on socket 1
> EAL: Detected lcore 29 as core 5 on socket 1
> EAL: Detected lcore 30 as core 6 on socket 1
> EAL: Detected lcore 31 as core 7 on socket 1
> EAL: Support maximum 64 logical core(s) by configuration.
> EAL: Detected 32 lcore(s)
> EAL: No free hugepages reported in hugepages-2048kB
> EAL: unsupported IOMMU type!
> EAL: VFIO support could not be initialized
> EAL: Setting up memory...
> EAL: Ask a virtual area of 0x80000000 bytes
> EAL: Virtual area found at 0x7f9fc0000000 (size = 0x80000000)
> EAL: Ask a virtual area of 0x80000000 bytes
> EAL: Virtual area found at 0x7f9f00000000 (size = 0x80000000)
> EAL: Requesting 2 pages of size 1024MB from socket 0
> EAL: Requesting 2 pages of size 1024MB from socket 1
> EAL: TSC frequency is ~2693512 KHz
> EAL: Master core 9 is ready (tid=f4511880)
> init (0) eth_packet0
> PMD: Initializing pmd_packet for eth_packet0
> PMD: eth_packet0: AF_PACKET MMAP parameters:
> PMD: eth_packet0: block size 4096
> PMD: eth_packet0: block count 256
> PMD: eth_packet0: frame size 2048
> PMD: eth_packet0: frame count 512
> PMD: eth_packet0: creating AF_PACKET-backed ethdev on numa socket 1
> init (0) eth_packet1
> PMD: Initializing pmd_packet for eth_packet1
> PMD: eth_packet1: AF_PACKET MMAP parameters:
> PMD: eth_packet1: block size 4096
> PMD: eth_packet1: block count 256
> PMD: eth_packet1: frame size 2048
> PMD: eth_packet1: frame count 512
> PMD: eth_packet1: creating AF_PACKET-backed ethdev on numa socket 1
> PMD: eth_packet1: could not set PACKET_FANOUT on AF_PACKET socket for eth1
> init (0) eth_packet2
> PMD: Initializing pmd_packet for eth_packet2
> PMD: eth_packet2: AF_PACKET MMAP parameters:
> PMD: eth_packet2: block size 4096
> PMD: eth_packet2: block count 256
> PMD: eth_packet2: frame size 2048
> PMD: eth_packet2: frame count 512
> PMD: eth_packet2: creating AF_PACKET-backed ethdev on numa socket 1
> PMD: eth_packet2: could not set PACKET_FANOUT on AF_PACKET socket for p802p1
> init (0) eth_packet3
> PMD: Initializing pmd_packet for eth_packet3
> PMD: eth_packet3: AF_PACKET MMAP parameters:
> PMD: eth_packet3: block size 4096
> PMD: eth_packet3: block count 256
> PMD: eth_packet3: frame size 2048
> PMD: eth_packet3: frame count 512
> PMD: eth_packet3: creating AF_PACKET-backed ethdev on numa socket 1
> PMD: eth_packet3: could not set PACKET_FANOUT on AF_PACKET socket for p9p3
> EAL: Core 10 is ready (tid=f34d9700)
> EAL: PCI device 0000:04:00.0 on NUMA socket 0
> EAL: probe driver: 8086:1521 rte_igb_pmd
> EAL: 0000:04:00.0 not managed by UIO driver, skipping
> EAL: PCI device 0000:04:00.1 on NUMA socket 0
> EAL: probe driver: 8086:1521 rte_igb_pmd
> EAL: 0000:04:00.1 not managed by UIO driver, skipping
> EAL: PCI device 0000:04:00.2 on NUMA socket 0
> EAL: probe driver: 8086:1521 rte_igb_pmd
> EAL: 0000:04:00.2 not managed by UIO driver, skipping
> EAL: PCI device 0000:04:00.3 on NUMA socket 0
> EAL: probe driver: 8086:1521 rte_igb_pmd
> EAL: 0000:04:00.3 not managed by UIO driver, skipping
> EAL: PCI device 0000:0c:00.0 on NUMA socket 0
> EAL: probe driver: 8086:10fb rte_ixgbe_pmd
> EAL: 0000:0c:00.0 not managed by UIO driver, skipping
> EAL: PCI device 0000:0c:00.1 on NUMA socket 0
> EAL: probe driver: 8086:10fb rte_ixgbe_pmd
> EAL: 0000:0c:00.1 not managed by UIO driver, skipping
> EAL: PCI device 0000:84:00.0 on NUMA socket 1
> EAL: probe driver: 8086:154a rte_ixgbe_pmd
> EAL: 0000:84:00.0 not managed by UIO driver, skipping
> EAL: PCI device 0000:84:00.1 on NUMA socket 1
> EAL: probe driver: 8086:154a rte_ixgbe_pmd
> EAL: 0000:84:00.1 not managed by UIO driver, skipping
> EAL: PCI device 0000:87:00.0 on NUMA socket 1
> EAL: probe driver: 8086:154a rte_ixgbe_pmd
> EAL: 0000:87:00.0 not managed by UIO driver, skipping
> EAL: PCI device 0000:87:00.1 on NUMA socket 1
> EAL: probe driver: 8086:154a rte_ixgbe_pmd
> EAL: 0000:87:00.1 not managed by UIO driver, skipping
> EAL: PCI device 0000:8b:00.0 on NUMA socket 1
> EAL: probe driver: 8086:154a rte_ixgbe_pmd
> EAL: 0000:8b:00.0 not managed by UIO driver, skipping
> EAL: PCI device 0000:8b:00.1 on NUMA socket 1
> EAL: probe driver: 8086:154a rte_ixgbe_pmd
> EAL: 0000:8b:00.1 not managed by UIO driver, skipping
> EAL: PCI device 0000:8e:00.0 on NUMA socket 1
> EAL: probe driver: 8086:154a rte_ixgbe_pmd
> EAL: 0000:8e:00.0 not managed by UIO driver, skipping
> EAL: PCI device 0000:8e:00.1 on NUMA socket 1
> EAL: probe driver: 8086:154a rte_ixgbe_pmd
> EAL: 0000:8e:00.1 not managed by UIO driver, skipping
> Configuring Port 0 (socket 0)
> Port 0: 68:05:CA:19:F0:50
> Checking link statuses...
> Port 0 Link Up - speed 10000 Mbps - full-duplex
> Done
> No commandline core given, start packet forwarding
>
> Warning! Cannot handle an odd number of ports with the current port topology. Configuration must be changed to have an even number of ports, or relaunch application with --port-topology=chained
>
> io packet forwarding - CRC stripping disabled - packets/burst=32
> nb forwarding cores=1 - nb forwarding ports=1
> RX queues=1 - RX desc=128 - RX free threshold=0
> RX threshold registers: pthresh=8 hthresh=8 wthresh=0
> TX queues=1 - TX desc=512 - TX free threshold=0
> TX threshold registers: pthresh=32 hthresh=0 wthresh=0
> TX RS bit threshold=0 - TXQ flags=0x0
> Press enter to exit
>
>
>
--
John W. Linville Someday the world will need a hero, and you
linville@tuxdriver.com might be all we have. Be ready.
next prev parent reply other threads:[~2014-07-14 13:59 UTC|newest]
Thread overview: 76+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-07-10 20:32 John W. Linville
2014-07-11 13:11 ` Stephen Hemminger
2014-07-11 14:49 ` John W. Linville
2014-07-11 15:06 ` Richardson, Bruce
2014-07-11 15:16 ` Stephen Hemminger
2014-07-11 16:07 ` Richardson, Bruce
2014-07-11 15:29 ` Venkatesan, Venky
2014-07-11 15:33 ` John W. Linville
2014-07-11 16:29 ` Venkatesan, Venky
2014-07-11 13:26 ` Thomas Monjalon
2014-07-11 14:51 ` John W. Linville
2014-07-11 15:04 ` Thomas Monjalon
2014-07-11 15:30 ` John W. Linville
2014-07-11 16:47 ` Thomas Monjalon
2014-07-11 17:38 ` Richardson, Bruce
2014-07-11 17:41 ` John W. Linville
2014-07-12 11:48 ` Neil Horman
[not found] ` <D0158A423229094DA7ABF71CF2FA0DA3117D3A23@shsmsx102.ccr.corp.intel.com>
2014-07-11 17:20 ` Zhou, Danny
2014-07-11 17:40 ` John W. Linville
2014-07-11 18:01 ` Zhou, Danny
2014-07-11 18:46 ` John W. Linville
2014-07-12 0:42 ` Zhou, Danny
2014-07-14 13:45 ` John W. Linville
2014-07-11 19:04 ` Zhou, Danny
2014-07-11 19:31 ` John W. Linville
2014-07-11 20:27 ` Zhou, Danny
2014-07-11 20:31 ` Shaw, Jeffrey B
2014-07-11 20:35 ` Zhou, Danny
2014-07-11 20:40 ` John W. Linville
2014-07-11 22:34 ` Thomas Monjalon
2014-07-14 13:46 ` John W. Linville
2014-07-15 21:27 ` Thomas Monjalon
2014-07-16 12:35 ` Neil Horman
2014-07-16 13:37 ` Thomas Monjalon
2014-07-16 14:07 ` John W. Linville
2014-07-16 14:26 ` Thomas Monjalon
2014-07-16 15:59 ` Shaw, Jeffrey B
2014-07-11 22:30 ` Thomas Monjalon
2014-07-14 17:53 ` John W. Linville
2014-07-11 22:51 ` Bruce Richardson
2014-07-14 13:48 ` John W. Linville [this message]
2014-07-14 17:35 ` John W. Linville
2014-07-14 18:24 ` [dpdk-dev] [PATCH v2] " John W. Linville
2014-07-15 0:15 ` Zhou, Danny
2014-07-15 12:17 ` Neil Horman
2014-07-15 14:01 ` John W. Linville
2014-07-15 15:40 ` Zhou, Danny
2014-07-15 19:08 ` John W. Linville
2014-07-15 20:31 ` Neil Horman
2014-07-15 20:41 ` Zhou, Danny
2014-07-15 15:34 ` Zhou, Danny
2014-09-12 18:05 ` John W. Linville
2014-09-12 18:31 ` Zhou, Danny
2014-09-12 18:54 ` John W. Linville
2014-09-12 20:35 ` Zhou, Danny
2014-09-15 15:09 ` Neil Horman
2014-09-15 15:15 ` John W. Linville
2014-09-15 15:43 ` Zhou, Danny
2014-09-15 16:22 ` Neil Horman
2014-09-15 17:48 ` John W. Linville
2014-09-15 19:11 ` Zhou, Danny
2014-09-16 20:16 ` Neil Horman
2014-09-26 9:28 ` Thomas Monjalon
2014-09-26 14:08 ` Neil Horman
2014-09-29 10:05 ` Bruce Richardson
2014-10-08 15:57 ` Thomas Monjalon
2014-10-08 19:14 ` Neil Horman
2014-11-13 10:03 ` Thomas Monjalon
2014-11-13 11:14 ` Neil Horman
2014-11-13 11:57 ` Thomas Monjalon
2014-11-14 0:42 ` Neil Horman
2014-11-14 14:45 ` John W. Linville
2014-11-17 15:57 ` [dpdk-dev] [PATCH v3] librte_pmd_af_packet: " John W. Linville
2014-11-24 16:16 ` Thomas Monjalon
2014-11-17 11:19 ` [dpdk-dev] [PATCH v2] librte_pmd_packet: " Neil Horman
2014-11-17 11:22 ` Thomas Monjalon
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20140714134832.GD27848@tuxdriver.com \
--to=linville@tuxdriver.com \
--cc=bruce.richardson@intel.com \
--cc=dev@dpdk.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).