[dpdk-dev] [PATCH] i40e: bug fix of querying reta

2014-12-09 Thread Helin Zhang
There is a bug in querying reta, of storing the data to the correct entry. Code changes is straightforward for this bug. Signed-off-by: Helin Zhang --- lib/librte_pmd_i40e/i40e_ethdev.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/librte_pmd_i40e/i40e_ethdev.c b/lib/l

[dpdk-dev] [RFC PATCH 00/17] Single virtio implementation

2014-12-09 Thread Ouyang, Changchun
Hi Thomas, > -Original Message- > From: Thomas Monjalon [mailto:thomas.monjalon at 6wind.com] > Sent: Monday, December 8, 2014 5:31 PM > To: Ouyang, Changchun > Cc: dev at dpdk.org > Subject: Re: [dpdk-dev] [RFC PATCH 00/17] Single virtio implementation > > Hi Changchun, > > 2014-12-08 1

[dpdk-dev] [PATCH v3] mbuf: fix of enabling all newly added RX error flags

2014-12-09 Thread Zhang, Helin
Hi Thomas > -Original Message- > From: Thomas Monjalon [mailto:thomas.monjalon at 6wind.com] > Sent: Monday, December 8, 2014 6:51 PM > To: Zhang, Helin > Cc: dev at dpdk.org > Subject: Re: [dpdk-dev] [PATCH v3] mbuf: fix of enabling all newly added RX > error flags > > Hi Helin, > > 201

[dpdk-dev] [PATCH v3] mbuf: fix of enabling all newly added RX error flags

2014-12-09 Thread Zhang, Helin
> -Original Message- > From: Ananyev, Konstantin > Sent: Monday, December 8, 2014 6:45 PM > To: Zhang, Helin; dev at dpdk.org > Cc: Cao, Waterman; Cao, Min; olivier.matz at 6wind.com > Subject: RE: [PATCH v3] mbuf: fix of enabling all newly added RX error flags > > Hi Helin, > > > -

[dpdk-dev] [PATCH v2 2/2] mbuf: assign valid bit values for some RX and TX flags

2014-12-09 Thread Zhang, Helin
> -Original Message- > From: Ananyev, Konstantin > Sent: Monday, December 8, 2014 6:55 PM > To: Zhang, Helin; dev at dpdk.org > Cc: Cao, Waterman; Cao, Min; Wu, Jingjing; Liu, Jijiang; > olivier.matz at 6wind.com > Subject: RE: [PATCH v2 2/2] mbuf: assign valid bit values for some RX and

[dpdk-dev] [PATCH v2] VFIO: Avoid to enable vfio while the module not loaded

2014-12-09 Thread Qiu, Michael
On 12/9/2014 2:47 AM, Burakov, Anatoly wrote: > Hi Michael > >> I don't think so, if we check module "vfio", but if given module name is >> "vfio_xx", it will also correct if use strncmp. > Sorry I missed this the last time. I don't think that is the case. If you do > strncmp on sizeof(buffer), s

[dpdk-dev] [RFC PATCH 00/17] Single virtio implementation

2014-12-09 Thread Qiu, Michael
On 12/9/2014 9:11 AM, Ouyang, Changchun wrote: > Hi Thomas, > >> -Original Message- >> From: Thomas Monjalon [mailto:thomas.monjalon at 6wind.com] >> Sent: Monday, December 8, 2014 5:31 PM >> To: Ouyang, Changchun >> Cc: dev at dpdk.org >> Subject: Re: [dpdk-dev] [RFC PATCH 00/17] Single vi

[dpdk-dev] [PATCH v2 00/28] Port Hotplug Framework

2014-12-09 Thread Tetsuya Mukawa
This patch series adds a dynamic port hotplug framework to DPDK. With the patches, DPDK apps can attach or detach ports at runtime. The basic concept of the port hotplug is like followings. - DPDK apps must have responsibility to manage ports. DPDK apps only know which ports are attached or deta

[dpdk-dev] [PATCH v2 01/28] eal/pci: Add a new flag indicating a driver can detach devices at runtime.

2014-12-09 Thread Tetsuya Mukawa
This patch adds "RTE_PCI_DRV_DETACHABLE" to drv_flags of rte_pci_driver structure. The flags indicates the driver can detach devices at runtime. Signed-off-by: Tetsuya Mukawa --- lib/librte_eal/common/include/rte_pci.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/librte_eal/common/i

[dpdk-dev] [PATCH v2 02/28] ethdev: Remove assumption that port will not be detached

2014-12-09 Thread Tetsuya Mukawa
To remove assumption, do like followings. - Add 'attached' member to rte_eth_dev structure. This member is used for indicating the port is attached, or not. - Add rte_eth_dev_allocate_new_port(). This function is used for allocating new port. Signed-off-by: Tetsuya Mukawa --- lib/librte_eth

[dpdk-dev] [PATCH v2 03/28] eal/pci: Replace pci address comparison code by eal_compare_pci_addr

2014-12-09 Thread Tetsuya Mukawa
This patch replaces pci_addr_comparison() and memcmp() of pci addresses by eal_compare_pci_addr(). Signed-off-by: Tetsuya Mukawa --- lib/librte_eal/bsdapp/eal/eal_pci.c | 16 +--- lib/librte_eal/common/eal_common_pci.c| 2 +- lib/librte_eal/common/include/rte_pci.h | 29

[dpdk-dev] [PATCH v2 04/28] ethdev: Add rte_eth_dev_free to free specified device

2014-12-09 Thread Tetsuya Mukawa
This patch adds rte_eth_dev_free(). The function is used for changing a attached status of the device that has specified name. Signed-off-by: Tetsuya Mukawa --- lib/librte_ether/rte_ethdev.c | 17 + lib/librte_ether/rte_ethdev.h | 11 +++ 2 files changed, 28 insertions(+)

[dpdk-dev] [PATCH v2 05/28] eal, ethdev: Add function pointer for closing a device

2014-12-09 Thread Tetsuya Mukawa
The patch adds function pointer to rte_pci_driver and eth_driver structure. These function pointers are used when ports are detached. Signed-off-by: Tetsuya Mukawa --- lib/librte_eal/common/include/rte_pci.h | 7 +++ lib/librte_ether/rte_ethdev.h | 24 2 f

[dpdk-dev] [PATCH v2 06/28] ethdev: Add rte_eth_dev_shutdown for closing PCI devices.

2014-12-09 Thread Tetsuya Mukawa
rte_eth_dev_shutdown() is called when PCI device is closed. Signed-off-by: Tetsuya Mukawa --- lib/librte_ether/rte_ethdev.c | 37 + 1 file changed, 37 insertions(+) diff --git a/lib/librte_ether/rte_ethdev.c b/lib/librte_ether/rte_ethdev.c index d5fdb03..5169

[dpdk-dev] [PATCH v2 07/28] ethdev: Add functions to know which port is attached or detached

2014-12-09 Thread Tetsuya Mukawa
The patch adds rte_eth_dev_save() and rte_eth_dev_get_changed_port(). rte_eth_dev_save() is used for saving current rte_eth_dev structures. rte_eth_dev_get_changed_port() receives the rte_eth_dev structures, then compare these with current values to know which port is actually attached or detached.

[dpdk-dev] [PATCH v2 08/28] ethdev: Add rte_eth_dev_get_addr_by_port

2014-12-09 Thread Tetsuya Mukawa
The function returns a pci address of a ethdev specified by port identifier. Signed-off-by: Tetsuya Mukawa --- lib/librte_ether/rte_ethdev.c | 17 + lib/librte_ether/rte_ethdev.h | 13 + 2 files changed, 30 insertions(+) diff --git a/lib/librte_ether/rte_ethdev.c b/l

[dpdk-dev] [PATCH v2 09/28] ethdev: Add rte_eth_dev_get_port_by_addr

2014-12-09 Thread Tetsuya Mukawa
The function returns a port identifier of a ethdev specified by pci address. v3: - Fix if-condition bug while comparing pci addresses. - Add error checking codes. Reported-by: Mark Enright Signed-off-by: Tetsuya Mukawa --- lib/librte_ether/rte_ethdev.c | 22 ++ lib/librte_e

[dpdk-dev] [PATCH v2 10/28] ethdev: Add rte_eth_dev_get_name_by_port

2014-12-09 Thread Tetsuya Mukawa
The function returns a unique identifier name of a ethdev specified by port identifier. Signed-off-by: Tetsuya Mukawa --- lib/librte_ether/rte_ethdev.c | 22 ++ lib/librte_ether/rte_ethdev.h | 12 2 files changed, 34 insertions(+) diff --git a/lib/librte_ether/r

[dpdk-dev] [PATCH v2 11/28] ethdev: Add rte_eth_dev_check_detachable

2014-12-09 Thread Tetsuya Mukawa
The function returns whether a PMD supports detach function, or not. Signed-off-by: Tetsuya Mukawa --- lib/librte_ether/rte_ethdev.c | 9 + lib/librte_ether/rte_ethdev.h | 11 +++ 2 files changed, 20 insertions(+) diff --git a/lib/librte_ether/rte_ethdev.c b/lib/librte_ether/rt

[dpdk-dev] [PATCH v2 12/28] ethdev: Change scope of rte_eth_dev_allocated to global

2014-12-09 Thread Tetsuya Mukawa
This function is used by virtual PMDs to support port hotplug framework. So change scope of the function to global. Signed-off-by: Tetsuya Mukawa --- lib/librte_ether/rte_ethdev.c | 2 +- lib/librte_ether/rte_ethdev.h | 10 ++ 2 files changed, 11 insertions(+), 1 deletion(-) diff --git

[dpdk-dev] [PATCH v2 13/28] eal/pci: Prevent double registration for devargs_list

2014-12-09 Thread Tetsuya Mukawa
The patch fixes rte_eal_devargs_add() not to register same device twice. Signed-off-by: Tetsuya Mukawa --- lib/librte_eal/common/eal_common_devargs.c | 35 ++ 1 file changed, 35 insertions(+) diff --git a/lib/librte_eal/common/eal_common_devargs.c b/lib/librte_eal/c

[dpdk-dev] [PATCH v2 14/28] eal/pci: Add rte_eal_devargs_remove

2014-12-09 Thread Tetsuya Mukawa
The function removes a specified devargs from devargs_list. Signed-off-by: Tetsuya Mukawa --- lib/librte_eal/common/eal_common_devargs.c | 16 lib/librte_eal/common/include/rte_devargs.h | 18 ++ 2 files changed, 34 insertions(+) diff --git a/lib/librte_eal/com

[dpdk-dev] [PATCH v2 15/28] eal/pci: Add probe and close function for virtual drivers

2014-12-09 Thread Tetsuya Mukawa
The patch adds rte_eal_dev_init_one() and rte_eal_dev_close_one(). These are used for attaching and detaching virtual devices. Signed-off-by: Tetsuya Mukawa --- lib/librte_eal/common/eal_common_dev.c | 66 + lib/librte_eal/common/include/rte_dev.h | 6 +++ lib/l

[dpdk-dev] [PATCH v2 16/28] eal/pci: Add port hotplug functions for virtual devices.

2014-12-09 Thread Tetsuya Mukawa
The patch adds rte_eal_dev_attach_vdev() and rte_eal_dev_detach_vdev(). rte_eal_dev_attach_vdev() receives virtual device name and parameters, and returns an attached port number. rte_eal_dev_detach_vdev() receives a port number, and returns device name actually detached. Signed-off-by: Tetsuya M

[dpdk-dev] [PATCH v2 17/28] eal/linux/pci: Add functions for unmapping igb_uio resources

2014-12-09 Thread Tetsuya Mukawa
The patch adds functions for unmapping igb_uio resources. The patch is only for Linux and igb_uio environment. VFIO and BSD are not supported. Signed-off-by: Tetsuya Mukawa --- lib/librte_eal/linuxapp/eal/eal_pci.c | 35 lib/librte_eal/linuxapp/eal/eal_pci_init.h | 7

[dpdk-dev] [PATCH v2 18/28] eal/pci: Prevent double registrations for pci_device_list

2014-12-09 Thread Tetsuya Mukawa
The patch fixes pci_scan_one() not to register same pci devices twice. Signed-off-by: Tetsuya Mukawa --- lib/librte_eal/linuxapp/eal/eal_pci.c | 9 ++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/lib/librte_eal/linuxapp/eal/eal_pci.c b/lib/librte_eal/linuxapp/eal/eal_pci

[dpdk-dev] [PATCH v2 19/28] eal/pci: Change scope of rte_eal_pci_scan to global

2014-12-09 Thread Tetsuya Mukawa
The function is called by port hotplug framework, so change scope of the function to global. Signed-off-by: Tetsuya Mukawa --- lib/librte_eal/common/eal_private.h | 11 +++ lib/librte_eal/linuxapp/eal/eal_pci.c | 6 +++--- 2 files changed, 14 insertions(+), 3 deletions(-) diff --git

[dpdk-dev] [PATCH v2 20/28] eal/pci: Add rte_eal_pci_close_one_driver

2014-12-09 Thread Tetsuya Mukawa
The function is used for closing the specified driver and device. Signed-off-by: Tetsuya Mukawa --- lib/librte_eal/common/eal_private.h | 15 + lib/librte_eal/linuxapp/eal/eal_pci.c | 61 +++ 2 files changed, 76 insertions(+) diff --git a/lib/librte_eal

[dpdk-dev] [PATCH v2 21/28] eal/pci: Fix pci_probe_all_drivers to share code with closing function

2014-12-09 Thread Tetsuya Mukawa
pci_close_all_drivers() will be implemented after the patch. To share a part of code between thses 2 functions, The patch fixes pci_probe_all_drivers() first. Signed-off-by: Tetsuya Mukawa --- lib/librte_eal/common/eal_common_pci.c | 28 1 file changed, 20 insertions

[dpdk-dev] [PATCH v2 22/28] eal/pci: Add pci_close_all_drivers

2014-12-09 Thread Tetsuya Mukawa
The function tries to find a driver for the specified device, and then close the driver. Signed-off-by: Tetsuya Mukawa --- lib/librte_eal/common/eal_common_pci.c | 19 +++ 1 file changed, 19 insertions(+) diff --git a/lib/librte_eal/common/eal_common_pci.c b/lib/librte_eal/comm

[dpdk-dev] [PATCH v2 23/28] eal/pci: Add rte_eal_pci_probe_one and rte_eal_pci_close_one

2014-12-09 Thread Tetsuya Mukawa
The functions are used for probe and close a device. First the function tries to find a device that has the specfied PCI address. Then, probe or close the device. Signed-off-by: Tetsuya Mukawa --- lib/librte_eal/common/eal_common_pci.c | 58 + lib/librte_eal/comm

[dpdk-dev] [PATCH v2 24/28] eal/pci: Add port hotplug functions for physical devices.

2014-12-09 Thread Tetsuya Mukawa
The patch adds rte_eal_dev_attach_pdev() and rte_eal_dev_detach_pdev(). rte_eal_dev_attach_pdev() receives a PCI address of the device and returns an attached port number. rte_eal_dev_detach_pdev() receives a port number, and returns a PCI address actually detached. Signed-off-by: Tetsuya Mukawa

[dpdk-dev] [PATCH v2 25/28] eal/pci: Remove pci_probe/close_all_drivers()

2014-12-09 Thread Tetsuya Mukawa
These functions are actually wrappers of pci_invoke_all_drivers(). Just call it directly. Signed-off-by: Tetsuya Mukawa --- lib/librte_eal/common/eal_common_pci.c | 30 -- 1 file changed, 4 insertions(+), 26 deletions(-) diff --git a/lib/librte_eal/common/eal_common_

[dpdk-dev] [PATCH v2 26/28] eal/pci: Add rte_eal_dev_attach/detach() functions

2014-12-09 Thread Tetsuya Mukawa
This functions wraps attaching and detaching functions for physical and virtual device. When rte_eal_dev_attach() is called, the function tries to realize the device name as pci address. If this is done successfully, rte_eal_dev_attach() will call rte_eal_dev_attach_pdev(). If not, calls rte_eal_de

[dpdk-dev] [PATCH v2 27/28] eal/pci: Remove rte_eal_dev_attach/detach_pdev() and rte_eal_dev_attach/detach_vdev()

2014-12-09 Thread Tetsuya Mukawa
These functions are wrapped by rte_eal_dev_attach/detach(). So delete these. Signed-off-by: Tetsuya Mukawa --- lib/librte_eal/common/eal_common_dev.c | 8 +++--- lib/librte_eal/common/include/rte_dev.h | 50 - 2 files changed, 4 insertions(+), 54 deletions(-) d

[dpdk-dev] [PATCH v2 28/28] eal: Enable port hotplug framework in Linux

2014-12-09 Thread Tetsuya Mukawa
The patch enables CONFIG_RTE_LIBRTE_EAL_HOTPLUG in Linux configuration. Signed-off-by: Tetsuya Mukawa --- config/common_linuxapp | 5 + 1 file changed, 5 insertions(+) diff --git a/config/common_linuxapp b/config/common_linuxapp index 2f9643b..27d05be 100644 --- a/config/common_linuxapp +++

[dpdk-dev] [PATCH v2] librte_pmd_pcap: Add port hotplug support

2014-12-09 Thread Tetsuya Mukawa
This patch adds finalization code to free resources allocated by the PMD. Signed-off-by: Tetsuya Mukawa --- lib/librte_pmd_pcap/rte_eth_pcap.c | 40 ++ 1 file changed, 40 insertions(+) diff --git a/lib/librte_pmd_pcap/rte_eth_pcap.c b/lib/librte_pmd_pcap/rte

[dpdk-dev] [PATCH v2] testpmd: Add port hotplug support

2014-12-09 Thread Tetsuya Mukawa
The patch introduces following commands. - port attach [ident] - port detach [port_id] - attach: attaching a port - detach: detaching a port - ident: pci address of physical device. Or device name and paramerters of virtual device. (ex. :02:00.0, eth_pcap0,iface=eth0) - p

[dpdk-dev] [PATCH v2 02/28] ethdev: Remove assumption that port will not be detached

2014-12-09 Thread Zhang, Helin
> -Original Message- > From: dev [mailto:dev-bounces at dpdk.org] On Behalf Of Tetsuya Mukawa > Sent: Tuesday, December 9, 2014 11:42 AM > To: dev at dpdk.org > Cc: nakajima.yoshihiro at lab.ntt.co.jp; menrigh at brocade.com; > masutani.hitoshi at lab.ntt.co.jp > Subject: [dpdk-dev] [PATC

[dpdk-dev] [RFC PATCH 00/17] Single virtio implementation

2014-12-09 Thread Ouyang, Changchun
Hi > -Original Message- > From: Qiu, Michael > Sent: Tuesday, December 9, 2014 11:23 AM > To: Ouyang, Changchun; Thomas Monjalon; Stephen Hemminger > Cc: dev at dpdk.org > Subject: Re: [dpdk-dev] [RFC PATCH 00/17] Single virtio implementation > > On 12/9/2014 9:11 AM, Ouyang, Changchun wr

[dpdk-dev] [PATCH v2] bond: fix for mac assignment to slaves device

2014-12-09 Thread Jiajia, SunX
Tested-by: Jiajia, SunX - Tested Commit: 505c3d03dc7ae8e06c68006e44fd80738a3d70a3 - OS: Fedora20 3.11.10-301.fc20.x86_64 - GCC: gcc version 4.8.3 - CPU: Intel(R) Xeon(R) CPU E5-2680 v2 @ 2.80GHz - NIC: Intel Corporation 82599ES 10-Gigabit SFI/SFP+ Network Connection [8086:10fb] - Default x86_64-

[dpdk-dev] [PATCH v2 02/28] ethdev: Remove assumption that port will not be detached

2014-12-09 Thread Tetsuya Mukawa
Hi Zhang, Thanks to your comment. I will submit again soon. Thanks, Tetsuya (2014/12/09 14:07), Zhang, Helin wrote: > >> -Original Message- >> From: dev [mailto:dev-bounces at dpdk.org] On Behalf Of Tetsuya Mukawa >> Sent: Tuesday, December 9, 2014 11:42 AM >> To: dev at dpdk.org >> Cc:

[dpdk-dev] [RFC PATCH 00/17] Single virtio implementation

2014-12-09 Thread Thomas Monjalon
2014-12-09 05:41, Ouyang, Changchun: > Hi > > > -Original Message- > > From: Qiu, Michael > > Sent: Tuesday, December 9, 2014 11:23 AM > > To: Ouyang, Changchun; Thomas Monjalon; Stephen Hemminger > > Cc: dev at dpdk.org > > Subject: Re: [dpdk-dev] [RFC PATCH 00/17] Single virtio implement

[dpdk-dev] [PATCH v3] mbuf: fix of enabling all newly added RX error flags

2014-12-09 Thread Thomas Monjalon
2014-12-09 02:14, Zhang, Helin: > From: Thomas Monjalon [mailto:thomas.monjalon at 6wind.com] > > 2014-12-06 09:33, Helin Zhang: > > > Before redefining mbuf structure, there was lack of free bits in > > > 'ol_flags' > > > (32 bits in total) for new RX or TX flags. So it tried to reuse > > > exist

[dpdk-dev] [PATCH v3 00/28] Port Hotplug Framework

2014-12-09 Thread Tetsuya Mukawa
This patch series adds a dynamic port hotplug framework to DPDK. With the patches, DPDK apps can attach or detach ports at runtime. The basic concept of the port hotplug is like followings. - DPDK apps must have responsibility to manage ports. DPDK apps only know which ports are attached or deta

[dpdk-dev] [PATCH v3 01/28] eal/pci: Add a new flag indicating a driver can detach devices at runtime.

2014-12-09 Thread Tetsuya Mukawa
This patch adds "RTE_PCI_DRV_DETACHABLE" to drv_flags of rte_pci_driver structure. The flags indicates the driver can detach devices at runtime. Signed-off-by: Tetsuya Mukawa --- lib/librte_eal/common/include/rte_pci.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/librte_eal/common/i

[dpdk-dev] [PATCH v3 02/28] ethdev: Remove assumption that port will not be detached

2014-12-09 Thread Tetsuya Mukawa
To remove assumption, do like followings. - Add 'attached' member to rte_eth_dev structure. This member is used for indicating the port is attached, or not. - Add rte_eth_dev_allocate_new_port(). This function is used for allocating new port. Signed-off-by: Tetsuya Mukawa --- lib/librte_eth

[dpdk-dev] [PATCH v3 03/28] eal/pci: Replace pci address comparison code by eal_compare_pci_addr

2014-12-09 Thread Tetsuya Mukawa
This patch replaces pci_addr_comparison() and memcmp() of pci addresses by eal_compare_pci_addr(). Signed-off-by: Tetsuya Mukawa --- lib/librte_eal/bsdapp/eal/eal_pci.c | 16 +--- lib/librte_eal/common/eal_common_pci.c| 2 +- lib/librte_eal/common/include/rte_pci.h | 29

[dpdk-dev] [PATCH v3 04/28] ethdev: Add rte_eth_dev_free to free specified device

2014-12-09 Thread Tetsuya Mukawa
This patch adds rte_eth_dev_free(). The function is used for changing a attached status of the device that has specified name. Signed-off-by: Tetsuya Mukawa --- lib/librte_ether/rte_ethdev.c | 17 + lib/librte_ether/rte_ethdev.h | 11 +++ 2 files changed, 28 insertions(+)

[dpdk-dev] [PATCH v3 05/28] eal, ethdev: Add function pointer for closing a device

2014-12-09 Thread Tetsuya Mukawa
The patch adds function pointer to rte_pci_driver and eth_driver structure. These function pointers are used when ports are detached. Signed-off-by: Tetsuya Mukawa --- lib/librte_eal/common/include/rte_pci.h | 7 +++ lib/librte_ether/rte_ethdev.h | 24 2 f

[dpdk-dev] [PATCH v3 06/28] ethdev: Add rte_eth_dev_shutdown for closing PCI devices.

2014-12-09 Thread Tetsuya Mukawa
rte_eth_dev_shutdown() is called when PCI device is closed. Signed-off-by: Tetsuya Mukawa --- lib/librte_ether/rte_ethdev.c | 37 + 1 file changed, 37 insertions(+) diff --git a/lib/librte_ether/rte_ethdev.c b/lib/librte_ether/rte_ethdev.c index d5fdb03..5169

[dpdk-dev] [PATCH v3 07/28] ethdev: Add functions to know which port is attached or detached

2014-12-09 Thread Tetsuya Mukawa
The patch adds rte_eth_dev_save() and rte_eth_dev_get_changed_port(). rte_eth_dev_save() is used for saving current rte_eth_dev structures. rte_eth_dev_get_changed_port() receives the rte_eth_dev structures, then compare these with current values to know which port is actually attached or detached.

[dpdk-dev] [PATCH v3 08/28] ethdev: Add rte_eth_dev_get_addr_by_port

2014-12-09 Thread Tetsuya Mukawa
The function returns a pci address of a ethdev specified by port identifier. Signed-off-by: Tetsuya Mukawa --- lib/librte_ether/rte_ethdev.c | 17 + lib/librte_ether/rte_ethdev.h | 13 + 2 files changed, 30 insertions(+) diff --git a/lib/librte_ether/rte_ethdev.c b/l

[dpdk-dev] [PATCH v3 09/28] ethdev: Add rte_eth_dev_get_port_by_addr

2014-12-09 Thread Tetsuya Mukawa
The function returns a port identifier of a ethdev specified by pci address. v3: - Fix if-condition bug while comparing pci addresses. - Add error checking codes. Reported-by: Mark Enright Signed-off-by: Tetsuya Mukawa --- lib/librte_ether/rte_ethdev.c | 22 ++ lib/librte_e

[dpdk-dev] [PATCH v3 10/28] ethdev: Add rte_eth_dev_get_name_by_port

2014-12-09 Thread Tetsuya Mukawa
The function returns a unique identifier name of a ethdev specified by port identifier. Signed-off-by: Tetsuya Mukawa --- lib/librte_ether/rte_ethdev.c | 22 ++ lib/librte_ether/rte_ethdev.h | 12 2 files changed, 34 insertions(+) diff --git a/lib/librte_ether/r

[dpdk-dev] [PATCH v3 11/28] ethdev: Add rte_eth_dev_check_detachable

2014-12-09 Thread Tetsuya Mukawa
The function returns whether a PMD supports detach function, or not. Signed-off-by: Tetsuya Mukawa --- lib/librte_ether/rte_ethdev.c | 9 + lib/librte_ether/rte_ethdev.h | 11 +++ 2 files changed, 20 insertions(+) diff --git a/lib/librte_ether/rte_ethdev.c b/lib/librte_ether/rt

[dpdk-dev] [PATCH v3 12/28] ethdev: Change scope of rte_eth_dev_allocated to global

2014-12-09 Thread Tetsuya Mukawa
This function is used by virtual PMDs to support port hotplug framework. So change scope of the function to global. Signed-off-by: Tetsuya Mukawa --- lib/librte_ether/rte_ethdev.c | 2 +- lib/librte_ether/rte_ethdev.h | 10 ++ 2 files changed, 11 insertions(+), 1 deletion(-) diff --git

[dpdk-dev] [PATCH v3 13/28] eal/pci: Prevent double registration for devargs_list

2014-12-09 Thread Tetsuya Mukawa
The patch fixes rte_eal_devargs_add() not to register same device twice. Signed-off-by: Tetsuya Mukawa --- lib/librte_eal/common/eal_common_devargs.c | 35 ++ 1 file changed, 35 insertions(+) diff --git a/lib/librte_eal/common/eal_common_devargs.c b/lib/librte_eal/c

[dpdk-dev] [PATCH v3 14/28] eal/pci: Add rte_eal_devargs_remove

2014-12-09 Thread Tetsuya Mukawa
The function removes a specified devargs from devargs_list. Signed-off-by: Tetsuya Mukawa --- lib/librte_eal/common/eal_common_devargs.c | 16 lib/librte_eal/common/include/rte_devargs.h | 18 ++ 2 files changed, 34 insertions(+) diff --git a/lib/librte_eal/com

[dpdk-dev] [PATCH v3 15/28] eal/pci: Add probe and close function for virtual drivers

2014-12-09 Thread Tetsuya Mukawa
The patch adds rte_eal_dev_init_one() and rte_eal_dev_close_one(). These are used for attaching and detaching virtual devices. Signed-off-by: Tetsuya Mukawa --- lib/librte_eal/common/eal_common_dev.c | 66 + lib/librte_eal/common/include/rte_dev.h | 6 +++ lib/l

[dpdk-dev] [PATCH v3 16/28] eal/pci: Add port hotplug functions for virtual devices.

2014-12-09 Thread Tetsuya Mukawa
The patch adds rte_eal_dev_attach_vdev() and rte_eal_dev_detach_vdev(). rte_eal_dev_attach_vdev() receives virtual device name and parameters, and returns an attached port number. rte_eal_dev_detach_vdev() receives a port number, and returns device name actually detached. Signed-off-by: Tetsuya M

[dpdk-dev] [PATCH v3 17/28] eal/linux/pci: Add functions for unmapping igb_uio resources

2014-12-09 Thread Tetsuya Mukawa
The patch adds functions for unmapping igb_uio resources. The patch is only for Linux and igb_uio environment. VFIO and BSD are not supported. Signed-off-by: Tetsuya Mukawa --- lib/librte_eal/linuxapp/eal/eal_pci.c | 35 lib/librte_eal/linuxapp/eal/eal_pci_init.h | 7

[dpdk-dev] [PATCH v3 18/28] eal/pci: Prevent double registrations for pci_device_list

2014-12-09 Thread Tetsuya Mukawa
The patch fixes pci_scan_one() not to register same pci devices twice. Signed-off-by: Tetsuya Mukawa --- lib/librte_eal/linuxapp/eal/eal_pci.c | 9 ++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/lib/librte_eal/linuxapp/eal/eal_pci.c b/lib/librte_eal/linuxapp/eal/eal_pci

[dpdk-dev] [PATCH v3 19/28] eal/pci: Change scope of rte_eal_pci_scan to global

2014-12-09 Thread Tetsuya Mukawa
The function is called by port hotplug framework, so change scope of the function to global. Signed-off-by: Tetsuya Mukawa --- lib/librte_eal/common/eal_private.h | 11 +++ lib/librte_eal/linuxapp/eal/eal_pci.c | 6 +++--- 2 files changed, 14 insertions(+), 3 deletions(-) diff --git

[dpdk-dev] [PATCH v3 20/28] eal/pci: Add rte_eal_pci_close_one_driver

2014-12-09 Thread Tetsuya Mukawa
The function is used for closing the specified driver and device. Signed-off-by: Tetsuya Mukawa --- lib/librte_eal/common/eal_private.h | 15 + lib/librte_eal/linuxapp/eal/eal_pci.c | 61 +++ 2 files changed, 76 insertions(+) diff --git a/lib/librte_eal

[dpdk-dev] [PATCH v3 21/28] eal/pci: Fix pci_probe_all_drivers to share code with closing function

2014-12-09 Thread Tetsuya Mukawa
pci_close_all_drivers() will be implemented after the patch. To share a part of code between thses 2 functions, The patch fixes pci_probe_all_drivers() first. Signed-off-by: Tetsuya Mukawa --- lib/librte_eal/common/eal_common_pci.c | 28 1 file changed, 20 insertions

[dpdk-dev] [PATCH v3 22/28] eal/pci: Add pci_close_all_drivers

2014-12-09 Thread Tetsuya Mukawa
The function tries to find a driver for the specified device, and then close the driver. Signed-off-by: Tetsuya Mukawa --- lib/librte_eal/common/eal_common_pci.c | 19 +++ 1 file changed, 19 insertions(+) diff --git a/lib/librte_eal/common/eal_common_pci.c b/lib/librte_eal/comm

[dpdk-dev] [PATCH v3 23/28] eal/pci: Add rte_eal_pci_probe_one and rte_eal_pci_close_one

2014-12-09 Thread Tetsuya Mukawa
The functions are used for probe and close a device. First the function tries to find a device that has the specfied PCI address. Then, probe or close the device. Signed-off-by: Tetsuya Mukawa --- lib/librte_eal/common/eal_common_pci.c | 58 + lib/librte_eal/comm

[dpdk-dev] [PATCH v3 24/28] eal/pci: Add port hotplug functions for physical devices.

2014-12-09 Thread Tetsuya Mukawa
The patch adds rte_eal_dev_attach_pdev() and rte_eal_dev_detach_pdev(). rte_eal_dev_attach_pdev() receives a PCI address of the device and returns an attached port number. rte_eal_dev_detach_pdev() receives a port number, and returns a PCI address actually detached. Signed-off-by: Tetsuya Mukawa

[dpdk-dev] [PATCH v3 25/28] eal/pci: Remove pci_probe/close_all_drivers()

2014-12-09 Thread Tetsuya Mukawa
These functions are actually wrappers of pci_invoke_all_drivers(). Just call it directly. Signed-off-by: Tetsuya Mukawa --- lib/librte_eal/common/eal_common_pci.c | 30 -- 1 file changed, 4 insertions(+), 26 deletions(-) diff --git a/lib/librte_eal/common/eal_common_

[dpdk-dev] [PATCH v3 26/28] eal/pci: Add rte_eal_dev_attach/detach() functions

2014-12-09 Thread Tetsuya Mukawa
This functions wraps attaching and detaching functions for physical and virtual device. When rte_eal_dev_attach() is called, the function tries to realize the device name as pci address. If this is done successfully, rte_eal_dev_attach() will call rte_eal_dev_attach_pdev(). If not, calls rte_eal_de

[dpdk-dev] [PATCH v3 27/28] eal/pci: Remove rte_eal_dev_attach/detach_pdev() and rte_eal_dev_attach/detach_vdev()

2014-12-09 Thread Tetsuya Mukawa
These functions are wrapped by rte_eal_dev_attach/detach(). So delete these. Signed-off-by: Tetsuya Mukawa --- lib/librte_eal/common/eal_common_dev.c | 8 +++--- lib/librte_eal/common/include/rte_dev.h | 50 - 2 files changed, 4 insertions(+), 54 deletions(-) d

[dpdk-dev] [PATCH v3 28/28] eal: Enable port hotplug framework in Linux

2014-12-09 Thread Tetsuya Mukawa
The patch enables CONFIG_RTE_LIBRTE_EAL_HOTPLUG in Linux configuration. Signed-off-by: Tetsuya Mukawa --- config/common_linuxapp | 5 + 1 file changed, 5 insertions(+) diff --git a/config/common_linuxapp b/config/common_linuxapp index 2f9643b..27d05be 100644 --- a/config/common_linuxapp +++

[dpdk-dev] [PATCH v3] librte_pmd_pcap: Add port hotplug support

2014-12-09 Thread Tetsuya Mukawa
This patch adds finalization code to free resources allocated by the PMD. Signed-off-by: Tetsuya Mukawa --- lib/librte_pmd_pcap/rte_eth_pcap.c | 40 ++ 1 file changed, 40 insertions(+) diff --git a/lib/librte_pmd_pcap/rte_eth_pcap.c b/lib/librte_pmd_pcap/rte

[dpdk-dev] [PATCH v3] testpmd: Add port hotplug support

2014-12-09 Thread Tetsuya Mukawa
The patch introduces following commands. - port attach [ident] - port detach [port_id] - attach: attaching a port - detach: detaching a port - ident: pci address of physical device. Or device name and paramerters of virtual device. (ex. :02:00.0, eth_pcap0,iface=eth0) - p

[dpdk-dev] [RFC PATCH 00/17] Single virtio implementation

2014-12-09 Thread Ouyang, Changchun
> -Original Message- > From: Thomas Monjalon [mailto:thomas.monjalon at 6wind.com] > Sent: Tuesday, December 9, 2014 2:12 PM > To: Ouyang, Changchun > Cc: Qiu, Michael; Stephen Hemminger; dev at dpdk.org > Subject: Re: [dpdk-dev] [RFC PATCH 00/17] Single virtio implementation > > 2014-12

[dpdk-dev] lib: include rte_memory.h for __rte_cache_aligned

2014-12-09 Thread Olivier MATZ
Hi Neil, On 12/08/2014 04:04 PM, Neil Horman wrote: > On Fri, Nov 07, 2014 at 09:28:09AM -0800, Jia Yu wrote: >> Include rte_memory.h for lib files that use __rte_cache_aligned >> attribute. >> >> Signed-off-by: Jia Yu >> > Why? I presume there was a build break or something. Please repost with

[dpdk-dev] [RFC PATCH 00/17] Single virtio implementation

2014-12-09 Thread Thomas Monjalon
2014-12-09 06:40, Ouyang, Changchun: > > > -Original Message- > > From: Thomas Monjalon [mailto:thomas.monjalon at 6wind.com] > > Sent: Tuesday, December 9, 2014 2:12 PM > > To: Ouyang, Changchun > > Cc: Qiu, Michael; Stephen Hemminger; dev at dpdk.org > > Subject: Re: [dpdk-dev] [RFC PATC

[dpdk-dev] [PATCH] enic: fix of compile error

2014-12-09 Thread Helin Zhang
Compile warnings/errors was found on gcc 4.7.2 as follows. Variables was reported of being used but uninitialized. Assigning an initial value to it is needed. lib/librte_pmd_enic/vnic/vnic_dev.c: In function vnic_dev_get_mac_addr: lib/librte_pmd_enic/vnic/vnic_dev.c:393:16: error: a1 may be used u

[dpdk-dev] lib: include rte_memory.h for __rte_cache_aligned

2014-12-09 Thread Jia Yu
Yes, Olivier?s observation is consistent with ours. Compilation didn?t complain if rte_memory.h is not included. Currently, the lib files indirectly included rte_mbuf.h or rte_mempool.h. These two header files already included rte_memory.h. Therefore without this patch, things still work (as valid

[dpdk-dev] error: value computed is not used

2014-12-09 Thread Qiu, Michael
Any other comments on this issue? Thanks, Michael On 12/8/2014 5:07 PM, Qiu, Michael wrote: > Hi all, > My platform is: > > uname -a > Linux suse-11-sp3 3.0.77-0.11-xen #1 SMP Tue Mar 11 16:48:56 CST 2014 > x86_64 x86_64 x86_64 GNU/Linux > > gcc -v > Using built-in specs. > COLLECT_GCC=gcc > COLL

[dpdk-dev] [RFC PATCH 00/17] Single virtio implementation

2014-12-09 Thread Bruce Richardson
On Tue, Dec 09, 2014 at 06:40:23AM +, Ouyang, Changchun wrote: > > > > -Original Message- > > From: Thomas Monjalon [mailto:thomas.monjalon at 6wind.com] > > Sent: Tuesday, December 9, 2014 2:12 PM > > To: Ouyang, Changchun > > Cc: Qiu, Michael; Stephen Hemminger; dev at dpdk.org > >

[dpdk-dev] [PATCH v2] VFIO: Avoid to enable vfio while the module not loaded

2014-12-09 Thread Burakov, Anatoly
Hi Michael, > > Yes, you are right, strncmp() will check 30 bytes if use sizeof(buffer). > > But any issue of strcmp() ? This rountin cares about exactly match. I think no > need to convert to strncmp() if it does have other issue. > > > fscanf with fgets would be better too, to make sure we ne

[dpdk-dev] DDPK use of MAP_FIXED in mmap

2014-12-09 Thread Bruce Richardson
On Mon, Dec 08, 2014 at 07:02:38PM +, Karmarkar Suyash wrote: > Hello, > > In DPDK when we use mmap why are we passing the MAP_FIXED flag when Linux man > page itself says that the option is discouraged? Any specific reason for > passing the MAP_FIXED flag? > > > http://linux.die.net/man/2

[dpdk-dev] [PATCH v2] app/test: fix memory needs after RTE_MAX_LCORE was increased to 128

2014-12-09 Thread Pablo de Lara
Since commit b91c67e5a693211862aa7dc3b78630b4e856c2af, maximum number of cores is 128, which has increase the total memory necessary for a rte_mempool structure, as the per-lcore local cache has been doubled in size. Therefore, eal_flags unit test was broken since it needed to use more hugepages.

[dpdk-dev] [PATCH 11/15] eal/tile: add EAL support for global mPIPE initialization

2014-12-09 Thread Neil Horman
On Mon, Dec 08, 2014 at 01:32:30PM -0800, Cyril Chemparathy wrote: > Hi Neil, > > > On 12/8/2014 12:03 PM, Neil Horman wrote: > >On Mon, Dec 08, 2014 at 04:59:34PM +0800, Zhigang Lu wrote: > >>The TileGx mPIPE hardware provides Ethernet connectivity, > >>packet classification, and packet load bal

[dpdk-dev] [PATCH v3 3/3] doc: add VM power mgmt app

2014-12-09 Thread Pablo de Lara
Added new section in sample app UG for the new VM power management app. Signed-off-by: Alan Carew Signed-off-by: Pablo de Lara --- doc/guides/rel_notes/rel_description.rst |2 + doc/guides/sample_app_ug/index.rst |5 + doc/guides/sample_app_ug/vm_power_management.r

[dpdk-dev] [PATCH v3 2/3] doc: add vm power mgmt request sequence svg

2014-12-09 Thread Pablo de Lara
Added second of the two figures in the VM power management app UG VM power management request sequence Signed-off-by: Alan Carew Signed-off-by: Pablo de Lara --- .../img/vm_power_mgr_vm_request_seq.svg| 927 1 files changed, 927 insertions(+), 0 deletions(-) c

[dpdk-dev] [PATCH v3 0/3] doc: add VM power mgmt app

2014-12-09 Thread Pablo de Lara
This patchset adds a new sample app UG, contaning explanation of the new two sample apps added in the VM power management patchset Changes in v3: Scaled svg files Removed trailing whitespaces Replaced directives for code blocks Separate svg files in different commits Fixed numbered lists Changes

[dpdk-dev] [PATCH v3 1/3] doc: add vm power mgmt overview svg

2014-12-09 Thread Pablo de Lara
Added first of the two figures in the VM power management app UG: VM power mangament highlevel overview Signed-off-by: Alan Carew Signed-off-by: Pablo de Lara --- .../sample_app_ug/img/vm_power_mgr_highlevel.svg | 742 1 files changed, 742 insertions(+), 0 deletions(-)

[dpdk-dev] [PATCH v2 0/3] enhance TX checksum command and csum forwarding engine

2014-12-09 Thread Jijiang Liu
In the current codes, the "tx_checksum set (ip|udp|tcp|sctp|vxlan) (hw|sw) (port-id)" command is not easy to understand and extend, so the patch set enhances the tx_checksum command and reworks csum forwarding engine due to the change of tx_checksum command. The main changes of the tx_checksum

[dpdk-dev] [PATCH v2 1/3] librte_ether:add outer IP offload capability flag

2014-12-09 Thread Jijiang Liu
If the flag is set in a PMD, which means the NIC(s) support TX checksum offload of tunneling packet. Signed-off-by: Jijiang Liu --- lib/librte_ether/rte_ethdev.h |1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/lib/librte_ether/rte_ethdev.h b/lib/librte_ether/rte_ethdev.

[dpdk-dev] [PATCH v2 3/3] app/testpmd:change tx_checksum command and csum forwarding engine

2014-12-09 Thread Jijiang Liu
The patch enhances the tx_checksum command and reworks csum forwarding engine due to the change of tx_checksum command. The main changes of the tx_checksum command are listed below, 1. add "tx_checksum set tunnel (hw|sw|none) (port-id)" command 2. add "tx_checksum set outer-ip (hw|sw) (port-id)"

[dpdk-dev] [PATCH v2 2/3] i40e:support outer IPv4 checksum capability

2014-12-09 Thread Jijiang Liu
The DEV_TX_OFFLOAD_OUTER_IPV4_CKSUM flag is added in i40e capability set, which means the i40e supports TX checksum offload of tunneling packet. Signed-off-by: Jijiang Liu --- lib/librte_pmd_i40e/i40e_ethdev.c |3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/lib/librte

[dpdk-dev] [PATCH] doc: fix typos in ring lib

2014-12-09 Thread Pablo de Lara
Ring library section in PG had a couple of typos, in the text and in one of the images Signed-off-by: Pablo de Lara --- doc/guides/prog_guide/img/ring-modulo1.svg |2 +- doc/guides/prog_guide/ring_lib.rst |2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/doc/g

[dpdk-dev] [PATCH 12/15] eal/tile: add mPIPE buffer stack mempool provider

2014-12-09 Thread Neil Horman
On Mon, Dec 08, 2014 at 04:59:35PM +0800, Zhigang Lu wrote: > TileGX: Modified mempool to allow for variable metadata. > Signed-off-by: Zhigang Lu > Signed-off-by: Cyril Chemparathy > --- > app/test-pmd/mempool_anon.c | 2 +- > app/test/Makefile | 6 +- > app/te

[dpdk-dev] [RFC PATCH 00/17] Single virtio implementation

2014-12-09 Thread Ouyang, Changchun
Hi Bruce, > -Original Message- > From: Richardson, Bruce > Sent: Tuesday, December 9, 2014 5:47 PM > To: Ouyang, Changchun > Cc: Thomas Monjalon; dev at dpdk.org > Subject: Re: [dpdk-dev] [RFC PATCH 00/17] Single virtio implementation > > On Tue, Dec 09, 2014 at 06:40:23AM +, Ouyang,

[dpdk-dev] [PATCH v3 03/28] eal/pci: Replace pci address comparison code by eal_compare_pci_addr

2014-12-09 Thread Qiu, Michael
On 2014/12/9 14:32, Tetsuya Mukawa wrote: > This patch replaces pci_addr_comparison() and memcmp() of pci addresses by > eal_compare_pci_addr(). > > Signed-off-by: Tetsuya Mukawa > --- > lib/librte_eal/bsdapp/eal/eal_pci.c | 16 +--- > lib/librte_eal/common/eal_common_pci.c|

[dpdk-dev] [PATCH v3 07/28] ethdev: Add functions to know which port is attached or detached

2014-12-09 Thread Qiu, Michael
On 2014/12/9 14:32, Tetsuya Mukawa wrote: > The patch adds rte_eth_dev_save() and rte_eth_dev_get_changed_port(). > rte_eth_dev_save() is used for saving current rte_eth_dev structures. > rte_eth_dev_get_changed_port() receives the rte_eth_dev structures, then > compare these with current values to

[dpdk-dev] [PATCH v2 0/3] enhance TX checksum command and csum forwarding engine

2014-12-09 Thread Ananyev, Konstantin
> From: dev [mailto:dev-bounces at dpdk.org] On Behalf Of Jijiang Liu > Sent: Tuesday, December 09, 2014 1:18 PM > To: dev at dpdk.org > Subject: [dpdk-dev] [PATCH v2 0/3] enhance TX checksum command and csum > forwarding engine > > In the current codes, the "tx_checksum set (ip|udp|tcp|sctp|vxla

  1   2   >