* set route
From: Jean-Jacques Sarton @ 2012-04-03 5:47 UTC (permalink / raw)
To: netdev
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Hello,
I think there is a little bug within the portion of code
for setting the network routing.
If I issue the following
ip li se dev x down; ip li se dev x up;\
ip ad ad 2001:db8:1:1::2/64 dev X;\
ip ro ad 2001:db8:1:1::/64 via 2001:db8:1:1::2 dev X
All id OK. If I insert a sleep 2 between set addr
and set route, I will get the error message:
RTNETLINK answers: No route to host
This seem, for me to be a BUG. The address is known
and therefore there is a route.
If the addresse for the gateway is outside, this
may make sense, but for a static route I expect
that the route is set regardless of the knowledge
of the addresse.
Do you have an explanation for the problem and if
this is a bug, will it be fixed ?
Regards,
Jean-Jacques Sarton
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)
iEYEARECAAYFAk96jvkACgkQM9JbiR3CwQskpACeMj0S6q5IYD9FhwGLOZZjWeKr
A3sAn1s99YK7aacxQ+Eiqb9MI4CaWDs+
=yLUY
-----END PGP SIGNATURE-----
^ permalink raw reply
* Re: /proc/net/dev is funky in 3.3.0
From: Ben Greear @ 2012-04-03 5:53 UTC (permalink / raw)
To: Eric Dumazet; +Cc: NetDev
In-Reply-To: <1333431810.18626.37.camel@edumazet-glaptop>
On 04/02/2012 10:43 PM, Eric Dumazet wrote:
> On Mon, 2012-04-02 at 21:29 -0700, Ben Greear wrote:
>> Not all entries are shown!
>>
>> [root@lanner-i7 lanforge]# cat /proc/net/dev|grep sta59
>> [root@lanner-i7 lanforge]# ifconfig sta59
>> sta59 Link encap:Ethernet HWaddr 00:95:95:00:00:3C
>> inet addr:10.111.9.39 Bcast:10.111.255.255 Mask:255.255.0.0
>> inet6 addr: fe80::295:95ff:fe00:3c/64 Scope:Link
>> UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
>> RX packets:58103 errors:0 dropped:0 overruns:0 frame:0
>> TX packets:26167 errors:0 dropped:0 overruns:0 carrier:0
>> collisions:0 txqueuelen:1000
>> RX bytes:39494634 (37.6 MiB) TX bytes:37095540 (35.3 MiB)
>>
>> Thanks,
>> Ben
>>
>
> Could you post "ip link" result ?
>
It is below. Looks like /proc/net/dev is missing 6 entries,
sta69 being one of them. See end of the email for some grep
and |wc results. Seems easily reproducible, so let me know if
you want more info.
[root@lanner-i7 lanforge]# ip link show dev sta59
466: sta59: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:3c brd ff:ff:ff:ff:ff:ff
[root@lanner-i7 lanforge]# ip link
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 16436 qdisc noqueue state UNKNOWN
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
2: p4p1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP qlen 1000
link/ether 00:90:0b:21:9f:5c brd ff:ff:ff:ff:ff:ff
4: p1p1: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc pfifo_fast state DOWN qlen 1000
link/ether 00:90:0b:21:9f:5d brd ff:ff:ff:ff:ff:ff
797: sta75: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:4c brd ff:ff:ff:ff:ff:ff
800: sta349: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:32 brd ff:ff:ff:ff:ff:ff
802: sta61: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:3e brd ff:ff:ff:ff:ff:ff
804: sta49: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:32 brd ff:ff:ff:ff:ff:ff
807: sta342: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:2b brd ff:ff:ff:ff:ff:ff
553: sta149: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:10:00:32 brd ff:ff:ff:ff:ff:ff
602: sta300: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:01 brd ff:ff:ff:ff:ff:ff
603: sta301: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:02 brd ff:ff:ff:ff:ff:ff
604: sta302: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:03 brd ff:ff:ff:ff:ff:ff
605: sta303: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:04 brd ff:ff:ff:ff:ff:ff
606: sta304: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:05 brd ff:ff:ff:ff:ff:ff
607: sta305: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:06 brd ff:ff:ff:ff:ff:ff
608: sta306: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:07 brd ff:ff:ff:ff:ff:ff
609: sta307: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:08 brd ff:ff:ff:ff:ff:ff
610: sta308: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:09 brd ff:ff:ff:ff:ff:ff
611: sta309: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:0a brd ff:ff:ff:ff:ff:ff
612: sta310: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:0b brd ff:ff:ff:ff:ff:ff
613: sta311: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:0c brd ff:ff:ff:ff:ff:ff
614: sta312: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:0d brd ff:ff:ff:ff:ff:ff
615: sta313: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:0e brd ff:ff:ff:ff:ff:ff
616: sta314: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:0f brd ff:ff:ff:ff:ff:ff
617: sta315: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:10 brd ff:ff:ff:ff:ff:ff
618: sta316: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:11 brd ff:ff:ff:ff:ff:ff
619: sta317: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:12 brd ff:ff:ff:ff:ff:ff
620: sta318: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:13 brd ff:ff:ff:ff:ff:ff
621: sta319: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:14 brd ff:ff:ff:ff:ff:ff
622: sta320: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:15 brd ff:ff:ff:ff:ff:ff
623: sta321: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:16 brd ff:ff:ff:ff:ff:ff
624: sta322: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:17 brd ff:ff:ff:ff:ff:ff
625: sta323: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:18 brd ff:ff:ff:ff:ff:ff
626: sta324: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:19 brd ff:ff:ff:ff:ff:ff
627: sta325: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:1a brd ff:ff:ff:ff:ff:ff
628: sta326: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:1b brd ff:ff:ff:ff:ff:ff
629: sta327: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:1c brd ff:ff:ff:ff:ff:ff
630: sta328: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:1d brd ff:ff:ff:ff:ff:ff
631: sta329: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:1e brd ff:ff:ff:ff:ff:ff
632: sta330: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:1f brd ff:ff:ff:ff:ff:ff
633: sta331: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:20 brd ff:ff:ff:ff:ff:ff
634: sta332: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:21 brd ff:ff:ff:ff:ff:ff
635: sta333: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:22 brd ff:ff:ff:ff:ff:ff
636: sta334: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:23 brd ff:ff:ff:ff:ff:ff
637: sta335: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:24 brd ff:ff:ff:ff:ff:ff
638: sta336: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:25 brd ff:ff:ff:ff:ff:ff
639: sta337: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:26 brd ff:ff:ff:ff:ff:ff
640: sta338: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:27 brd ff:ff:ff:ff:ff:ff
641: sta339: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:28 brd ff:ff:ff:ff:ff:ff
642: sta340: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:29 brd ff:ff:ff:ff:ff:ff
643: sta341: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:2a brd ff:ff:ff:ff:ff:ff
644: sta343: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:2c brd ff:ff:ff:ff:ff:ff
645: sta344: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:2d brd ff:ff:ff:ff:ff:ff
646: sta345: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:2e brd ff:ff:ff:ff:ff:ff
647: sta346: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:2f brd ff:ff:ff:ff:ff:ff
648: sta347: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:30 brd ff:ff:ff:ff:ff:ff
649: sta348: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:31 brd ff:ff:ff:ff:ff:ff
650: sta350: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:33 brd ff:ff:ff:ff:ff:ff
651: sta351: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:34 brd ff:ff:ff:ff:ff:ff
652: sta352: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:35 brd ff:ff:ff:ff:ff:ff
653: sta353: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:36 brd ff:ff:ff:ff:ff:ff
654: sta354: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:37 brd ff:ff:ff:ff:ff:ff
655: sta355: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:38 brd ff:ff:ff:ff:ff:ff
656: sta356: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:39 brd ff:ff:ff:ff:ff:ff
657: sta357: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:3a brd ff:ff:ff:ff:ff:ff
658: sta358: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:3b brd ff:ff:ff:ff:ff:ff
659: sta359: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:3c brd ff:ff:ff:ff:ff:ff
660: sta360: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:3d brd ff:ff:ff:ff:ff:ff
661: sta361: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:3e brd ff:ff:ff:ff:ff:ff
662: sta362: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:3f brd ff:ff:ff:ff:ff:ff
406: wlan0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:0e:8e:3d:30:e8 brd ff:ff:ff:ff:ff:ff
663: sta363: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:40 brd ff:ff:ff:ff:ff:ff
407: wlan1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:0e:8e:3d:30:f8 brd ff:ff:ff:ff:ff:ff
664: sta364: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:41 brd ff:ff:ff:ff:ff:ff
408: sta0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:01 brd ff:ff:ff:ff:ff:ff
665: sta365: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:42 brd ff:ff:ff:ff:ff:ff
409: sta1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:02 brd ff:ff:ff:ff:ff:ff
666: sta366: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:43 brd ff:ff:ff:ff:ff:ff
410: sta2: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:03 brd ff:ff:ff:ff:ff:ff
667: sta367: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:44 brd ff:ff:ff:ff:ff:ff
411: sta3: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:04 brd ff:ff:ff:ff:ff:ff
668: sta368: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:45 brd ff:ff:ff:ff:ff:ff
412: sta4: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:05 brd ff:ff:ff:ff:ff:ff
669: sta369: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:46 brd ff:ff:ff:ff:ff:ff
413: sta5: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:06 brd ff:ff:ff:ff:ff:ff
670: sta370: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:47 brd ff:ff:ff:ff:ff:ff
414: sta6: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:07 brd ff:ff:ff:ff:ff:ff
671: sta371: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:48 brd ff:ff:ff:ff:ff:ff
415: sta7: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:08 brd ff:ff:ff:ff:ff:ff
672: sta372: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:49 brd ff:ff:ff:ff:ff:ff
416: sta8: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:09 brd ff:ff:ff:ff:ff:ff
673: sta373: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:4a brd ff:ff:ff:ff:ff:ff
417: sta9: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:0a brd ff:ff:ff:ff:ff:ff
674: sta374: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:4b brd ff:ff:ff:ff:ff:ff
418: sta10: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:0b brd ff:ff:ff:ff:ff:ff
675: sta375: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:4c brd ff:ff:ff:ff:ff:ff
419: sta11: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:0c brd ff:ff:ff:ff:ff:ff
676: sta376: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:4d brd ff:ff:ff:ff:ff:ff
420: sta12: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:0d brd ff:ff:ff:ff:ff:ff
677: sta377: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:4e brd ff:ff:ff:ff:ff:ff
421: sta13: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:0e brd ff:ff:ff:ff:ff:ff
678: sta378: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:4f brd ff:ff:ff:ff:ff:ff
422: sta14: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:0f brd ff:ff:ff:ff:ff:ff
679: sta379: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:50 brd ff:ff:ff:ff:ff:ff
423: sta15: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:10 brd ff:ff:ff:ff:ff:ff
680: sta380: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:51 brd ff:ff:ff:ff:ff:ff
424: sta16: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:11 brd ff:ff:ff:ff:ff:ff
681: sta381: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:52 brd ff:ff:ff:ff:ff:ff
425: sta17: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:12 brd ff:ff:ff:ff:ff:ff
682: sta382: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:53 brd ff:ff:ff:ff:ff:ff
426: sta18: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:13 brd ff:ff:ff:ff:ff:ff
683: sta383: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:54 brd ff:ff:ff:ff:ff:ff
427: sta19: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:14 brd ff:ff:ff:ff:ff:ff
684: sta384: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:55 brd ff:ff:ff:ff:ff:ff
428: sta20: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:15 brd ff:ff:ff:ff:ff:ff
685: sta385: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:56 brd ff:ff:ff:ff:ff:ff
429: sta21: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:16 brd ff:ff:ff:ff:ff:ff
686: sta386: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:57 brd ff:ff:ff:ff:ff:ff
430: sta22: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:17 brd ff:ff:ff:ff:ff:ff
687: sta387: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:58 brd ff:ff:ff:ff:ff:ff
431: sta23: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:18 brd ff:ff:ff:ff:ff:ff
688: sta388: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:59 brd ff:ff:ff:ff:ff:ff
432: sta24: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:19 brd ff:ff:ff:ff:ff:ff
689: sta389: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:5a brd ff:ff:ff:ff:ff:ff
433: sta25: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:1a brd ff:ff:ff:ff:ff:ff
690: sta390: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:5b brd ff:ff:ff:ff:ff:ff
434: sta26: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:1b brd ff:ff:ff:ff:ff:ff
691: sta391: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:5c brd ff:ff:ff:ff:ff:ff
435: sta27: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:1c brd ff:ff:ff:ff:ff:ff
692: sta392: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:5d brd ff:ff:ff:ff:ff:ff
436: sta28: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:1d brd ff:ff:ff:ff:ff:ff
693: sta393: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:5e brd ff:ff:ff:ff:ff:ff
437: sta29: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:1e brd ff:ff:ff:ff:ff:ff
694: sta394: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:5f brd ff:ff:ff:ff:ff:ff
438: sta30: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:1f brd ff:ff:ff:ff:ff:ff
695: sta395: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:60 brd ff:ff:ff:ff:ff:ff
439: sta31: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:20 brd ff:ff:ff:ff:ff:ff
696: sta396: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:61 brd ff:ff:ff:ff:ff:ff
440: sta32: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:21 brd ff:ff:ff:ff:ff:ff
697: sta397: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:62 brd ff:ff:ff:ff:ff:ff
441: sta33: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:22 brd ff:ff:ff:ff:ff:ff
698: sta398: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:63 brd ff:ff:ff:ff:ff:ff
442: sta34: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:23 brd ff:ff:ff:ff:ff:ff
699: sta399: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:30:00:64 brd ff:ff:ff:ff:ff:ff
443: sta35: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:24 brd ff:ff:ff:ff:ff:ff
444: sta36: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:25 brd ff:ff:ff:ff:ff:ff
445: sta37: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:26 brd ff:ff:ff:ff:ff:ff
446: sta38: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:27 brd ff:ff:ff:ff:ff:ff
447: sta39: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:28 brd ff:ff:ff:ff:ff:ff
448: sta40: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:29 brd ff:ff:ff:ff:ff:ff
449: sta41: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:2a brd ff:ff:ff:ff:ff:ff
450: sta42: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:2b brd ff:ff:ff:ff:ff:ff
451: sta43: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:2c brd ff:ff:ff:ff:ff:ff
452: sta44: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:2d brd ff:ff:ff:ff:ff:ff
453: sta45: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:2e brd ff:ff:ff:ff:ff:ff
454: sta46: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:2f brd ff:ff:ff:ff:ff:ff
455: sta47: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:30 brd ff:ff:ff:ff:ff:ff
456: sta48: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:31 brd ff:ff:ff:ff:ff:ff
457: sta50: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:33 brd ff:ff:ff:ff:ff:ff
458: sta51: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:34 brd ff:ff:ff:ff:ff:ff
459: sta52: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:35 brd ff:ff:ff:ff:ff:ff
460: sta53: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:36 brd ff:ff:ff:ff:ff:ff
461: sta54: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:37 brd ff:ff:ff:ff:ff:ff
462: sta55: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:38 brd ff:ff:ff:ff:ff:ff
463: sta56: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:39 brd ff:ff:ff:ff:ff:ff
464: sta57: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:3a brd ff:ff:ff:ff:ff:ff
465: sta58: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:3b brd ff:ff:ff:ff:ff:ff
466: sta59: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:3c brd ff:ff:ff:ff:ff:ff
467: sta60: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:3d brd ff:ff:ff:ff:ff:ff
468: sta62: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:3f brd ff:ff:ff:ff:ff:ff
469: sta63: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:40 brd ff:ff:ff:ff:ff:ff
470: sta64: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:41 brd ff:ff:ff:ff:ff:ff
471: sta65: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:42 brd ff:ff:ff:ff:ff:ff
472: sta66: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:43 brd ff:ff:ff:ff:ff:ff
473: sta67: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:44 brd ff:ff:ff:ff:ff:ff
474: sta68: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:45 brd ff:ff:ff:ff:ff:ff
475: sta69: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:46 brd ff:ff:ff:ff:ff:ff
476: sta70: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:47 brd ff:ff:ff:ff:ff:ff
477: sta71: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:48 brd ff:ff:ff:ff:ff:ff
478: sta72: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:49 brd ff:ff:ff:ff:ff:ff
479: sta73: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:4a brd ff:ff:ff:ff:ff:ff
480: sta74: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:4b brd ff:ff:ff:ff:ff:ff
481: sta76: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:4d brd ff:ff:ff:ff:ff:ff
482: sta77: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:4e brd ff:ff:ff:ff:ff:ff
483: sta78: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:4f brd ff:ff:ff:ff:ff:ff
484: sta79: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:50 brd ff:ff:ff:ff:ff:ff
485: sta80: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:51 brd ff:ff:ff:ff:ff:ff
486: sta81: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:52 brd ff:ff:ff:ff:ff:ff
487: sta82: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:53 brd ff:ff:ff:ff:ff:ff
488: sta83: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:54 brd ff:ff:ff:ff:ff:ff
489: sta84: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:55 brd ff:ff:ff:ff:ff:ff
490: sta85: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:56 brd ff:ff:ff:ff:ff:ff
491: sta86: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:57 brd ff:ff:ff:ff:ff:ff
492: sta87: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:58 brd ff:ff:ff:ff:ff:ff
493: sta88: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:59 brd ff:ff:ff:ff:ff:ff
494: sta89: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:5a brd ff:ff:ff:ff:ff:ff
495: sta90: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:5b brd ff:ff:ff:ff:ff:ff
496: sta91: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:5c brd ff:ff:ff:ff:ff:ff
497: sta92: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:5d brd ff:ff:ff:ff:ff:ff
498: sta93: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:5e brd ff:ff:ff:ff:ff:ff
499: sta94: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:5f brd ff:ff:ff:ff:ff:ff
500: sta95: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:60 brd ff:ff:ff:ff:ff:ff
501: sta96: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:61 brd ff:ff:ff:ff:ff:ff
502: sta97: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:62 brd ff:ff:ff:ff:ff:ff
503: sta98: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:63 brd ff:ff:ff:ff:ff:ff
504: sta99: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:95:95:00:00:64 brd ff:ff:ff:ff:ff:ff
[root@lanner-i7 lanforge]# ip link|grep sta59
466: sta59: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
[root@lanner-i7 lanforge]# cat /proc/net/dev|wc
202 3420 24979
[root@lanner-i7 lanforge]# cat /proc/net/dev|grep sta59
[root@lanner-i7 lanforge]# ip link show|grep qdisc|wc
206 2264 17189
Thanks,
Ben
--
Ben Greear <greearb@candelatech.com>
Candela Technologies Inc http://www.candelatech.com
^ permalink raw reply
* Re: [PATCH 2/2] TCP: Use 32768-65535 outgoing port range by default
From: David Miller @ 2012-04-03 6:28 UTC (permalink / raw)
To: fernando; +Cc: shemminger, netdev
In-Reply-To: <20120403141827.sakagdugg04os8w8@webmail.int.intellilink.co.jp>
From: fernando@intellilink.co.jp
Date: Tue, 3 Apr 2012 14:18:27 +0900
> The thing is that certain non-linux hosts already use a superset of
> the 61000-65095 range and 61000 looks like a magic number to most
> users.
Who cares what other systems usage, it's only an issue about local
port allocations and locally performed masquerading.
> Do you want me to document where 61000 comes from instead?
I think the current documentation on this is adequate.
^ permalink raw reply
* Re: [PATCH] phonet: Check input from user before allocating
From: Rémi Denis-Courmont @ 2012-04-03 6:36 UTC (permalink / raw)
To: David Miller; +Cc: levinsasha928, davej, netdev, linux-kernel
In-Reply-To: <20120402.174006.70116829696492189.davem@davemloft.net>
On Mon, 02 Apr 2012 17:40:06 -0400 (EDT), David Miller
<davem@davemloft.net> wrote:
> UDP generates a fragment list of MTU sized SKBs.
>
> Phonet could avoid the large allocations by building page based
> SKBs.
Oh right. And Phonet devices don't support scatter/gather, so that I guess
that would merely delay the problem.
Also sendmsg() code would need to be reectored to look up the output
device and then the MTU before allocating the socket buffer. This will only
work if the default MTU is reduced first :/
--
Rémi Denis-Courmont
Sent from my collocated server
^ permalink raw reply
* Re: /proc/net/dev is funky in 3.3.0
From: Eric Dumazet @ 2012-04-03 6:36 UTC (permalink / raw)
To: Ben Greear; +Cc: NetDev
In-Reply-To: <4F7A905B.3080107@candelatech.com>
On Mon, 2012-04-02 at 22:53 -0700, Ben Greear wrote:
> On 04/02/2012 10:43 PM, Eric Dumazet wrote:
> > On Mon, 2012-04-02 at 21:29 -0700, Ben Greear wrote:
> >> Not all entries are shown!
> >>
> >> [root@lanner-i7 lanforge]# cat /proc/net/dev|grep sta59
> >> [root@lanner-i7 lanforge]# ifconfig sta59
> >> sta59 Link encap:Ethernet HWaddr 00:95:95:00:00:3C
> >> inet addr:10.111.9.39 Bcast:10.111.255.255 Mask:255.255.0.0
> >> inet6 addr: fe80::295:95ff:fe00:3c/64 Scope:Link
> >> UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
> >> RX packets:58103 errors:0 dropped:0 overruns:0 frame:0
> >> TX packets:26167 errors:0 dropped:0 overruns:0 carrier:0
> >> collisions:0 txqueuelen:1000
> >> RX bytes:39494634 (37.6 MiB) TX bytes:37095540 (35.3 MiB)
> >>
> >> Thanks,
> >> Ben
> >>
> >
> > Could you post "ip link" result ?
> >
>
> It is below. Looks like /proc/net/dev is missing 6 entries,
> sta69 being one of them. See end of the email for some grep
> and |wc results. Seems easily reproducible, so let me know if
> you want more info.
Hmm, I think I understand, commit f04565ddf52 added a regression here, I
will send a fix.
Thanks
^ permalink raw reply
* Re: [PATCH] phonet: Check input from user before allocating
From: David Miller @ 2012-04-03 6:38 UTC (permalink / raw)
To: remi; +Cc: levinsasha928, davej, netdev, linux-kernel
In-Reply-To: <dc6e3bc8b96d91bd7ce44639b60cfec2@chewa.net>
From: Rémi Denis-Courmont <remi@remlab.net>
Date: Tue, 03 Apr 2012 08:36:20 +0200
> Oh right. And Phonet devices don't support scatter/gather, so that I
> guess that would merely delay the problem.
And this lack of SG support in the drivers never materialized largely
because the phonet stack never generated such things.
So yes indeed both sides of this equation will need to be addressed.
^ permalink raw reply
* Re: [PATCH 03/10] stmmac: sanitize the rx coe and add the type-1 csum
From: Giuseppe CAVALLARO @ 2012-04-03 6:49 UTC (permalink / raw)
To: Deepak SIKRI
Cc: netdev@vger.kernel.org, davem@davemloft.net, Srinivas KANDAGATLA,
spear-devel, Shiraz HASHIM, Viresh KUMAR,
bhutchings@solarflare.com
In-Reply-To: <4F79D13F.6020609@st.com>
Hello Deepak,
On 4/2/2012 6:18 PM, Deepak SIKRI wrote:
> On 4/2/2012 4:37 PM, Giuseppe CAVALLARO wrote:
[snip]
>> I've not clear at all your question.
>> The driver well uses the rx_coe as briefly described below:
>>
>> probe funct
>> |__ hw_init
>> |_ check the RX type from HW cap reg
>> |__ Override the rx_coe if required
>>
>> After that the rx_coe is used and passed to the core as expected.
>> In case of there is no HW cap register so the rx_coe from platform will
>> be used.
>>
>> Peppe
>
> In the same patch, this portion of the code has been removed.
>
> -static int dwmac1000_rx_coe_supported(void __iomem *ioaddr)
> -{
> - u32 value = readl(ioaddr + GMAC_CONTROL);
> -
> - value |= GMAC_CONTROL_IPC;
> - writel(value, ioaddr + GMAC_CONTROL);
> -
> - value = readl(ioaddr + GMAC_CONTROL);
> -
> - return !!(value& GMAC_CONTROL_IPC);
> -}
>
> Earlier this was taking care of setting the IP Checksum offloading feature
> in case its available. This code has to be present, as I do not see any
> other location where the IPC bit is being programmed.
>
> Also, the location of setting the IPC should be post the mac has been
> reset.
Previously, the stmmac called the dwmac1000_rx_coe_supported to verify
it could do the CSUM in Hw. If true the driver used the type 2 by default.
I've voluntarily removed this function because not necessary anymore.
In fact, YOU improved the rx_coe from the platform. If it is passed as
STMMAC_RX_COE_NONE then it means the driver is not able to perform any
csum for the incoming frames. This is actually used on old gmac/mac
cores. In new cores, the HW cap register will be used to manage and fix
this logic.
I could restore the core you are mentioning but just to do another
safety check at run-time in case of the user provided a broken setting
from the platform and there is not the HW cap register. Hmm, I do not
know if this actually could help indeed... just an extra check IMHO.
>
> I hope this clears the things a bit. Sorry for the miscommunication.
No problem for the miscommunication ;-)
Let me know
Ciao
Peppe
>
> Rgds
> Deepak
>
>
>
>
>
>
>>> Regards
>>> Deepak
>>>
>> .
>>
>
>
^ permalink raw reply
* Re: /proc/net/dev is funky in 3.3.0
From: Eric Dumazet @ 2012-04-03 7:06 UTC (permalink / raw)
To: Ben Greear; +Cc: NetDev
In-Reply-To: <1333434995.18626.39.camel@edumazet-glaptop>
On Tue, 2012-04-03 at 08:36 +0200, Eric Dumazet wrote:
> Hmm, I think I understand, commit f04565ddf52 added a regression here, I
> will send a fix.
>
If you want to try following patch, please do so, I cant try it right
now...
I'll provide a proper changelog/attributions in a couple of hours, and
make tests myself of course.
Thanks
net/core/dev.c | 46 ++++++++++++----------------------------------
1 file changed, 12 insertions(+), 34 deletions(-)
diff --git a/net/core/dev.c b/net/core/dev.c
index 6c7dc9d..f7e7de3 100644
--- a/net/core/dev.c
+++ b/net/core/dev.c
@@ -4028,54 +4028,45 @@ static int dev_ifconf(struct net *net, char __user *arg)
#ifdef CONFIG_PROC_FS
-#define BUCKET_SPACE (32 - NETDEV_HASHBITS)
+#define BUCKET_SPACE (32 - NETDEV_HASHBITS - 1)
struct dev_iter_state {
struct seq_net_private p;
- unsigned int pos; /* bucket << BUCKET_SPACE + offset */
};
#define get_bucket(x) ((x) >> BUCKET_SPACE)
#define get_offset(x) ((x) & ((1 << BUCKET_SPACE) - 1))
#define set_bucket_offset(b, o) ((b) << BUCKET_SPACE | (o))
-static inline struct net_device *dev_from_same_bucket(struct seq_file *seq)
+static inline struct net_device *dev_from_same_bucket(struct seq_file *seq, loff_t *pos)
{
- struct dev_iter_state *state = seq->private;
struct net *net = seq_file_net(seq);
struct net_device *dev;
struct hlist_node *p;
struct hlist_head *h;
- unsigned int count, bucket, offset;
+ unsigned int count = 0, offset = get_offset(*pos);
- bucket = get_bucket(state->pos);
- offset = get_offset(state->pos);
- h = &net->dev_name_head[bucket];
- count = 0;
+ h = &net->dev_name_head[get_bucket(*pos)];
hlist_for_each_entry_rcu(dev, p, h, name_hlist) {
- if (count++ == offset) {
- state->pos = set_bucket_offset(bucket, count);
+ if (++count == offset)
return dev;
- }
}
return NULL;
}
-static inline struct net_device *dev_from_new_bucket(struct seq_file *seq)
+static inline struct net_device *dev_from_bucket(struct seq_file *seq, loff_t *pos)
{
- struct dev_iter_state *state = seq->private;
struct net_device *dev;
unsigned int bucket;
- bucket = get_bucket(state->pos);
do {
- dev = dev_from_same_bucket(seq);
+ dev = dev_from_same_bucket(seq, pos);
if (dev)
return dev;
- bucket++;
- state->pos = set_bucket_offset(bucket, 0);
+ bucket = get_bucket(*pos);
+ *pos = set_bucket_offset(bucket + 1, 1);
} while (bucket < NETDEV_HASHENTRIES);
return NULL;
@@ -4088,33 +4079,20 @@ static inline struct net_device *dev_from_new_bucket(struct seq_file *seq)
void *dev_seq_start(struct seq_file *seq, loff_t *pos)
__acquires(RCU)
{
- struct dev_iter_state *state = seq->private;
-
rcu_read_lock();
if (!*pos)
return SEQ_START_TOKEN;
- /* check for end of the hash */
- if (state->pos == 0 && *pos > 1)
+ if (get_bucket(*pos) >= NETDEV_HASHENTRIES)
return NULL;
- return dev_from_new_bucket(seq);
+ return dev_from_bucket(seq, pos);
}
void *dev_seq_next(struct seq_file *seq, void *v, loff_t *pos)
{
- struct net_device *dev;
-
++*pos;
-
- if (v == SEQ_START_TOKEN)
- return dev_from_new_bucket(seq);
-
- dev = dev_from_same_bucket(seq);
- if (dev)
- return dev;
-
- return dev_from_new_bucket(seq);
+ return dev_from_bucket(seq, pos);
}
void dev_seq_stop(struct seq_file *seq, void *v)
^ permalink raw reply related
* Re: /proc/net/dev is funky in 3.3.0
From: Mihai Maruseac @ 2012-04-03 7:17 UTC (permalink / raw)
To: Eric Dumazet; +Cc: Ben Greear, NetDev, Mihai Maruseac, Daniel Baluta
In-Reply-To: <1333436789.18626.43.camel@edumazet-glaptop>
On Tue, Apr 3, 2012 at 10:06 AM, Eric Dumazet <eric.dumazet@gmail.com> wrote:
> On Tue, 2012-04-03 at 08:36 +0200, Eric Dumazet wrote:
>
>> Hmm, I think I understand, commit f04565ddf52 added a regression here, I
>> will send a fix.
>>
>
> If you want to try following patch, please do so, I cant try it right
> now...
>
> I'll provide a proper changelog/attributions in a couple of hours, and
> make tests myself of course.
>
> Thanks
>
> net/core/dev.c | 46 ++++++++++++----------------------------------
> 1 file changed, 12 insertions(+), 34 deletions(-)
>
> diff --git a/net/core/dev.c b/net/core/dev.c
> index 6c7dc9d..f7e7de3 100644
> --- a/net/core/dev.c
> +++ b/net/core/dev.c
> @@ -4028,54 +4028,45 @@ static int dev_ifconf(struct net *net, char __user *arg)
>
> #ifdef CONFIG_PROC_FS
>
> -#define BUCKET_SPACE (32 - NETDEV_HASHBITS)
> +#define BUCKET_SPACE (32 - NETDEV_HASHBITS - 1)
>
> struct dev_iter_state {
> struct seq_net_private p;
> - unsigned int pos; /* bucket << BUCKET_SPACE + offset */
> };
>
> #define get_bucket(x) ((x) >> BUCKET_SPACE)
> #define get_offset(x) ((x) & ((1 << BUCKET_SPACE) - 1))
> #define set_bucket_offset(b, o) ((b) << BUCKET_SPACE | (o))
>
> -static inline struct net_device *dev_from_same_bucket(struct seq_file *seq)
> +static inline struct net_device *dev_from_same_bucket(struct seq_file *seq, loff_t *pos)
> {
> - struct dev_iter_state *state = seq->private;
> struct net *net = seq_file_net(seq);
> struct net_device *dev;
> struct hlist_node *p;
> struct hlist_head *h;
> - unsigned int count, bucket, offset;
> + unsigned int count = 0, offset = get_offset(*pos);
>
> - bucket = get_bucket(state->pos);
> - offset = get_offset(state->pos);
> - h = &net->dev_name_head[bucket];
> - count = 0;
> + h = &net->dev_name_head[get_bucket(*pos)];
> hlist_for_each_entry_rcu(dev, p, h, name_hlist) {
> - if (count++ == offset) {
> - state->pos = set_bucket_offset(bucket, count);
> + if (++count == offset)
> return dev;
> - }
> }
>
> return NULL;
> }
>
> -static inline struct net_device *dev_from_new_bucket(struct seq_file *seq)
> +static inline struct net_device *dev_from_bucket(struct seq_file *seq, loff_t *pos)
> {
> - struct dev_iter_state *state = seq->private;
> struct net_device *dev;
> unsigned int bucket;
>
> - bucket = get_bucket(state->pos);
> do {
> - dev = dev_from_same_bucket(seq);
> + dev = dev_from_same_bucket(seq, pos);
> if (dev)
> return dev;
>
> - bucket++;
> - state->pos = set_bucket_offset(bucket, 0);
> + bucket = get_bucket(*pos);
> + *pos = set_bucket_offset(bucket + 1, 1);
> } while (bucket < NETDEV_HASHENTRIES);
>
> return NULL;
> @@ -4088,33 +4079,20 @@ static inline struct net_device *dev_from_new_bucket(struct seq_file *seq)
> void *dev_seq_start(struct seq_file *seq, loff_t *pos)
> __acquires(RCU)
> {
> - struct dev_iter_state *state = seq->private;
> -
> rcu_read_lock();
> if (!*pos)
> return SEQ_START_TOKEN;
>
> - /* check for end of the hash */
> - if (state->pos == 0 && *pos > 1)
> + if (get_bucket(*pos) >= NETDEV_HASHENTRIES)
> return NULL;
>
> - return dev_from_new_bucket(seq);
> + return dev_from_bucket(seq, pos);
> }
>
> void *dev_seq_next(struct seq_file *seq, void *v, loff_t *pos)
> {
> - struct net_device *dev;
> -
> ++*pos;
> -
> - if (v == SEQ_START_TOKEN)
> - return dev_from_new_bucket(seq);
> -
> - dev = dev_from_same_bucket(seq);
> - if (dev)
> - return dev;
> -
> - return dev_from_new_bucket(seq);
> + return dev_from_bucket(seq, pos);
> }
>
> void dev_seq_stop(struct seq_file *seq, void *v)
>
Looks good to me.
Thanks Eric,
Mihai
^ permalink raw reply
* Re: [PATCH 03/10] stmmac: sanitize the rx coe and add the type-1 csum
From: deepaksi @ 2012-04-03 7:56 UTC (permalink / raw)
To: Giuseppe CAVALLARO
Cc: netdev@vger.kernel.org, davem@davemloft.net, Srinivas KANDAGATLA,
spear-devel, Shiraz HASHIM, Viresh KUMAR,
bhutchings@solarflare.com
In-Reply-To: <4F7A9D7E.8080007@st.com>
Ciao Peppe,
On 4/3/2012 12:19 PM, Giuseppe CAVALLARO wrote:
>
> [snip]
>> reset.
> Previously, the stmmac called the dwmac1000_rx_coe_supported to verify
> it could do the CSUM in Hw. If true the driver used the type 2 by default.
>
> I've voluntarily removed this function because not necessary anymore.
> In fact, YOU improved the rx_coe from the platform. If it is passed as
> STMMAC_RX_COE_NONE then it means the driver is not able to perform any
> csum for the incoming frames. This is actually used on old gmac/mac
> cores. In new cores, the HW cap register will be used to manage and fix
> this logic.
> I could restore the core you are mentioning but just to do another
> safety check at run-time in case of the user provided a broken setting
> from the platform and there is not the HW cap register. Hmm, I do not
> know if this actually could help indeed... just an extra check IMHO.
These are the updates required in the code.
In function dwmac1000_core_init(), you may need to set the IPC bit based
on the fact that
if rx_coe has been setup through the platform code.
This bit set is a must for the checksum offload to be enabled. Rest of
the code looks good.
Deepak
>> I hope this clears the things a bit. Sorry for the miscommunication.
> No problem for the miscommunication ;-)
>
> Let me know
> Ciao
> Peppe
>
>> Rgds
>> Deepak
>>
>>
>>
>>
>>
>>
>>>> Regards
>>>> Deepak
>>>>
>>> .
>>>
>>
> .
>
^ permalink raw reply
* Re: [3.4-rc1][Regression][network wireless] 'task xxxx blocked for more than 120 seconds' after resume
From: Johannes Berg @ 2012-04-03 8:07 UTC (permalink / raw)
To: maciej.rutecki
Cc: Linux Kernel Mailing List, Rafael J. Wysocki, linux-wireless,
netdev
In-Reply-To: <201204022157.05598.maciej.rutecki@gmail.com>
-ilw
+netdev
I have no idea what this could be, but I'm almost certain it's not
caused by our wireless driver. Looks more like rtl8169 is to blame.
johannes
On Mon, 2012-04-02 at 21:57 +0200, Maciej Rutecki wrote:
> Last known good kernel: 3.3
>
> Bad kernel: 3.4-rc1 + patch: http://cgit.freedesktop.org/~danvet/drm-
> intel/commit/?h=drm-intel-fixes&id=55a254ac63a3ac1867d1501030e7fba69c7d4aeb
>
> Subsystem: network (wireless)
>
> After resume from suspend to disk I do not have network connection (wireless)
> and I got it in dmesg:
>
> [ 2398.278375] INFO: task nmbd:2442 blocked for more than 120 seconds.
> [ 2398.278384] "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables
> this message.
> [ 2398.278390] nmbd D ffff88023fb933c0 0 2442 1 0x00000000
> [ 2398.278401] ffff880232d6f5d0 0000000000000082 0000000000000206
> ffff880235186ee0
> [ 2398.278413] 00000000000133c0 ffff8802320fdfd8 ffff8802320fdfd8 ffff880232d6f5d0
> [ 2398.278423] ffff8802320fde5c ffffffff81868020 ffff880232d6f5d0 0000000000000002
> [ 2398.278433] Call Trace:
> [ 2398.278451] [<ffffffff813fba8c>] ? __mutex_lock_common.isra.5+0xff/0x164
> [ 2398.278462] [<ffffffff813fb97a>] ? mutex_lock+0x1a/0x2d
> [ 2398.278471] [<ffffffff8135bb44>] ? netlink_trim+0x13/0x79
> [ 2398.278480] [<ffffffff81349f0c>] ? rtnetlink_rcv+0xe/0x28
> [ 2398.278488] [<ffffffff8135cffc>] ? netlink_unicast+0xe6/0x14e
> [ 2398.278497] [<ffffffff8135d265>] ? netlink_sendmsg+0x201/0x23c
> [ 2398.278505] [<ffffffff811091b1>] ? __pollwait+0xce/0xce
> [ 2398.278515] [<ffffffff8132e2a2>] ? sock_sendmsg+0xca/0xe7
> [ 2398.278521] [<ffffffff811091b1>] ? __pollwait+0xce/0xce
> [ 2398.278530] [<ffffffff8103d1da>] ? sys_time+0xc/0x39
> [ 2398.278539] [<ffffffff81011e5d>] ? emulate_vsyscall+0x191/0x270
> [ 2398.278548] [<ffffffff81056a33>] ? should_resched+0x5/0x23
> [ 2398.278554] [<ffffffff813fc545>] ? _cond_resched+0x6/0x1b
> [ 2398.278562] [<ffffffff8132cd08>] ? copy_from_user+0x18/0x30
> [ 2398.278571] [<ffffffff8132fb20>] ? sys_sendto+0xf7/0x137
> [ 2398.278581] [<ffffffff810fa2a0>] ? fd_install+0x25/0x4a
> [ 2398.278591] [<ffffffff81401ff9>] ? system_call_fastpath+0x16/0x1b
> [ 2398.278659] INFO: task ifconfig:6734 blocked for more than 120 seconds.
> [ 2398.278664] "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables
> this message.
> [ 2398.278669] ifconfig D ffff88023fb933c0 0 6734 2598 0x00000000
> [ 2398.278678] ffff8801faae30a0 0000000000000086 0000000000000001
> ffff880235186ee0
> [ 2398.278688] 00000000000133c0 ffff880232163fd8 ffff880232163fd8 ffff8801faae30a0
> [ 2398.278697] 0000000000000001 ffff880230f2b4d8 ffff8801faae30a0
> 0000000000000002
> [ 2398.278707] Call Trace:
> [ 2398.278716] [<ffffffff813fba8c>] ? __mutex_lock_common.isra.5+0xff/0x164
> [ 2398.278723] [<ffffffff81056a33>] ? should_resched+0x5/0x23
> [ 2398.278732] [<ffffffff813fb97a>] ? mutex_lock+0x1a/0x2d
> [ 2398.278759] [<ffffffffa0116d33>] ? rtl8169_close+0x49/0x14f [r8169]
> [ 2398.278768] [<ffffffff8133cb37>] ? __dev_close_many+0x85/0xb2
> [ 2398.278775] [<ffffffff8133cb94>] ? __dev_close+0x30/0x47
> [ 2398.278783] [<ffffffff813405c0>] ? dev_set_rx_mode+0x1d/0x29
> [ 2398.278792] [<ffffffff81340844>] ? __dev_change_flags+0x9d/0x118
> [ 2398.278799] [<ffffffff81340922>] ? dev_change_flags+0x12/0x42
> [ 2398.278810] [<ffffffff8138a769>] ? devinet_ioctl+0x285/0x554
> [ 2398.278818] [<ffffffff8132cdb3>] ? sock_do_ioctl+0x1b/0x36
> [ 2398.278826] [<ffffffff8132d1be>] ? sock_ioctl+0x205/0x212
> [ 2398.278836] [<ffffffff8110887d>] ? do_vfs_ioctl+0x459/0x49a
> [ 2398.278844] [<ffffffff810ee42b>] ? kmem_cache_alloc+0x86/0xea
> [ 2398.278853] [<ffffffff81108909>] ? sys_ioctl+0x4b/0x72
> [ 2398.278862] [<ffffffff81401ff9>] ? system_call_fastpath+0x16/0x1b
> [ 2518.146666] INFO: task nmbd:2442 blocked for more than 120 seconds.
> [ 2518.146675] "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables
> this message.
> [ 2518.146682] nmbd D ffff88023fb933c0 0 2442 1 0x00000000
> [ 2518.146693] ffff880232d6f5d0 0000000000000082 0000000000000206
> ffff880235186ee0
> [ 2518.146704] 00000000000133c0 ffff8802320fdfd8 ffff8802320fdfd8 ffff880232d6f5d0
> [ 2518.146714] ffff8802320fde5c ffffffff81868020 ffff880232d6f5d0 0000000000000002
> [ 2518.146725] Call Trace:
> [ 2518.146743] [<ffffffff813fba8c>] ? __mutex_lock_common.isra.5+0xff/0x164
> [ 2518.146753] [<ffffffff813fb97a>] ? mutex_lock+0x1a/0x2d
> [ 2518.146763] [<ffffffff8135bb44>] ? netlink_trim+0x13/0x79
> [ 2518.146772] [<ffffffff81349f0c>] ? rtnetlink_rcv+0xe/0x28
> [ 2518.146780] [<ffffffff8135cffc>] ? netlink_unicast+0xe6/0x14e
> [ 2518.146788] [<ffffffff8135d265>] ? netlink_sendmsg+0x201/0x23c
> [ 2518.146796] [<ffffffff811091b1>] ? __pollwait+0xce/0xce
> [ 2518.146807] [<ffffffff8132e2a2>] ? sock_sendmsg+0xca/0xe7
> [ 2518.146813] [<ffffffff811091b1>] ? __pollwait+0xce/0xce
> [ 2518.146822] [<ffffffff8103d1da>] ? sys_time+0xc/0x39
> [ 2518.146831] [<ffffffff81011e5d>] ? emulate_vsyscall+0x191/0x270
> [ 2518.146839] [<ffffffff81056a33>] ? should_resched+0x5/0x23
> [ 2518.146846] [<ffffffff813fc545>] ? _cond_resched+0x6/0x1b
> [ 2518.146854] [<ffffffff8132cd08>] ? copy_from_user+0x18/0x30
> [ 2518.146862] [<ffffffff8132fb20>] ? sys_sendto+0xf7/0x137
> [ 2518.146872] [<ffffffff810fa2a0>] ? fd_install+0x25/0x4a
> [ 2518.146883] [<ffffffff81401ff9>] ? system_call_fastpath+0x16/0x1b
> [ 2518.146915] INFO: task ksysguardd:3501 blocked for more than 120 seconds.
> [ 2518.146919] "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables
> this message.
> [ 2518.146924] ksysguardd D ffff88023fa133c0 0 3501 3436 0x00000000
> [ 2518.146934] ffff8802322ed8d0 0000000000000082 ffff880228522980 ffffffff81813020
> [ 2518.146943] 00000000000133c0 ffff880225c7bfd8 ffff880225c7bfd8 ffff8802322ed8d0
> [ 2518.146953] 00000008a01445fe ffffffff81868020 ffff8802322ed8d0 0000000000000002
> [ 2518.146962] Call Trace:
> [ 2518.146972] [<ffffffff813fba8c>] ? __mutex_lock_common.isra.5+0xff/0x164
> [ 2518.146981] [<ffffffff813fb97a>] ? mutex_lock+0x1a/0x2d
> [ 2518.146993] [<ffffffff813daa7b>] ? wireless_dev_seq_start+0x12/0x5e
> [ 2518.147002] [<ffffffff811136bd>] ? seq_read+0x148/0x354
> [ 2518.147012] [<ffffffff81141a3e>] ? proc_reg_read+0x78/0x91
> [ 2518.147021] [<ffffffff810fb7e5>] ? vfs_read+0x9f/0xe6
> [ 2518.147028] [<ffffffff810fb871>] ? sys_read+0x45/0x6b
> [ 2518.147037] [<ffffffff81401ff9>] ? system_call_fastpath+0x16/0x1b
> [ 2518.147063] INFO: task ifconfig:6734 blocked for more than 120 seconds.
> [ 2518.147068] "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables
> this message.
> [ 2518.147072] ifconfig D ffff88023fb933c0 0 6734 2598 0x00000000
> [ 2518.147081] ffff8801faae30a0 0000000000000086 0000000000000001
> ffff880235186ee0
> [ 2518.147090] 00000000000133c0 ffff880232163fd8 ffff880232163fd8 ffff8801faae30a0
> [ 2518.147099] 0000000000000001 ffff880230f2b4d8 ffff8801faae30a0
> 0000000000000002
> [ 2518.147109] Call Trace:
> [ 2518.147118] [<ffffffff813fba8c>] ? __mutex_lock_common.isra.5+0xff/0x164
> [ 2518.147125] [<ffffffff81056a33>] ? should_resched+0x5/0x23
> [ 2518.147133] [<ffffffff813fb97a>] ? mutex_lock+0x1a/0x2d
> [ 2518.147160] [<ffffffffa0116d33>] ? rtl8169_close+0x49/0x14f [r8169]
> [ 2518.147169] [<ffffffff8133cb37>] ? __dev_close_many+0x85/0xb2
> [ 2518.147176] [<ffffffff8133cb94>] ? __dev_close+0x30/0x47
> [ 2518.147184] [<ffffffff813405c0>] ? dev_set_rx_mode+0x1d/0x29
> [ 2518.147192] [<ffffffff81340844>] ? __dev_change_flags+0x9d/0x118
> [ 2518.147200] [<ffffffff81340922>] ? dev_change_flags+0x12/0x42
> [ 2518.147210] [<ffffffff8138a769>] ? devinet_ioctl+0x285/0x554
> [ 2518.147219] [<ffffffff8132cdb3>] ? sock_do_ioctl+0x1b/0x36
> [ 2518.147227] [<ffffffff8132d1be>] ? sock_ioctl+0x205/0x212
> [ 2518.147237] [<ffffffff8110887d>] ? do_vfs_ioctl+0x459/0x49a
> [ 2518.147245] [<ffffffff810ee42b>] ? kmem_cache_alloc+0x86/0xea
> [ 2518.147254] [<ffffffff81108909>] ? sys_ioctl+0x4b/0x72
> [ 2518.147263] [<ffffffff81401ff9>] ? system_call_fastpath+0x16/0x1b
> [ 2638.014954] INFO: task nmbd:2442 blocked for more than 120 seconds.
> [ 2638.014963] "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables
> this message.
> [ 2638.014969] nmbd D ffff88023fb933c0 0 2442 1 0x00000000
> [ 2638.014980] ffff880232d6f5d0 0000000000000082 0000000000000206
> ffff880235186ee0
> [ 2638.014992] 00000000000133c0 ffff8802320fdfd8 ffff8802320fdfd8 ffff880232d6f5d0
> [ 2638.015002] ffff8802320fde5c ffffffff81868020 ffff880232d6f5d0 0000000000000002
> [ 2638.015012] Call Trace:
> [ 2638.015030] [<ffffffff813fba8c>] ? __mutex_lock_common.isra.5+0xff/0x164
> [ 2638.015041] [<ffffffff813fb97a>] ? mutex_lock+0x1a/0x2d
> [ 2638.015050] [<ffffffff8135bb44>] ? netlink_trim+0x13/0x79
> [ 2638.015059] [<ffffffff81349f0c>] ? rtnetlink_rcv+0xe/0x28
> [ 2638.015067] [<ffffffff8135cffc>] ? netlink_unicast+0xe6/0x14e
> [ 2638.015075] [<ffffffff8135d265>] ? netlink_sendmsg+0x201/0x23c
> [ 2638.015083] [<ffffffff811091b1>] ? __pollwait+0xce/0xce
> [ 2638.015093] [<ffffffff8132e2a2>] ? sock_sendmsg+0xca/0xe7
> [ 2638.015099] [<ffffffff811091b1>] ? __pollwait+0xce/0xce
> [ 2638.015108] [<ffffffff8103d1da>] ? sys_time+0xc/0x39
> [ 2638.015116] [<ffffffff81011e5d>] ? emulate_vsyscall+0x191/0x270
> [ 2638.015124] [<ffffffff81056a33>] ? should_resched+0x5/0x23
> [ 2638.015131] [<ffffffff813fc545>] ? _cond_resched+0x6/0x1b
> [ 2638.015138] [<ffffffff8132cd08>] ? copy_from_user+0x18/0x30
> [ 2638.015147] [<ffffffff8132fb20>] ? sys_sendto+0xf7/0x137
> [ 2638.015156] [<ffffffff810fa2a0>] ? fd_install+0x25/0x4a
> [ 2638.015166] [<ffffffff81401ff9>] ? system_call_fastpath+0x16/0x1b
> [ 2638.015196] INFO: task ksysguardd:3501 blocked for more than 120 seconds.
> [ 2638.015201] "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables
> this message.
> [ 2638.015205] ksysguardd D ffff88023fa133c0 0 3501 3436 0x00000000
> [ 2638.015214] ffff8802322ed8d0 0000000000000082 ffff880228522980 ffffffff81813020
> [ 2638.015224] 00000000000133c0 ffff880225c7bfd8 ffff880225c7bfd8 ffff8802322ed8d0
> [ 2638.015233] 00000008a01445fe ffffffff81868020 ffff8802322ed8d0 0000000000000002
> [ 2638.015243] Call Trace:
> [ 2638.015252] [<ffffffff813fba8c>] ? __mutex_lock_common.isra.5+0xff/0x164
> [ 2638.015262] [<ffffffff813fb97a>] ? mutex_lock+0x1a/0x2d
> [ 2638.015273] [<ffffffff813daa7b>] ? wireless_dev_seq_start+0x12/0x5e
> [ 2638.015282] [<ffffffff811136bd>] ? seq_read+0x148/0x354
> [ 2638.015291] [<ffffffff81141a3e>] ? proc_reg_read+0x78/0x91
> [ 2638.015299] [<ffffffff810fb7e5>] ? vfs_read+0x9f/0xe6
> [ 2638.015307] [<ffffffff810fb871>] ? sys_read+0x45/0x6b
> [ 2638.015315] [<ffffffff81401ff9>] ? system_call_fastpath+0x16/0x1b
> [ 2638.015339] INFO: task ifconfig:6734 blocked for more than 120 seconds.
> [ 2638.015344] "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables
> this message.
> [ 2638.015348] ifconfig D ffff88023fb933c0 0 6734 2598 0x00000000
> [ 2638.015357] ffff8801faae30a0 0000000000000086 0000000000000001
> ffff880235186ee0
> [ 2638.015366] 00000000000133c0 ffff880232163fd8 ffff880232163fd8 ffff8801faae30a0
> [ 2638.015375] 0000000000000001 ffff880230f2b4d8 ffff8801faae30a0
> 0000000000000002
> [ 2638.015384] Call Trace:
> [ 2638.015393] [<ffffffff813fba8c>] ? __mutex_lock_common.isra.5+0xff/0x164
> [ 2638.015400] [<ffffffff81056a33>] ? should_resched+0x5/0x23
> [ 2638.015409] [<ffffffff813fb97a>] ? mutex_lock+0x1a/0x2d
> [ 2638.015434] [<ffffffffa0116d33>] ? rtl8169_close+0x49/0x14f [r8169]
> [ 2638.015443] [<ffffffff8133cb37>] ? __dev_close_many+0x85/0xb2
> [ 2638.015450] [<ffffffff8133cb94>] ? __dev_close+0x30/0x47
> [ 2638.015458] [<ffffffff813405c0>] ? dev_set_rx_mode+0x1d/0x29
> [ 2638.015466] [<ffffffff81340844>] ? __dev_change_flags+0x9d/0x118
> [ 2638.015474] [<ffffffff81340922>] ? dev_change_flags+0x12/0x42
> [ 2638.015484] [<ffffffff8138a769>] ? devinet_ioctl+0x285/0x554
> [ 2638.015492] [<ffffffff8132cdb3>] ? sock_do_ioctl+0x1b/0x36
> [ 2638.015500] [<ffffffff8132d1be>] ? sock_ioctl+0x205/0x212
> [ 2638.015510] [<ffffffff8110887d>] ? do_vfs_ioctl+0x459/0x49a
> [ 2638.015518] [<ffffffff810ee42b>] ? kmem_cache_alloc+0x86/0xea
> [ 2638.015527] [<ffffffff81108909>] ? sys_ioctl+0x4b/0x72
> [ 2638.015535] [<ffffffff81401ff9>] ? system_call_fastpath+0x16/0x1b
>
>
> Config:
> http://mrutecki.pl/download/kernel/3.4-rc1/netdev_resume/config-3.4.0-rc1
>
> full dmesg:
> http://mrutecki.pl/download/kernel/3.4-rc1/netdev_resume/dmesg_netdev-3.4-
> rc1.txt
>
> lspci:
> 00:00.0 Host bridge: Intel Corporation 2nd Generation Core Processor Family
> DRAM Controller (rev 09)
> 00:02.0 VGA compatible controller: Intel Corporation 2nd Generation Core
> Processor Family Integrated Graphics Controller (rev 09)
> 00:16.0 Communication controller: Intel Corporation 6 Series/C200 Series
> Chipset Family MEI Controller #1 (rev 04)
> 00:1a.0 USB controller: Intel Corporation 6 Series/C200 Series Chipset Family
> USB Enhanced Host Controller #2 (rev 04)
> 00:1b.0 Audio device: Intel Corporation 6 Series/C200 Series Chipset Family
> High Definition Audio Controller (rev 04)
> 00:1c.0 PCI bridge: Intel Corporation 6 Series/C200 Series Chipset Family PCI
> Express Root Port 1 (rev b4)
> 00:1c.1 PCI bridge: Intel Corporation 6 Series/C200 Series Chipset Family PCI
> Express Root Port 2 (rev b4)
> 00:1c.2 PCI bridge: Intel Corporation 6 Series/C200 Series Chipset Family PCI
> Express Root Port 3 (rev b4)
> 00:1c.3 PCI bridge: Intel Corporation 6 Series/C200 Series Chipset Family PCI
> Express Root Port 4 (rev b4)
> 00:1c.7 PCI bridge: Intel Corporation 6 Series/C200 Series Chipset Family PCI
> Express Root Port 8 (rev b4)
> 00:1d.0 USB controller: Intel Corporation 6 Series/C200 Series Chipset Family
> USB Enhanced Host Controller #1 (rev 04)
> 00:1f.0 ISA bridge: Intel Corporation HM65 Express Chipset Family LPC
> Controller (rev 04)
> 00:1f.2 SATA controller: Intel Corporation 6 Series/C200 Series Chipset Family
> 6 port SATA AHCI Controller (rev 04)
> 00:1f.3 SMBus: Intel Corporation 6 Series/C200 Series Chipset Family SMBus
> Controller (rev 04)
> 02:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8111/8168B PCI
> Express Gigabit Ethernet controller (rev 06)
> 03:00.0 System peripheral: Ricoh Co Ltd MMC/SD Host Controller (rev 07)
> 08:00.0 Network controller: Intel Corporation Centrino Wireless-N 1000
>
> Regards
^ permalink raw reply
* Re: [PATCH] netfilter: xt_CT: remove a compile warning
From: Pablo Neira Ayuso @ 2012-04-03 8:17 UTC (permalink / raw)
To: Eric Dumazet; +Cc: David Miller, netdev
In-Reply-To: <1333424902.18626.36.camel@edumazet-glaptop>
[-- Attachment #1: Type: text/plain, Size: 423 bytes --]
On Tue, Apr 03, 2012 at 05:48:22AM +0200, Eric Dumazet wrote:
> If CONFIG_NF_CONNTRACK_TIMEOUT=n we have following warning :
>
> CC [M] net/netfilter/xt_CT.o
> net/netfilter/xt_CT.c: In function ‘xt_ct_tg_check_v1’:
> net/netfilter/xt_CT.c:284: warning: label ‘err4’ defined but not used
Thanks Eric.
I think I prefer the one attached.
I 'll pass it to davem with a couple of other minor fixes anytime soon.
[-- Attachment #2: 0001-netfilter-xt_CT-remove-a-compile-warning.patch --]
[-- Type: text/x-diff, Size: 1055 bytes --]
>From 44b52bccf855b0706de624c29fc3d82ca954bb4e Mon Sep 17 00:00:00 2001
From: Pablo Neira Ayuso <pablo@netfilter.org>
Date: Tue, 3 Apr 2012 10:08:48 +0200
Subject: [PATCH] netfilter: xt_CT: remove a compile warning
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
If CONFIG_NF_CONNTRACK_TIMEOUT=n we have following warning :
CC [M] net/netfilter/xt_CT.o
net/netfilter/xt_CT.c: In function ‘xt_ct_tg_check_v1’:
net/netfilter/xt_CT.c:284: warning: label ‘err4’ defined but not used
Reported-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
---
net/netfilter/xt_CT.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/net/netfilter/xt_CT.c b/net/netfilter/xt_CT.c
index 0c8e438..138b75e 100644
--- a/net/netfilter/xt_CT.c
+++ b/net/netfilter/xt_CT.c
@@ -281,8 +281,10 @@ out:
info->ct = ct;
return 0;
+#ifdef CONFIG_NF_CONNTRACK_TIMEOUT
err4:
rcu_read_unlock();
+#endif
err3:
nf_conntrack_free(ct);
err2:
--
1.7.2.5
^ permalink raw reply related
* Re: [PATCH] netfilter: xt_CT: remove a compile warning
From: Eric Dumazet @ 2012-04-03 8:31 UTC (permalink / raw)
To: Pablo Neira Ayuso; +Cc: David Miller, netdev
In-Reply-To: <20120403081728.GA19753@1984>
On Tue, 2012-04-03 at 10:17 +0200, Pablo Neira Ayuso wrote:
> On Tue, Apr 03, 2012 at 05:48:22AM +0200, Eric Dumazet wrote:
> > If CONFIG_NF_CONNTRACK_TIMEOUT=n we have following warning :
> >
> > CC [M] net/netfilter/xt_CT.o
> > net/netfilter/xt_CT.c: In function ‘xt_ct_tg_check_v1’:
> > net/netfilter/xt_CT.c:284: warning: label ‘err4’ defined but not used
>
> Thanks Eric.
>
> I think I prefer the one attached.
>
> I 'll pass it to davem with a couple of other minor fixes anytime soon.
Its your call, but you should move the whole
#if CONFIG_NF_CONNTRACK_TIMEOUT
... lot of lines ...
#endif
in a helper function to make things a bit more maintainable
^ permalink raw reply
* [PATCH net: fix /proc/net/dev regression
From: Eric Dumazet @ 2012-04-03 8:33 UTC (permalink / raw)
To: Ben Greear, David Miller; +Cc: NetDev, Mihai Maruseac
In-Reply-To: <1333436789.18626.43.camel@edumazet-glaptop>
Commit f04565ddf52 (dev: use name hash for dev_seq_ops) added a second
regression, as some devices are missing from /proc/net/dev if many
devices are defined.
When seq_file buffer is filled, the last ->next/show() method is
canceled (pos value is reverted to value prior ->next() call)
Problem is after above commit, we dont restart the lookup at right
position in ->start() method.
Fix this by removing the internal 'pos' pointer added in commit, since
we need to use the 'loff_t *pos' provided by seq_file layer.
This also reverts commit 5cac98dd0 (net: Fix corruption
in /proc/*/net/dev_mcast), since its not needed anymore.
Reported-by: Ben Greear <greearb@candelatech.com>
Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Cc: Mihai Maruseac <mmaruseac@ixiacom.com>
---
include/linux/netdevice.h | 2 -
net/core/dev.c | 58 ++++++++----------------------------
net/core/dev_addr_lists.c | 3 +
3 files changed, 15 insertions(+), 48 deletions(-)
diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h
index 1f77540..5cbaa20 100644
--- a/include/linux/netdevice.h
+++ b/include/linux/netdevice.h
@@ -2604,8 +2604,6 @@ extern void net_disable_timestamp(void);
extern void *dev_seq_start(struct seq_file *seq, loff_t *pos);
extern void *dev_seq_next(struct seq_file *seq, void *v, loff_t *pos);
extern void dev_seq_stop(struct seq_file *seq, void *v);
-extern int dev_seq_open_ops(struct inode *inode, struct file *file,
- const struct seq_operations *ops);
#endif
extern int netdev_class_create_file(struct class_attribute *class_attr);
diff --git a/net/core/dev.c b/net/core/dev.c
index 6c7dc9d..c25d453 100644
--- a/net/core/dev.c
+++ b/net/core/dev.c
@@ -4028,54 +4028,41 @@ static int dev_ifconf(struct net *net, char __user *arg)
#ifdef CONFIG_PROC_FS
-#define BUCKET_SPACE (32 - NETDEV_HASHBITS)
-
-struct dev_iter_state {
- struct seq_net_private p;
- unsigned int pos; /* bucket << BUCKET_SPACE + offset */
-};
+#define BUCKET_SPACE (32 - NETDEV_HASHBITS - 1)
#define get_bucket(x) ((x) >> BUCKET_SPACE)
#define get_offset(x) ((x) & ((1 << BUCKET_SPACE) - 1))
#define set_bucket_offset(b, o) ((b) << BUCKET_SPACE | (o))
-static inline struct net_device *dev_from_same_bucket(struct seq_file *seq)
+static inline struct net_device *dev_from_same_bucket(struct seq_file *seq, loff_t *pos)
{
- struct dev_iter_state *state = seq->private;
struct net *net = seq_file_net(seq);
struct net_device *dev;
struct hlist_node *p;
struct hlist_head *h;
- unsigned int count, bucket, offset;
+ unsigned int count = 0, offset = get_offset(*pos);
- bucket = get_bucket(state->pos);
- offset = get_offset(state->pos);
- h = &net->dev_name_head[bucket];
- count = 0;
+ h = &net->dev_name_head[get_bucket(*pos)];
hlist_for_each_entry_rcu(dev, p, h, name_hlist) {
- if (count++ == offset) {
- state->pos = set_bucket_offset(bucket, count);
+ if (++count == offset)
return dev;
- }
}
return NULL;
}
-static inline struct net_device *dev_from_new_bucket(struct seq_file *seq)
+static inline struct net_device *dev_from_bucket(struct seq_file *seq, loff_t *pos)
{
- struct dev_iter_state *state = seq->private;
struct net_device *dev;
unsigned int bucket;
- bucket = get_bucket(state->pos);
do {
- dev = dev_from_same_bucket(seq);
+ dev = dev_from_same_bucket(seq, pos);
if (dev)
return dev;
- bucket++;
- state->pos = set_bucket_offset(bucket, 0);
+ bucket = get_bucket(*pos) + 1;
+ *pos = set_bucket_offset(bucket, 1);
} while (bucket < NETDEV_HASHENTRIES);
return NULL;
@@ -4088,33 +4075,20 @@ static inline struct net_device *dev_from_new_bucket(struct seq_file *seq)
void *dev_seq_start(struct seq_file *seq, loff_t *pos)
__acquires(RCU)
{
- struct dev_iter_state *state = seq->private;
-
rcu_read_lock();
if (!*pos)
return SEQ_START_TOKEN;
- /* check for end of the hash */
- if (state->pos == 0 && *pos > 1)
+ if (get_bucket(*pos) >= NETDEV_HASHENTRIES)
return NULL;
- return dev_from_new_bucket(seq);
+ return dev_from_bucket(seq, pos);
}
void *dev_seq_next(struct seq_file *seq, void *v, loff_t *pos)
{
- struct net_device *dev;
-
++*pos;
-
- if (v == SEQ_START_TOKEN)
- return dev_from_new_bucket(seq);
-
- dev = dev_from_same_bucket(seq);
- if (dev)
- return dev;
-
- return dev_from_new_bucket(seq);
+ return dev_from_bucket(seq, pos);
}
void dev_seq_stop(struct seq_file *seq, void *v)
@@ -4213,13 +4187,7 @@ static const struct seq_operations dev_seq_ops = {
static int dev_seq_open(struct inode *inode, struct file *file)
{
return seq_open_net(inode, file, &dev_seq_ops,
- sizeof(struct dev_iter_state));
-}
-
-int dev_seq_open_ops(struct inode *inode, struct file *file,
- const struct seq_operations *ops)
-{
- return seq_open_net(inode, file, ops, sizeof(struct dev_iter_state));
+ sizeof(struct seq_net_private));
}
static const struct file_operations dev_seq_fops = {
diff --git a/net/core/dev_addr_lists.c b/net/core/dev_addr_lists.c
index 29c07fe..626698f 100644
--- a/net/core/dev_addr_lists.c
+++ b/net/core/dev_addr_lists.c
@@ -696,7 +696,8 @@ static const struct seq_operations dev_mc_seq_ops = {
static int dev_mc_seq_open(struct inode *inode, struct file *file)
{
- return dev_seq_open_ops(inode, file, &dev_mc_seq_ops);
+ return seq_open_net(inode, file, &dev_mc_seq_ops,
+ sizeof(struct seq_net_private));
}
static const struct file_operations dev_mc_seq_fops = {
^ permalink raw reply related
* [PATCH 4/4] ppp: use for_each_set_bit_from
From: Akinobu Mita @ 2012-04-03 8:47 UTC (permalink / raw)
To: linux-kernel, akpm; +Cc: Akinobu Mita, Dmitry Kozlov, netdev
In-Reply-To: <1333442836-9947-1-git-send-email-akinobu.mita@gmail.com>
Use for_each_set_bit_from to iterate over all the set bit in a memory
region.
Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com>
Cc: Dmitry Kozlov <xeb@mail.ru>
Cc: netdev@vger.kernel.org
---
drivers/net/ppp/pptp.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/net/ppp/pptp.c b/drivers/net/ppp/pptp.c
index 885dbdd..72b50f5 100644
--- a/drivers/net/ppp/pptp.c
+++ b/drivers/net/ppp/pptp.c
@@ -116,8 +116,8 @@ static int lookup_chan_dst(u16 call_id, __be32 d_addr)
int i;
rcu_read_lock();
- for (i = find_next_bit(callid_bitmap, MAX_CALLID, 1); i < MAX_CALLID;
- i = find_next_bit(callid_bitmap, MAX_CALLID, i + 1)) {
+ i = 1;
+ for_each_set_bit_from(i, callid_bitmap, MAX_CALLID) {
sock = rcu_dereference(callid_sock[i]);
if (!sock)
continue;
--
1.7.4.4
^ permalink raw reply related
* Re: [RFC] net:phy:phylib: phy shares the same interrupt with mac
From: Florian Fainelli @ 2012-04-03 8:49 UTC (permalink / raw)
To: Jason Lin; +Cc: netdev
In-Reply-To: <CAGCDX1nndpdGHZzhh_Y+2OMLZvvUmAqkAsmgHu9hdUXTJFE--Q@mail.gmail.com>
Hi,
Le 04/03/12 04:11, Jason Lin a écrit :
> 1) Add a new definition PHY_MAC if phy shares the same
> interrupt with mac.
> 2) Add do_phy_workqueue(), that mac can invoke this function
> in its ISR when link status changed or other conditions.
>
> Does this seems reasonable?
No, I think this is well handled by the PHY_IGNORE_INTERRUPT case
(documented in Documentation/networking/phy.txt) by doing the following:
- distinguish between MAC and PHY interrupts in your MAC interrupt
handler (most likely you have separate bits for PHY interrupts)
- once you see a PHY interrupt, call the appropriate PHY state machine
callbacks to update the PHY state machine
>
>
> ---------------------------
> drivers/net/phy/phy.c | 27 +++++++++++++++++++++++++++
> drivers/net/phy/phy_device.c | 4 ++--
> include/linux/phy.h | 3 +++
> 3 files changed, 32 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/net/phy/phy.c b/drivers/net/phy/phy.c
> index 7670aac..c8009e9 100644
> --- a/drivers/net/phy/phy.c
> +++ b/drivers/net/phy/phy.c
> @@ -527,6 +527,28 @@ static irqreturn_t phy_interrupt(int irq, void *phy_dat)
> return IRQ_HANDLED;
> }
>
> +/*
> + * do_phy_workqueue - PHY interrupt handler used by MAC
> + * @irq: interrupt line
> + * @phydev: phy_device pointer
> + *
> + * Description: When a PHY use the same interrupt with MAC,
> + * the handler is invoked by MAC, and schedules a work task
> + * to clear the PHY's interrupt.
> + * This handler is invoked only in MAC's ISR.
> + */
> +irqreturn_t do_phy_workqueue(int irq, struct phy_device *phydev) {
> +
> + BUG_ON(!in_interrupt());
> +
> + if (PHY_HALTED == phydev->state)
> + return IRQ_NONE;
> +
> + schedule_work(&phydev->phy_queue);
> + return IRQ_HANDLED;
> +}
> +EXPORT_SYMBOL(do_phy_workqueue);
> +
> /**
> * phy_enable_interrupts - Enable the interrupts from the PHY side
> * @phydev: target phy_device struct
> @@ -589,6 +611,11 @@ int phy_start_interrupts(struct phy_device *phydev)
>
> INIT_WORK(&phydev->phy_queue, phy_change);
>
> + if (phydev->irq == PHY_MAC) {
> + err = phy_enable_interrupts(phydev);
> + return err;
> + }
> +
> atomic_set(&phydev->irq_disable, 0);
> if (request_irq(phydev->irq, phy_interrupt,
> IRQF_SHARED,
> diff --git a/drivers/net/phy/phy_device.c b/drivers/net/phy/phy_device.c
> index 993c52c..1857097 100644
> --- a/drivers/net/phy/phy_device.c
> +++ b/drivers/net/phy/phy_device.c
> @@ -345,7 +345,7 @@ int phy_connect_direct(struct net_device *dev,
> struct phy_device *phydev,
>
> phy_prepare_link(phydev, handler);
> phy_start_machine(phydev, NULL);
> - if (phydev->irq> 0)
> + if ((phydev->irq> 0) || (phydev->irq == PHY_MAC))
> phy_start_interrupts(phydev);
>
> return 0;
> @@ -399,7 +399,7 @@ EXPORT_SYMBOL(phy_connect);
> */
> void phy_disconnect(struct phy_device *phydev)
> {
> - if (phydev->irq> 0)
> + if ((phydev->irq> 0) || (phydev->irq == PHY_MAC))
> phy_stop_interrupts(phydev);
>
> phy_stop_machine(phydev);
> diff --git a/include/linux/phy.h b/include/linux/phy.h
> index 7da5fa8..155822c 100644
> --- a/include/linux/phy.h
> +++ b/include/linux/phy.h
> @@ -44,9 +44,11 @@
> * Set phydev->irq to PHY_POLL if interrupts are not supported,
> * or not desired for this PHY. Set to PHY_IGNORE_INTERRUPT if
> * the attached driver handles the interrupt
> + * Set to PHY_MAC if using the same interrupt with MAC
> */
> #define PHY_POLL -1
> #define PHY_IGNORE_INTERRUPT -2
> +#define PHY_MAC -3
>
> #define PHY_HAS_INTERRUPT 0x00000001
> #define PHY_HAS_MAGICANEG 0x00000002
> @@ -510,6 +512,7 @@ int phy_ethtool_sset(struct phy_device *phydev,
> struct ethtool_cmd *cmd);
> int phy_ethtool_gset(struct phy_device *phydev, struct ethtool_cmd *cmd);
> int phy_mii_ioctl(struct phy_device *phydev,
> struct ifreq *ifr, int cmd);
> +irqreturn_t do_phy_workqueue(int irq, struct phy_device *phydev);
> int phy_start_interrupts(struct phy_device *phydev);
> void phy_print_status(struct phy_device *phydev);
> void phy_device_free(struct phy_device *phydev);
> --
> 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
* Re: [PATCH] netfilter: xt_CT: remove a compile warning
From: Pablo Neira Ayuso @ 2012-04-03 9:35 UTC (permalink / raw)
To: Eric Dumazet; +Cc: David Miller, netdev
In-Reply-To: <1333441883.18626.60.camel@edumazet-glaptop>
On Tue, Apr 03, 2012 at 10:31:23AM +0200, Eric Dumazet wrote:
> On Tue, 2012-04-03 at 10:17 +0200, Pablo Neira Ayuso wrote:
> > On Tue, Apr 03, 2012 at 05:48:22AM +0200, Eric Dumazet wrote:
> > > If CONFIG_NF_CONNTRACK_TIMEOUT=n we have following warning :
> > >
> > > CC [M] net/netfilter/xt_CT.o
> > > net/netfilter/xt_CT.c: In function ‘xt_ct_tg_check_v1’:
> > > net/netfilter/xt_CT.c:284: warning: label ‘err4’ defined but not used
> >
> > Thanks Eric.
> >
> > I think I prefer the one attached.
> >
> > I 'll pass it to davem with a couple of other minor fixes anytime soon.
>
> Its your call, but you should move the whole
>
> #if CONFIG_NF_CONNTRACK_TIMEOUT
> ... lot of lines ...
> #endif
>
> in a helper function to make things a bit more maintainable
I will, thanks for the suggestion.
^ permalink raw reply
* Re: [PATCH 3.3.0 1/3] net:phy:bcm63xx: remove unnecessary code
From: Srinivas KANDAGATLA @ 2012-04-03 9:49 UTC (permalink / raw)
To: Joe Perches; +Cc: netdev, davem
In-Reply-To: <1333386157.15422.21.camel@joe2Laptop>
Yes, I have audited all the drivers. none of them return positive values.
In general, I think phy_write should return either 0 or an error code
and *NOT* positive values.
Any mdio bus driver returning positive values for phy_writes will break
the phylib too.
On 02/04/12 18:02, Joe Perches wrote:
> On Mon, 2012-04-02 at 17:51 +0100, Srinivas KANDAGATLA wrote:
>> On 02/04/12 17:42, Joe Perches wrote:
>>> On Mon, 2012-04-02 at 17:24 +0100, Srinivas KANDAGATLA wrote:
>>> Do these really make any functional difference?
>> No it does not make any functional difference.
>>> Doesn't the compiler generate the same output?
>> I think it will not generate same output.
> Yes, you are right. The code currently returns 0 for
> non-error cases and you've changed it to possibly
> return a positive value.
>
> Have you checked all the callers to make sure this
> doesn't introduce a new defect?
>
^ permalink raw reply
* Re: netlink: 12 bytes leftover after parsing attributes - triggered by iproute2 libnetlink's rtnl_dump_request()
From: Thomas Graf @ 2012-04-03 10:01 UTC (permalink / raw)
To: Stephen Hemminger; +Cc: Ben Hutchings, Bruno Prémont, netdev, Greg Rose
In-Reply-To: <20120320170229.49de95f5@nehalam.linuxnetplumber.net>
On Tue, Mar 20, 2012 at 05:02:29PM -0700, Stephen Hemminger wrote:
> On Tue, 20 Mar 2012 15:00:30 +0000
> Ben Hutchings <ben@decadent.org.uk> wrote:
>
> > On Tue, 2012-03-20 at 07:41 -0700, Stephen Hemminger wrote:
> > >
> > > >
> > > > Should this get fixed at kernel level, iproute2 libnetlink level or
> > > > at end-user level (e.g. collectd)?
> > > > Three lines every 10 seconds is a damn lot!
> > > >
> > > > Thanks,
> > > > Bruno
> > >
> > > Netlink is supposed to be encoded as Type-Length-Value and correctly written
> > > programs ignore types they don't understand. So either the library is getting
> > > confused by the type or the attribute is not encoded correctly.
> > >
> > >
> > > The issue could be in libnetlink library. What version of collectd and libnetlink
> > > are you using?
> >
> > This was also reported as provoked by a client using the ntrack
> > rtnetlink code: http://thread.gmane.org/gmane.linux.network/224236
Bruno,
Can you send a full bug report to libnl@lists.infradead.org and I'll make sure
this gets addressed in libnl.
^ permalink raw reply
* [PATCH net] bnx2x: correction to firmware interface
From: Yuval Mintz @ 2012-04-03 10:07 UTC (permalink / raw)
To: davem, netdev
Cc: Yuval Mintz, Dmitry Kravkov, Eilon Greenstein, Michael Chan,
Bhanu Prakash Gollapudi
Commit 621b4d6 updated the bnx2x driver to a new FW version, but lacked
a commit to a header file with changes to the firmware's interface.
The missing interface change causes iscsi and fcoe to misbehave with the
updated firmware.
Signed-off-by: Yuval Mintz <yuvalmin@broadcom.com>
Signed-off-by: Dmitry Kravkov <dmitry@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
CC: Michael Chan <mchan@broadcom.com>
CC: Bhanu Prakash Gollapudi <bprakash@broadcom.com>
---
Hi Dave,
Please consider applying this bug fix to 'net'.
Thanks,
Yuval
---
.../net/ethernet/broadcom/bnx2x/bnx2x_fw_defs.h | 110 ++++++++++----------
1 files changed, 55 insertions(+), 55 deletions(-)
diff --git a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_fw_defs.h b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_fw_defs.h
index cd6dfa9..b9b2633 100644
--- a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_fw_defs.h
+++ b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_fw_defs.h
@@ -25,31 +25,31 @@
(IRO[149].base + ((funcId) * IRO[149].m1))
#define CSTORM_IGU_MODE_OFFSET (IRO[157].base)
#define CSTORM_ISCSI_CQ_SIZE_OFFSET(pfId) \
- (IRO[315].base + ((pfId) * IRO[315].m1))
-#define CSTORM_ISCSI_CQ_SQN_SIZE_OFFSET(pfId) \
(IRO[316].base + ((pfId) * IRO[316].m1))
+#define CSTORM_ISCSI_CQ_SQN_SIZE_OFFSET(pfId) \
+ (IRO[317].base + ((pfId) * IRO[317].m1))
#define CSTORM_ISCSI_EQ_CONS_OFFSET(pfId, iscsiEqId) \
- (IRO[308].base + ((pfId) * IRO[308].m1) + ((iscsiEqId) * IRO[308].m2))
+ (IRO[309].base + ((pfId) * IRO[309].m1) + ((iscsiEqId) * IRO[309].m2))
#define CSTORM_ISCSI_EQ_NEXT_EQE_ADDR_OFFSET(pfId, iscsiEqId) \
- (IRO[310].base + ((pfId) * IRO[310].m1) + ((iscsiEqId) * IRO[310].m2))
+ (IRO[311].base + ((pfId) * IRO[311].m1) + ((iscsiEqId) * IRO[311].m2))
#define CSTORM_ISCSI_EQ_NEXT_PAGE_ADDR_OFFSET(pfId, iscsiEqId) \
- (IRO[309].base + ((pfId) * IRO[309].m1) + ((iscsiEqId) * IRO[309].m2))
+ (IRO[310].base + ((pfId) * IRO[310].m1) + ((iscsiEqId) * IRO[310].m2))
#define CSTORM_ISCSI_EQ_NEXT_PAGE_ADDR_VALID_OFFSET(pfId, iscsiEqId) \
- (IRO[311].base + ((pfId) * IRO[311].m1) + ((iscsiEqId) * IRO[311].m2))
+ (IRO[312].base + ((pfId) * IRO[312].m1) + ((iscsiEqId) * IRO[312].m2))
#define CSTORM_ISCSI_EQ_PROD_OFFSET(pfId, iscsiEqId) \
- (IRO[307].base + ((pfId) * IRO[307].m1) + ((iscsiEqId) * IRO[307].m2))
+ (IRO[308].base + ((pfId) * IRO[308].m1) + ((iscsiEqId) * IRO[308].m2))
#define CSTORM_ISCSI_EQ_SB_INDEX_OFFSET(pfId, iscsiEqId) \
- (IRO[313].base + ((pfId) * IRO[313].m1) + ((iscsiEqId) * IRO[313].m2))
+ (IRO[314].base + ((pfId) * IRO[314].m1) + ((iscsiEqId) * IRO[314].m2))
#define CSTORM_ISCSI_EQ_SB_NUM_OFFSET(pfId, iscsiEqId) \
- (IRO[312].base + ((pfId) * IRO[312].m1) + ((iscsiEqId) * IRO[312].m2))
+ (IRO[313].base + ((pfId) * IRO[313].m1) + ((iscsiEqId) * IRO[313].m2))
#define CSTORM_ISCSI_HQ_SIZE_OFFSET(pfId) \
- (IRO[314].base + ((pfId) * IRO[314].m1))
+ (IRO[315].base + ((pfId) * IRO[315].m1))
#define CSTORM_ISCSI_NUM_OF_TASKS_OFFSET(pfId) \
- (IRO[306].base + ((pfId) * IRO[306].m1))
+ (IRO[307].base + ((pfId) * IRO[307].m1))
#define CSTORM_ISCSI_PAGE_SIZE_LOG_OFFSET(pfId) \
- (IRO[305].base + ((pfId) * IRO[305].m1))
+ (IRO[306].base + ((pfId) * IRO[306].m1))
#define CSTORM_ISCSI_PAGE_SIZE_OFFSET(pfId) \
- (IRO[304].base + ((pfId) * IRO[304].m1))
+ (IRO[305].base + ((pfId) * IRO[305].m1))
#define CSTORM_RECORD_SLOW_PATH_OFFSET(funcId) \
(IRO[151].base + ((funcId) * IRO[151].m1))
#define CSTORM_SP_STATUS_BLOCK_DATA_OFFSET(pfId) \
@@ -96,37 +96,37 @@
#define TSTORM_FUNC_EN_OFFSET(funcId) \
(IRO[103].base + ((funcId) * IRO[103].m1))
#define TSTORM_ISCSI_ERROR_BITMAP_OFFSET(pfId) \
- (IRO[271].base + ((pfId) * IRO[271].m1))
-#define TSTORM_ISCSI_L2_ISCSI_OOO_CID_TABLE_OFFSET(pfId) \
(IRO[272].base + ((pfId) * IRO[272].m1))
-#define TSTORM_ISCSI_L2_ISCSI_OOO_CLIENT_ID_TABLE_OFFSET(pfId) \
+#define TSTORM_ISCSI_L2_ISCSI_OOO_CID_TABLE_OFFSET(pfId) \
(IRO[273].base + ((pfId) * IRO[273].m1))
-#define TSTORM_ISCSI_L2_ISCSI_OOO_PROD_OFFSET(pfId) \
+#define TSTORM_ISCSI_L2_ISCSI_OOO_CLIENT_ID_TABLE_OFFSET(pfId) \
(IRO[274].base + ((pfId) * IRO[274].m1))
+#define TSTORM_ISCSI_L2_ISCSI_OOO_PROD_OFFSET(pfId) \
+ (IRO[275].base + ((pfId) * IRO[275].m1))
#define TSTORM_ISCSI_NUM_OF_TASKS_OFFSET(pfId) \
- (IRO[270].base + ((pfId) * IRO[270].m1))
+ (IRO[271].base + ((pfId) * IRO[271].m1))
#define TSTORM_ISCSI_PAGE_SIZE_LOG_OFFSET(pfId) \
- (IRO[269].base + ((pfId) * IRO[269].m1))
+ (IRO[270].base + ((pfId) * IRO[270].m1))
#define TSTORM_ISCSI_PAGE_SIZE_OFFSET(pfId) \
- (IRO[268].base + ((pfId) * IRO[268].m1))
+ (IRO[269].base + ((pfId) * IRO[269].m1))
#define TSTORM_ISCSI_RQ_SIZE_OFFSET(pfId) \
- (IRO[267].base + ((pfId) * IRO[267].m1))
+ (IRO[268].base + ((pfId) * IRO[268].m1))
#define TSTORM_ISCSI_TCP_LOCAL_ADV_WND_OFFSET(pfId) \
- (IRO[276].base + ((pfId) * IRO[276].m1))
+ (IRO[277].base + ((pfId) * IRO[277].m1))
#define TSTORM_ISCSI_TCP_VARS_FLAGS_OFFSET(pfId) \
- (IRO[263].base + ((pfId) * IRO[263].m1))
-#define TSTORM_ISCSI_TCP_VARS_LSB_LOCAL_MAC_ADDR_OFFSET(pfId) \
(IRO[264].base + ((pfId) * IRO[264].m1))
-#define TSTORM_ISCSI_TCP_VARS_MID_LOCAL_MAC_ADDR_OFFSET(pfId) \
+#define TSTORM_ISCSI_TCP_VARS_LSB_LOCAL_MAC_ADDR_OFFSET(pfId) \
(IRO[265].base + ((pfId) * IRO[265].m1))
-#define TSTORM_ISCSI_TCP_VARS_MSB_LOCAL_MAC_ADDR_OFFSET(pfId) \
+#define TSTORM_ISCSI_TCP_VARS_MID_LOCAL_MAC_ADDR_OFFSET(pfId) \
(IRO[266].base + ((pfId) * IRO[266].m1))
+#define TSTORM_ISCSI_TCP_VARS_MSB_LOCAL_MAC_ADDR_OFFSET(pfId) \
+ (IRO[267].base + ((pfId) * IRO[267].m1))
#define TSTORM_MAC_FILTER_CONFIG_OFFSET(pfId) \
(IRO[202].base + ((pfId) * IRO[202].m1))
#define TSTORM_RECORD_SLOW_PATH_OFFSET(funcId) \
(IRO[105].base + ((funcId) * IRO[105].m1))
#define TSTORM_TCP_MAX_CWND_OFFSET(pfId) \
- (IRO[216].base + ((pfId) * IRO[216].m1))
+ (IRO[217].base + ((pfId) * IRO[217].m1))
#define TSTORM_VF_TO_PF_OFFSET(funcId) \
(IRO[104].base + ((funcId) * IRO[104].m1))
#define USTORM_AGG_DATA_OFFSET (IRO[206].base)
@@ -140,29 +140,29 @@
#define USTORM_ETH_PAUSE_ENABLED_OFFSET(portId) \
(IRO[183].base + ((portId) * IRO[183].m1))
#define USTORM_FCOE_EQ_PROD_OFFSET(pfId) \
- (IRO[317].base + ((pfId) * IRO[317].m1))
+ (IRO[318].base + ((pfId) * IRO[318].m1))
#define USTORM_FUNC_EN_OFFSET(funcId) \
(IRO[178].base + ((funcId) * IRO[178].m1))
#define USTORM_ISCSI_CQ_SIZE_OFFSET(pfId) \
- (IRO[281].base + ((pfId) * IRO[281].m1))
-#define USTORM_ISCSI_CQ_SQN_SIZE_OFFSET(pfId) \
(IRO[282].base + ((pfId) * IRO[282].m1))
+#define USTORM_ISCSI_CQ_SQN_SIZE_OFFSET(pfId) \
+ (IRO[283].base + ((pfId) * IRO[283].m1))
#define USTORM_ISCSI_ERROR_BITMAP_OFFSET(pfId) \
- (IRO[286].base + ((pfId) * IRO[286].m1))
+ (IRO[287].base + ((pfId) * IRO[287].m1))
#define USTORM_ISCSI_GLOBAL_BUF_PHYS_ADDR_OFFSET(pfId) \
- (IRO[283].base + ((pfId) * IRO[283].m1))
+ (IRO[284].base + ((pfId) * IRO[284].m1))
#define USTORM_ISCSI_NUM_OF_TASKS_OFFSET(pfId) \
- (IRO[279].base + ((pfId) * IRO[279].m1))
+ (IRO[280].base + ((pfId) * IRO[280].m1))
#define USTORM_ISCSI_PAGE_SIZE_LOG_OFFSET(pfId) \
- (IRO[278].base + ((pfId) * IRO[278].m1))
+ (IRO[279].base + ((pfId) * IRO[279].m1))
#define USTORM_ISCSI_PAGE_SIZE_OFFSET(pfId) \
- (IRO[277].base + ((pfId) * IRO[277].m1))
+ (IRO[278].base + ((pfId) * IRO[278].m1))
#define USTORM_ISCSI_R2TQ_SIZE_OFFSET(pfId) \
- (IRO[280].base + ((pfId) * IRO[280].m1))
+ (IRO[281].base + ((pfId) * IRO[281].m1))
#define USTORM_ISCSI_RQ_BUFFER_SIZE_OFFSET(pfId) \
- (IRO[284].base + ((pfId) * IRO[284].m1))
-#define USTORM_ISCSI_RQ_SIZE_OFFSET(pfId) \
(IRO[285].base + ((pfId) * IRO[285].m1))
+#define USTORM_ISCSI_RQ_SIZE_OFFSET(pfId) \
+ (IRO[286].base + ((pfId) * IRO[286].m1))
#define USTORM_MEM_WORKAROUND_ADDRESS_OFFSET(pfId) \
(IRO[182].base + ((pfId) * IRO[182].m1))
#define USTORM_RECORD_SLOW_PATH_OFFSET(funcId) \
@@ -188,39 +188,39 @@
#define XSTORM_FUNC_EN_OFFSET(funcId) \
(IRO[47].base + ((funcId) * IRO[47].m1))
#define XSTORM_ISCSI_HQ_SIZE_OFFSET(pfId) \
- (IRO[294].base + ((pfId) * IRO[294].m1))
+ (IRO[295].base + ((pfId) * IRO[295].m1))
#define XSTORM_ISCSI_LOCAL_MAC_ADDR0_OFFSET(pfId) \
- (IRO[297].base + ((pfId) * IRO[297].m1))
-#define XSTORM_ISCSI_LOCAL_MAC_ADDR1_OFFSET(pfId) \
(IRO[298].base + ((pfId) * IRO[298].m1))
-#define XSTORM_ISCSI_LOCAL_MAC_ADDR2_OFFSET(pfId) \
+#define XSTORM_ISCSI_LOCAL_MAC_ADDR1_OFFSET(pfId) \
(IRO[299].base + ((pfId) * IRO[299].m1))
-#define XSTORM_ISCSI_LOCAL_MAC_ADDR3_OFFSET(pfId) \
+#define XSTORM_ISCSI_LOCAL_MAC_ADDR2_OFFSET(pfId) \
(IRO[300].base + ((pfId) * IRO[300].m1))
-#define XSTORM_ISCSI_LOCAL_MAC_ADDR4_OFFSET(pfId) \
+#define XSTORM_ISCSI_LOCAL_MAC_ADDR3_OFFSET(pfId) \
(IRO[301].base + ((pfId) * IRO[301].m1))
-#define XSTORM_ISCSI_LOCAL_MAC_ADDR5_OFFSET(pfId) \
+#define XSTORM_ISCSI_LOCAL_MAC_ADDR4_OFFSET(pfId) \
(IRO[302].base + ((pfId) * IRO[302].m1))
-#define XSTORM_ISCSI_LOCAL_VLAN_OFFSET(pfId) \
+#define XSTORM_ISCSI_LOCAL_MAC_ADDR5_OFFSET(pfId) \
(IRO[303].base + ((pfId) * IRO[303].m1))
+#define XSTORM_ISCSI_LOCAL_VLAN_OFFSET(pfId) \
+ (IRO[304].base + ((pfId) * IRO[304].m1))
#define XSTORM_ISCSI_NUM_OF_TASKS_OFFSET(pfId) \
- (IRO[293].base + ((pfId) * IRO[293].m1))
+ (IRO[294].base + ((pfId) * IRO[294].m1))
#define XSTORM_ISCSI_PAGE_SIZE_LOG_OFFSET(pfId) \
- (IRO[292].base + ((pfId) * IRO[292].m1))
+ (IRO[293].base + ((pfId) * IRO[293].m1))
#define XSTORM_ISCSI_PAGE_SIZE_OFFSET(pfId) \
- (IRO[291].base + ((pfId) * IRO[291].m1))
+ (IRO[292].base + ((pfId) * IRO[292].m1))
#define XSTORM_ISCSI_R2TQ_SIZE_OFFSET(pfId) \
- (IRO[296].base + ((pfId) * IRO[296].m1))
+ (IRO[297].base + ((pfId) * IRO[297].m1))
#define XSTORM_ISCSI_SQ_SIZE_OFFSET(pfId) \
- (IRO[295].base + ((pfId) * IRO[295].m1))
+ (IRO[296].base + ((pfId) * IRO[296].m1))
#define XSTORM_ISCSI_TCP_VARS_ADV_WND_SCL_OFFSET(pfId) \
- (IRO[290].base + ((pfId) * IRO[290].m1))
+ (IRO[291].base + ((pfId) * IRO[291].m1))
#define XSTORM_ISCSI_TCP_VARS_FLAGS_OFFSET(pfId) \
- (IRO[289].base + ((pfId) * IRO[289].m1))
+ (IRO[290].base + ((pfId) * IRO[290].m1))
#define XSTORM_ISCSI_TCP_VARS_TOS_OFFSET(pfId) \
- (IRO[288].base + ((pfId) * IRO[288].m1))
+ (IRO[289].base + ((pfId) * IRO[289].m1))
#define XSTORM_ISCSI_TCP_VARS_TTL_OFFSET(pfId) \
- (IRO[287].base + ((pfId) * IRO[287].m1))
+ (IRO[288].base + ((pfId) * IRO[288].m1))
#define XSTORM_RATE_SHAPING_PER_VN_VARS_OFFSET(pfId) \
(IRO[44].base + ((pfId) * IRO[44].m1))
#define XSTORM_RECORD_SLOW_PATH_OFFSET(funcId) \
--
1.7.9.rc2
^ permalink raw reply related
* [PATCH 0/3] netfilter fixes for 3.4-rc1
From: pablo @ 2012-04-03 10:13 UTC (permalink / raw)
To: netdev; +Cc: davem
From: Pablo Neira Ayuso <pablo@netfilter.org>
[ This is a resent including netdev mailing list, sorry I forgot to include it ]
Hi David,
The following patches contain a couple of small fixes for Netfilter:
* One compilation warning fix for xt_LOG from Jan Beulich.
* Fix compilation issues of user-land ipset with kernel header file
from Jan Engelhardt via Jozsef Kadlecsik.
* Fix one compilation warning in the recent changes done in xt_CT to
support the extended cttimeout infrastracture, spotted by Eric
Dumazet.
You can pull them from:
git://1984.lsi.us.es/net master
Thanks!
Jan Beulich (1):
netfilter: xt_LOG: don't use xchg() for simple assignment
Jan Engelhardt (1):
netfilter: ipset: avoid use of kernel-only types
Pablo Neira Ayuso (1):
netfilter: xt_CT: remove a compile warning
include/linux/netfilter/xt_set.h | 4 ++--
include/net/netfilter/xt_log.h | 2 +-
net/netfilter/xt_CT.c | 2 ++
3 files changed, 5 insertions(+), 3 deletions(-)
--
1.7.2.5
^ permalink raw reply
* [PATCH 1/3] netfilter: xt_LOG: don't use xchg() for simple assignment
From: pablo @ 2012-04-03 10:13 UTC (permalink / raw)
To: netdev; +Cc: davem
In-Reply-To: <1333448001-2507-1-git-send-email-pablo@netfilter.org>
From: Jan Beulich <JBeulich@suse.com>
At least on ia64 the (bogus) use of xchg() here results in the compiler
warning about an unused expression result. As only an assignment is
intended here, convert it to such.
Signed-off-by: Jan Beulich <jbeulich@suse.com>
Acked-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
---
include/net/netfilter/xt_log.h | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/include/net/netfilter/xt_log.h b/include/net/netfilter/xt_log.h
index 7e1544e..9d9756c 100644
--- a/include/net/netfilter/xt_log.h
+++ b/include/net/netfilter/xt_log.h
@@ -47,7 +47,7 @@ static void sb_close(struct sbuff *m)
if (likely(m != &emergency))
kfree(m);
else {
- xchg(&emergency_ptr, m);
+ emergency_ptr = m;
local_bh_enable();
}
}
--
1.7.2.5
^ permalink raw reply related
* [PATCH 3/3] netfilter: xt_CT: remove a compile warning
From: pablo @ 2012-04-03 10:13 UTC (permalink / raw)
To: netdev; +Cc: davem
In-Reply-To: <1333448001-2507-1-git-send-email-pablo@netfilter.org>
From: Pablo Neira Ayuso <pablo@netfilter.org>
If CONFIG_NF_CONNTRACK_TIMEOUT=n we have following warning :
CC [M] net/netfilter/xt_CT.o
net/netfilter/xt_CT.c: In function ‘xt_ct_tg_check_v1’:
net/netfilter/xt_CT.c:284: warning: label ‘err4’ defined but not used
Reported-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
---
net/netfilter/xt_CT.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/net/netfilter/xt_CT.c b/net/netfilter/xt_CT.c
index 0c8e438..138b75e 100644
--- a/net/netfilter/xt_CT.c
+++ b/net/netfilter/xt_CT.c
@@ -281,8 +281,10 @@ out:
info->ct = ct;
return 0;
+#ifdef CONFIG_NF_CONNTRACK_TIMEOUT
err4:
rcu_read_unlock();
+#endif
err3:
nf_conntrack_free(ct);
err2:
--
1.7.2.5
^ permalink raw reply related
* [PATCH 2/3] netfilter: ipset: avoid use of kernel-only types
From: pablo @ 2012-04-03 10:13 UTC (permalink / raw)
To: netdev; +Cc: davem
In-Reply-To: <1333448001-2507-1-git-send-email-pablo@netfilter.org>
From: Jan Engelhardt <jengelh@medozas.de>
When using the xt_set.h header in userspace, one will get these gcc
reports:
ipset/ip_set.h:184:1: error: unknown type name "u16"
In file included from libxt_SET.c:21:0:
netfilter/xt_set.h:61:2: error: unknown type name "u32"
netfilter/xt_set.h:62:2: error: unknown type name "u32"
Signed-off-by: Jan Engelhardt <jengelh@medozas.de>
Signed-off-by: Jozsef Kadlecsik <kadlec@blackhole.kfki.hu>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
---
include/linux/netfilter/xt_set.h | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/include/linux/netfilter/xt_set.h b/include/linux/netfilter/xt_set.h
index c0405ac..e3a9978 100644
--- a/include/linux/netfilter/xt_set.h
+++ b/include/linux/netfilter/xt_set.h
@@ -58,8 +58,8 @@ struct xt_set_info_target_v1 {
struct xt_set_info_target_v2 {
struct xt_set_info add_set;
struct xt_set_info del_set;
- u32 flags;
- u32 timeout;
+ __u32 flags;
+ __u32 timeout;
};
#endif /*_XT_SET_H*/
--
1.7.2.5
^ permalink raw reply related
* Re: netlink: 12 bytes leftover after parsing attributes - triggered by iproute2 libnetlink's rtnl_dump_request()
From: Bruno Prémont @ 2012-04-03 10:17 UTC (permalink / raw)
To: Thomas Graf, libnl; +Cc: Stephen Hemminger, Ben Hutchings, netdev, Greg Rose
In-Reply-To: <20120403100157.GA8611@canuck.infradead.org>
[-- Attachment #1: Type: text/plain, Size: 4642 bytes --]
Thomas,
On Tue, 3 Apr 2012 06:01:57 Thomas Graf <tgraf@infradead.org> wrote:
> Can you send a full bug report to libnl@lists.infradead.org and I'll make sure
> this gets addressed in libnl.
Here it comes (mostly initial mail with some adjustments):
Starting with linux-3.3 when using collectd's netlink plugin to monitor
interface statistics I'm seeing 3 lines of complaint in kernel log per
monitoring loop (10s interval)
[64951.027953] netlink: 12 bytes leftover after parsing attributes.
The same userspace code running on 3.2 does not produce the lines in
kernel log.
Basic source code to reproduce (netlink subset of collectd's netlink plugin):
#include <stdio.h>
#include <string.h>
#include <sys/socket.h>
#include <linux/netlink.h>
#include <linux/rtnetlink.h>
#include <libnetlink.h>
int link_filter (const struct sockaddr_nl *sa, struct nlmsghdr *nmh, void *args) {
return 0; /* would present the data */
}
int main(int argc, char **argv) {
struct rtnl_handle rth;
struct ifinfomsg im;
struct tcmsg tm;
memset(&rth, 0, sizeof(rth));
rtnl_open(&rth, 0);
memset(&im, 0, sizeof(im));
im.ifi_type = AF_UNSPEC;
rtnl_dump_request(&rth, RTM_GETLINK, &im, sizeof(im));
rtnl_dump_filter(&rth, link_filter, NULL, NULL, NULL);
rtnl_close(&rth);
return 0;
}
Compile with
$CC -o test test.c -lnetlink
(here using libnetlink.a from iproute2-2.6.38)
Strace of test code shows the following:
sendmsg(3, {msg_name(12)={sa_family=AF_NETLINK, pid=0, groups=00000000}, msg_iov(2)=[{" \0\0\0\22\0\1\3\272[hO\0\0\0\0", 16}, {"\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0", 16}], msg_controllen=0, msg_flags=0}, 0) = 32
recvmsg(3, {msg_name(12)={sa_family=AF_NETLINK, pid=0, groups=00000000}, msg_iov(1)=[{..., 16384}], msg_controllen=0, msg_flags=0}, 0) = 2980
recvmsg(3, {msg_name(12)={sa_family=AF_NETLINK, pid=0, groups=00000000}, msg_iov(1)=[{..., 16384}], msg_controllen=0, msg_flags=0}, 0) = 20
Note: when omitting the rtnl_dump_filter() call only two lines appear
in kernel log.
Comparing to iproute2 call (ip -s link list) which does not trigger the same
message in kernel log I have:
send(3, "\24\0\0\0\22\0\1\3\225]hO\0\0\0\0\21\0\0\0", 20, 0) = 20
recvmsg(3, {msg_name(12)={sa_family=AF_NETLINK, pid=0, groups=00000000}, msg_iov(1)=[{..., 16384}], msg_controllen=0, msg_flags=0}, 0) = 2980
recvmsg(3, {msg_name(12)={sa_family=AF_NETLINK, pid=0, groups=00000000}, msg_iov(1)=[{..., 16384}], msg_controllen=0, msg_flags=0}, 0) = 20
Looking at kernel history related to net/netlink I've seen the following
commit which introduced the warning (or rather started using kernel's
nla_parse() function in this path - and that function complains):
commit 115c9b81928360d769a76c632bae62d15206a94a
Author: Greg Rose <gregory.v.rose@intel.com>
Date: Tue Feb 21 16:54:48 2012 -0500
rtnetlink: Fix problem with buffer allocation
Implement a new netlink attribute type IFLA_EXT_MASK. The mask
is a 32 bit value that can be used to indicate to the kernel that
certain extended ifinfo values are requested by the user application.
At this time the only mask value defined is RTEXT_FILTER_VF to
indicate that the user wants the ifinfo dump to send information
about the VFs belonging to the interface.
This patch fixes a bug in which certain applications do not have
large enough buffers to accommodate the extra information returned
by the kernel with large numbers of SR-IOV virtual functions.
Those applications will not send the new netlink attribute with
the interface info dump request netlink messages so they will
not get unexpectedly large request buffers returned by the kernel.
Modifies the rtnl_calcit function to traverse the list of net
devices and compute the minimum buffer size that can hold the
info dumps of all matching devices based upon the filter passed
in via the new netlink attribute filter mask. If no filter
mask is sent then the buffer allocation defaults to NLMSG_GOODSIZE.
With this change it is possible to add yet to be defined netlink
attributes to the dump request which should make it fairly extensible
in the future.
A kernel at preceding commit 84338a6c9dbb6ff3de4749864020f8f25d86fc81 (neighbour:
Fixed race condition at tbl->nht) does not show the log message,
starting with that commit the message appears.
A working adjustment to collectd (or above test code) is to call
rtnl_wilddump_request() instead of rtnl_dump_request() in order to
get the information.
rtnl_wilddump_request() is also the function used internally by iproute2's
ip command to fetch the data.
Bruno
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: collectd-netlink-kernwarn-fix.patch --]
[-- Type: text/x-patch, Size: 1650 bytes --]
Starting with linux-3.3-rc5 kernel at each interval netlink plugin triggers
three lines of kernel log:
netlink: 12 bytes leftover after parsing attributes.
Change the libnetlink function used to query link statistics to match
iproute2's behavior and thus not trip on the kernel's new parsing of
optional attributes for RTM_GETLINK.
While at it, also fix libnetlink's complaint to stderr:
!!!Deficit 16, rta_len=996
caused by incorrect calculation of msg_len.
Signed-off-by: Bruno Prémont <bonbons@linux-vserver.org>
---
This should get applied to 5.0 and 4.10 series!
The two hunks may get applied separately.
--- collectd-a/src/netlink.c 2012-03-21 19:20:15.304227640 +0100
+++ collectd-b/src/netlink.c 2012-03-21 19:21:20.454323202 +0100
@@ -223,7 +223,7 @@ static int link_filter (const struct soc
msg = NLMSG_DATA (nmh);
- msg_len = nmh->nlmsg_len - sizeof (struct ifinfomsg);
+ msg_len = nmh->nlmsg_len - NLMSG_LENGTH(sizeof (struct ifinfomsg));
if (msg_len < 0)
{
ERROR ("netlink plugin: link_filter: msg_len = %i < 0;", msg_len);
@@ -554,17 +554,13 @@ static int ir_init (void)
static int ir_read (void)
{
- struct ifinfomsg im;
struct tcmsg tm;
int ifindex;
static const int type_id[] = { RTM_GETQDISC, RTM_GETTCLASS, RTM_GETTFILTER };
static const char *type_name[] = { "qdisc", "class", "filter" };
- memset (&im, '\0', sizeof (im));
- im.ifi_type = AF_UNSPEC;
-
- if (rtnl_dump_request (&rth, RTM_GETLINK, &im, sizeof (im)) < 0)
+ if (rtnl_wilddump_request (&rth, AF_UNSPEC, RTM_GETLINK) < 0)
{
ERROR ("netlink plugin: ir_read: rtnl_dump_request failed.");
return (-1);
^ permalink raw reply
page: next (older) | prev (newer) | latest
- recent:[subjects (threaded)|topics (new)|topics (active)]
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox