DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] [PATCH] i40e:Fix for wrong publish of card speed (was mixed between 10G and 40G)
       [not found] <20160717153404.12790-1-ibarnea@cisco.com>
@ 2016-07-17 15:43 ` Ido Barnea (ibarnea)
  2016-07-18  1:52   ` Wu, Jingjing
       [not found]   ` <20160718095433.31383-1-ibarnea@cisco.com>
  0 siblings, 2 replies; 7+ messages in thread
From: Ido Barnea (ibarnea) @ 2016-07-17 15:43 UTC (permalink / raw)
  To: dev

Signed-off-by: Ido Barnea <ibarnea@cisco.com>


---
 drivers/net/i40e/i40e_ethdev.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/i40e/i40e_ethdev.c b/drivers/net/i40e/i40e_ethdev.c
index 3f9f05e..64d60ef 100644
--- a/drivers/net/i40e/i40e_ethdev.c
+++ b/drivers/net/i40e/i40e_ethdev.c
@@ -2628,10 +2628,10 @@ i40e_dev_info_get(struct rte_eth_dev *dev, struct rte_eth_dev_info *dev_info
	if (i40e_is_40G_device(hw->device_id))		/* For XL710 */

-		dev_info->speed_capa = ETH_LINK_SPEED_1G | ETH_LINK_SPEED_10G;
+		dev_info->speed_capa = ETH_LINK_SPEED_10G | ETH_LINK_SPEED_40G;
 	else
 		/* For X710 */
-		dev_info->speed_capa = ETH_LINK_SPEED_10G | ETH_LINK_SPEED_40G;
+		dev_info->speed_capa = ETH_LINK_SPEED_1G | ETH_LINK_SPEED_10G;
 }
static int
-- 
2.8.3

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [dpdk-dev] [PATCH] i40e:Fix for wrong publish of card speed (was mixed between 10G and 40G)
  2016-07-17 15:43 ` [dpdk-dev] [PATCH] i40e:Fix for wrong publish of card speed (was mixed between 10G and 40G) Ido Barnea (ibarnea)
@ 2016-07-18  1:52   ` Wu, Jingjing
  2016-07-18  4:43     ` Ido Barnea (ibarnea)
       [not found]   ` <20160718095433.31383-1-ibarnea@cisco.com>
  1 sibling, 1 reply; 7+ messages in thread
From: Wu, Jingjing @ 2016-07-18  1:52 UTC (permalink / raw)
  To: Ido Barnea (ibarnea), dev

Hi, Barnea

Thanks for the patch. But for 40G link, I think it should be
dev_info->speed_capa = ETH_LINK_SPEED_40G.

Thanks
Jingjing

> -----Original Message-----
> From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Ido Barnea (ibarnea)
> Sent: Sunday, July 17, 2016 11:43 PM
> To: dev@dpdk.org
> Subject: [dpdk-dev] [PATCH] i40e:Fix for wrong publish of card speed (was
> mixed between 10G and 40G)
> 
> Signed-off-by: Ido Barnea <ibarnea@cisco.com>
> 
> 
> ---
>  drivers/net/i40e/i40e_ethdev.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/net/i40e/i40e_ethdev.c b/drivers/net/i40e/i40e_ethdev.c
> index 3f9f05e..64d60ef 100644
> --- a/drivers/net/i40e/i40e_ethdev.c
> +++ b/drivers/net/i40e/i40e_ethdev.c
> @@ -2628,10 +2628,10 @@ i40e_dev_info_get(struct rte_eth_dev *dev,
> struct rte_eth_dev_info *dev_info
> 	if (i40e_is_40G_device(hw->device_id))		/* For XL710
> */
> 
> -		dev_info->speed_capa = ETH_LINK_SPEED_1G |
> ETH_LINK_SPEED_10G;
> +		dev_info->speed_capa = ETH_LINK_SPEED_10G |
> ETH_LINK_SPEED_40G;
>  	else
>  		/* For X710 */
> -		dev_info->speed_capa = ETH_LINK_SPEED_10G |
> ETH_LINK_SPEED_40G;
> +		dev_info->speed_capa = ETH_LINK_SPEED_1G |
> ETH_LINK_SPEED_10G;
>  }
> static int
> --
> 2.8.3

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [dpdk-dev] [PATCH] i40e:Fix for wrong publish of card speed (was mixed between 10G and 40G)
  2016-07-18  1:52   ` Wu, Jingjing
@ 2016-07-18  4:43     ` Ido Barnea (ibarnea)
  2016-07-18  5:09       ` Wu, Jingjing
  0 siblings, 1 reply; 7+ messages in thread
From: Ido Barnea (ibarnea) @ 2016-07-18  4:43 UTC (permalink / raw)
  To: Wu, Jingjing, dev

Hi Jingjing,
The existing code was obviously wrong. 
For the XL710 it returned: ETH_LINK_SPEED_1G |ETH_LINK_SPEED_10G
And for the X710: ETH_LINK_SPEED_10G |ETH_LINK_SPEED_40G


I did a minimal fix, and swapped the lines.

Any fix that will return the correct values is welcome.
For my purpose your proposal is fine.

You want me to change my patch, or you will do it?

Thanks,
Ido



On 18/07/2016, 4:52 AM, "Wu, Jingjing" <jingjing.wu@intel.com> wrote:

>Hi, Barnea
>
>Thanks for the patch. But for 40G link, I think it should be
>dev_info->speed_capa = ETH_LINK_SPEED_40G.
>
>Thanks
>Jingjing
>
>> -----Original Message-----
>> From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Ido Barnea (ibarnea)
>> Sent: Sunday, July 17, 2016 11:43 PM
>> To: dev@dpdk.org
>> Subject: [dpdk-dev] [PATCH] i40e:Fix for wrong publish of card speed (was
>> mixed between 10G and 40G)
>> 
>> Signed-off-by: Ido Barnea <ibarnea@cisco.com>
>> 
>> 
>> ---
>>  drivers/net/i40e/i40e_ethdev.c | 4 ++--
>>  1 file changed, 2 insertions(+), 2 deletions(-)
>> 
>> diff --git a/drivers/net/i40e/i40e_ethdev.c b/drivers/net/i40e/i40e_ethdev.c
>> index 3f9f05e..64d60ef 100644
>> --- a/drivers/net/i40e/i40e_ethdev.c
>> +++ b/drivers/net/i40e/i40e_ethdev.c
>> @@ -2628,10 +2628,10 @@ i40e_dev_info_get(struct rte_eth_dev *dev,
>> struct rte_eth_dev_info *dev_info
>> 	if (i40e_is_40G_device(hw->device_id))		/* For XL710
>> */
>> 
>> -		dev_info->speed_capa = ETH_LINK_SPEED_1G |
>> ETH_LINK_SPEED_10G;
>> +		dev_info->speed_capa = ETH_LINK_SPEED_10G |
>> ETH_LINK_SPEED_40G;
>>  	else
>>  		/* For X710 */
>> -		dev_info->speed_capa = ETH_LINK_SPEED_10G |
>> ETH_LINK_SPEED_40G;
>> +		dev_info->speed_capa = ETH_LINK_SPEED_1G |
>> ETH_LINK_SPEED_10G;
>>  }
>> static int
>> --
>> 2.8.3

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [dpdk-dev] [PATCH] i40e:Fix for wrong publish of card speed (was mixed between 10G and 40G)
  2016-07-18  4:43     ` Ido Barnea (ibarnea)
@ 2016-07-18  5:09       ` Wu, Jingjing
  0 siblings, 0 replies; 7+ messages in thread
From: Wu, Jingjing @ 2016-07-18  5:09 UTC (permalink / raw)
  To: Ido Barnea (ibarnea), dev

Hi, Ido

Got your opinion. If you can also fix the 40G, it will be better. You can just send a v2 patch, and I can ack it. Or I can also send the v2 patch for you.

Thanks
Jingjing

> -----Original Message-----
> From: Ido Barnea (ibarnea) [mailto:ibarnea@cisco.com]
> Sent: Monday, July 18, 2016 12:43 PM
> To: Wu, Jingjing; dev@dpdk.org
> Subject: Re: [PATCH] i40e:Fix for wrong publish of card speed (was mixed
> between 10G and 40G)
> 
> Hi Jingjing,
> The existing code was obviously wrong.
> For the XL710 it returned: ETH_LINK_SPEED_1G |ETH_LINK_SPEED_10G And
> for the X710: ETH_LINK_SPEED_10G |ETH_LINK_SPEED_40G
> 
> 
> I did a minimal fix, and swapped the lines.
> 
> Any fix that will return the correct values is welcome.
> For my purpose your proposal is fine.
> 
> You want me to change my patch, or you will do it?
> 
> Thanks,
> Ido
> 
> 
> 
> On 18/07/2016, 4:52 AM, "Wu, Jingjing" <jingjing.wu@intel.com> wrote:
> 
> >Hi, Barnea
> >
> >Thanks for the patch. But for 40G link, I think it should be
> >dev_info->speed_capa = ETH_LINK_SPEED_40G.
> >
> >Thanks
> >Jingjing
> >
> >> -----Original Message-----
> >> From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Ido Barnea
> >> (ibarnea)
> >> Sent: Sunday, July 17, 2016 11:43 PM
> >> To: dev@dpdk.org
> >> Subject: [dpdk-dev] [PATCH] i40e:Fix for wrong publish of card speed
> >> (was mixed between 10G and 40G)
> >>
> >> Signed-off-by: Ido Barnea <ibarnea@cisco.com>
> >>
> >>
> >> ---
> >>  drivers/net/i40e/i40e_ethdev.c | 4 ++--
> >>  1 file changed, 2 insertions(+), 2 deletions(-)
> >>
> >> diff --git a/drivers/net/i40e/i40e_ethdev.c
> >> b/drivers/net/i40e/i40e_ethdev.c index 3f9f05e..64d60ef 100644
> >> --- a/drivers/net/i40e/i40e_ethdev.c
> >> +++ b/drivers/net/i40e/i40e_ethdev.c
> >> @@ -2628,10 +2628,10 @@ i40e_dev_info_get(struct rte_eth_dev *dev,
> >> struct rte_eth_dev_info *dev_info
> >> 	if (i40e_is_40G_device(hw->device_id))		/* For XL710
> >> */
> >>
> >> -		dev_info->speed_capa = ETH_LINK_SPEED_1G |
> >> ETH_LINK_SPEED_10G;
> >> +		dev_info->speed_capa = ETH_LINK_SPEED_10G |
> >> ETH_LINK_SPEED_40G;
> >>  	else
> >>  		/* For X710 */
> >> -		dev_info->speed_capa = ETH_LINK_SPEED_10G |
> >> ETH_LINK_SPEED_40G;
> >> +		dev_info->speed_capa = ETH_LINK_SPEED_1G |
> >> ETH_LINK_SPEED_10G;
> >>  }
> >> static int
> >> --
> >> 2.8.3

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [dpdk-dev] [PATCH v2] i40e:Fix for wrong publish of card speed (was mixed between 10G and 40G)
       [not found]   ` <20160718095433.31383-1-ibarnea@cisco.com>
@ 2016-07-18  9:56     ` Ido Barnea (ibarnea)
  2016-07-20  1:01       ` Wu, Jingjing
  2016-07-21 23:27       ` Thomas Monjalon
  0 siblings, 2 replies; 7+ messages in thread
From: Ido Barnea (ibarnea) @ 2016-07-18  9:56 UTC (permalink / raw)
  To: dev; +Cc: Wu, Jingjing

Signed-off-by: Ido Barnea <ibarnea@cisco.com>


---
 drivers/net/i40e/i40e_ethdev.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/i40e/i40e_ethdev.c b/drivers/net/i40e/i40e_ethdev.c
index 3f9f05e..84c86aa 100644
--- a/drivers/net/i40e/i40e_ethdev.c
+++ b/drivers/net/i40e/i40e_ethdev.c
@@ -2628,10 +2628,10 @@ i40e_dev_info_get(struct rte_eth_dev *dev, struct rte_eth_dev_info *dev_info)
	if (i40e_is_40G_device(hw->device_id))
 		/* For XL710 */
-		dev_info->speed_capa = ETH_LINK_SPEED_1G | ETH_LINK_SPEED_10G;
+		dev_info->speed_capa = ETH_LINK_SPEED_40G;
 	else
 		/* For X710 */
-		dev_info->speed_capa = ETH_LINK_SPEED_10G | ETH_LINK_SPEED_40G;
+		dev_info->speed_capa = ETH_LINK_SPEED_1G | ETH_LINK_SPEED_10G;
 }
static int
-- 
2.8.3



^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [dpdk-dev] [PATCH v2] i40e:Fix for wrong publish of card speed (was mixed between 10G and 40G)
  2016-07-18  9:56     ` [dpdk-dev] [PATCH v2] " Ido Barnea (ibarnea)
@ 2016-07-20  1:01       ` Wu, Jingjing
  2016-07-21 23:27       ` Thomas Monjalon
  1 sibling, 0 replies; 7+ messages in thread
From: Wu, Jingjing @ 2016-07-20  1:01 UTC (permalink / raw)
  To: Ido Barnea (ibarnea), dev



> -----Original Message-----
> From: Ido Barnea (ibarnea) [mailto:ibarnea@cisco.com]
> Sent: Monday, July 18, 2016 5:57 PM
> To: dev@dpdk.org
> Cc: Wu, Jingjing
> Subject: [PATCH v2] i40e:Fix for wrong publish of card speed (was mixed
> between 10G and 40G)
> 
> Signed-off-by: Ido Barnea <ibarnea@cisco.com>
> 
Acked-by: Jingjing Wu <jingjing.wu@intel.com>

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [dpdk-dev] [PATCH v2] i40e:Fix for wrong publish of card speed (was mixed between 10G and 40G)
  2016-07-18  9:56     ` [dpdk-dev] [PATCH v2] " Ido Barnea (ibarnea)
  2016-07-20  1:01       ` Wu, Jingjing
@ 2016-07-21 23:27       ` Thomas Monjalon
  1 sibling, 0 replies; 7+ messages in thread
From: Thomas Monjalon @ 2016-07-21 23:27 UTC (permalink / raw)
  To: Ido Barnea (ibarnea); +Cc: dev, Wu, Jingjing

2016-07-18 09:56, Ido Barnea:
> Signed-off-by: Ido Barnea <ibarnea@cisco.com>

Patch reconstructed (format was not applicable),
and applied, thanks

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2016-07-21 23:27 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <20160717153404.12790-1-ibarnea@cisco.com>
2016-07-17 15:43 ` [dpdk-dev] [PATCH] i40e:Fix for wrong publish of card speed (was mixed between 10G and 40G) Ido Barnea (ibarnea)
2016-07-18  1:52   ` Wu, Jingjing
2016-07-18  4:43     ` Ido Barnea (ibarnea)
2016-07-18  5:09       ` Wu, Jingjing
     [not found]   ` <20160718095433.31383-1-ibarnea@cisco.com>
2016-07-18  9:56     ` [dpdk-dev] [PATCH v2] " Ido Barnea (ibarnea)
2016-07-20  1:01       ` Wu, Jingjing
2016-07-21 23:27       ` Thomas Monjalon

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).