[dpdk-dev] [PATCH v2 0/8] L2fwd-crypto fixes/enhancements

2016-03-31 Thread De Lara Guarch, Pablo


> -Original Message-
> From: Thomas Monjalon [mailto:thomas.monjalon at 6wind.com]
> Sent: Thursday, March 31, 2016 10:20 AM
> To: De Lara Guarch, Pablo
> Cc: dev at dpdk.org; Doherty, Declan
> Subject: Re: [dpdk-dev] [PATCH v2 0/8] L2fwd-crypto fixes/enhancements
> 
> 2016-03-31 10:01, Pablo de Lara:
> > This patches fixes some small issues in L2fwd-crypto
> > app and also improves the app, making it more flexible
> > (accepting different key sizes)
> > and readable (information display improvement).
> >
> > Changes in v2:
> >
> > - Extended help information
> 
> The line "Tested-by: Min Cao " is missing.

Thanks for pointing that out. V3 sent with that line.

Pablo



[dpdk-dev] [PATCH 0/7] L2fwd-crypto fixes/enhancements

2016-03-31 Thread Cao, Min
Tested-by: Min Cao 

- Tested Commit: 6ac91f938cc88423885b757ce24c2a984da097d4
- OS: Fedora20 3.11.10-301.fc20.x86_64
- GCC: gcc (GCC) 4.8.3
- CPU: Intel(R) Xeon(R) CPU E5-2658 v3 @ 2.20GHz
- NIC: Niantic
- Default x86_64-native-linuxapp-gcc configuration
- Prerequisites:
- Total 44 cases, 44 passed, 0 failed

- test case 1: QAT Unit test 
Total 31 cases, 31 passed, 0 failed

- test case 2: AES_NI Unit test 
Total 10 cases, 10 passed, 0 failed

- test case 3: l2fwd-crypto AES-CBC 128/192/256
Total 3 cases, 3 passed, 0 failed



-Original Message-
From: dev [mailto:dev-boun...@dpdk.org] On Behalf Of Pablo de Lara
Sent: Wednesday, March 30, 2016 9:02 PM
To: dev at dpdk.org
Cc: Doherty, Declan; De Lara Guarch, Pablo
Subject: [dpdk-dev] [PATCH 0/7] L2fwd-crypto fixes/enhancements

This patches fixes some small issues in L2fwd-crypto app and also improves the 
app, making it more flexible (accepting different key sizes) and readable 
(information display improvement).

Pablo de Lara (7):
  l2fwd-crypto: add missing new line character in help
  l2fwd-crypto: rename period parameter
  l2fwd-crypto: add missing string initialization
  l2fwd-crypto: fix length of random IV/AAD
  l2fwd-crypto: fix ambiguous input key size
  l2fwd-crypto: use key-value list of supported algorithms
  l2fwd-crypto: extend crypto information

 examples/l2fwd-crypto/main.c  | 465 --
 lib/librte_cryptodev/rte_crypto_sym.h |   6 +-
 2 files changed, 398 insertions(+), 73 deletions(-)

--
2.5.5



[dpdk-dev] Must kni be associated with a dpdk port?

2016-03-31 Thread ALeX Wang
Thx a lot, for the answer,!

Exactly what I'm looking for,~

On 31 March 2016 at 02:55, Ferruh Yigit  wrote:

> On 3/30/2016 6:20 PM, ALeX Wang wrote:
> > Hi,
> >
> > I want to use 'rte_kni_alloc()' to create a kernel iface and
> > use it to test application rx.  From the api and example in
> > 'examples/kni/main.c', i saw the 'conf' argument is assigned
> > with pci info of a dpdk port.
> >
> > Want to ask if this is compulsory...  Must kni always be
> > used together with a dpdk port?
> >
> > Thanks,
> >
>
> Hi Alex,
>
> You don't have to associate kni with dpdk port.
>
> pci info is required for ethtool support, if you are only interested in
> data transfer, you don't have to provide pci information.
>
> Regards,
> ferruh
>



-- 
Alex Wang,
Open vSwitch developer


[dpdk-dev] 16.07 Roadmap

2016-03-31 Thread O'Driscoll, Tim
As we're nearing the completion of the 16.04 release, I'd like to let the 
community know our plans for 16.07. It would be good if others are also willing 
to share their plans so that we can build up a complete picture of what's 
targeted for 16.07.

These are the features that we're planning to submit:

Vhost/Virtio Performance Loopback Utility: A tool will be provided which will 
allow virtio/vhost performance testing without the need for NIC traffic.

Virtio Code Refactoring for Rx/TX Split: The Rx and Tx queues will be split as 
they have different information to maintain apart from the common vring. Other 
cleanups will be made to make the queues more friendly for optimization.

Virtio Descriptor Index Update: The virtio descriptor index will be optimized 
for cache2cache transfer in the virtio PMD. The performance increase is 
expected to be below 10%.

Virtio in Containers: Support will be added for virtio in containers (see 
http://dpdk.org/ml/archives/dev/2016-February/032786.html). Multi-queue support 
will also be added.

I40e NSH: This includes: 1. Recognize the Network Services Header packet type; 
2. Direct traffic to queues based on service path header and service index 
(dependent on firmware change so may not make 16.07); 3. Checksum offload.

I40e Floating VEB: Deferred from 16.04. See 
http://dpdk.org/ml/archives/dev/2016-March/036470.html for details.

Automatic VF Reset From PF (i40e/ixgbe): Currently, when a PF notifies a VF 
that a reset is required, DPDK just reports this event to the application, 
which then needs to restart the VF port. A more user-friendly mechanism will be 
implemented where DPDK will reset the VF port directly. The application will 
still be notified, but will not need to handle the reset of the VF port.

Software Implementation of the KASUMI Algorithm: Under the cryptodev API, a 
software implementation of the KASUMI algorithm will be supported. KASUMI is 
widely used in mobile communications systems.

Bit-Level Support for SNOW 3G: Support for the SNOW 3G algorithm is being added 
in the 16.04 release. In 16.07, this will be enhanced so that offsets and 
lengths can be specified in bits instead of bytes (so, you could encrypt 50 
bits of a stream starting from the 5th bit for example).

IPsec Sample App Enhancements: Support for IPv6 and Transport Mode will be 
added to the IPsec sample application that was submitted in 16.04.

XStats Enhancements: Improve the extended NIC stats API to use id value pairs 
instead of string value pairs. Remap stats registers to use standard interface 
MIB naming and sizing.

Keep-Alive Enhancements: Improve DPDK keep-alive to use the DPDK 
alarm/interrupt API instead of using callbacks.

Live Migration for SRIOV: Support for live migration for vhost-user is being 
added to 16.04. This will be further enhanced to support live migration for 
SR-IOV by using link bonding to bond an SRIOV interface with a virtio interface.

IP Pipeline Enhancements: This includes: 1. Configure the MAC address in the 
routing pipeline; 2. Enable RSS per network interface through the configuration 
file; 3. Streamline the CLI code of the IP pipeline application.

Packet Capture Framework: In 16.04, there was lots of discussion on 
requirements for tcpdump support in DPDK (see 
http://dpdk.org/ml/archives/dev/2016-March/035592.html). For 16.07, we plan to 
submit a packet capture framework which will support hooks for filtering 
capabilities such as BPF. Our specific use case for this is for low rate packet 
capture for debug purposes. It should be possible for others to extend the 
framework to support high rate packet capture if they require that capability.

External Mempool Manager: This was originally submitted for 16.04 but had to be 
deferred due to ABI changes. See 
http://dpdk.org/ml/archives/dev/2016-March/035107.html for details.


In addition, there are some features that we're working on now but which we 
know won't make 16.07, either because time is too tight or because of external 
dependencies. These include:

QEMU vHost Back-End Reconnect: Currently, if a vswitch is connected to VMs via 
vhost-user and the vswitch is restarted, then when it comes back up again it 
cannot reconnect to the existing VMs. To address this, both QEMU and vhost-user 
need to support client mode (currently only server mode is supported), which 
implements reconnection messages that allow the vswitch to reconnect to the 
VMs. Changes are required in QEMU as well as in DPDK, so this change will need 
to be coordinated with the QEMU community.

Delay Packet Copy in vHost-User Dequeue: It may be possible to increase 
vhost-user performance by delaying the packet copy until a point where we know 
for certain whether the copy is required or not. This would avoid copying the 
packet in cases where it is not definitely required. Further investigation is 
required to determine how much of a performance gain can be achieved.


Tim


[dpdk-dev] [PATCH] igb: change default RX wthresh back

2016-03-31 Thread Ananyev, Konstantin

Hi Wenzhuo,
> 
> A problem is found on i350 VF. TX will happen once per 4
> packets. If only 1~3 packets are received, they will not be
> forwarded.
> 
> The reason is the default RX write-back threshold is changed
> to 4. This patch changes the value back to 0, so every packet
> can be handled immediately.
> 
> Fixes: 4a41c17dba18 (igb: set default thresholds based on MAC type)
> Signed-off-by: Wenzhuo Lu 
> ---
>  drivers/net/e1000/igb_ethdev.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/net/e1000/igb_ethdev.c b/drivers/net/e1000/igb_ethdev.c
> index bd0ae26..34120ae 100644
> --- a/drivers/net/e1000/igb_ethdev.c
> +++ b/drivers/net/e1000/igb_ethdev.c
> @@ -64,7 +64,7 @@
> 
>  #define IGB_DEFAULT_RX_PTHRESH  ((hw->mac.type == e1000_i354) ? 12 : 8)
>  #define IGB_DEFAULT_RX_HTHRESH  8
> -#define IGB_DEFAULT_RX_WTHRESH  ((hw->mac.type == e1000_82576) ? 1 : 4)
> +#define IGB_DEFAULT_RX_WTHRESH  0

But that still doesn't prevent user from setting wthresh to whatever he likes 
inside
rx_queue_setup(), so the problem persists right?
As a side notice, it seems really bad practice to use implicit variables inside 
macro definition. 
Konstantin

> 
>  #define IGB_DEFAULT_TX_PTHRESH  ((hw->mac.type == e1000_i354) ? 20 : 8)
>  #define IGB_DEFAULT_TX_HTHRESH  1
> --
> 1.9.3



[dpdk-dev] [PATCH v4 05/10] qede: Add core driver

2016-03-31 Thread Harish Patil
>
>On Tue, 29 Mar 2016 22:28:20 -0700
>Rasesh Mody  wrote:
>
>> +static void
>> +qede_alloc_etherdev(struct qede_dev *qdev, struct qed_dev_eth_info
>>*info)
>> +{
>> +rte_memcpy(>dev_info, info, sizeof(*info));
>
>Why bother with rte_memcpy here? why not just assignment or memcpy()?

Basically, I have tried using rte_* equivalent macros if available.
Would it be a problem?
OR is it that rte_memcpy() is meant to be used only in data path?

>
>> +qdev->num_tc = qdev->dev_info.num_tc;
>> +qdev->ops = qed_ops;
>> +}
>




[dpdk-dev] [PATCH] bonding: fix bond link detect in non-interrupt mode

2016-03-31 Thread Thomas Monjalon
2016-03-25 17:44, John Daley:
> From: Nelson Escobar 
> 
> Stopping then re-starting a bond interface containing slaves that
> used polling for link detection caused the bond to think all slave
> links were down and inactive.
> 
> Move the start of the polling for link from slave_add() to
> bond_ethdev_start() and in bond_ethdev_stop() make sure we clear
> the last_link_status of the slaves.
> 
> Signed-off-by: Nelson Escobar 
> Signed-off-by: John Daley 

A "Fixes:" line would be appreciated to know the origin of the bug.
Thanks


[dpdk-dev] [PATCH v13 0/8] ethdev: 100G and link speed API refactoring

2016-03-31 Thread Lu, Wenzhuo
Hi Thomas, Marc,

> -Original Message-
> From: Thomas Monjalon [mailto:thomas.monjalon at 6wind.com]
> Sent: Wednesday, March 30, 2016 5:23 PM
> To: dev at dpdk.org
> Cc: Marc Sune; Xu, Qian Q; Xing, Beilei; Ananyev, Konstantin; Lu, Wenzhuo;
> Richardson, Bruce; Glynn, Michael J
> Subject: Re: [PATCH v13 0/8] ethdev: 100G and link speed API refactoring
> 
> 2016-03-26 02:27, Marc Sune:
> > There are still too few tests and reviews, especially for
> > autonegotiation with Intel devices (patch #6).
> > I would not be surprised to see some bugs in this rework.
> >
> > The capabilities must be adapted per device. It can be improved in a
> > separate patch.
> >
> > It will be integrated in 16.04-rc3.
> > Please test and review shortly, thanks!
> 
> Still no feedback for e1000 and i40e devices.
> Should we consider it is working fine?
I've tried i350 with this patch set. At least the basic rx/tx function is 
working.
But it's a big patch, I still have some questions. I'll comment soon.


[dpdk-dev] [PATCH v3 2/2] ethdev: add ETH_RSS_RETA_SIZE_256

2016-03-31 Thread Jerin Jacob
Signed-off-by: Jerin Jacob 
---
 lib/librte_ether/rte_ethdev.h | 1 +
 1 file changed, 1 insertion(+)

diff --git a/lib/librte_ether/rte_ethdev.h b/lib/librte_ether/rte_ethdev.h
index a4eeeba..d93f85a 100644
--- a/lib/librte_ether/rte_ethdev.h
+++ b/lib/librte_ether/rte_ethdev.h
@@ -470,6 +470,7 @@ struct rte_eth_rss_conf {
  */
 #define ETH_RSS_RETA_SIZE_64  64
 #define ETH_RSS_RETA_SIZE_128 128
+#define ETH_RSS_RETA_SIZE_256 256
 #define ETH_RSS_RETA_SIZE_512 512
 #define RTE_RETA_GROUP_SIZE   64

-- 
2.1.0



[dpdk-dev] [PATCH v3 1/2] ethdev: add tunnel and port RSS offload types

2016-03-31 Thread Jerin Jacob
- added VXLAN, GENEVE and NVGRE tunnel flow types
- added PORT flow type for accounting physical/virtual
port or channel number in flow creation

Signed-off-by: Jerin Jacob 
---
 app/test-pmd/cmdline.c  | 18 +++---
 app/test-pmd/config.c   |  9 +
 doc/guides/testpmd_app_ug/testpmd_funcs.rst |  6 +-
 lib/librte_ether/rte_eth_ctrl.h |  6 +-
 lib/librte_ether/rte_ethdev.h   | 16 +++-
 5 files changed, 49 insertions(+), 6 deletions(-)

diff --git a/app/test-pmd/cmdline.c b/app/test-pmd/cmdline.c
index 93203f4..5fe8239 100644
--- a/app/test-pmd/cmdline.c
+++ b/app/test-pmd/cmdline.c
@@ -565,7 +565,7 @@ static void cmd_help_long_parsed(void *parsed_result,
"Set crc-strip/rx-checksum/hardware-vlan/drop_en"
" for ports.\n\n"

-   "port config all rss (all|ip|tcp|udp|sctp|ether|none)\n"
+   "port config all rss 
(all|ip|tcp|udp|sctp|ether|port|vxlan|geneve|nvgre|none)\n"
"Set the RSS mode.\n\n"

"port config port-id rss reta 
(hash,queue)[,(hash,queue)]\n"
@@ -1545,6 +1545,14 @@ cmd_config_rss_parsed(void *parsed_result,
rss_conf.rss_hf = ETH_RSS_SCTP;
else if (!strcmp(res->value, "ether"))
rss_conf.rss_hf = ETH_RSS_L2_PAYLOAD;
+   else if (!strcmp(res->value, "port"))
+   rss_conf.rss_hf = ETH_RSS_PORT;
+   else if (!strcmp(res->value, "vxlan"))
+   rss_conf.rss_hf = ETH_RSS_VXLAN;
+   else if (!strcmp(res->value, "geneve"))
+   rss_conf.rss_hf = ETH_RSS_GENEVE;
+   else if (!strcmp(res->value, "nvgre"))
+   rss_conf.rss_hf = ETH_RSS_NVGRE;
else if (!strcmp(res->value, "none"))
rss_conf.rss_hf = 0;
else {
@@ -1566,12 +1574,12 @@ cmdline_parse_token_string_t cmd_config_rss_name =
TOKEN_STRING_INITIALIZER(struct cmd_config_rss, name, "rss");
 cmdline_parse_token_string_t cmd_config_rss_value =
TOKEN_STRING_INITIALIZER(struct cmd_config_rss, value,
-   "all#ip#tcp#udp#sctp#ether#none");
+   "all#ip#tcp#udp#sctp#ether#port#vxlan#geneve#nvgre#none");

 cmdline_parse_inst_t cmd_config_rss = {
.f = cmd_config_rss_parsed,
.data = NULL,
-   .help_str = "port config all rss all|ip|tcp|udp|sctp|ether|none",
+   .help_str = "port config all rss 
all|ip|tcp|udp|sctp|ether|port|vxlan|geneve|nvgre|none",
.tokens = {
(void *)_config_rss_port,
(void *)_config_rss_keyword,
@@ -9304,6 +9312,10 @@ flowtype_to_str(uint16_t ftype)
{"ipv6-sctp", RTE_ETH_FLOW_NONFRAG_IPV6_SCTP},
{"ipv6-other", RTE_ETH_FLOW_NONFRAG_IPV6_OTHER},
{"l2_payload", RTE_ETH_FLOW_L2_PAYLOAD},
+   {"port", RTE_ETH_FLOW_PORT},
+   {"vxlan", RTE_ETH_FLOW_VXLAN},
+   {"geneve", RTE_ETH_FLOW_GENEVE},
+   {"nvgre", RTE_ETH_FLOW_NVGRE},
};

for (i = 0; i < RTE_DIM(ftype_table); i++) {
diff --git a/app/test-pmd/config.c b/app/test-pmd/config.c
index b1bbec6..0b3619d 100644
--- a/app/test-pmd/config.c
+++ b/app/test-pmd/config.c
@@ -137,6 +137,11 @@ static const struct rss_type_info rss_type_table[] = {
{ "ipv6-ex", ETH_RSS_IPV6_EX },
{ "ipv6-tcp-ex", ETH_RSS_IPV6_TCP_EX },
{ "ipv6-udp-ex", ETH_RSS_IPV6_UDP_EX },
+   { "port", ETH_RSS_PORT },
+   { "vxlan", ETH_RSS_VXLAN },
+   { "geneve", ETH_RSS_GENEVE },
+   { "nvgre", ETH_RSS_NVGRE },
+
 };

 static void
@@ -2028,6 +2033,10 @@ flowtype_to_str(uint16_t flow_type)
{"ipv6-sctp", RTE_ETH_FLOW_NONFRAG_IPV6_SCTP},
{"ipv6-other", RTE_ETH_FLOW_NONFRAG_IPV6_OTHER},
{"l2_payload", RTE_ETH_FLOW_L2_PAYLOAD},
+   {"port", RTE_ETH_FLOW_PORT},
+   {"vxlan", RTE_ETH_FLOW_VXLAN},
+   {"geneve", RTE_ETH_FLOW_GENEVE},
+   {"nvgre", RTE_ETH_FLOW_NVGRE},
};

for (i = 0; i < RTE_DIM(flowtype_str_table); i++) {
diff --git a/doc/guides/testpmd_app_ug/testpmd_funcs.rst 
b/doc/guides/testpmd_app_ug/testpmd_funcs.rst
index 94fba6a..e8839c2 100644
--- a/doc/guides/testpmd_app_ug/testpmd_funcs.rst
+++ b/doc/guides/testpmd_app_ug/testpmd_funcs.rst
@@ -177,6 +177,10 @@ For example:
  ipv6-sctp
  ipv6-other
  l2_payload
+ port
+ vxlan
+ geneve
+ nvgre

 show port rss reta
 ~~
@@ -1258,7 +1262,7 @@ port config - RSS

 Set the RSS (Receive Side Scaling) mode on or off::

-   testpmd> port config all rss (all|ip|tcp|udp|sctp|ether|none)
+   testpmd> port config all rss 
(all|ip|tcp|udp|sctp|ether|port|vxlan|geneve|nvgre|none)

 RSS is on by default.

diff --git a/lib/librte_ether/rte_eth_ctrl.h b/lib/librte_ether/rte_eth_ctrl.h
index b8c7be9..8afbd92 100644
--- 

[dpdk-dev] [PATCH v3 0/2] New RSS offload flags

2016-03-31 Thread Jerin Jacob
v1..v2
- Added cover letter
- Corrected typo in RET_ETH_FLOW_VXLAN name
- Updated test-pmd application to access newly defined RSS offload flags

v2..v3
-testpmd document update(Suggested by John and Pablo)

Jerin Jacob (2):
  ethdev: add tunnel and port RSS offload types
  ethdev: add ETH_RSS_RETA_SIZE_256

 app/test-pmd/cmdline.c  | 18 +++---
 app/test-pmd/config.c   |  9 +
 doc/guides/testpmd_app_ug/testpmd_funcs.rst |  6 +-
 lib/librte_ether/rte_eth_ctrl.h |  6 +-
 lib/librte_ether/rte_ethdev.h   | 17 -
 5 files changed, 50 insertions(+), 6 deletions(-)

-- 
2.1.0



[dpdk-dev] [PATCH v2 1/2] ethdev: add tunnel and port RSS offload types

2016-03-31 Thread Jerin Jacob
On Tue, Mar 29, 2016 at 11:58:47AM +, De Lara Guarch, Pablo wrote:
> Hi Jerin,
> 
> > -Original Message-
> > From: dev [mailto:dev-bounces at dpdk.org] On Behalf Of Jerin Jacob
> > Sent: Tuesday, March 29, 2016 12:20 PM
> > To: dev at dpdk.org
> > Cc: thomas.monjalon at 6wind.com; Richardson, Bruce; Jerin Jacob
> > Subject: [dpdk-dev] [PATCH v2 1/2] ethdev: add tunnel and port RSS offload
> > types
> > 
> > - added VXLAN, GENEVE and NVGRE tunnel flow types
> > - added PORT flow type for accounting physical/virtual
> > port or channel number in flow creation
> > 
> > Signed-off-by: Jerin Jacob 
> > ---
> >  app/test-pmd/cmdline.c  | 18 +++---
> >  app/test-pmd/config.c   |  9 +
> >  lib/librte_ether/rte_eth_ctrl.h |  6 +-
> >  lib/librte_ether/rte_ethdev.h   | 16 +++-
> >  4 files changed, 44 insertions(+), 5 deletions(-)
> > 
> > diff --git a/app/test-pmd/cmdline.c b/app/test-pmd/cmdline.c
> > index 93203f4..5fe8239 100644
> > --- a/app/test-pmd/cmdline.c
> > +++ b/app/test-pmd/cmdline.c
> > @@ -565,7 +565,7 @@ static void cmd_help_long_parsed(void
> > *parsed_result,
> > "Set crc-strip/rx-checksum/hardware-
> > vlan/drop_en"
> > " for ports.\n\n"
> > 
> > -   "port config all rss
> > (all|ip|tcp|udp|sctp|ether|none)\n"
> > +   "port config all rss
> > (all|ip|tcp|udp|sctp|ether|port|vxlan|geneve|nvgre|none)\n"
> 
> Could you update the testpmd document and extend the options in the command 
> line help?
Hi John and Pablo,

I will send the V3 with testpmd document update. Command line help is
already part of V2

> 
> Thanks,
> Pablo
> 
> 


[dpdk-dev] [PATCH v13 6/8] ethdev: redesign link speed config

2016-03-31 Thread Xing, Beilei
Marc,

I?ve verified v13 + the modification, and it works.

Best Regards
Beilei Xing

From: marc.sune at gmail.com [mailto:marc.s...@gmail.com] On Behalf Of Marc
Sent: Wednesday, March 30, 2016 4:00 PM
To: Xing, Beilei 
Cc: Thomas Monjalon ; Xu, Qian Q ; dev at dpdk.org; Ananyev, Konstantin ; Lu, Wenzhuo ; Richardson, Bruce 
; Glynn, Michael J 
Subject: Re: [PATCH v13 6/8] ethdev: redesign link speed config



On 29 March 2016 at 08:18, Xing, Beilei mailto:beilei.xing at intel.com>> wrote:


> -Original Message-
> From: Marc Sune [mailto:marcdevel at gmail.com]
> Sent: Saturday, March 26, 2016 9:27 AM
> To: Thomas Monjalon mailto:thomas.monjalon at 
> 6wind.com>>; Xu, Qian Q
> mailto:qian.q.xu at intel.com>>; Xing, Beilei 
> mailto:beilei.xing at intel.com>>; dev at 
> dpdk.org;
> Ananyev, Konstantin  intel.com>; Lu, Wenzhuo
> mailto:wenzhuo.lu at intel.com>>; Richardson, Bruce 
> mailto:bruce.richardson at intel.com>>;
> Glynn, Michael J mailto:michael.j.glynn at 
> intel.com>>
> Cc: Marc Sune mailto:marcdevel at gmail.com>>
> Subject: [PATCH v13 6/8] ethdev: redesign link speed config
>

> a/drivers/net/ixgbe/ixgbe_ethdev.c b/drivers/net/ixgbe/ixgbe_ethdev.c
> index a98e8eb..6cc2da0 100644
> --- a/drivers/net/ixgbe/ixgbe_ethdev.c
> +++ b/drivers/net/ixgbe/ixgbe_ethdev.c
> @@ -2193,32 +2195,21 @@ ixgbe_dev_start(struct rte_eth_dev *dev)
>   if (err)
>   goto error;
>
> + speed = 0x0;
> + if (*link_speeds & ETH_LINK_SPEED_10G)
> + speed |= IXGBE_LINK_SPEED_10GB_FULL;
> + if (*link_speeds & ETH_LINK_SPEED_1G)
> + speed |= IXGBE_LINK_SPEED_1GB_FULL;
> + if (*link_speeds & ETH_LINK_SPEED_100M)
> + speed |= IXGBE_LINK_SPEED_100_FULL;
> +
>   err = ixgbe_setup_link(hw, speed, link_up);
>   if (err)
>   goto error;

Hi Marc,
According to ixgbe HW, link speed shouldn't be 0 when setting up,
Otherwise device will start fail. So we need to set speed if link_speed
is ETH_LINK_SPEED_AUTONEG. Following code is for reference.

speed = 0x0;
if ((*link_speeds & 0x1) == ETH_LINK_SPEED_AUTONEG)
speed = (hw->mac.type != ixgbe_mac_82598EB) ?
IXGBE_LINK_SPEED_82599_AUTONEG :
IXGBE_LINK_SPEED_82598_AUTONEG;
else {
if (*link_speeds & ETH_LINK_SPEED_10G)
speed |= IXGBE_LINK_SPEED_10GB_FULL;
if (*link_speeds & ETH_LINK_SPEED_1G)
speed |= IXGBE_LINK_SPEED_1GB_FULL;
if (*link_speeds & ETH_LINK_SPEED_100M)
speed |= IXGBE_LINK_SPEED_100_FULL;
}

Beilei,

OK, thanks.

Can you/someone please try v13 + this modification, so that we make sure this 
is the final version for ixgbe?

Regards
Marc


Beilei Xing
Thanks



[dpdk-dev] [PATCH v3 2/7] drivers/net/e1000: Suppress misleading indentation warning

2016-03-31 Thread Lu, Wenzhuo
Hi,

> -Original Message-
> From: Aaron Conole [mailto:aconole at redhat.com]
> Sent: Wednesday, March 30, 2016 10:07 PM
> To: Thomas Monjalon
> Cc: Panu Matilainen; Lu, Wenzhuo; dev at dpdk.org; Richardson, Bruce
> Subject: [PATCH v3 2/7] drivers/net/e1000: Suppress misleading indentation
> warning
> 
> The register read/write mphy functions have misleading whitespace around the
> `locked` check. This cleanup merely preserves the existing functionality and
> suppresses future gcc versions' "misleading indentation" warning.
> 
> Suggested-by: Panu Matilainen 
> Signed-off-by: Aaron Conole 
Acked-by: Wenzhuo Lu 


[dpdk-dev] [PATCH] Fix KNI compilation under Wind River Linux 6.0 recent RCPLs.

2016-03-31 Thread Vincent JARDIN
Le 30/03/2016 23:50, Stephen Hemminger a ?crit :
> Do we want to require DPDK to work in the face of every weird vendor
> kernel backport. This is a road to nowhere...
+1 with Steve. No way! There is no rational.


[dpdk-dev] [PATCH v2 2/2] Fix prefetch instruction on IBM POWER8

2016-03-31 Thread Chao Zhu
Current prefetch instruction (dcbt) implementation for IBM POWER8 has wrong
Touch Hint(TH) parameter. The current setting of TH=1 indicates to load data 
from
current cache line and an unlimited number of sequentially following cache 
lines.
TTH=0 means to load data from current cache line. rte_prefetch0 function is 
defined
to load one cache line, which means TH=0 is suited here.

Signed-off-by: Chao Zhu 
---
 .../common/include/arch/ppc_64/rte_prefetch.h  |6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/lib/librte_eal/common/include/arch/ppc_64/rte_prefetch.h 
b/lib/librte_eal/common/include/arch/ppc_64/rte_prefetch.h
index bcc7185..9a1995e 100644
--- a/lib/librte_eal/common/include/arch/ppc_64/rte_prefetch.h
+++ b/lib/librte_eal/common/include/arch/ppc_64/rte_prefetch.h
@@ -41,17 +41,17 @@ extern "C" {

 static inline void rte_prefetch0(const volatile void *p)
 {
-   asm volatile ("dcbt 0,%[p],1" : : [p] "r" (p));
+   asm volatile ("dcbt 0,%[p],0" : : [p] "r" (p));
 }

 static inline void rte_prefetch1(const volatile void *p)
 {
-   asm volatile ("dcbt 0,%[p],1" : : [p] "r" (p));
+   asm volatile ("dcbt 0,%[p],0" : : [p] "r" (p));
 }

 static inline void rte_prefetch2(const volatile void *p)
 {
-   asm volatile ("dcbt 0,%[p],1" : : [p] "r" (p));
+   asm volatile ("dcbt 0,%[p],0" : : [p] "r" (p));
 }

 static inline void rte_prefetch_non_temporal(const volatile void *p)
-- 
1.7.1



[dpdk-dev] [PATCH v2 1/2] Fix CPU and memory parameters on IBM POWER8

2016-03-31 Thread Chao Zhu
This patch fixes the max logic number and memory channel number settings
on IBM POWER8 platform.
1. The max number of logic cores of a POWER8 processor is 96. Normally,
   there are two sockets on a server. So the max number of logic cores
   are 192. So this parch set CONFIG_RTE_MAX_LCORE to 256.
2. The socket number on POWER8 little endian platform can be larger than 16.
   This patch set CONFIG_RTE_MAX_NUMA_NODES to 32 for POWER8.
3. Currently, the max number of memory channels are hardcoded to 4. However,
   on a POWER8 machine, the max number of memory channels are 8. This patch
   removes the constraint.

Signed-off-by: Chao Zhu 
---
 config/defconfig_ppc_64-power8-linuxapp-gcc |2 ++
 lib/librte_eal/common/eal_common_options.c  |3 +--
 2 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/config/defconfig_ppc_64-power8-linuxapp-gcc 
b/config/defconfig_ppc_64-power8-linuxapp-gcc
index a80a19e..9eb0cc4 100644
--- a/config/defconfig_ppc_64-power8-linuxapp-gcc
+++ b/config/defconfig_ppc_64-power8-linuxapp-gcc
@@ -36,6 +36,8 @@ CONFIG_RTE_ARCH="ppc_64"
 CONFIG_RTE_ARCH_PPC_64=y
 CONFIG_RTE_ARCH_64=y

+CONFIG_RTE_MAX_LCORE=256
+CONFIG_RTE_MAX_NUMA_NODES=32
 CONFIG_RTE_CACHE_LINE_SIZE=128

 CONFIG_RTE_TOOLCHAIN="gcc"
diff --git a/lib/librte_eal/common/eal_common_options.c 
b/lib/librte_eal/common/eal_common_options.c
index 29942ea..2b418d5 100644
--- a/lib/librte_eal/common/eal_common_options.c
+++ b/lib/librte_eal/common/eal_common_options.c
@@ -797,8 +797,7 @@ eal_parse_common_option(int opt, const char *optarg,
/* force number of channels */
case 'n':
conf->force_nchannel = atoi(optarg);
-   if (conf->force_nchannel == 0 ||
-   conf->force_nchannel > 4) {
+   if (conf->force_nchannel == 0) {
RTE_LOG(ERR, EAL, "invalid channel number\n");
return -1;
}
-- 
1.7.1



[dpdk-dev] [PATCH v2 0/2] Fix parameters and prefetch function on IBM POWER8

2016-03-31 Thread Chao Zhu
This patch set fixes CPU/memory parameters and correct wrong prefetch settings 
for IBM POWER8.
Changes in v2:
1. Move the parameter configuration to POWER specific configuration file
2. Remove the memeory channel number constraint instead of adding additional 
configuration flag.

Chao Zhu (2):
  Fix CPU and memory parameters on IBM POWER8
  Fix prefetch instruction on IBM POWER8

 config/defconfig_ppc_64-power8-linuxapp-gcc|2 ++
 lib/librte_eal/common/eal_common_options.c |3 +--
 .../common/include/arch/ppc_64/rte_prefetch.h  |6 +++---
 3 files changed, 6 insertions(+), 5 deletions(-)



<    1   2