netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* vmxnet3 driver broken since 3.0?
@ 2011-12-04  9:15 Alessandro Salvatori
  2011-12-11 22:38 ` Zbigniew Luszpinski
  0 siblings, 1 reply; 5+ messages in thread
From: Alessandro Salvatori @ 2011-12-04  9:15 UTC (permalink / raw)
  To: netdev

Under both 3.1.3 and 3.0.8, I am seeing the following when I modprobe
vmxnet3 build within the respective kernel tree:

[77314.335684] VMware vmxnet3 virtual NIC driver - version 1.1.18.0-k-NAPI
[77314.335742] alloc_netdev: Unable to allocate device with zero queues.
[77314.335744] # of Tx queues : 0, # of Rx queues : 0
[77314.335745] Failed to alloc ethernet device for adapter 0000:0b:00.0
[77314.335748] vmxnet3: probe of 0000:0b:00.0 failed with error -12

with 2.6.39.4 the module comes up fine and works fine.

haven't had a chance to try the one from the 3.2 release candidates yet.

thanks in advance!
-Alessandro-
 Here i am, A young man,
 A crashing computer program,
 Here is a pen, write out my name...

(from: The Servant - Orchestra)

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

* Re: vmxnet3 driver broken since 3.0?
  2011-12-04  9:15 vmxnet3 driver broken since 3.0? Alessandro Salvatori
@ 2011-12-11 22:38 ` Zbigniew Luszpinski
  2011-12-12  7:54   ` Alessandro Salvatori
  0 siblings, 1 reply; 5+ messages in thread
From: Zbigniew Luszpinski @ 2011-12-11 22:38 UTC (permalink / raw)
  To: netdev

Alessandro Salvatori <sandr8 <at> gmail.com> writes:
> haven't had a chance to try the one from the 3.2 release candidates yet.

In 3.2-rc5 is still broken. Exactly the same error you get. :(
Someone introduced a change since kernel 3.0 which broke vmxnet3 driver. And
this breaking change continues in kernel 3.1 and 3.2-rc5 so it seems it will not
go away. :(

have a nice day,
Zbigniew Luszpinski

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

* Re: vmxnet3 driver broken since 3.0?
  2011-12-11 22:38 ` Zbigniew Luszpinski
@ 2011-12-12  7:54   ` Alessandro Salvatori
  2011-12-12 17:05     ` Stephen Hemminger
  0 siblings, 1 reply; 5+ messages in thread
From: Alessandro Salvatori @ 2011-12-12  7:54 UTC (permalink / raw)
  To: Zbigniew Luszpinski; +Cc: netdev

I guess this is the change that was introduced in 3.0 and that breaks vmxnet3:

commit 55513fb4281464e97aa1ff2b9c906ca5aed917c5
Author: Tom Herbert <therbert@google.com>
Date:   Mon Oct 18 17:55:58 2010 +0000

    net: fail alloc_netdev_mq if queue count < 1

    In alloc_netdev_mq fail if requested queue_count < 1.

    Signed-off-by: Tom Herbert <therbert@google.com>
    Acked-by: Eric Dumazet <eric.dumazet@gmail.com>
    Signed-off-by: David S. Miller <davem@davemloft.net>

diff --git a/net/core/dev.c b/net/core/dev.c
index 04972a4..f44d29a 100644
--- a/net/core/dev.c
+++ b/net/core/dev.c
@@ -5511,6 +5511,12 @@ struct net_device *alloc_netdev_mq(int
sizeof_priv, const char *name,

        BUG_ON(strlen(name) >= sizeof(dev->name));

+       if (queue_count < 1) {
+               pr_err("alloc_netdev: Unable to allocate device "
+                      "with zero queues.\n");
+               return NULL;
+       }
+
        alloc_size = sizeof(struct net_device);
        if (sizeof_priv) {
                /* ensure 32-byte alignment of private area */

thanks!
-Alessandro-
 Here i am, A young man,
 A crashing computer program,
 Here is a pen, write out my name...

(from: The Servant - Orchestra)



On Sun, Dec 11, 2011 at 14:38, Zbigniew Luszpinski <zbiggy@o2.pl> wrote:
> Alessandro Salvatori <sandr8 <at> gmail.com> writes:
>> haven't had a chance to try the one from the 3.2 release candidates yet.
>
> In 3.2-rc5 is still broken. Exactly the same error you get. :(
> Someone introduced a change since kernel 3.0 which broke vmxnet3 driver. And
> this breaking change continues in kernel 3.1 and 3.2-rc5 so it seems it will not
> go away. :(
>
> have a nice day,
> Zbigniew Luszpinski
>
> --
> To unsubscribe from this list: send the line "unsubscribe netdev" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* Re: vmxnet3 driver broken since 3.0?
  2011-12-12  7:54   ` Alessandro Salvatori
@ 2011-12-12 17:05     ` Stephen Hemminger
  0 siblings, 0 replies; 5+ messages in thread
From: Stephen Hemminger @ 2011-12-12 17:05 UTC (permalink / raw)
  To: sandr8; +Cc: Zbigniew Luszpinski, netdev

On Sun, 11 Dec 2011 23:54:50 -0800
Alessandro Salvatori <sandr8@gmail.com> wrote:

> I guess this is the change that was introduced in 3.0 and that breaks vmxnet3:
> 
> commit 55513fb4281464e97aa1ff2b9c906ca5aed917c5
> Author: Tom Herbert <therbert@google.com>
> Date:   Mon Oct 18 17:55:58 2010 +0000
> 
>     net: fail alloc_netdev_mq if queue count < 1
> 
>     In alloc_netdev_mq fail if requested queue_count < 1.
> 
>     Signed-off-by: Tom Herbert <therbert@google.com>
>     Acked-by: Eric Dumazet <eric.dumazet@gmail.com>
>     Signed-off-by: David S. Miller <davem@davemloft.net>
> 
> diff --git a/net/core/dev.c b/net/core/dev.c
> index 04972a4..f44d29a 100644
> --- a/net/core/dev.c
> +++ b/net/core/dev.c
> @@ -5511,6 +5511,12 @@ struct net_device *alloc_netdev_mq(int
> sizeof_priv, const char *name,
> 
>         BUG_ON(strlen(name) >= sizeof(dev->name));
> 
> +       if (queue_count < 1) {
> +               pr_err("alloc_netdev: Unable to allocate device "
> +                      "with zero queues.\n");
> +               return NULL;
> +       }
> +
>         alloc_size = sizeof(struct net_device);
>         if (sizeof_priv) {
>                 /* ensure 32-byte alignment of private area */

Looks like the problem is not in networking core but either in the logic
that computes number of queues.

By default it computes number of queues based on number of cpus.

	num_rx_queues = min(VMXNET3_DEVICE_MAX_RX_QUEUES,
				    (int)num_online_cpus());
	
	num_rx_queues = rounddown_pow_of_two(num_rx_queues);

I suspect something is wrong in the cpu management if it reports
num_online_cpus == 0.

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

* Re: vmxnet3 driver broken since 3.0?
       [not found] <D3F292ADF945FB49B35E96C94C2061B9150914BA@nsmail.netscout.com>
@ 2011-12-12 17:09 ` chetan loke
  0 siblings, 0 replies; 5+ messages in thread
From: chetan loke @ 2011-12-12 17:09 UTC (permalink / raw)
  To: pv-drivers, sandr8, zbiggy, netdev

> From: netdev-owner@vger.kernel.org [mailto:netdev-owner@vger.kernel.org] On Behalf Of Alessandro Salvatori
> Sent: December 12, 2011 2:55 AM
> To: Zbigniew Luszpinski
> Cc: netdev@vger.kernel.org
> Subject: Re: vmxnet3 driver broken since 3.0?
>
> I guess this is the change that was introduced in 3.0 and that breaks vmxnet3:
>
> commit 55513fb4281464e97aa1ff2b9c906ca5aed917c5
> Author: Tom Herbert <therbert@google.com>
> Date:   Mon Oct 18 17:55:58 2010 +0000
>
>    net: fail alloc_netdev_mq if queue count < 1
>
>    In alloc_netdev_mq fail if requested queue_count < 1.
>
>    Signed-off-by: Tom Herbert <therbert@google.com>
>    Acked-by: Eric Dumazet <eric.dumazet@gmail.com>
>    Signed-off-by: David S. Miller <davem@davemloft.net>
>
> diff --git a/net/core/dev.c b/net/core/dev.c
> index 04972a4..f44d29a 100644
> --- a/net/core/dev.c
> +++ b/net/core/dev.c
> @@ -5511,6 +5511,12 @@ struct net_device *alloc_netdev_mq(int
> sizeof_priv, const char *name,
>
>        BUG_ON(strlen(name) >= sizeof(dev->name));
>
> +       if (queue_count < 1) {
> +               pr_err("alloc_netdev: Unable to allocate device "
> +                      "with zero queues.\n");
> +               return NULL;
> +       }
> +
>        alloc_size = sizeof(struct net_device);
>        if (sizeof_priv) {
>                /* ensure 32-byte alignment of private area */
>
> thanks!
> -Alessandro-


CC'd VMware.

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

end of thread, other threads:[~2011-12-12 17:09 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-12-04  9:15 vmxnet3 driver broken since 3.0? Alessandro Salvatori
2011-12-11 22:38 ` Zbigniew Luszpinski
2011-12-12  7:54   ` Alessandro Salvatori
2011-12-12 17:05     ` Stephen Hemminger
     [not found] <D3F292ADF945FB49B35E96C94C2061B9150914BA@nsmail.netscout.com>
2011-12-12 17:09 ` chetan loke

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).