[dpdk-dev] [PATCH RFC v2 10/12] lib/librte_vhost: vhost-user memory region map

2014-12-16 Thread Tetsuya Mukawa
(2014/12/11 6:37), Huawei Xie wrote: > deals with vhost user memory map/unmap alignment > > Signed-off-by: Huawei Xie > --- > lib/librte_vhost/rte_virtio_net.h | 2 + > lib/librte_vhost/vhost-net.h | 2 - > lib/librte_vhost/vhost_user/vhost-net-user.h | 3 +- >

[dpdk-dev] [PATCH RFC v2 00/12] lib/librte_vhost: vhost-user support

2014-12-15 Thread Tetsuya Mukawa
Hi Xie, I've got warnings from checkpatch.pl. Mostly 'over 80 characters' warnings. (But I know these are come from original vhost-example code sometimes.) So far, your patches are RFC, so I haven't check these strictly. Thanks, Tetsuya (2014/12/11 6:37), Huawei Xie wrote: > This patchset

[dpdk-dev] [PATCH RFC v2 07/12] lib/librte_vhost: async event and callback

2014-12-15 Thread Tetsuya Mukawa
(2014/12/11 6:37), Huawei Xie wrote: > Signed-off-by: Huawei Xie > --- > lib/librte_vhost/vhost_user/fd_man.c | 205 > +++ > lib/librte_vhost/vhost_user/fd_man.h | 64 +++ > 2 files changed, 269 insertions(+) > create mode 100644

[dpdk-dev] [PATCH RFC v2 06/12] lib/librte_vhost: cuse_set_memory_table

2014-12-15 Thread Tetsuya Mukawa
(2014/12/11 6:37), Huawei Xie wrote: > cuse_set_memory_table > > Signed-off-by: Huawei Xie > --- > lib/librte_vhost/Makefile | 2 +- > lib/librte_vhost/vhost-net.h | 4 +- > lib/librte_vhost/vhost_cuse/vhost-net-cdev.c | 7 +- >

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

2014-12-11 Thread Tetsuya Mukawa
dn't want to change original patch separation radically. Anyway, I will merge a few patches. At the time I will merge these. Thanks, Tetsuya > Thanks, > Michael > > On 12/9/2014 2:34 PM, Tetsuya Mukawa wrote: >> These functions are actually wrappers of pci_invoke_all_drivers(

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

2014-12-11 Thread Tetsuya Mukawa
(2014/12/11 14:54), Qiu, Michael wrote: > On 12/9/2014 2:34 PM, Tetsuya Mukawa wrote: >> 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. >> >&

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

2014-12-11 Thread Tetsuya Mukawa
ace pci address comparison code by eal_compare_pci_addr And it will be fixed in following. [dpdk-dev] [PATCH v3 18/28] eal/pci: Prevent double registrations for pci_device_list I will merge it. Thanks, Tetsuya > If other patch, I missed, with the same issue, please take same action. > >

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

2014-12-11 Thread Tetsuya Mukawa
(2014/12/11 13:46), Qiu, Michael wrote: > On 12/11/2014 11:52 AM, Qiu, Michael wrote: >> On 12/9/2014 2:34 PM, Tetsuya Mukawa wrote: >>> pci_close_all_drivers() will be implemented after the patch. >>> To share a part of code between thses 2 functions, The patch fixe

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

2014-12-11 Thread Tetsuya Mukawa
Hi Michael, (2014/12/09 23:55), Qiu, Michael wrote: > On 2014/12/9 14:33, Tetsuya Mukawa wrote: >> The patch fixes rte_eal_devargs_add() not to register same device twice. >> >> Signed-off-by: Tetsuya Mukawa >> --- >> lib/librte_eal

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

2014-12-11 Thread Tetsuya Mukawa
(2014/12/11 12:35), Qiu, Michael wrote: > On 12/11/2014 11:12 AM, Tetsuya Mukawa wrote: >> Hi Michael, >> >> (2014/12/09 23:39), Qiu, Michael wrote: >>> On 2014/12/9 14:32, Tetsuya Mukawa wrote: >>>> The patch adds rte_eth_dev_save() and rte_eth_dev

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

2014-12-11 Thread Tetsuya Mukawa
Hi Michael, (2014/12/10 0:51), Qiu, Michael wrote: > On 2014/12/9 14:33, Tetsuya Mukawa wrote: >> 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 >&

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

2014-12-11 Thread Tetsuya Mukawa
Hi Michael, (2014/12/09 23:39), Qiu, Michael wrote: > 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_ch

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

2014-12-11 Thread Tetsuya Mukawa
Hi Michael, (2014/12/09 23:22), Qiu, Michael wrote: > 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/lib

[dpdk-dev] [PATCH RFC v2 00/12] lib/librte_vhost: vhost-user support

2014-12-11 Thread Tetsuya Mukawa
Hi Xie, (2014/12/11 7:04), Xie, Huawei wrote: > This patch set is based on latest vhost. > It fixes vhost-user memory map/unmap alignment issue. > It uses VHOST_USER_GET_VRING_BASE as the message for vhost device stop > in vhost-user. > It uses VHOST_SET_VRING_KICK as the

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

2014-12-11 Thread Tetsuya Mukawa
ya > But just one suggestion, merge or not depends you. > > Thanks, > Michael > On 2014/12/9 14:33, Tetsuya Mukawa wrote: >> The function removes a specified devargs from devargs_list. >> >> Signed-off-by: Tetsuya Mukawa >> --- >> lib/librte_eal/common

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

2014-12-09 Thread Tetsuya Mukawa
) - port_id: port identifier Signed-off-by: Tetsuya Mukawa --- app/test-pmd/cmdline.c| 133 +-- app/test-pmd/config.c | 116 +++ app/test-pmd/parameters.c | 21 +++-- app/test-pmd/testpmd.c| 199

[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 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

[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

[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 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

[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

[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 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

[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

[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

[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

[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

[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

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

2014-12-09 Thread Tetsuya Mukawa
. Signed-off-by: Tetsuya Mukawa --- lib/librte_ether/rte_ethdev.c | 21 + lib/librte_ether/rte_ethdev.h | 21 + 2 files changed, 42 insertions(+) diff --git a/lib/librte_ether/rte_ethdev.c b/lib/librte_ether/rte_ethdev.c index 51697e1..6a3700e 100644

[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

[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

[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_

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

2014-12-09 Thread Tetsuya Mukawa
after forwarding, if attaching and detaching is repeatedly. - Fix if-condition of rte_eth_dev_get_port_by_addr(). (Thanks to Mark Enright) RFC PATCH v2 Changes: - remove 'rte_eth_dev_validate_port()', and cleanup codes. Tetsuya Mukawa (28): eal/pci: Add a new flag indicating a driver can

[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 >>

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

2014-12-09 Thread Tetsuya Mukawa
) - port_id: port identifier Signed-off-by: Tetsuya Mukawa --- app/test-pmd/cmdline.c| 133 +-- app/test-pmd/config.c | 116 +++ app/test-pmd/parameters.c | 21 +++-- app/test-pmd/testpmd.c| 199

[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

[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 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

[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 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

[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

[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 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

[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

[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

[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

[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

[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

[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

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

2014-12-09 Thread Tetsuya Mukawa
. Signed-off-by: Tetsuya Mukawa --- lib/librte_ether/rte_ethdev.c | 21 + lib/librte_ether/rte_ethdev.h | 21 + 2 files changed, 42 insertions(+) diff --git a/lib/librte_ether/rte_ethdev.c b/lib/librte_ether/rte_ethdev.c index 51697e1..6a3700e 100644

[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

[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 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 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

[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_

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

2014-12-09 Thread Tetsuya Mukawa
of rte_eth_dev_get_port_by_addr(). (Thanks to Mark Enright) RFC PATCH v2 Changes: - remove 'rte_eth_dev_validate_port()', and cleanup codes. Tetsuya Mukawa (28): eal/pci: Add a new flag indicating a driver can detach devices at runtime. ethdev: Remove assumption that port will not be detached

[dpdk-dev] Next Community Call, Tuesday 2nd December, 8:00 AM GMT

2014-12-02 Thread Tetsuya Mukawa
ill also record the session and post the video for > those who can't attend. > > > Tim > >> -----Original Message- >> From: Tetsuya Mukawa [mailto:mukawa at igel.co.jp] >> Sent: Monday, December 1, 2014 2:50 AM >> To: O'driscoll, Tim; dev at dpdk.org >>

[dpdk-dev] Next Community Call, Tuesday 2nd December, 8:00 AM GMT

2014-12-01 Thread Tetsuya Mukawa
ss the following: > ? Remaining 2.0 candidate features, especially PCI Hotplug as there's been a > lot of discussion on that on the mailing list. Hopefully Tetsuya Mukawa can > join us to describe his work on this. > ? DPDK Test Suite. We hope to announce the release of this next week

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

2014-11-20 Thread Tetsuya Mukawa
:00.0, eth_pcap0,iface=eth0) Signed-off-by: Tetsuya Mukawa --- app/test-pmd/cmdline.c| 139 +++- app/test-pmd/config.c | 54 +++ app/test-pmd/parameters.c | 21 +++-- app/test-pmd/testpmd.c| 226 -- app/test

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

2014-11-20 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 | 33 + 1 file changed, 33 insertions(+) diff --git a/lib/librte_pmd_pcap/rte_eth_pcap.c b/lib/librte_pmd_pcap

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

2014-11-20 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 57b61c9..a2b1e36 100644 --- a/config/common_linuxapp

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

2014-11-20 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 23/25] eal/pci: Add rte_eal_pci_probe_one and rte_eal_pci_close_one

2014-11-20 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

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

2014-11-20 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

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

2014-11-20 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

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

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

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

2014-11-20 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/include/eal_private.h | 11 +++ lib/librte_eal/linuxapp/eal/eal_pci.c | 6 +++--- 2 files changed, 14 insertions(+), 3 deletions

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

2014-11-20 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

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

2014-11-20 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 | 32 + lib/librte_eal/linuxapp/eal/eal_pci_uio.c

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

2014-11-20 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

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

2014-11-20 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 | 74 + lib/librte_eal/common/include/rte_dev.h | 6 +++ lib

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

2014-11-20 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 | 13 + lib/librte_eal/common/include/rte_devargs.h | 18 ++ 2 files changed, 31 insertions(+) diff --git a/lib/librte_eal

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

2014-11-20 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 | 32 ++ 1 file changed, 32 insertions(+) diff --git a/lib/librte_eal/common/eal_common_devargs.c b/lib/librte_eal

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

2014-11-20 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

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

2014-11-20 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

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

2014-11-20 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 | 17 + lib/librte_ether/rte_ethdev.h | 12 2 files changed, 29 insertions(+) diff --git a/lib/librte_ether

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

2014-11-20 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 | 17 + lib/librte_ether

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

2014-11-20 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 | 12 lib/librte_ether/rte_ethdev.h | 13 + 2 files changed, 25 insertions(+) diff --git a/lib/librte_ether/rte_ethdev.c b/lib

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

2014-11-20 Thread Tetsuya Mukawa
. Signed-off-by: Tetsuya Mukawa --- lib/librte_ether/rte_ethdev.c | 18 ++ lib/librte_ether/rte_ethdev.h | 21 + 2 files changed, 39 insertions(+) diff --git a/lib/librte_ether/rte_ethdev.c b/lib/librte_ether/rte_ethdev.c index c9f82d9..5e1b6b9 100644

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

2014-11-20 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 f217e14

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

2014-11-20 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 | 4 2 files changed, 11

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

2014-11-20 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 03/25] eal/pci: Replace pci address comparison code by eal_compare_pci_addr

2014-11-20 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] [RFC PATCH v2 00/25] Port Hotplug Framework

2014-11-18 Thread Tetsuya Mukawa
to change PMDs. But still I don't have implementations for physical PMDs. - If there is someone who can develop hotplug function together, it's nice! Thanks, Tetsuya (2014/11/04 12:45), Tetsuya Mukawa wrote: > This patch series adds a dynamic port hotplug framework to DPDK. > With the p

[dpdk-dev] vhost-user technical isssues

2014-11-17 Thread Tetsuya Mukawa
Hi Xie, (2014/11/14 19:59), Xie, Huawei wrote: > I tested with latest qemu(with offset fix) in vhost app(not with test case), > unmap succeeds only when the size is aligned to 1GB(hugepage size). I appreciate for your testing. > Another important thing is could we do mmap(0,

[dpdk-dev] [PATCH RFC] lib/librte_vhost: vhost-user

2014-11-17 Thread Tetsuya Mukawa
Hi Xie, (2014/11/17 15:04), Tetsuya Mukawa wrote: > Hi Xie, > > > (2014/11/15 10:14), Huawei Xie wrote: >> implement socket server >> fd event dispatch mechanism >> vhost sock message handling >> memory map for each region >> VHOST_USER_SET_VRING_KICK_F

[dpdk-dev] [RFC PATCH 2/2] lib/librte_vhost: Add device abstraction layer

2014-11-17 Thread Tetsuya Mukawa
--- lib/librte_vhost/Makefile | 6 +- lib/librte_vhost/rte_virtio_net.h | 22 - lib/librte_vhost/vhost-cuse/vhost-net-cdev.c | 6 +- lib/librte_vhost/vhost-cuse/vhost-net-cdev.h | 40 + lib/librte_vhost/vhost-cuse/virtio-net-cdev.c | 1 +

[dpdk-dev] [RFC PATCH 1/2] lib/librte_vhost: change macro name of include guard.

2014-11-17 Thread Tetsuya Mukawa
This patch changes include macro name like following. - "_VIRTIO_NET_H_" > "_RTE_VIRTIO_NET_H_" --- lib/librte_vhost/rte_virtio_net.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/librte_vhost/rte_virtio_net.h b/lib/librte_vhost/rte_virtio_net.h index

[dpdk-dev] [RFC PATCH] lib/librte_vhost: cleanup white spaces, tabs and indents

2014-11-17 Thread Tetsuya Mukawa
--- lib/librte_vhost/rte_virtio_net.h | 4 +-- lib/librte_vhost/vhost-cuse/vhost-net-cdev.c | 4 +-- lib/librte_vhost/vhost-cuse/virtio-net-cdev.c | 8 ++--- lib/librte_vhost/vhost-user/fd_man.c | 13 lib/librte_vhost/vhost-user/fd_man.h | 2 +-

[dpdk-dev] [PATCH RFC] lib/librte_vhost: vhost-user

2014-11-17 Thread Tetsuya Mukawa
Hi Xie, (2014/11/15 10:14), Huawei Xie wrote: > implement socket server > fd event dispatch mechanism > vhost sock message handling > memory map for each region > VHOST_USER_SET_VRING_KICK_FD as the indicator that vring is available > VHOST_USER_GET_VRING_BASE as the message that vring should

[dpdk-dev] vhost-user technical isssues

2014-11-14 Thread Tetsuya Mukawa
Hi Lin, (2014/11/14 14:30), Linhaifeng wrote: > > On 2014/11/14 13:12, Tetsuya Mukawa wrote: >> ease try another value like 6000MB > i have try this value 6000MB.I can munmap success. > > you mmap with size "memory_size + memory_offset" should also munmap with this

[dpdk-dev] vhost-user technical isssues

2014-11-14 Thread Tetsuya Mukawa
Hi Lin, (2014/11/14 13:42), Linhaifeng wrote: > > On 2014/11/14 11:40, Tetsuya Mukawa wrote: >> Hi Lin, >> >> (2014/11/14 12:13), Linhaifeng wrote: >>> size should be same as mmap and >>> guest_mem -= (memory.regions[i].mmap_offset / sizeof(*guest_mem));

[dpdk-dev] [RFC PATCH 7/7] lib/librte_vhost: Add vhost-user implementation

2014-11-14 Thread Tetsuya Mukawa
(2014/11/14 9:07), Xie, Huawei wrote: >> +struct vhost_device_user_ctx { >> +int *fds; >> +int fd_num; >> +struct vhost_driver *drv; >> +}; >> + >> /* >> * Structure used to identify device context. >> */ >> @@ -83,6 +89,7 @@ struct

[dpdk-dev] vhost-user technical isssues

2014-11-14 Thread Tetsuya Mukawa
(2014/11/14 12:40), Tetsuya Mukawa wrote: > I am using 1GB hugepage size. > > $ sudo QTEST_HUGETLBFS_PATH=/mnt/huge make check > region=0, mmap=0x2aaac000, size=6291456000 > region=0, munmap=0x2aaac000, size=6291456000, ret=-1 << failed > > 6291456000 is n

[dpdk-dev] vhost-user technical isssues

2014-11-14 Thread Tetsuya Mukawa
Hi Lin, (2014/11/14 12:13), Linhaifeng wrote: > > size should be same as mmap and > guest_mem -= (memory.regions[i].mmap_offset / sizeof(*guest_mem)); > Thanks. It should be. How about following patch? --- diff --git a/tests/vhost-user-test.c

[dpdk-dev] vhost-user technical isssues

2014-11-14 Thread Tetsuya Mukawa
Hi Xie, (2014/11/14 9:22), Xie, Huawei wrote: >> I think so. I guess we need to consider 2 types of restarting. One is >> virtio-net driver restarting, the other is vhost-user backend >> restarting. But, so far, it's nice to start to think about virtio-net >> driver restarting first. Probably we

[dpdk-dev] vhost-user technical isssues

2014-11-14 Thread Tetsuya Mukawa
(2014/11/14 11:24), Linhaifeng wrote: > On 2014/11/14 9:28, Xie, Huawei wrote: > actually there may be two hugepage files created by qemu. one day i > create a 4G VM found qemu create 2 hugepage file and send them to > vhost-user. you can try to test it. That's the case. Bcasue I didn't think

[dpdk-dev] vhost-user technical isssues

2014-11-12 Thread Tetsuya Mukawa
Hi Xie, (2014/11/12 6:37), Xie, Huawei wrote: > Hi Tetsuya: > There are two major technical issues in my mind for vhost-user implementation. > > 1) memory region map > Vhost-user passes us file fd and offset for each memory region. Unfortunately > the mmap offset is "very" wrong. I discovered

[dpdk-dev] [RFC PATCH 7/7] lib/librte_vhost: Add vhost-user implementation

2014-11-10 Thread Tetsuya Mukawa
Hi Xie, (2014/11/10 17:18), Xie, Huawei wrote: > Tetsuya: > I already did this, :), and will publish the code for review after I do some > cleanup next week. I appreciate it. I guess your implementation assumes that all vhost-user functions you implemented are called by virtio common layer. Is

<    4   5   6   7   8   9   10   >