Netdev List
 help / color / mirror / Atom feed
* Re: Bug#614622: linux-image-2.6.37-1-686: atl2 NIC claims NO CARRIER after suspend/resume; rmmod+insmod fixes the problem
From: Daniel Kahn Gillmor @ 2011-02-23  1:57 UTC (permalink / raw)
  To: Xiong Huang
  Cc: Ben Hutchings, Jay Cliburn, Chris Snook, 614622@bugs.debian.org,
	Cloud Ren, netdev
In-Reply-To: <0FBC7C9C2640634A8B837C2EFFCFF32F01837E4A63@SHEXMB-01.global.atheros.com>

[-- Attachment #1: Type: text/plain, Size: 590 bytes --]

Hi Xiong--

On 02/22/2011 08:38 PM, Xiong Huang wrote:
>    What I mean is to check if the cable link (you can check the peer link LED if your onboard NIC haven't) is ON.
> If the cable link is ON, we may focus on software layer :)

the peer (mini-switch) link LED stays off, regardless of unplug/replug
of the cable, power-cycling the mini-switch, or of tweaking the
interface via:

 ip link set eth0 down
 ip link set eth0 up

However, the peer link LED turns on immediately when i do:

 modprobe -v -r atl2
 modprobe -v atl2

hope this is useful info,

	--dkg




[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 1030 bytes --]

^ permalink raw reply

* Re: [PATCH v2] ipvs: unify the formula to estimate the overhead of processing connections
From: Wensong Zhang @ 2011-02-23  1:56 UTC (permalink / raw)
  To: Simon Horman
  Cc: Changli Gao, David S. Miller, Patrick McHardy, Julian Anastasov,
	netdev, lvs-devel, netfilter-devel
In-Reply-To: <20110222055553.GA4192@verge.net.au>

Sure, I am ok with this patch. Thanks!

On Tue, Feb 22, 2011 at 1:56 PM, Simon Horman <horms@verge.net.au> wrote:
> On Sat, Feb 19, 2011 at 05:32:28PM +0800, Changli Gao wrote:
>> lc and wlc use the same formula, but lblc and lblcr use another one. There
>> is no reason for using two different formulas for the lc variants.
>>
>> The formula used by lc is used by all the lc variants in this patch.
>
> Wensong, are you ok with this version of the patch?
>
>>
>> Signed-off-by: Changli Gao <xiaosuo@gmail.com>
>> ---
>> v2: use ip_vs_dest_conn_overhead() instead.
>>  include/net/ip_vs.h              |   14 ++++++++++++++
>>  net/netfilter/ipvs/ip_vs_lblc.c  |   13 +++----------
>>  net/netfilter/ipvs/ip_vs_lblcr.c |   25 +++++++------------------
>>  net/netfilter/ipvs/ip_vs_lc.c    |   18 +-----------------
>>  net/netfilter/ipvs/ip_vs_wlc.c   |   20 ++------------------
>>  5 files changed, 27 insertions(+), 63 deletions(-)
>> diff --git a/include/net/ip_vs.h b/include/net/ip_vs.h
>> index 5d75fea..e80ffb7 100644
>> --- a/include/net/ip_vs.h
>> +++ b/include/net/ip_vs.h
>> @@ -1241,6 +1241,20 @@ static inline void ip_vs_conn_drop_conntrack(struct ip_vs_conn *cp)
>>  /* CONFIG_IP_VS_NFCT */
>>  #endif
>>
>> +static inline unsigned int
>> +ip_vs_dest_conn_overhead(struct ip_vs_dest *dest)
>> +{
>> +     /*
>> +      * We think the overhead of processing active connections is 256
>> +      * times higher than that of inactive connections in average. (This
>> +      * 256 times might not be accurate, we will change it later) We
>> +      * use the following formula to estimate the overhead now:
>> +      *                dest->activeconns*256 + dest->inactconns
>> +      */
>> +     return (atomic_read(&dest->activeconns) << 8) +
>> +             atomic_read(&dest->inactconns);
>> +}
>> +
>>  #endif /* __KERNEL__ */
>>
>>  #endif       /* _NET_IP_VS_H */
>> diff --git a/net/netfilter/ipvs/ip_vs_lblc.c b/net/netfilter/ipvs/ip_vs_lblc.c
>> index 00b5ffa..58ae403 100644
>> --- a/net/netfilter/ipvs/ip_vs_lblc.c
>> +++ b/net/netfilter/ipvs/ip_vs_lblc.c
>> @@ -389,12 +389,7 @@ __ip_vs_lblc_schedule(struct ip_vs_service *svc)
>>       int loh, doh;
>>
>>       /*
>> -      * We think the overhead of processing active connections is fifty
>> -      * times higher than that of inactive connections in average. (This
>> -      * fifty times might not be accurate, we will change it later.) We
>> -      * use the following formula to estimate the overhead:
>> -      *                dest->activeconns*50 + dest->inactconns
>> -      * and the load:
>> +      * We use the following formula to estimate the load:
>>        *                (dest overhead) / dest->weight
>>        *
>>        * Remember -- no floats in kernel mode!!!
>> @@ -410,8 +405,7 @@ __ip_vs_lblc_schedule(struct ip_vs_service *svc)
>>                       continue;
>>               if (atomic_read(&dest->weight) > 0) {
>>                       least = dest;
>> -                     loh = atomic_read(&least->activeconns) * 50
>> -                             + atomic_read(&least->inactconns);
>> +                     loh = ip_vs_dest_conn_overhead(least);
>>                       goto nextstage;
>>               }
>>       }
>> @@ -425,8 +419,7 @@ __ip_vs_lblc_schedule(struct ip_vs_service *svc)
>>               if (dest->flags & IP_VS_DEST_F_OVERLOAD)
>>                       continue;
>>
>> -             doh = atomic_read(&dest->activeconns) * 50
>> -                     + atomic_read(&dest->inactconns);
>> +             doh = ip_vs_dest_conn_overhead(dest);
>>               if (loh * atomic_read(&dest->weight) >
>>                   doh * atomic_read(&least->weight)) {
>>                       least = dest;
>> diff --git a/net/netfilter/ipvs/ip_vs_lblcr.c b/net/netfilter/ipvs/ip_vs_lblcr.c
>> index bfa25f1..2ddefe8 100644
>> --- a/net/netfilter/ipvs/ip_vs_lblcr.c
>> +++ b/net/netfilter/ipvs/ip_vs_lblcr.c
>> @@ -178,8 +178,7 @@ static inline struct ip_vs_dest *ip_vs_dest_set_min(struct ip_vs_dest_set *set)
>>
>>               if ((atomic_read(&least->weight) > 0)
>>                   && (least->flags & IP_VS_DEST_F_AVAILABLE)) {
>> -                     loh = atomic_read(&least->activeconns) * 50
>> -                             + atomic_read(&least->inactconns);
>> +                     loh = ip_vs_dest_conn_overhead(least);
>>                       goto nextstage;
>>               }
>>       }
>> @@ -192,8 +191,7 @@ static inline struct ip_vs_dest *ip_vs_dest_set_min(struct ip_vs_dest_set *set)
>>               if (dest->flags & IP_VS_DEST_F_OVERLOAD)
>>                       continue;
>>
>> -             doh = atomic_read(&dest->activeconns) * 50
>> -                     + atomic_read(&dest->inactconns);
>> +             doh = ip_vs_dest_conn_overhead(dest);
>>               if ((loh * atomic_read(&dest->weight) >
>>                    doh * atomic_read(&least->weight))
>>                   && (dest->flags & IP_VS_DEST_F_AVAILABLE)) {
>> @@ -228,8 +226,7 @@ static inline struct ip_vs_dest *ip_vs_dest_set_max(struct ip_vs_dest_set *set)
>>       list_for_each_entry(e, &set->list, list) {
>>               most = e->dest;
>>               if (atomic_read(&most->weight) > 0) {
>> -                     moh = atomic_read(&most->activeconns) * 50
>> -                             + atomic_read(&most->inactconns);
>> +                     moh = ip_vs_dest_conn_overhead(most);
>>                       goto nextstage;
>>               }
>>       }
>> @@ -239,8 +236,7 @@ static inline struct ip_vs_dest *ip_vs_dest_set_max(struct ip_vs_dest_set *set)
>>    nextstage:
>>       list_for_each_entry(e, &set->list, list) {
>>               dest = e->dest;
>> -             doh = atomic_read(&dest->activeconns) * 50
>> -                     + atomic_read(&dest->inactconns);
>> +             doh = ip_vs_dest_conn_overhead(dest);
>>               /* moh/mw < doh/dw ==> moh*dw < doh*mw, where mw,dw>0 */
>>               if ((moh * atomic_read(&dest->weight) <
>>                    doh * atomic_read(&most->weight))
>> @@ -563,12 +559,7 @@ __ip_vs_lblcr_schedule(struct ip_vs_service *svc)
>>       int loh, doh;
>>
>>       /*
>> -      * We think the overhead of processing active connections is fifty
>> -      * times higher than that of inactive connections in average. (This
>> -      * fifty times might not be accurate, we will change it later.) We
>> -      * use the following formula to estimate the overhead:
>> -      *                dest->activeconns*50 + dest->inactconns
>> -      * and the load:
>> +      * We use the following formula to estimate the load:
>>        *                (dest overhead) / dest->weight
>>        *
>>        * Remember -- no floats in kernel mode!!!
>> @@ -585,8 +576,7 @@ __ip_vs_lblcr_schedule(struct ip_vs_service *svc)
>>
>>               if (atomic_read(&dest->weight) > 0) {
>>                       least = dest;
>> -                     loh = atomic_read(&least->activeconns) * 50
>> -                             + atomic_read(&least->inactconns);
>> +                     loh = ip_vs_dest_conn_overhead(least);
>>                       goto nextstage;
>>               }
>>       }
>> @@ -600,8 +590,7 @@ __ip_vs_lblcr_schedule(struct ip_vs_service *svc)
>>               if (dest->flags & IP_VS_DEST_F_OVERLOAD)
>>                       continue;
>>
>> -             doh = atomic_read(&dest->activeconns) * 50
>> -                     + atomic_read(&dest->inactconns);
>> +             doh = ip_vs_dest_conn_overhead(dest);
>>               if (loh * atomic_read(&dest->weight) >
>>                   doh * atomic_read(&least->weight)) {
>>                       least = dest;
>> diff --git a/net/netfilter/ipvs/ip_vs_lc.c b/net/netfilter/ipvs/ip_vs_lc.c
>> index 4f69db1..160cb80 100644
>> --- a/net/netfilter/ipvs/ip_vs_lc.c
>> +++ b/net/netfilter/ipvs/ip_vs_lc.c
>> @@ -22,22 +22,6 @@
>>
>>  #include <net/ip_vs.h>
>>
>> -
>> -static inline unsigned int
>> -ip_vs_lc_dest_overhead(struct ip_vs_dest *dest)
>> -{
>> -     /*
>> -      * We think the overhead of processing active connections is 256
>> -      * times higher than that of inactive connections in average. (This
>> -      * 256 times might not be accurate, we will change it later) We
>> -      * use the following formula to estimate the overhead now:
>> -      *                dest->activeconns*256 + dest->inactconns
>> -      */
>> -     return (atomic_read(&dest->activeconns) << 8) +
>> -             atomic_read(&dest->inactconns);
>> -}
>> -
>> -
>>  /*
>>   *   Least Connection scheduling
>>   */
>> @@ -62,7 +46,7 @@ ip_vs_lc_schedule(struct ip_vs_service *svc, const struct sk_buff *skb)
>>               if ((dest->flags & IP_VS_DEST_F_OVERLOAD) ||
>>                   atomic_read(&dest->weight) == 0)
>>                       continue;
>> -             doh = ip_vs_lc_dest_overhead(dest);
>> +             doh = ip_vs_dest_conn_overhead(dest);
>>               if (!least || doh < loh) {
>>                       least = dest;
>>                       loh = doh;
>> diff --git a/net/netfilter/ipvs/ip_vs_wlc.c b/net/netfilter/ipvs/ip_vs_wlc.c
>> index bbddfdb..db751f5 100644
>> --- a/net/netfilter/ipvs/ip_vs_wlc.c
>> +++ b/net/netfilter/ipvs/ip_vs_wlc.c
>> @@ -27,22 +27,6 @@
>>
>>  #include <net/ip_vs.h>
>>
>> -
>> -static inline unsigned int
>> -ip_vs_wlc_dest_overhead(struct ip_vs_dest *dest)
>> -{
>> -     /*
>> -      * We think the overhead of processing active connections is 256
>> -      * times higher than that of inactive connections in average. (This
>> -      * 256 times might not be accurate, we will change it later) We
>> -      * use the following formula to estimate the overhead now:
>> -      *                dest->activeconns*256 + dest->inactconns
>> -      */
>> -     return (atomic_read(&dest->activeconns) << 8) +
>> -             atomic_read(&dest->inactconns);
>> -}
>> -
>> -
>>  /*
>>   *   Weighted Least Connection scheduling
>>   */
>> @@ -71,7 +55,7 @@ ip_vs_wlc_schedule(struct ip_vs_service *svc, const struct sk_buff *skb)
>>               if (!(dest->flags & IP_VS_DEST_F_OVERLOAD) &&
>>                   atomic_read(&dest->weight) > 0) {
>>                       least = dest;
>> -                     loh = ip_vs_wlc_dest_overhead(least);
>> +                     loh = ip_vs_dest_conn_overhead(least);
>>                       goto nextstage;
>>               }
>>       }
>> @@ -85,7 +69,7 @@ ip_vs_wlc_schedule(struct ip_vs_service *svc, const struct sk_buff *skb)
>>       list_for_each_entry_continue(dest, &svc->destinations, n_list) {
>>               if (dest->flags & IP_VS_DEST_F_OVERLOAD)
>>                       continue;
>> -             doh = ip_vs_wlc_dest_overhead(dest);
>> +             doh = ip_vs_dest_conn_overhead(dest);
>>               if (loh * atomic_read(&dest->weight) >
>>                   doh * atomic_read(&least->weight)) {
>>                       least = dest;
>>
>
--
To unsubscribe from this list: send the line "unsubscribe netfilter-devel" 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: Bug#614622: linux-image-2.6.37-1-686: atl2 NIC claims NO CARRIER after suspend/resume; rmmod+insmod fixes the problem
From: Xiong Huang @ 2011-02-23  1:38 UTC (permalink / raw)
  To: Daniel Kahn Gillmor
  Cc: Ben Hutchings, Jay Cliburn, Chris Snook, 614622@bugs.debian.org,
	Cloud Ren, netdev
In-Reply-To: <4D64643C.1020001@fifthhorseman.net>

Hi Daniel

   What I mean is to check if the cable link (you can check the peer link LED if your onboard NIC haven't) is ON.
If the cable link is ON, we may focus on software layer :)

Thanks
Xiong
-----Original Message-----
From: Daniel Kahn Gillmor [mailto:dkg@fifthhorseman.net] 
Sent: Wednesday, February 23, 2011 9:35
To: Xiong Huang
Cc: Ben Hutchings; Jay Cliburn; Chris Snook; Jie Yang; 614622@bugs.debian.org; netdev
Subject: Re: Bug#614622: linux-image-2.6.37-1-686: atl2 NIC claims NO CARRIER after suspend/resume; rmmod+insmod fixes the problem

Hi Xiong,

On 02/22/2011 08:22 PM, Xiong Huang wrote:
> after the onboard NIC claims NO Carrier after resuming from suspend-to-RAM, how about it if unplug then re-plug the cable ?

i've tried that, and it is not sufficient to remove the NO CARRIER flag from the output of "ip link".  I've also tried power-cycling the 10/100 miniswitch on the other end of the ethernet cable, but no luck there either.

So far, the only thing i've found that clears the NO CARRIER state is to remove and re-insert atl2.ko.

I remain open to other suggestions.  And thanks for the speedy followup!

	--dkg


^ permalink raw reply

* Re: 2.6.37 regression: adding main interface to a bridge breaks vlan interface RX
From: Jesse Gross @ 2011-02-23  1:35 UTC (permalink / raw)
  To: chriss; +Cc: netdev
In-Reply-To: <loom.20110214T141934-88@post.gmane.org>

On Mon, Feb 14, 2011 at 5:22 AM, chriss <mail_to_chriss@gmx.net> wrote:
> Nicolas de Pesloüan <nicolas.2p.debian <at> gmail.com> writes:
>
>> I think you should have a look at ebtables command, in particular, the
> BROUTING chain of broute
>> table. If this chain ask the packet to be dropped, then bridge will ignore it
> and give a chance to
>> the upper layer to use it. Upper layer might be IP, or in your particular
> setup, VLAN.
>>
>> HTH,
>>
>>       Nicolas.
>
> Thank you very much for the ebtables hint.
>
> I also tried to add the vlan to my bridge device but only droping the vlan
> tagged paket with ebtables got it working.
>
> I'm not sure if this is the wanted behavior for bridging vlan actions.
> ..or my network setup is just to ..f%%%'ed up?!

It should work even without ebtables (running vlan on top of bridge,
not side by side).  I'll try to look at this in the next couple of
days.

^ permalink raw reply

* Bug#614622: linux-image-2.6.37-1-686: atl2 NIC claims NO CARRIER after suspend/resume; rmmod+insmod fixes the problem
From: Daniel Kahn Gillmor @ 2011-02-23  1:34 UTC (permalink / raw)
  To: Xiong Huang
  Cc: Ben Hutchings, Jay Cliburn, Chris Snook, Jie Yang,
	614622@bugs.debian.org, netdev
In-Reply-To: <0FBC7C9C2640634A8B837C2EFFCFF32F01837E4A48@SHEXMB-01.global.atheros.com>

[-- Attachment #1: Type: text/plain, Size: 605 bytes --]

Hi Xiong,

On 02/22/2011 08:22 PM, Xiong Huang wrote:
> after the onboard NIC claims NO Carrier after resuming from suspend-to-RAM, how about it if unplug then re-plug the cable ?

i've tried that, and it is not sufficient to remove the NO CARRIER flag
from the output of "ip link".  I've also tried power-cycling the 10/100
miniswitch on the other end of the ethernet cable, but no luck there either.

So far, the only thing i've found that clears the NO CARRIER state is to
remove and re-insert atl2.ko.

I remain open to other suggestions.  And thanks for the speedy followup!

	--dkg


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 1030 bytes --]

^ permalink raw reply

* Re: TX VLAN acceleration on bridges broken in 2.6.37?
From: Jesse Gross @ 2011-02-23  1:32 UTC (permalink / raw)
  To: Jan Niehusmann; +Cc: linux-kernel, netdev
In-Reply-To: <20110221232902.GA3440@x61s.reliablesolutions.de>

On Mon, Feb 21, 2011 at 3:29 PM, Jan Niehusmann <jan@gondor.com> wrote:
> With the following configuration, sending vlan tagged traffic from a
> bridged interface doesn't work in 2.6.37.
> The same configuration does work with 2.6.36:
>
> - bridge br0 with physical interface eth0
> - eth0 being an e1000e device (don't know if that's important)
> - vlan interface br0.10
> - (on 2.6.37) tx vlan acceleration active on br0 (default)
>
> Networking on br0.10 doesn't work, and tcpdump on eth0 shows packets
> sent on br0.10 as untagged, instead of vlan 10 tagged.
>
> After turning vlan tx offloading off with 'ethtool -K br0 txvlan off',
> everything works as expected, again.
>
> The workaround is made permanent by reverting "bridge: Add support for
> TX vlan offload.", 361ff8a6cf90d62c0071b7e532e37369bfd3ae77, turning
> of the feature on bridges completely.

I tested this at one point and it worked but it sounds like something
broke after that.  It's probably fairly simple, so I'd rather just fix
the problem instead of reverting the commit.  I'm just coming back
from vacation and am trying to catch up but I'll try to look at it in
the next couple of days.

^ permalink raw reply

* RE: Bug#614622: linux-image-2.6.37-1-686: atl2 NIC claims NO CARRIER after suspend/resume; rmmod+insmod fixes the problem
From: Xiong Huang @ 2011-02-23  1:22 UTC (permalink / raw)
  To: Ben Hutchings, Jay Cliburn, Chris Snook, Jie Yang
  Cc: 614622@bugs.debian.org, netdev, Daniel Kahn Gillmor
In-Reply-To: <1298423651.2211.496.camel@localhost>

after the onboard NIC claims NO Carrier after resuming from suspend-to-RAM, how about it if unplug then re-plug the cable ?


best regards
Xiong
-----Original Message-----
From: netdev-owner@vger.kernel.org [mailto:netdev-owner@vger.kernel.org] On Behalf Of Ben Hutchings
Sent: Wednesday, February 23, 2011 9:14
To: Jay Cliburn; Chris Snook; Jie Yang
Cc: 614622@bugs.debian.org; netdev; Daniel Kahn Gillmor
Subject: Re: Bug#614622: linux-image-2.6.37-1-686: atl2 NIC claims NO CARRIER after suspend/resume; rmmod+insmod fixes the problem

This bug report was made against Debian's package of Linux 2.6.37:

On Tue, 2011-02-22 at 13:08 -0500, Daniel Kahn Gillmor wrote:
> Package: linux-2.6
> Version: 2.6.37-1
> Severity: normal
> 
> I recently switched from 2.6.37-trunk-686 to 2.6.37-1-686.
> 
> after the switch, i find that sometimes my atl2.ko-driven onboard NIC 
> persistently claims NO CARRIER after resuming from suspend-to-RAM, 
> even when plugged into a legitimate ethernet port.  This is not 
> entirely reliable, but maybe 50% of the time.
> 
> if i remove and re-load atl2.ko, the interface can properly detect the 
> ethernet.
> 
> i'm happy to help debug this further if there is any information you 
> want me to gather on this hardware.  Please let me know.

I don't see any changes to this driver between 2.6.37-rc4 (the first version we built as '2.6.37-trunk-686') and 2.6.37, so I think Daniel just had good luck with the earlier versions.

> ** Kernel log:
[...]
> [67880.276036] PM: suspend of devices complete after 147.583 msecs 
> [67880.292274] PM: late suspend of devices complete after 16.227 msecs 
> [67880.292426] ACPI: Preparing to enter system sleep state S3 
> [67880.316648] PM: Saving platform NVS memory [67880.357927] Disabling 
> non-boot CPUs ...
> [67880.357927] Back to C!
> [67880.357927] PM: Restoring platform NVS memory [67880.357927] Force 
> enabled HPET at resume [67880.357927] ACPI: Waking up from system 
> sleep state S3 [67880.400865] HDA Intel 0000:00:1b.0: restoring config 
> space at offset 0x1 (was 0x100006, writing 0x100002) [67880.400904] 
> pci 0000:00:1c.0: restoring config space at offset 0x9 (was 0x1fff1, 
> writing 0x3fc13fb1) [67880.400913] pci 0000:00:1c.0: restoring config 
> space at offset 0x8 (was 0xfff0, writing 0x3fa03f90) [67880.400923] 
> pci 0000:00:1c.0: restoring config space at offset 0x7 (was 0xf0, 
> writing 0x1010) [67880.400937] pci 0000:00:1c.0: restoring config 
> space at offset 0x1 (was 0x100104, writing 0x100107) [67880.400976] 
> pci 0000:00:1c.1: restoring config space at offset 0x9 (was 0x1fff1, 
> writing 0x3fe13fd1) [67880.400987] pci 0000:00:1c.1: restoring config 
> space at offset 0x7 (was 0xf0, writing 0x2020) [67880.401001] pci 
> 0000:00:1c.1: restoring config space at offset 0x1 (was 0x100106, 
> writing 0x100107) [67880.401042] pci 0000:00:1c.2: restoring config 
> space at offset 0x7 (was 0xf0, writing 0x3030) [67880.401056] pci 
> 0000:00:1c.2: restoring config space at offset 0x1 (was 0x100106, 
> writing 0x100107) [67880.401099] uhci_hcd 0000:00:1d.0: restoring 
> config space at offset 0x1 (was 0x2800005, writing 0x2800001) 
> [67880.401132] uhci_hcd 0000:00:1d.1: restoring config space at offset 
> 0x1 (was 0x2800005, writing 0x2800001) [67880.401165] uhci_hcd 
> 0000:00:1d.2: restoring config space at offset 0x1 (was 0x2800005, 
> writing 0x2800001) [67880.401197] uhci_hcd 0000:00:1d.3: restoring 
> config space at offset 0x1 (was 0x2800005, writing 0x2800001) 
> [67880.401239] ehci_hcd 0000:00:1d.7: restoring config space at offset 
> 0x1 (was 0x2900006, writing 0x2900002) [67880.401265] pci 
> 0000:00:1e.0: restoring config space at offset 0xf (was 0x60000, 
> writing 0x600ff) [67880.401538] PM: early resume of devices complete 
> after 0.795 msecs [67880.406036] HDA Intel 0000:00:1b.0: PCI INT A -> 
> GSI 16 (level, low) -> IRQ 16 [67880.406048] HDA Intel 0000:00:1b.0: 
> setting latency timer to 64 [67880.406093] HDA Intel 0000:00:1b.0: irq 
> 40 for MSI/MSI-X [67880.406136] pci 0000:00:1c.0: PCI INT A -> GSI 16 
> (level, low) -> IRQ 16 [67880.406143] pci 0000:00:1c.0: setting 
> latency timer to 64 [67880.406156] pci 0000:00:1c.1: PCI INT B -> GSI 
> 17 (level, low) -> IRQ 17 [67880.406163] pci 0000:00:1c.1: setting 
> latency timer to 64 [67880.406176] pci 0000:00:1c.2: PCI INT C -> GSI 
> 18 (level, low) -> IRQ 18 [67880.406183] pci 0000:00:1c.2: setting 
> latency timer to 64 [67880.406198] uhci_hcd 0000:00:1d.0: PCI INT A -> 
> GSI 23 (level, low) -> IRQ 23 [67880.406208] uhci_hcd 0000:00:1d.0: 
> setting latency timer to 64 [67880.406234] usb usb2: root hub lost 
> power or was reset [67880.406253] uhci_hcd 0000:00:1d.1: PCI INT B -> 
> GSI 19 (level, low) -> IRQ 19 [67880.406262] uhci_hcd 0000:00:1d.1: 
> setting latency timer to 64 [67880.406287] usb usb3: root hub lost 
> power or was reset [67880.406303] uhci_hcd 0000:00:1d.2: PCI INT C -> 
> GSI 18 (level, low) -> IRQ 18 [67880.406313] uhci_hcd 0000:00:1d.2: 
> setting latency timer to 64 [67880.406337] usb usb4: root hub lost 
> power or was reset [67880.406354] uhci_hcd 0000:00:1d.3: PCI INT D -> 
> GSI 16 (level, low) -> IRQ 16 [67880.406363] uhci_hcd 0000:00:1d.3: 
> setting latency timer to 64 [67880.406387] usb usb5: root hub lost 
> power or was reset [67880.406405] ehci_hcd 0000:00:1d.7: PCI INT A -> 
> GSI 23 (level, low) -> IRQ 23 [67880.406415] ehci_hcd 0000:00:1d.7: 
> setting latency timer to 64 [67880.406486] pci 0000:00:1e.0: setting 
> latency timer to 64 [67880.406505] ata_piix 0000:00:1f.2: PCI INT B -> 
> GSI 19 (level, low) -> IRQ 19 [67880.406513] ata_piix 0000:00:1f.2: 
> setting latency timer to 64 [67880.406543] atl2 0000:03:00.0: PCI INT 
> A -> GSI 17 (level, low) -> IRQ 17 [67880.406551] atl2 0000:03:00.0: 
> setting latency timer to 64 [67880.411177] i915 0000:00:02.0: PCI INT 
> A -> GSI 16 (level, low) -> IRQ 16 [67880.411186] i915 0000:00:02.0: setting latency timer to 64 [67880.413110] sd 0:0:0:0: [sda] Starting disk [67880.652031] usb 1-5: reset high speed USB device using ehci_hcd and address 2 [67880.896031] usb 1-8: reset high speed USB device using ehci_hcd and address 3 [67882.532200] ata1.00: ACPI cmd ef/03:45:00:00:00:a0 (SET FEATURES) filtered out [67882.532209] ata1.00: ACPI cmd ef/03:0c:00:00:00:a0 (SET FEATURES) filtered out [67882.548191] ata1.00: configured for UDMA/133 [67882.548697] PM: resume of devices complete after 2147.034 msecs [67882.549278] PM: Finishing wakeup.
> [67882.549283] Restarting tasks ... done.
> [67882.549761] video LNXVIDEO:00: Restoring backlight state 
> [67882.980083] usb 3-2: new low speed USB device using uhci_hcd and 
> address 5 [67883.150414] atl2 0000:03:00.0: irq 41 for MSI/MSI-X 
> [67883.151364] ADDRCONF(NETDEV_UP): eth0: link is not ready 
> [67883.159163] usb 3-2: New USB device found, idVendor=0973, 
> idProduct=0001 [67883.159174] usb 3-2: New USB device strings: Mfr=1, 
> Product=2, SerialNumber=0 [67883.159181] usb 3-2: Product: 
> SchlumbergerSema Cryptoflex e-gate [67883.159187] usb 3-2: 
> Manufacturer: SchlumbergerSema

I assume this is where Daniel reloads the driver:

> [67977.344181] atl2 0000:03:00.0: PCI INT A disabled [67977.379792] 
> Atheros(R) L2 Ethernet Driver - version 2.2.3 [67977.379802] Copyright 
> (c) 2007 Atheros Corporation.
> [67977.379870] atl2 0000:03:00.0: PCI INT A -> GSI 17 (level, low) -> 
> IRQ 17 [67977.379892] atl2 0000:03:00.0: setting latency timer to 64 
> [67993.948723] atl2 0000:03:00.0: irq 41 for MSI/MSI-X [67993.949268] 
> ADDRCONF(NETDEV_UP): eth0: link is not ready [67994.154327] atl2: eth0 
> NIC Link is Up<100 Mbps Full Duplex> [67994.154739] 
> ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready

[...]
> ** PCI devices:
[...]
> 03:00.0 Ethernet controller [0200]: Atheros Communications L2 Fast Ethernet [1969:2048] (rev a0)
>         Subsystem: ASUSTeK Computer Inc. Device [1043:8233]
>         Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B- DisINTx+
>         Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort- <MAbort- >SERR- <PERR- INTx-
>         Latency: 0, Cache Line Size: 16 bytes
>         Interrupt: pin A routed to IRQ 41
>         Region 0: Memory at fbfc0000 (64-bit, non-prefetchable) [size=256K]
>         Expansion ROM at fbfa0000 [disabled] [size=128K]
>         Capabilities: <access denied>
>         Kernel driver in use: atl2
[...]

Ben.

--
Ben Hutchings
Once a job is fouled up, anything done to improve it makes it worse.

^ permalink raw reply

* [PATCH] e1000: power off PHY after reset when interface is down
From: prasanna.panchamukhi @ 2011-02-23  1:25 UTC (permalink / raw)
  To: bruce.w.allan, jeffrey.t.kirsher, jeffrey.e.pieper
  Cc: e1000-devel, netdev, prasanna.panchamukhi

From: Prasanna S. Panchamukhi <prasanna.panchamukhi@riverbed.com>

Some Phys supported by the e1000 driver do not remain powered off across
a reset of the device when the interface is down, e.g. on 82546.
This patch powers down (only when WoL is disabled) the PHY after reset if
the interface is down and ethtool diagnostics are not currently running.

Similar problem was see on 82571 controller and was fixed in e1000e driver
by Bruce Allan.
Please refer commit 31dbe5b4ac6fca72dec946e4d0fa7f0913f1d9b1 for details.

Signed-off-by: Prasanna S. Panchamukhi <prasanna.panchamukhi@riverbed.com>
---
 drivers/net/e1000/e1000_ethtool.c |   27 +++++++++++++++++++--------
 drivers/net/e1000/e1000_main.c    |    7 +++++++
 2 files changed, 26 insertions(+), 8 deletions(-)

diff --git a/drivers/net/e1000/e1000_ethtool.c b/drivers/net/e1000/e1000_ethtool.c
index f4d0922..d3f18f5 100644
--- a/drivers/net/e1000/e1000_ethtool.c
+++ b/drivers/net/e1000/e1000_ethtool.c
@@ -1554,6 +1554,15 @@ static void e1000_diag_test(struct net_device *netdev,
 	bool if_running = netif_running(netdev);
 
 	set_bit(__E1000_TESTING, &adapter->flags);
+
+	if (!if_running) {
+		e1000_power_up_phy(adapter);
+
+		adapter->hw.wait_autoneg_complete = 1;
+		e1000_reset(adapter);
+		adapter->hw.wait_autoneg_complete = 0;
+	}
+
 	if (eth_test->flags == ETH_TEST_FL_OFFLINE) {
 		/* Offline tests */
 
@@ -1572,8 +1581,6 @@ static void e1000_diag_test(struct net_device *netdev,
 		if (if_running)
 			/* indicate we're in test mode */
 			dev_close(netdev);
-		else
-			e1000_reset(adapter);
 
 		if (e1000_reg_test(adapter, &data[0]))
 			eth_test->flags |= ETH_TEST_FL_FAILED;
@@ -1587,8 +1594,6 @@ static void e1000_diag_test(struct net_device *netdev,
 			eth_test->flags |= ETH_TEST_FL_FAILED;
 
 		e1000_reset(adapter);
-		/* make sure the phy is powered up */
-		e1000_power_up_phy(adapter);
 		if (e1000_loopback_test(adapter, &data[3]))
 			eth_test->flags |= ETH_TEST_FL_FAILED;
 
@@ -1602,19 +1607,25 @@ static void e1000_diag_test(struct net_device *netdev,
 		if (if_running)
 			dev_open(netdev);
 	} else {
-		e_info(hw, "online testing starting\n");
 		/* Online tests */
-		if (e1000_link_test(adapter, &data[4]))
-			eth_test->flags |= ETH_TEST_FL_FAILED;
 
-		/* Online tests aren't run; pass by default */
+		e_info(hw, "online testing starting\n");
+
+		/* register, eeprom, intr and loopback tests not run online */
 		data[0] = 0;
 		data[1] = 0;
 		data[2] = 0;
 		data[3] = 0;
 
+		if (e1000_link_test(adapter, &data[4]))
+			eth_test->flags |= ETH_TEST_FL_FAILED;
+
 		clear_bit(__E1000_TESTING, &adapter->flags);
 	}
+
+	if (!if_running)
+		e1000_reset(adapter);
+
 	msleep_interruptible(4 * 1000);
 }
 
diff --git a/drivers/net/e1000/e1000_main.c b/drivers/net/e1000/e1000_main.c
index bfab140..beec573 100644
--- a/drivers/net/e1000/e1000_main.c
+++ b/drivers/net/e1000/e1000_main.c
@@ -704,6 +704,13 @@ void e1000_reset(struct e1000_adapter *adapter)
 	ew32(VET, ETHERNET_IEEE_VLAN_TYPE);
 
 	e1000_reset_adaptive(hw);
+
+	if (!netif_running(adapter->netdev) &&
+	    !test_bit(__E1000_TESTING, &adapter->flags)) {
+		e1000_power_down_phy(adapter);
+		return;
+	}
+
 	e1000_phy_get_info(hw, &adapter->phy_info);
 
 	e1000_release_manageability(adapter);
-- 
1.7.0.4


------------------------------------------------------------------------------
Free Software Download: Index, Search & Analyze Logs and other IT data in 
Real-Time with Splunk. Collect, index and harness all the fast moving IT data 
generated by your applications, servers and devices whether physical, virtual
or in the cloud. Deliver compliance at lower cost and gain new business 
insights. http://p.sf.net/sfu/splunk-dev2dev 
_______________________________________________
E1000-devel mailing list
E1000-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/e1000-devel
To learn more about Intel&#174; Ethernet, visit http://communities.intel.com/community/wired

^ permalink raw reply related

* Re: Bug#614622: linux-image-2.6.37-1-686: atl2 NIC claims NO CARRIER after suspend/resume; rmmod+insmod fixes the problem
From: Ben Hutchings @ 2011-02-23  1:14 UTC (permalink / raw)
  To: Jay Cliburn, Chris Snook, Jie Yang; +Cc: 614622, netdev, Daniel Kahn Gillmor
In-Reply-To: <20110222180821.5217.2375.reportbug@localhost.localdomain>

[-- Attachment #1: Type: text/plain, Size: 8043 bytes --]

This bug report was made against Debian's package of Linux 2.6.37:

On Tue, 2011-02-22 at 13:08 -0500, Daniel Kahn Gillmor wrote:
> Package: linux-2.6
> Version: 2.6.37-1
> Severity: normal
> 
> I recently switched from 2.6.37-trunk-686 to 2.6.37-1-686.
> 
> after the switch, i find that sometimes my atl2.ko-driven onboard NIC
> persistently claims NO CARRIER after resuming from suspend-to-RAM,
> even when plugged into a legitimate ethernet port.  This is not
> entirely reliable, but maybe 50% of the time.
> 
> if i remove and re-load atl2.ko, the interface can properly detect the
> ethernet.
> 
> i'm happy to help debug this further if there is any information you
> want me to gather on this hardware.  Please let me know.

I don't see any changes to this driver between 2.6.37-rc4 (the first
version we built as '2.6.37-trunk-686') and 2.6.37, so I think Daniel
just had good luck with the earlier versions.

> ** Kernel log:
[...]
> [67880.276036] PM: suspend of devices complete after 147.583 msecs
> [67880.292274] PM: late suspend of devices complete after 16.227 msecs
> [67880.292426] ACPI: Preparing to enter system sleep state S3
> [67880.316648] PM: Saving platform NVS memory
> [67880.357927] Disabling non-boot CPUs ...
> [67880.357927] Back to C!
> [67880.357927] PM: Restoring platform NVS memory
> [67880.357927] Force enabled HPET at resume
> [67880.357927] ACPI: Waking up from system sleep state S3
> [67880.400865] HDA Intel 0000:00:1b.0: restoring config space at offset 0x1 (was 0x100006, writing 0x100002)
> [67880.400904] pci 0000:00:1c.0: restoring config space at offset 0x9 (was 0x1fff1, writing 0x3fc13fb1)
> [67880.400913] pci 0000:00:1c.0: restoring config space at offset 0x8 (was 0xfff0, writing 0x3fa03f90)
> [67880.400923] pci 0000:00:1c.0: restoring config space at offset 0x7 (was 0xf0, writing 0x1010)
> [67880.400937] pci 0000:00:1c.0: restoring config space at offset 0x1 (was 0x100104, writing 0x100107)
> [67880.400976] pci 0000:00:1c.1: restoring config space at offset 0x9 (was 0x1fff1, writing 0x3fe13fd1)
> [67880.400987] pci 0000:00:1c.1: restoring config space at offset 0x7 (was 0xf0, writing 0x2020)
> [67880.401001] pci 0000:00:1c.1: restoring config space at offset 0x1 (was 0x100106, writing 0x100107)
> [67880.401042] pci 0000:00:1c.2: restoring config space at offset 0x7 (was 0xf0, writing 0x3030)
> [67880.401056] pci 0000:00:1c.2: restoring config space at offset 0x1 (was 0x100106, writing 0x100107)
> [67880.401099] uhci_hcd 0000:00:1d.0: restoring config space at offset 0x1 (was 0x2800005, writing 0x2800001)
> [67880.401132] uhci_hcd 0000:00:1d.1: restoring config space at offset 0x1 (was 0x2800005, writing 0x2800001)
> [67880.401165] uhci_hcd 0000:00:1d.2: restoring config space at offset 0x1 (was 0x2800005, writing 0x2800001)
> [67880.401197] uhci_hcd 0000:00:1d.3: restoring config space at offset 0x1 (was 0x2800005, writing 0x2800001)
> [67880.401239] ehci_hcd 0000:00:1d.7: restoring config space at offset 0x1 (was 0x2900006, writing 0x2900002)
> [67880.401265] pci 0000:00:1e.0: restoring config space at offset 0xf (was 0x60000, writing 0x600ff)
> [67880.401538] PM: early resume of devices complete after 0.795 msecs
> [67880.406036] HDA Intel 0000:00:1b.0: PCI INT A -> GSI 16 (level, low) -> IRQ 16
> [67880.406048] HDA Intel 0000:00:1b.0: setting latency timer to 64
> [67880.406093] HDA Intel 0000:00:1b.0: irq 40 for MSI/MSI-X
> [67880.406136] pci 0000:00:1c.0: PCI INT A -> GSI 16 (level, low) -> IRQ 16
> [67880.406143] pci 0000:00:1c.0: setting latency timer to 64
> [67880.406156] pci 0000:00:1c.1: PCI INT B -> GSI 17 (level, low) -> IRQ 17
> [67880.406163] pci 0000:00:1c.1: setting latency timer to 64
> [67880.406176] pci 0000:00:1c.2: PCI INT C -> GSI 18 (level, low) -> IRQ 18
> [67880.406183] pci 0000:00:1c.2: setting latency timer to 64
> [67880.406198] uhci_hcd 0000:00:1d.0: PCI INT A -> GSI 23 (level, low) -> IRQ 23
> [67880.406208] uhci_hcd 0000:00:1d.0: setting latency timer to 64
> [67880.406234] usb usb2: root hub lost power or was reset
> [67880.406253] uhci_hcd 0000:00:1d.1: PCI INT B -> GSI 19 (level, low) -> IRQ 19
> [67880.406262] uhci_hcd 0000:00:1d.1: setting latency timer to 64
> [67880.406287] usb usb3: root hub lost power or was reset
> [67880.406303] uhci_hcd 0000:00:1d.2: PCI INT C -> GSI 18 (level, low) -> IRQ 18
> [67880.406313] uhci_hcd 0000:00:1d.2: setting latency timer to 64
> [67880.406337] usb usb4: root hub lost power or was reset
> [67880.406354] uhci_hcd 0000:00:1d.3: PCI INT D -> GSI 16 (level, low) -> IRQ 16
> [67880.406363] uhci_hcd 0000:00:1d.3: setting latency timer to 64
> [67880.406387] usb usb5: root hub lost power or was reset
> [67880.406405] ehci_hcd 0000:00:1d.7: PCI INT A -> GSI 23 (level, low) -> IRQ 23
> [67880.406415] ehci_hcd 0000:00:1d.7: setting latency timer to 64
> [67880.406486] pci 0000:00:1e.0: setting latency timer to 64
> [67880.406505] ata_piix 0000:00:1f.2: PCI INT B -> GSI 19 (level, low) -> IRQ 19
> [67880.406513] ata_piix 0000:00:1f.2: setting latency timer to 64
> [67880.406543] atl2 0000:03:00.0: PCI INT A -> GSI 17 (level, low) -> IRQ 17
> [67880.406551] atl2 0000:03:00.0: setting latency timer to 64
> [67880.411177] i915 0000:00:02.0: PCI INT A -> GSI 16 (level, low) -> IRQ 16
> [67880.411186] i915 0000:00:02.0: setting latency timer to 64
> [67880.413110] sd 0:0:0:0: [sda] Starting disk
> [67880.652031] usb 1-5: reset high speed USB device using ehci_hcd and address 2
> [67880.896031] usb 1-8: reset high speed USB device using ehci_hcd and address 3
> [67882.532200] ata1.00: ACPI cmd ef/03:45:00:00:00:a0 (SET FEATURES) filtered out
> [67882.532209] ata1.00: ACPI cmd ef/03:0c:00:00:00:a0 (SET FEATURES) filtered out
> [67882.548191] ata1.00: configured for UDMA/133
> [67882.548697] PM: resume of devices complete after 2147.034 msecs
> [67882.549278] PM: Finishing wakeup.
> [67882.549283] Restarting tasks ... done.
> [67882.549761] video LNXVIDEO:00: Restoring backlight state
> [67882.980083] usb 3-2: new low speed USB device using uhci_hcd and address 5
> [67883.150414] atl2 0000:03:00.0: irq 41 for MSI/MSI-X
> [67883.151364] ADDRCONF(NETDEV_UP): eth0: link is not ready
> [67883.159163] usb 3-2: New USB device found, idVendor=0973, idProduct=0001
> [67883.159174] usb 3-2: New USB device strings: Mfr=1, Product=2, SerialNumber=0
> [67883.159181] usb 3-2: Product: SchlumbergerSema Cryptoflex e-gate
> [67883.159187] usb 3-2: Manufacturer: SchlumbergerSema

I assume this is where Daniel reloads the driver:

> [67977.344181] atl2 0000:03:00.0: PCI INT A disabled
> [67977.379792] Atheros(R) L2 Ethernet Driver - version 2.2.3
> [67977.379802] Copyright (c) 2007 Atheros Corporation.
> [67977.379870] atl2 0000:03:00.0: PCI INT A -> GSI 17 (level, low) -> IRQ 17
> [67977.379892] atl2 0000:03:00.0: setting latency timer to 64
> [67993.948723] atl2 0000:03:00.0: irq 41 for MSI/MSI-X
> [67993.949268] ADDRCONF(NETDEV_UP): eth0: link is not ready
> [67994.154327] atl2: eth0 NIC Link is Up<100 Mbps Full Duplex>
> [67994.154739] ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready

[...]
> ** PCI devices:
[...]
> 03:00.0 Ethernet controller [0200]: Atheros Communications L2 Fast Ethernet [1969:2048] (rev a0)
>         Subsystem: ASUSTeK Computer Inc. Device [1043:8233]
>         Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B- DisINTx+
>         Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort- <MAbort- >SERR- <PERR- INTx-
>         Latency: 0, Cache Line Size: 16 bytes
>         Interrupt: pin A routed to IRQ 41
>         Region 0: Memory at fbfc0000 (64-bit, non-prefetchable) [size=256K]
>         Expansion ROM at fbfa0000 [disabled] [size=128K]
>         Capabilities: <access denied>
>         Kernel driver in use: atl2
[...]

Ben.

-- 
Ben Hutchings
Once a job is fouled up, anything done to improve it makes it worse.

[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 828 bytes --]

^ permalink raw reply

* Re: [PATCH v2] ethtool : Add option -L | --set-common to set common flags.
From: Mahesh Bandewar @ 2011-02-23  0:41 UTC (permalink / raw)
  To: Ben Hutchings; +Cc: David Miller, Tom Herbert, Laurent Chavey, netdev
In-Reply-To: <1298304057.2608.39.camel@bwh-desktop>

That makes sense! The corresponding kernel patch -

http://patchwork.ozlabs.org/patch/77815/

is in RFC state. So what does that state mean?

Thanks,
--mahesh..

On Mon, Feb 21, 2011 at 8:00 AM, Ben Hutchings
<bhutchings@solarflare.com> wrote:
>
> On Tue, 2011-01-18 at 14:37 -0800, Mahesh Bandewar wrote:
> > This patch adds -L | --set-common option to add / remove common flags which
> > includes loopback flag. The -l | --show-common displays the current values
> > for these common flags.
> [...]
>
> I haven't forgotten this, but I won't apply it until the corresponding
> kernel change is applied.
>
> Ben.
>
> --
> Ben Hutchings, Senior Software Engineer, Solarflare Communications
> Not speaking for my employer; that's the marketing department's job.
> They asked us to note that Solarflare product names are trademarked.
>

^ permalink raw reply

* Re: [PATCH] ipvs: fix dst_lock locking on dest update
From: Simon Horman @ 2011-02-23  0:26 UTC (permalink / raw)
  To: Julian Anastasov; +Cc: David S. Miller, netdev, lvs-devel
In-Reply-To: <alpine.LFD.2.00.1102220949510.2388@ja.ssi.bg>

On Tue, Feb 22, 2011 at 10:40:25AM +0200, Julian Anastasov wrote:
> 
> 	Fix dst_lock usage in __ip_vs_update_dest. We need
> _bh locking because destination is updated in user context.
> Can cause lockups on frequent destination updates.
> Problem reported by Simon Kirby. Bug was introduced
> in 2.6.37 from the "ipvs: changes for local real server"
> change.
> 
> Signed-off-by: Julian Anastasov <ja@ssi.bg>

Acked-by: Simon Horman <horms@verge.net.au>

> ---
> 
> 	Dave, please apply to net-2.6.
> Patch is for 2.6.37+ and applies to 2.6.38-rc6. There is
> little fuzz when applying to net-next, let me know if
> I should provide patch for other trees.
> 
> --- linux-2.6.37/net/netfilter/ipvs/ip_vs_ctl.c	2011-01-06 00:01:23.600069161 +0200
> +++ linux/net/netfilter/ipvs/ip_vs_ctl.c	2011-02-19 23:14:44.463250743 +0200
> @@ -810,9 +810,9 @@ __ip_vs_update_dest(struct ip_vs_service
>  	dest->u_threshold = udest->u_threshold;
>  	dest->l_threshold = udest->l_threshold;
> 
> -	spin_lock(&dest->dst_lock);
> +	spin_lock_bh(&dest->dst_lock);
>  	ip_vs_dst_reset(dest);
> -	spin_unlock(&dest->dst_lock);
> +	spin_unlock_bh(&dest->dst_lock);
> 
>  	if (add)
>  		ip_vs_new_estimator(&dest->stats);
> 

^ permalink raw reply

* Re: net: update Documentation/networking/00-INDEX
From: Rob Landley @ 2011-02-23  0:09 UTC (permalink / raw)
  To: Randy Dunlap; +Cc: netdev, davem, Mariusz Kozlowski, LKML, linux-doc
In-Reply-To: <20110222142343.f3318134.rdunlap@xenotime.net>

On 02/22/2011 04:23 PM, Randy Dunlap wrote:
> From: Randy Dunlap <randy.dunlap@oracle.com>
> 
> Clean up entries in 00-INDEX: drop files that have been removed.
> 
> Reported-by: Rob Landley <rlandley@parallels.com>
> Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>

Acked-by: Rob Landley <rlandley@parallels.com>

^ permalink raw reply

* Re: [PATCH] ipvs: use hlist instead of list
From: Simon Horman @ 2011-02-22  6:45 UTC (permalink / raw)
  To: Changli Gao
  Cc: David S. Miller, Patrick McHardy, Wensong Zhang, Julian Anastasov,
	netdev, lvs-devel, netfilter-devel
In-Reply-To: <1298109908-29272-1-git-send-email-xiaosuo@gmail.com>

Thanks, I have queued this change.

On Sat, Feb 19, 2011 at 06:05:08PM +0800, Changli Gao wrote:
> Signed-off-by: Changli Gao <xiaosuo@gmail.com>
> ---
>  include/net/ip_vs.h             |    2 -
>  net/netfilter/ipvs/ip_vs_conn.c |   52 ++++++++++++++++++++++------------------
>  2 files changed, 30 insertions(+), 24 deletions(-)
> diff --git a/include/net/ip_vs.h b/include/net/ip_vs.h
> index e80ffb7..2078a47 100644
> --- a/include/net/ip_vs.h
> +++ b/include/net/ip_vs.h
> @@ -494,7 +494,7 @@ struct ip_vs_conn_param {
>   *	IP_VS structure allocated for each dynamically scheduled connection
>   */
>  struct ip_vs_conn {
> -	struct list_head        c_list;         /* hashed list heads */
> +	struct hlist_node	c_list;         /* hashed list heads */
>  #ifdef CONFIG_NET_NS
>  	struct net              *net;           /* Name space */
>  #endif
> diff --git a/net/netfilter/ipvs/ip_vs_conn.c b/net/netfilter/ipvs/ip_vs_conn.c
> index 83233fe..9c2a517 100644
> --- a/net/netfilter/ipvs/ip_vs_conn.c
> +++ b/net/netfilter/ipvs/ip_vs_conn.c
> @@ -59,7 +59,7 @@ static int ip_vs_conn_tab_mask __read_mostly;
>  /*
>   *  Connection hash table: for input and output packets lookups of IPVS
>   */
> -static struct list_head *ip_vs_conn_tab __read_mostly;
> +static struct hlist_head *ip_vs_conn_tab __read_mostly;
>  
>  /*  SLAB cache for IPVS connections */
>  static struct kmem_cache *ip_vs_conn_cachep __read_mostly;
> @@ -201,7 +201,7 @@ static inline int ip_vs_conn_hash(struct ip_vs_conn *cp)
>  	spin_lock(&cp->lock);
>  
>  	if (!(cp->flags & IP_VS_CONN_F_HASHED)) {
> -		list_add(&cp->c_list, &ip_vs_conn_tab[hash]);
> +		hlist_add_head(&cp->c_list, &ip_vs_conn_tab[hash]);
>  		cp->flags |= IP_VS_CONN_F_HASHED;
>  		atomic_inc(&cp->refcnt);
>  		ret = 1;
> @@ -234,7 +234,7 @@ static inline int ip_vs_conn_unhash(struct ip_vs_conn *cp)
>  	spin_lock(&cp->lock);
>  
>  	if (cp->flags & IP_VS_CONN_F_HASHED) {
> -		list_del(&cp->c_list);
> +		hlist_del(&cp->c_list);
>  		cp->flags &= ~IP_VS_CONN_F_HASHED;
>  		atomic_dec(&cp->refcnt);
>  		ret = 1;
> @@ -259,12 +259,13 @@ __ip_vs_conn_in_get(const struct ip_vs_conn_param *p)
>  {
>  	unsigned hash;
>  	struct ip_vs_conn *cp;
> +	struct hlist_node *n;
>  
>  	hash = ip_vs_conn_hashkey_param(p, false);
>  
>  	ct_read_lock(hash);
>  
> -	list_for_each_entry(cp, &ip_vs_conn_tab[hash], c_list) {
> +	hlist_for_each_entry(cp, n, &ip_vs_conn_tab[hash], c_list) {
>  		if (cp->af == p->af &&
>  		    p->cport == cp->cport && p->vport == cp->vport &&
>  		    ip_vs_addr_equal(p->af, p->caddr, &cp->caddr) &&
> @@ -345,12 +346,13 @@ struct ip_vs_conn *ip_vs_ct_in_get(const struct ip_vs_conn_param *p)
>  {
>  	unsigned hash;
>  	struct ip_vs_conn *cp;
> +	struct hlist_node *n;
>  
>  	hash = ip_vs_conn_hashkey_param(p, false);
>  
>  	ct_read_lock(hash);
>  
> -	list_for_each_entry(cp, &ip_vs_conn_tab[hash], c_list) {
> +	hlist_for_each_entry(cp, n, &ip_vs_conn_tab[hash], c_list) {
>  		if (!ip_vs_conn_net_eq(cp, p->net))
>  			continue;
>  		if (p->pe_data && p->pe->ct_match) {
> @@ -394,6 +396,7 @@ struct ip_vs_conn *ip_vs_conn_out_get(const struct ip_vs_conn_param *p)
>  {
>  	unsigned hash;
>  	struct ip_vs_conn *cp, *ret=NULL;
> +	struct hlist_node *n;
>  
>  	/*
>  	 *	Check for "full" addressed entries
> @@ -402,7 +405,7 @@ struct ip_vs_conn *ip_vs_conn_out_get(const struct ip_vs_conn_param *p)
>  
>  	ct_read_lock(hash);
>  
> -	list_for_each_entry(cp, &ip_vs_conn_tab[hash], c_list) {
> +	hlist_for_each_entry(cp, n, &ip_vs_conn_tab[hash], c_list) {
>  		if (cp->af == p->af &&
>  		    p->vport == cp->cport && p->cport == cp->dport &&
>  		    ip_vs_addr_equal(p->af, p->vaddr, &cp->caddr) &&
> @@ -818,7 +821,7 @@ ip_vs_conn_new(const struct ip_vs_conn_param *p,
>  		return NULL;
>  	}
>  
> -	INIT_LIST_HEAD(&cp->c_list);
> +	INIT_HLIST_NODE(&cp->c_list);
>  	setup_timer(&cp->timer, ip_vs_conn_expire, (unsigned long)cp);
>  	ip_vs_conn_net_set(cp, p->net);
>  	cp->af		   = p->af;
> @@ -894,8 +897,8 @@ ip_vs_conn_new(const struct ip_vs_conn_param *p,
>   */
>  #ifdef CONFIG_PROC_FS
>  struct ip_vs_iter_state {
> -	struct seq_net_private p;
> -	struct list_head *l;
> +	struct seq_net_private	p;
> +	struct hlist_head	*l;
>  };
>  
>  static void *ip_vs_conn_array(struct seq_file *seq, loff_t pos)
> @@ -903,13 +906,14 @@ static void *ip_vs_conn_array(struct seq_file *seq, loff_t pos)
>  	int idx;
>  	struct ip_vs_conn *cp;
>  	struct ip_vs_iter_state *iter = seq->private;
> +	struct hlist_node *n;
>  
>  	for (idx = 0; idx < ip_vs_conn_tab_size; idx++) {
>  		ct_read_lock_bh(idx);
> -		list_for_each_entry(cp, &ip_vs_conn_tab[idx], c_list) {
> +		hlist_for_each_entry(cp, n, &ip_vs_conn_tab[idx], c_list) {
>  			if (pos-- == 0) {
>  				iter->l = &ip_vs_conn_tab[idx];
> -			return cp;
> +				return cp;
>  			}
>  		}
>  		ct_read_unlock_bh(idx);
> @@ -930,7 +934,8 @@ static void *ip_vs_conn_seq_next(struct seq_file *seq, void *v, loff_t *pos)
>  {
>  	struct ip_vs_conn *cp = v;
>  	struct ip_vs_iter_state *iter = seq->private;
> -	struct list_head *e, *l = iter->l;
> +	struct hlist_node *e;
> +	struct hlist_head *l = iter->l;
>  	int idx;
>  
>  	++*pos;
> @@ -938,15 +943,15 @@ static void *ip_vs_conn_seq_next(struct seq_file *seq, void *v, loff_t *pos)
>  		return ip_vs_conn_array(seq, 0);
>  
>  	/* more on same hash chain? */
> -	if ((e = cp->c_list.next) != l)
> -		return list_entry(e, struct ip_vs_conn, c_list);
> +	if ((e = cp->c_list.next))
> +		return hlist_entry(e, struct ip_vs_conn, c_list);
>  
>  	idx = l - ip_vs_conn_tab;
>  	ct_read_unlock_bh(idx);
>  
>  	while (++idx < ip_vs_conn_tab_size) {
>  		ct_read_lock_bh(idx);
> -		list_for_each_entry(cp, &ip_vs_conn_tab[idx], c_list) {
> +		hlist_for_each_entry(cp, e, &ip_vs_conn_tab[idx], c_list) {
>  			iter->l = &ip_vs_conn_tab[idx];
>  			return cp;
>  		}
> @@ -959,7 +964,7 @@ static void *ip_vs_conn_seq_next(struct seq_file *seq, void *v, loff_t *pos)
>  static void ip_vs_conn_seq_stop(struct seq_file *seq, void *v)
>  {
>  	struct ip_vs_iter_state *iter = seq->private;
> -	struct list_head *l = iter->l;
> +	struct hlist_head *l = iter->l;
>  
>  	if (l)
>  		ct_read_unlock_bh(l - ip_vs_conn_tab);
> @@ -1148,13 +1153,14 @@ void ip_vs_random_dropentry(struct net *net)
>  	 */
>  	for (idx = 0; idx < (ip_vs_conn_tab_size>>5); idx++) {
>  		unsigned hash = net_random() & ip_vs_conn_tab_mask;
> +		struct hlist_node *n;
>  
>  		/*
>  		 *  Lock is actually needed in this loop.
>  		 */
>  		ct_write_lock_bh(hash);
>  
> -		list_for_each_entry(cp, &ip_vs_conn_tab[hash], c_list) {
> +		hlist_for_each_entry(cp, n, &ip_vs_conn_tab[hash], c_list) {
>  			if (cp->flags & IP_VS_CONN_F_TEMPLATE)
>  				/* connection template */
>  				continue;
> @@ -1202,12 +1208,14 @@ static void ip_vs_conn_flush(struct net *net)
>  
>  flush_again:
>  	for (idx = 0; idx < ip_vs_conn_tab_size; idx++) {
> +		struct hlist_node *n;
> +
>  		/*
>  		 *  Lock is actually needed in this loop.
>  		 */
>  		ct_write_lock_bh(idx);
>  
> -		list_for_each_entry(cp, &ip_vs_conn_tab[idx], c_list) {
> +		hlist_for_each_entry(cp, n, &ip_vs_conn_tab[idx], c_list) {
>  			if (!ip_vs_conn_net_eq(cp, net))
>  				continue;
>  			IP_VS_DBG(4, "del connection\n");
> @@ -1265,8 +1273,7 @@ int __init ip_vs_conn_init(void)
>  	/*
>  	 * Allocate the connection hash table and initialize its list heads
>  	 */
> -	ip_vs_conn_tab = vmalloc(ip_vs_conn_tab_size *
> -				 sizeof(struct list_head));
> +	ip_vs_conn_tab = vmalloc(ip_vs_conn_tab_size * sizeof(*ip_vs_conn_tab));
>  	if (!ip_vs_conn_tab)
>  		return -ENOMEM;
>  
> @@ -1286,9 +1293,8 @@ int __init ip_vs_conn_init(void)
>  	IP_VS_DBG(0, "Each connection entry needs %Zd bytes at least\n",
>  		  sizeof(struct ip_vs_conn));
>  
> -	for (idx = 0; idx < ip_vs_conn_tab_size; idx++) {
> -		INIT_LIST_HEAD(&ip_vs_conn_tab[idx]);
> -	}
> +	for (idx = 0; idx < ip_vs_conn_tab_size; idx++)
> +		INIT_HLIST_HEAD(&ip_vs_conn_tab[idx]);
>  
>  	for (idx = 0; idx < CT_LOCKARRAY_SIZE; idx++)  {
>  		rwlock_init(&__ip_vs_conntbl_lock_array[idx].l);
> --
> To unsubscribe from this list: send the line "unsubscribe lvs-devel" 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 v2] ipvs: unify the formula to estimate the overhead of processing connections
From: Simon Horman @ 2011-02-22  5:56 UTC (permalink / raw)
  To: Changli Gao
  Cc: David S. Miller, Patrick McHardy, Wensong Zhang, Julian Anastasov,
	netdev, lvs-devel, netfilter-devel
In-Reply-To: <1298107948-9224-1-git-send-email-xiaosuo@gmail.com>

On Sat, Feb 19, 2011 at 05:32:28PM +0800, Changli Gao wrote:
> lc and wlc use the same formula, but lblc and lblcr use another one. There
> is no reason for using two different formulas for the lc variants.
> 
> The formula used by lc is used by all the lc variants in this patch.

Wensong, are you ok with this version of the patch?

> 
> Signed-off-by: Changli Gao <xiaosuo@gmail.com>
> ---
> v2: use ip_vs_dest_conn_overhead() instead.
>  include/net/ip_vs.h              |   14 ++++++++++++++
>  net/netfilter/ipvs/ip_vs_lblc.c  |   13 +++----------
>  net/netfilter/ipvs/ip_vs_lblcr.c |   25 +++++++------------------
>  net/netfilter/ipvs/ip_vs_lc.c    |   18 +-----------------
>  net/netfilter/ipvs/ip_vs_wlc.c   |   20 ++------------------
>  5 files changed, 27 insertions(+), 63 deletions(-)
> diff --git a/include/net/ip_vs.h b/include/net/ip_vs.h
> index 5d75fea..e80ffb7 100644
> --- a/include/net/ip_vs.h
> +++ b/include/net/ip_vs.h
> @@ -1241,6 +1241,20 @@ static inline void ip_vs_conn_drop_conntrack(struct ip_vs_conn *cp)
>  /* CONFIG_IP_VS_NFCT */
>  #endif
>  
> +static inline unsigned int
> +ip_vs_dest_conn_overhead(struct ip_vs_dest *dest)
> +{
> +	/*
> +	 * We think the overhead of processing active connections is 256
> +	 * times higher than that of inactive connections in average. (This
> +	 * 256 times might not be accurate, we will change it later) We
> +	 * use the following formula to estimate the overhead now:
> +	 *		  dest->activeconns*256 + dest->inactconns
> +	 */
> +	return (atomic_read(&dest->activeconns) << 8) +
> +		atomic_read(&dest->inactconns);
> +}
> +
>  #endif /* __KERNEL__ */
>  
>  #endif	/* _NET_IP_VS_H */
> diff --git a/net/netfilter/ipvs/ip_vs_lblc.c b/net/netfilter/ipvs/ip_vs_lblc.c
> index 00b5ffa..58ae403 100644
> --- a/net/netfilter/ipvs/ip_vs_lblc.c
> +++ b/net/netfilter/ipvs/ip_vs_lblc.c
> @@ -389,12 +389,7 @@ __ip_vs_lblc_schedule(struct ip_vs_service *svc)
>  	int loh, doh;
>  
>  	/*
> -	 * We think the overhead of processing active connections is fifty
> -	 * times higher than that of inactive connections in average. (This
> -	 * fifty times might not be accurate, we will change it later.) We
> -	 * use the following formula to estimate the overhead:
> -	 *                dest->activeconns*50 + dest->inactconns
> -	 * and the load:
> +	 * We use the following formula to estimate the load:
>  	 *                (dest overhead) / dest->weight
>  	 *
>  	 * Remember -- no floats in kernel mode!!!
> @@ -410,8 +405,7 @@ __ip_vs_lblc_schedule(struct ip_vs_service *svc)
>  			continue;
>  		if (atomic_read(&dest->weight) > 0) {
>  			least = dest;
> -			loh = atomic_read(&least->activeconns) * 50
> -				+ atomic_read(&least->inactconns);
> +			loh = ip_vs_dest_conn_overhead(least);
>  			goto nextstage;
>  		}
>  	}
> @@ -425,8 +419,7 @@ __ip_vs_lblc_schedule(struct ip_vs_service *svc)
>  		if (dest->flags & IP_VS_DEST_F_OVERLOAD)
>  			continue;
>  
> -		doh = atomic_read(&dest->activeconns) * 50
> -			+ atomic_read(&dest->inactconns);
> +		doh = ip_vs_dest_conn_overhead(dest);
>  		if (loh * atomic_read(&dest->weight) >
>  		    doh * atomic_read(&least->weight)) {
>  			least = dest;
> diff --git a/net/netfilter/ipvs/ip_vs_lblcr.c b/net/netfilter/ipvs/ip_vs_lblcr.c
> index bfa25f1..2ddefe8 100644
> --- a/net/netfilter/ipvs/ip_vs_lblcr.c
> +++ b/net/netfilter/ipvs/ip_vs_lblcr.c
> @@ -178,8 +178,7 @@ static inline struct ip_vs_dest *ip_vs_dest_set_min(struct ip_vs_dest_set *set)
>  
>  		if ((atomic_read(&least->weight) > 0)
>  		    && (least->flags & IP_VS_DEST_F_AVAILABLE)) {
> -			loh = atomic_read(&least->activeconns) * 50
> -				+ atomic_read(&least->inactconns);
> +			loh = ip_vs_dest_conn_overhead(least);
>  			goto nextstage;
>  		}
>  	}
> @@ -192,8 +191,7 @@ static inline struct ip_vs_dest *ip_vs_dest_set_min(struct ip_vs_dest_set *set)
>  		if (dest->flags & IP_VS_DEST_F_OVERLOAD)
>  			continue;
>  
> -		doh = atomic_read(&dest->activeconns) * 50
> -			+ atomic_read(&dest->inactconns);
> +		doh = ip_vs_dest_conn_overhead(dest);
>  		if ((loh * atomic_read(&dest->weight) >
>  		     doh * atomic_read(&least->weight))
>  		    && (dest->flags & IP_VS_DEST_F_AVAILABLE)) {
> @@ -228,8 +226,7 @@ static inline struct ip_vs_dest *ip_vs_dest_set_max(struct ip_vs_dest_set *set)
>  	list_for_each_entry(e, &set->list, list) {
>  		most = e->dest;
>  		if (atomic_read(&most->weight) > 0) {
> -			moh = atomic_read(&most->activeconns) * 50
> -				+ atomic_read(&most->inactconns);
> +			moh = ip_vs_dest_conn_overhead(most);
>  			goto nextstage;
>  		}
>  	}
> @@ -239,8 +236,7 @@ static inline struct ip_vs_dest *ip_vs_dest_set_max(struct ip_vs_dest_set *set)
>    nextstage:
>  	list_for_each_entry(e, &set->list, list) {
>  		dest = e->dest;
> -		doh = atomic_read(&dest->activeconns) * 50
> -			+ atomic_read(&dest->inactconns);
> +		doh = ip_vs_dest_conn_overhead(dest);
>  		/* moh/mw < doh/dw ==> moh*dw < doh*mw, where mw,dw>0 */
>  		if ((moh * atomic_read(&dest->weight) <
>  		     doh * atomic_read(&most->weight))
> @@ -563,12 +559,7 @@ __ip_vs_lblcr_schedule(struct ip_vs_service *svc)
>  	int loh, doh;
>  
>  	/*
> -	 * We think the overhead of processing active connections is fifty
> -	 * times higher than that of inactive connections in average. (This
> -	 * fifty times might not be accurate, we will change it later.) We
> -	 * use the following formula to estimate the overhead:
> -	 *                dest->activeconns*50 + dest->inactconns
> -	 * and the load:
> +	 * We use the following formula to estimate the load:
>  	 *                (dest overhead) / dest->weight
>  	 *
>  	 * Remember -- no floats in kernel mode!!!
> @@ -585,8 +576,7 @@ __ip_vs_lblcr_schedule(struct ip_vs_service *svc)
>  
>  		if (atomic_read(&dest->weight) > 0) {
>  			least = dest;
> -			loh = atomic_read(&least->activeconns) * 50
> -				+ atomic_read(&least->inactconns);
> +			loh = ip_vs_dest_conn_overhead(least);
>  			goto nextstage;
>  		}
>  	}
> @@ -600,8 +590,7 @@ __ip_vs_lblcr_schedule(struct ip_vs_service *svc)
>  		if (dest->flags & IP_VS_DEST_F_OVERLOAD)
>  			continue;
>  
> -		doh = atomic_read(&dest->activeconns) * 50
> -			+ atomic_read(&dest->inactconns);
> +		doh = ip_vs_dest_conn_overhead(dest);
>  		if (loh * atomic_read(&dest->weight) >
>  		    doh * atomic_read(&least->weight)) {
>  			least = dest;
> diff --git a/net/netfilter/ipvs/ip_vs_lc.c b/net/netfilter/ipvs/ip_vs_lc.c
> index 4f69db1..160cb80 100644
> --- a/net/netfilter/ipvs/ip_vs_lc.c
> +++ b/net/netfilter/ipvs/ip_vs_lc.c
> @@ -22,22 +22,6 @@
>  
>  #include <net/ip_vs.h>
>  
> -
> -static inline unsigned int
> -ip_vs_lc_dest_overhead(struct ip_vs_dest *dest)
> -{
> -	/*
> -	 * We think the overhead of processing active connections is 256
> -	 * times higher than that of inactive connections in average. (This
> -	 * 256 times might not be accurate, we will change it later) We
> -	 * use the following formula to estimate the overhead now:
> -	 *		  dest->activeconns*256 + dest->inactconns
> -	 */
> -	return (atomic_read(&dest->activeconns) << 8) +
> -		atomic_read(&dest->inactconns);
> -}
> -
> -
>  /*
>   *	Least Connection scheduling
>   */
> @@ -62,7 +46,7 @@ ip_vs_lc_schedule(struct ip_vs_service *svc, const struct sk_buff *skb)
>  		if ((dest->flags & IP_VS_DEST_F_OVERLOAD) ||
>  		    atomic_read(&dest->weight) == 0)
>  			continue;
> -		doh = ip_vs_lc_dest_overhead(dest);
> +		doh = ip_vs_dest_conn_overhead(dest);
>  		if (!least || doh < loh) {
>  			least = dest;
>  			loh = doh;
> diff --git a/net/netfilter/ipvs/ip_vs_wlc.c b/net/netfilter/ipvs/ip_vs_wlc.c
> index bbddfdb..db751f5 100644
> --- a/net/netfilter/ipvs/ip_vs_wlc.c
> +++ b/net/netfilter/ipvs/ip_vs_wlc.c
> @@ -27,22 +27,6 @@
>  
>  #include <net/ip_vs.h>
>  
> -
> -static inline unsigned int
> -ip_vs_wlc_dest_overhead(struct ip_vs_dest *dest)
> -{
> -	/*
> -	 * We think the overhead of processing active connections is 256
> -	 * times higher than that of inactive connections in average. (This
> -	 * 256 times might not be accurate, we will change it later) We
> -	 * use the following formula to estimate the overhead now:
> -	 *		  dest->activeconns*256 + dest->inactconns
> -	 */
> -	return (atomic_read(&dest->activeconns) << 8) +
> -		atomic_read(&dest->inactconns);
> -}
> -
> -
>  /*
>   *	Weighted Least Connection scheduling
>   */
> @@ -71,7 +55,7 @@ ip_vs_wlc_schedule(struct ip_vs_service *svc, const struct sk_buff *skb)
>  		if (!(dest->flags & IP_VS_DEST_F_OVERLOAD) &&
>  		    atomic_read(&dest->weight) > 0) {
>  			least = dest;
> -			loh = ip_vs_wlc_dest_overhead(least);
> +			loh = ip_vs_dest_conn_overhead(least);
>  			goto nextstage;
>  		}
>  	}
> @@ -85,7 +69,7 @@ ip_vs_wlc_schedule(struct ip_vs_service *svc, const struct sk_buff *skb)
>  	list_for_each_entry_continue(dest, &svc->destinations, n_list) {
>  		if (dest->flags & IP_VS_DEST_F_OVERLOAD)
>  			continue;
> -		doh = ip_vs_wlc_dest_overhead(dest);
> +		doh = ip_vs_dest_conn_overhead(dest);
>  		if (loh * atomic_read(&dest->weight) >
>  		    doh * atomic_read(&least->weight)) {
>  			least = dest;
> 

^ permalink raw reply

* net: update Documentation/networking/00-INDEX
From: Randy Dunlap @ 2011-02-22 22:23 UTC (permalink / raw)
  To: netdev, davem; +Cc: Rob Landley, Mariusz Kozlowski, LKML, linux-doc
In-Reply-To: <20110221120303.48106f6c.rdunlap@xenotime.net>

From: Randy Dunlap <randy.dunlap@oracle.com>

Clean up entries in 00-INDEX: drop files that have been removed.

Reported-by: Rob Landley <rlandley@parallels.com>
Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
---
 Documentation/networking/00-INDEX |    6 ------
 1 file changed, 6 deletions(-)

--- linux-next-20110222.orig/Documentation/networking/00-INDEX
+++ linux-next-20110222/Documentation/networking/00-INDEX
@@ -40,8 +40,6 @@ decnet.txt
 	- info on using the DECnet networking layer in Linux.
 depca.txt
 	- the Digital DEPCA/EtherWORKS DE1?? and DE2?? LANCE Ethernet driver
-dgrs.txt
-	- the Digi International RightSwitch SE-X Ethernet driver
 dmfe.txt
 	- info on the Davicom DM9102(A)/DM9132/DM9801 fast ethernet driver.
 e100.txt
@@ -50,8 +48,6 @@ e1000.txt
 	- info on Intel's E1000 line of gigabit ethernet boards
 eql.txt
 	- serial IP load balancing
-ethertap.txt
-	- the Ethertap user space packet reception and transmission driver
 ewrk3.txt
 	- the Digital EtherWORKS 3 DE203/4/5 Ethernet driver
 filter.txt
@@ -104,8 +100,6 @@ tuntap.txt
 	- TUN/TAP device driver, allowing user space Rx/Tx of packets.
 vortex.txt
 	- info on using 3Com Vortex (3c590, 3c592, 3c595, 3c597) Ethernet cards.
-wavelan.txt
-	- AT&T GIS (nee NCR) WaveLAN card: An Ethernet-like radio transceiver
 x25.txt
 	- general info on X.25 development.
 x25-iface.txt

^ permalink raw reply

* Re: [PATCH] ax88796: depend on HAS_IOMEM not on individual ARCHs
From: David Miller @ 2011-02-22 22:01 UTC (permalink / raw)
  To: mkl; +Cc: netdev
In-Reply-To: <4D642DC6.2010307@pengutronix.de>

From: Marc Kleine-Budde <mkl@pengutronix.de>
Date: Tue, 22 Feb 2011 22:42:30 +0100

> On 02/22/2011 09:37 PM, David Miller wrote:
>> I know it's going to cause allmodconfig build errors on sparc64,
>> for example.
> 
> How to fix?
>> drivers/net/ax88796.c:195: error: implicit declaration of function 'readsw'
>> drivers/net/ax88796.c:198: error: implicit declaration of function 'readsb'
> 
> Use "ioreadX_rep" or add a "!SPARC64" to Kconfig?

Make sparc64 provide the necessary interface.

^ permalink raw reply

* pull request: wireless-next-2.6 2011-02-22
From: John W. Linville @ 2011-02-22 21:52 UTC (permalink / raw)
  To: davem; +Cc: linux-wireless, netdev

Dave,

Here is the latest batch of wireless bits intended for 2.6.39.  It seems
I neglected to send a pull request last week, so this one is a bit big
-- I apologize!

This includes a rather large batch of bluetooth bits by way of Gustavo.
It looks like a variety of bits, including some code refactoring, some
protocol support enhancements, some bugfixes, etc. -- nothing too
unusual.

Other items of interest include a new driver from Realtek, some ssb
support enhancements, and the usual sort of updates for mac80211 and a
variety of drivers.  Also included is a wireless-2.6 pull to resolve
some build breakage.

Please let me know if there are problems!

John

---

The following changes since commit db62983a1e4b2af9e79c97af768f0c8b80bd93f0:

  Merge branch 'net/ax88796' of git://git.pengutronix.de/git/mkl/linux-2.6 (2011-02-22 11:15:29 -0800)

are available in the git repository at:

  git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-next-2.6.git for-davem

Andrei Emeltchenko (3):
      Bluetooth: Use non-flushable by default L2CAP data packets
      Bluetooth: Do not use assignments in IF conditions
      Bluetooth: fix crash by disabling tasklet in sock accept

Andrei Warkentin (1):
      Bluetooth: Make hci a child of the corresponding tty device.

Bala Shanmugam (1):
      Bluetooth: Add firmware support for Atheros 3012

Ben Greear (7):
      ath9k: Print channel-type in chan-change dbg message.
      mac80211: Properly set work-item channel-type.
      mac80211: Allow scanning on existing channel-type.
      mac80211: Allow work items to use existing channel type.
      ath9k: Add debug info for configuring power level.
      mac80211: Ensure power-level set properly for scanning.
      mac80211: Add power to debugfs.

Bob Copeland (1):
      ath5k: move external function definitions to a header file

Cho, Yu-Chen (1):
      Bluetooth: Add Atheros BT AR5BBU12 fw supported

Christian Lamparter (6):
      p54: sort channel list by frequency instead of channel index
      p54: p54_generate_band cleanup
      p54: enhance rssi->dBm database import
      p54spi: update sample eeprom
      p54: implement flush callback
      ar9170usb: mark the old driver as obsolete

Claudio Takahasi (3):
      Bluetooth: Add LE signaling commands handling
      Bluetooth: Add connection parameter update response
      Bluetooth: Send LE Connection Update Command

Eliad Peller (4):
      wl12xx: mcp2.5 - add config_ps acx
      wl12xx: move to new firmware (6.1.3.50.49)
      wl12xx: use the conf struct instead of macros for memory configuration
      wl12xx: set supported_rates after association

George (9):
      rtlwifi: Add usb driver
      rtlwifi: Add headers for rtl8187cu
      rtlwifi: rtl8192cu: Add routines dm, fw, led and sw
      rtlwifi: rtl8192cu: Add routine hw
      rtlwifi: rtl8192cu: Add routine mac
      rtlwifi: rtl8192cu: Add routine phy
      rtlwifi: rtl8192cu: Add routine rf
      rtlwifi: rtl8192cu: Add routine table
      rtlwifi: rtl8192cu: Add routine trx

Gustavo F. Padovan (27):
      Merge branch 'master' of git://git.kernel.org/.../padovan/bluetooth-2.6 into wireless
      Bluetooth: Fix setting of MTU for ERTM and Streaming Mode
      Bluetooth: Rename l2cap.c to l2cap_core.c
      Bluetooth: Initial work for L2CAP split.
      Bluetooth: move l2cap_sock_ops to l2cap_sock.c
      Bluetooth: move l2cap_sock_release() to l2cap_sock.c
      Bluetooth: move l2cap_sock_bind()/listen() to l2cap_sock.c
      Bluetooth: move l2cap_sock_accept() to l2cap_sock.c
      Bluetooth: move l2cap_sock_getname() to l2cap_sock.c
      Bluetooth: move l2cap_sock_setsockopt() to l2cap_sock.c
      Bluetooth: move l2cap_sock_getsockopt() to l2cap_sock.c
      Bluetooth: move l2cap_sock_connect() to l2cap_sock.c
      Bluetooth: move l2cap_sock_recvmsg() to l2cap_sock.c
      Bluetooth: move l2cap_sock_shutdown() to l2cap_sock.c
      Bluetooth: move l2cap_sock_sendmsg() to l2cap_sock.c
      Bluetooth: move L2CAP sock timers function to l2cap_sock.c
      Bluetooth: move l2cap_sock_kill() to l2cap_sock.c
      Bluetooth: move __l2cap_sock_close() to l2cap_sock.c
      Bluetooth: update Bluetooth daemon name in Kconfig help
      Bluetooth: Merge L2CAP and SCO modules into bluetooth.ko
      Bluetooth: remove l2cap_load() hack
      Bluetooth: Add L2CAP mode to debugfs output
      Bluetooth: Use usb_fill_int_urb()
      Bluetooth: Fix crash when ioctl(HCIUARTSETPROTO) fails
      Bluetooth: fix errors reported by checkpatch.pl
      Bluetooth: Fix errors reported by checkpatch.pl
      Bluetooth: fix checkpatch errors in af_bluetooth.c

Helmut Schaa (4):
      mac80211: Remove superfluous if clause
      rt2x00: Minor optimization for devices with RTS/CTS offload
      Revert "rt2x00 : avoid timestamp for monitor injected frame."
      rt2x00: Remove superfluos empty line

Henry Ptasinski (1):
      wireless-next-2.6: brcm80211: fix compile issue

Jan Beulich (1):
      small adjustment to net/mac80211/Kconfig

Jesper Juhl (1):
      Bluetooth: Fix failure to release lock in read_index_list()

Johan Hedberg (25):
      Bluetooth: Implement automatic setup procedure for local adapters
      Bluetooth: Add support for management powered event
      Bluetooth: Add support for set_powered management command
      Bluetooth: Add support for set_discoverable management command
      Bluetooth: Add set_connectable management command
      Bluetooth: Unify mode related management messages to a single struct
      Bluetooth: Add flag to track managment controlled adapters
      Bluetooth: Add send_mode_rsp convenience function for mgmt.c
      Bluetooth: Implement set_pairable managment command
      Bluetooth: Implement UUID handling through the management interface
      Bluetooth: Implement debugfs support for listing UUIDs
      Bluetooth: Reject pairing requests when in non-pairable mode
      Bluetooth: Add special handling with __hci_request and HCI_INIT
      Bluetooth: Add controller side link key clearing to hci_init_req
      Bluetooth: Remove page timeout setting from HCI init sequence
      Bluetooth: Implement a more complete adapter initialization sequence
      Bluetooth: Add class of device control to the management interface
      Bluetooth: Implement link key handling for the management interface
      Bluetooth: Add connected/disconnected management events
      Bluetooth: Add disconnect managment command
      Bluetooth: Add support for connect failed management event
      Bluetooth: Add get_connections managment interface command
      Bluetooth: Create common cmd_complete function for mgmt.c
      Bluetooth: Add support for PIN code handling in the management interface
      Bluetooth: Add set_io_capability management command

Johannes Berg (2):
      mac80211: reply to directed probes in IBSS
      mac80211: fix 2.4 GHz 40 MHz disabling

John W. Linville (5):
      Merge branch 'for-linville' of git://git.kernel.org/.../luca/wl12xx
      Merge branch 'master' of git://git.kernel.org/.../padovan/bluetooth-2.6
      Merge branch 'master' of git://git.kernel.org/.../padovan/bluetooth-next-2.6
      Merge ssh://master.kernel.org/.../linville/wireless-2.6
      Merge branch 'master' of git://git.kernel.org/.../linville/wireless-next-2.6 into for-davem

Jussi Kivilinna (4):
      zd1211rw: correct use of usb_bulk_msg on interrupt endpoints
      zd1211rw: use async urb for write command
      zd1211rw: move async iowrite16v up to callers
      zd1211rw: add unlikely to ZD_ASSERT

Larry Finger (13):
      rtlwifi: Modify core routines
      rtlwifi: rtl8192ce: Refactor rtl8192ce/dm
      rtlwifi: rtl8192ce: Refactor rtl8192ce/fw
      rtlwifi: rtl8192ce: Rework rtl8192ce/phy.c
      p54: Fix compile warning
      rtlwifi: Make changes in rtlwifi/rtl8192ce/reg.h to support rtl8192cu
      rtlwifi: Make changes in rtlwifi/rtl8192ce/def.h to support rtl8192cu
      rtlwifi: Modify some rtl8192ce routines for merging rtl8192cu
      rtlwifi: Modify wifi.h for rtl8192cu
      rtlwifi: Move common parts of rtl8192ce/phy.c
      rtlwifi: Modify build system for rtl8192cu
      rtlwifi: rtl8192ce: Fix endian warnings
      rtlwifi: Remove obsolete/unused macros

Michael Buesch (1):
      ssb: Make ssb_wait_bit multi-bit safe

Mohammed Shafi Shajakhan (1):
      ath9k: Fix ath9k prevents CPU to enter C3 states

Nikolay Ledovskikh (1):
      ath5k: Correct channel setting for AR2317 chip

Oliver Neukum (1):
      Bluetooth: fix crash with quirky dongles doing sound

RA-Jay Hung (2):
      rt2x00: Add antenna setting for RT3070/RT3090/RT3390 with RX antenna diversity support
      rt2x00: Fix rt2800 txpower setting to correct value

RA-Shiang Tu (1):
      rt2x00: Add support for RT5390 chip

Rafał Miłecki (5):
      ssb: extract boardflags2 for SPROMs rev 4 and 5
      ssb: trivial: fix SPROM extract warning formatting
      ssb: remove invalid define SSB_TMSLOW_PHYCLK
      ssb: when needed, reject IM input while disabling device
      ssb: reset device only if it was enabled

Rajkumar Manoharan (1):
      ath9k: disable beaconing before stopping beacon queue

Randy Dunlap (1):
      wl12xx: fix sdio_test kconfig/build errors

Rogério Brito (1):
      Bluetooth: ath3k: Avoid duplication of code

Seth Forshee (1):
      rt2x00: Check for errors from skb_pad() calls

Shiang Tu (2):
      rt2x00: Add/Modify protection related register definitions
      rt2x00: Add/Modify the GPIO register definition

Stanislaw Gruszka (4):
      iwlwifi: cleanup iwl_recover_from_statistics
      iwlwifi: cleanup iwl_good_ack_health
      iwlwifi: fix ack health for WiFi/BT combo devices
      mac80211: fix conn_mon_timer running after disassociate

Steve Brown (1):
      ath9k: Remove redundant beacon_interval

Sujith Manoharan (1):
      ath9k_hw: Fix power on reset

Szymon Janc (5):
      Bluetooth: Use #include <linux/uaccess.h> instead of <asm/uaccess.h>
      Bluetooth: Clean up hci_sniff_subrate_evt function
      Bluetooth: Fix some code style issues in hci_core.h
      Bluetooth: Fix some code style issues in hci_core.c
      Bluetooth: Fix some code style issues in hci_event.c

Vasanthakumar Thiagarajan (1):
      ath9k: Implement op_flush()

Vasiliy Kulikov (3):
      Bluetooth: l2cap: fix 1 byte infoleak to userspace
      Bluetooth: bnep: fix buffer overflow
      Bluetooth: sco: fix information leak to userspace

Ville Tervo (9):
      Bluetooth: Add low energy commands and events
      Bluetooth: Add LE connect support
      Bluetooth: Use LE buffers for LE traffic
      Bluetooth: Add LE connection support to L2CAP
      Bluetooth: Add server socket support for LE connection
      Bluetooth: Do not send disconn comand over LE links
      Bluetooth: Treat LE and ACL links separately on timeout
      Bluetooth: Add SMP command structures
      Bluetooth: Use proper timer for hci command timout

Vinicius Costa Gomes (1):
      Bluetooth: Fix initiated LE connections

Vivek Natarajan (3):
      ath9k_htc: Fix a compilation warning.
      ath9k_hw: Updates for AR9485 1.1 chipsets.
      mac80211: Clear PS related flag on disabling power save.

Vladislav P (1):
      Bluetooth: Release BTM while sleeping to avoid deadlock

Wey-Yi Guy (2):
      iwlagn: donot process bt update when bt coex disable
      iwlagn: handle bt defer work in 2000 series

Wojciech Dubowik (1):
      ath5k: Enable AR2315 chipset recognition

Xose Vazquez Perez (1):
      wireless: rt2x00: rt2800pci.c: add two ids

 Documentation/feature-removal-schedule.txt         |   11 +
 MAINTAINERS                                        |    2 +-
 drivers/bluetooth/ath3k.c                          |  290 +++-
 drivers/bluetooth/btusb.c                          |   20 +-
 drivers/bluetooth/hci_ldisc.c                      |    1 +
 drivers/net/wireless/ath/ar9170/Kconfig            |    4 +-
 drivers/net/wireless/ath/ath5k/ath5k.h             |   20 +
 drivers/net/wireless/ath/ath5k/attach.c            |    3 +-
 drivers/net/wireless/ath/ath5k/mac80211-ops.c      |   17 -
 drivers/net/wireless/ath/ath5k/phy.c               |    1 +
 drivers/net/wireless/ath/ath9k/ar9003_hw.c         |  112 +-
 drivers/net/wireless/ath/ath9k/ar9485_initvals.h   | 1141 +++++++++
 drivers/net/wireless/ath/ath9k/ath9k.h             |   13 +-
 drivers/net/wireless/ath/ath9k/beacon.c            |   43 +-
 drivers/net/wireless/ath/ath9k/htc_drv_main.c      |    2 +-
 drivers/net/wireless/ath/ath9k/hw.c                |    1 -
 drivers/net/wireless/ath/ath9k/init.c              |    8 -
 drivers/net/wireless/ath/ath9k/main.c              |  124 +-
 drivers/net/wireless/ath/ath9k/reg.h               |    4 +
 drivers/net/wireless/ath/ath9k/xmit.c              |   30 +-
 drivers/net/wireless/iwlwifi/iwl-2000.c            |    3 +-
 drivers/net/wireless/iwlwifi/iwl-agn-lib.c         |   12 +-
 drivers/net/wireless/iwlwifi/iwl-agn.c             |   74 +-
 drivers/net/wireless/iwlwifi/iwl-rx.c              |   37 +-
 drivers/net/wireless/p54/eeprom.c                  |  208 ++-
 drivers/net/wireless/p54/eeprom.h                  |    7 +
 drivers/net/wireless/p54/fwio.c                    |   12 +-
 drivers/net/wireless/p54/lmac.h                    |    1 +
 drivers/net/wireless/p54/main.c                    |   47 +-
 drivers/net/wireless/p54/p54.h                     |    6 +-
 drivers/net/wireless/p54/p54spi_eeprom.h           |    9 +-
 drivers/net/wireless/p54/txrx.c                    |    6 +-
 drivers/net/wireless/rt2x00/Kconfig                |   12 +
 drivers/net/wireless/rt2x00/rt2800.h               |  129 +-
 drivers/net/wireless/rt2x00/rt2800lib.c            |  747 +++++--
 drivers/net/wireless/rt2x00/rt2800pci.c            |   12 +
 drivers/net/wireless/rt2x00/rt2x00.h               |    4 +
 drivers/net/wireless/rt2x00/rt2x00ht.c             |    1 -
 drivers/net/wireless/rt2x00/rt2x00mac.c            |    6 +-
 drivers/net/wireless/rt2x00/rt2x00queue.c          |    9 +-
 drivers/net/wireless/rt2x00/rt61pci.c              |   12 +-
 drivers/net/wireless/rt2x00/rt73usb.c              |   12 +-
 drivers/net/wireless/rtlwifi/Kconfig               |   17 +-
 drivers/net/wireless/rtlwifi/Makefile              |    6 +-
 drivers/net/wireless/rtlwifi/base.c                |   76 +-
 drivers/net/wireless/rtlwifi/base.h                |   39 +-
 drivers/net/wireless/rtlwifi/core.c                |   14 +-
 drivers/net/wireless/rtlwifi/debug.h               |    1 +
 drivers/net/wireless/rtlwifi/pci.c                 |  148 +-
 drivers/net/wireless/rtlwifi/pci.h                 |   12 +-
 drivers/net/wireless/rtlwifi/ps.c                  |   58 +-
 drivers/net/wireless/rtlwifi/rtl8192c/dm_common.c  | 1388 +++++++++++
 drivers/net/wireless/rtlwifi/rtl8192c/phy_common.c | 2049 ++++++++++++++++
 drivers/net/wireless/rtlwifi/rtl8192ce/Makefile    |    2 +
 drivers/net/wireless/rtlwifi/rtl8192ce/def.h       |  144 ++
 drivers/net/wireless/rtlwifi/rtl8192ce/dm.c        | 1361 +-----------
 drivers/net/wireless/rtlwifi/rtl8192ce/dm.h        |    1 +
 drivers/net/wireless/rtlwifi/rtl8192ce/fw.c        |   59 +-
 drivers/net/wireless/rtlwifi/rtl8192ce/hw.c        |  153 +-
 drivers/net/wireless/rtlwifi/rtl8192ce/led.c       |    6 +-
 drivers/net/wireless/rtlwifi/rtl8192ce/phy.c       | 2072 +----------------
 drivers/net/wireless/rtlwifi/rtl8192ce/phy.h       |    7 +-
 drivers/net/wireless/rtlwifi/rtl8192ce/reg.h       |   73 +-
 drivers/net/wireless/rtlwifi/rtl8192ce/sw.c        |    7 +-
 drivers/net/wireless/rtlwifi/rtl8192ce/sw.h        |    2 +
 drivers/net/wireless/rtlwifi/rtl8192ce/trx.c       |  170 +-
 drivers/net/wireless/rtlwifi/rtl8192ce/trx.h       |  464 ++--
 drivers/net/wireless/rtlwifi/rtl8192cu/Makefile    |   15 +
 drivers/net/wireless/rtlwifi/rtl8192cu/def.h       |   62 +
 drivers/net/wireless/rtlwifi/rtl8192cu/dm.c        |  116 +
 drivers/net/wireless/rtlwifi/rtl8192cu/dm.h        |   32 +
 drivers/net/wireless/rtlwifi/rtl8192cu/fw.c        |   30 +
 drivers/net/wireless/rtlwifi/rtl8192cu/fw.h        |   30 +
 drivers/net/wireless/rtlwifi/rtl8192cu/hw.c        | 2505 ++++++++++++++++++++
 drivers/net/wireless/rtlwifi/rtl8192cu/hw.h        |  107 +
 drivers/net/wireless/rtlwifi/rtl8192cu/led.c       |  142 ++
 drivers/net/wireless/rtlwifi/rtl8192cu/led.h       |   37 +
 drivers/net/wireless/rtlwifi/rtl8192cu/mac.c       | 1144 +++++++++
 drivers/net/wireless/rtlwifi/rtl8192cu/mac.h       |  180 ++
 drivers/net/wireless/rtlwifi/rtl8192cu/phy.c       |  611 +++++
 drivers/net/wireless/rtlwifi/rtl8192cu/phy.h       |   34 +
 drivers/net/wireless/rtlwifi/rtl8192cu/reg.h       |   30 +
 drivers/net/wireless/rtlwifi/rtl8192cu/rf.c        |  493 ++++
 drivers/net/wireless/rtlwifi/rtl8192cu/rf.h        |   30 +
 drivers/net/wireless/rtlwifi/rtl8192cu/sw.c        |  327 +++
 drivers/net/wireless/rtlwifi/rtl8192cu/sw.h        |   35 +
 drivers/net/wireless/rtlwifi/rtl8192cu/table.c     | 1888 +++++++++++++++
 drivers/net/wireless/rtlwifi/rtl8192cu/table.h     |   71 +
 drivers/net/wireless/rtlwifi/rtl8192cu/trx.c       |  684 ++++++
 drivers/net/wireless/rtlwifi/rtl8192cu/trx.h       |  430 ++++
 drivers/net/wireless/rtlwifi/usb.c                 | 1035 ++++++++
 drivers/net/wireless/rtlwifi/usb.h                 |  164 ++
 drivers/net/wireless/rtlwifi/wifi.h                |  667 ++++--
 drivers/net/wireless/wl12xx/Kconfig                |    2 +-
 drivers/net/wireless/wl12xx/acx.c                  |   86 +-
 drivers/net/wireless/wl12xx/acx.h                  |   41 +-
 drivers/net/wireless/wl12xx/cmd.c                  |   10 +-
 drivers/net/wireless/wl12xx/cmd.h                  |   14 +-
 drivers/net/wireless/wl12xx/conf.h                 |   49 +
 drivers/net/wireless/wl12xx/event.c                |   14 -
 drivers/net/wireless/wl12xx/event.h                |    2 -
 drivers/net/wireless/wl12xx/init.c                 |   13 +
 drivers/net/wireless/wl12xx/main.c                 |  143 +-
 drivers/net/wireless/wl12xx/ps.c                   |    6 +-
 drivers/net/wireless/wl12xx/rx.c                   |    6 +-
 drivers/net/wireless/wl12xx/rx.h                   |    2 +-
 drivers/net/wireless/wl12xx/tx.c                   |   22 -
 drivers/net/wireless/wl12xx/wl12xx.h               |   66 +-
 drivers/net/wireless/zd1211rw/zd_chip.c            |   35 +-
 drivers/net/wireless/zd1211rw/zd_def.h             |    2 +-
 drivers/net/wireless/zd1211rw/zd_usb.c             |  177 ++-
 drivers/net/wireless/zd1211rw/zd_usb.h             |    9 +-
 drivers/ssb/main.c                                 |   44 +-
 drivers/ssb/pci.c                                  |    6 +-
 drivers/staging/brcm80211/brcmfmac/wl_cfg80211.c   |    4 +-
 include/linux/ssb/ssb_regs.h                       |    7 +-
 include/net/bluetooth/bluetooth.h                  |   33 +
 include/net/bluetooth/hci.h                        |  122 +
 include/net/bluetooth/hci_core.h                   |  152 +-
 include/net/bluetooth/l2cap.h                      |   53 +-
 include/net/bluetooth/mgmt.h                       |  142 ++
 include/net/bluetooth/smp.h                        |   76 +
 net/bluetooth/Kconfig                              |   16 +-
 net/bluetooth/Makefile                             |    4 +-
 net/bluetooth/af_bluetooth.c                       |   53 +-
 net/bluetooth/bnep/core.c                          |    2 -
 net/bluetooth/bnep/sock.c                          |    1 +
 net/bluetooth/cmtp/capi.c                          |    3 +-
 net/bluetooth/cmtp/core.c                          |   11 +-
 net/bluetooth/hci_conn.c                           |   78 +-
 net/bluetooth/hci_core.c                           |  345 +++-
 net/bluetooth/hci_event.c                          |  622 +++++-
 net/bluetooth/hci_sock.c                           |    6 +-
 net/bluetooth/hci_sysfs.c                          |   58 +-
 net/bluetooth/hidp/core.c                          |   11 +-
 net/bluetooth/{l2cap.c => l2cap_core.c}            | 1722 ++++----------
 net/bluetooth/l2cap_sock.c                         | 1156 +++++++++
 net/bluetooth/mgmt.c                               | 1312 ++++++++++-
 net/bluetooth/rfcomm/core.c                        |    2 -
 net/bluetooth/rfcomm/tty.c                         |    2 +
 net/bluetooth/sco.c                                |   17 +-
 net/mac80211/Kconfig                               |    2 +-
 net/mac80211/cfg.c                                 |    1 +
 net/mac80211/debugfs.c                             |    6 +
 net/mac80211/ibss.c                                |   11 +-
 net/mac80211/ieee80211_i.h                         |    2 -
 net/mac80211/main.c                                |   33 +-
 net/mac80211/mlme.c                                |    8 +
 net/mac80211/rx.c                                  |   12 +-
 net/mac80211/scan.c                                |   15 +-
 net/mac80211/tx.c                                  |    1 +
 net/mac80211/util.c                                |    6 -
 net/mac80211/work.c                                |   59 +-
 153 files changed, 22844 insertions(+), 6512 deletions(-)
 create mode 100644 drivers/net/wireless/rtlwifi/rtl8192c/dm_common.c
 create mode 100644 drivers/net/wireless/rtlwifi/rtl8192c/phy_common.c
 create mode 100644 drivers/net/wireless/rtlwifi/rtl8192cu/Makefile
 create mode 100644 drivers/net/wireless/rtlwifi/rtl8192cu/def.h
 create mode 100644 drivers/net/wireless/rtlwifi/rtl8192cu/dm.c
 create mode 100644 drivers/net/wireless/rtlwifi/rtl8192cu/dm.h
 create mode 100644 drivers/net/wireless/rtlwifi/rtl8192cu/fw.c
 create mode 100644 drivers/net/wireless/rtlwifi/rtl8192cu/fw.h
 create mode 100644 drivers/net/wireless/rtlwifi/rtl8192cu/hw.c
 create mode 100644 drivers/net/wireless/rtlwifi/rtl8192cu/hw.h
 create mode 100644 drivers/net/wireless/rtlwifi/rtl8192cu/led.c
 create mode 100644 drivers/net/wireless/rtlwifi/rtl8192cu/led.h
 create mode 100644 drivers/net/wireless/rtlwifi/rtl8192cu/mac.c
 create mode 100644 drivers/net/wireless/rtlwifi/rtl8192cu/mac.h
 create mode 100644 drivers/net/wireless/rtlwifi/rtl8192cu/phy.c
 create mode 100644 drivers/net/wireless/rtlwifi/rtl8192cu/phy.h
 create mode 100644 drivers/net/wireless/rtlwifi/rtl8192cu/reg.h
 create mode 100644 drivers/net/wireless/rtlwifi/rtl8192cu/rf.c
 create mode 100644 drivers/net/wireless/rtlwifi/rtl8192cu/rf.h
 create mode 100644 drivers/net/wireless/rtlwifi/rtl8192cu/sw.c
 create mode 100644 drivers/net/wireless/rtlwifi/rtl8192cu/sw.h
 create mode 100644 drivers/net/wireless/rtlwifi/rtl8192cu/table.c
 create mode 100644 drivers/net/wireless/rtlwifi/rtl8192cu/table.h
 create mode 100644 drivers/net/wireless/rtlwifi/rtl8192cu/trx.c
 create mode 100644 drivers/net/wireless/rtlwifi/rtl8192cu/trx.h
 create mode 100644 drivers/net/wireless/rtlwifi/usb.c
 create mode 100644 drivers/net/wireless/rtlwifi/usb.h
 create mode 100644 include/net/bluetooth/smp.h
 rename net/bluetooth/{l2cap.c => l2cap_core.c} (76%)
 create mode 100644 net/bluetooth/l2cap_sock.c

Omnibus patch available here:

	http://www.kernel.org/pub/linux/kernel/people/linville/wireless-next-2.6-2011-02-22.patch.bz2

-- 
John W. Linville		Someday the world will need a hero, and you
linville@tuxdriver.com			might be all we have.  Be ready.

^ permalink raw reply

* Re: [PATCH] TX timestamp IPv6 support
From: Anders Berggren @ 2011-02-22 21:50 UTC (permalink / raw)
  To: David Miller; +Cc: netdev
In-Reply-To: <20110222.093633.193722951.davem@davemloft.net>

> Please submit your change properly, as per Documentation/SubmittingPatches,
> in particular you need to provide a proper Signed-off-by: tag for your
> change.

Thank you. I made a second try:

http://marc.info/?l=linux-netdev&m=129841103607145&w=2

^ permalink raw reply

* Re: [PATCH ethtool 5/5] ethtool: Add --version option
From: Ben Hutchings @ 2011-02-22 21:49 UTC (permalink / raw)
  To: Jeff Garzik; +Cc: Eric Dumazet, Stephen Hemminger, netdev
In-Reply-To: <4D642C14.6020505@garzik.org>

On Tue, 2011-02-22 at 16:35 -0500, Jeff Garzik wrote:
> On 02/22/2011 08:05 AM, Eric Dumazet wrote:
> > Le mardi 22 février 2011 à 12:37 +0000, Ben Hutchings a écrit :
> >> On Mon, 2011-02-21 at 22:16 -0800, Stephen Hemminger wrote:
> >> [...]
> >>> The standard convention is to use -V for short form of version option.
> >>
> >> This is not anywhere near standard.
> >>
> >> $ cp -V
> >> cp: invalid option -- 'V'
> >> Try `cp --help' for more information.
> >> $ bash -V
> >> bash: -V: invalid option
> >> [...]
> >> $ emacs -V
> >> [opens window]
> >> $ vim -V
> >> chdir(/usr/share/vim)
> >> fchdir() to previous dir
> >> sourcing "$VIM/vimrc"
> >> [...looks like that meant 'verbose'...]
> >
> > Now try with networking tools, many use -V
> >
> > (As a matter of fact, ethtool -h already is used to display help)
> >
> > # ping -V
> > ping utility, iputils-sss20071127
> > # tc -V
> > tc utility, iproute2-ss100823
> > # ssh -V
> > OpenSSH_5.1p1 Debian-5, OpenSSL 0.9.8g 19 Oct 2007
> 
> Stephen is correct, "-V" is a common standard (but by no means 
> universal).  The following is what using argp ("info argp") generates 
> for any program by default:
[...]

Well, it's my bikeshed now. :-)  I don't think it's worth using one of
the few remaining letters on this.

Ben.

-- 
Ben Hutchings, Senior Software Engineer, Solarflare Communications
Not speaking for my employer; that's the marketing department's job.
They asked us to note that Solarflare product names are trademarked.


^ permalink raw reply

* [PATCH] net: TX timestamps for IPv6 UDP packets
From: Anders Berggren @ 2011-02-22 21:43 UTC (permalink / raw)
  To: John Ronciak; +Cc: netdev

Enabling TX timestamps (SO_TIMESTAMPING) for IPv6 UDP packets, in 
the same fashion as for IPv4. Necessary in order for NICs such as
Intel 82580 to timestamp IPv6 packets.

Signed-off-by: Anders Berggren <anders@halon.se>
---

diff --git a/net/ipv6/ip6_output.c b/net/ipv6/ip6_output.c
index 94b5bf1..74d9343 100644
--- a/net/ipv6/ip6_output.c
+++ b/net/ipv6/ip6_output.c
@@ -1115,6 +1115,7 @@ int ip6_append_data(struct sock *sk, int getfrag(void *from, char *to,
 	int err;
 	int offset = 0;
 	int csummode = CHECKSUM_NONE;
+	__u8 tx_flags = 0;
 
 	if (flags&MSG_PROBE)
 		return 0;
@@ -1199,6 +1200,13 @@ int ip6_append_data(struct sock *sk, int getfrag(void *from, char *to,
 		}
 	}
 
+	/* For UDP, check if TX timestamp is enabled */
+	if (sk->sk_type == SOCK_DGRAM) {
+		err = sock_tx_timestamp(sk, &tx_flags);
+		if (err)
+			goto error;
+	}
+
 	/*
 	 * Let's try using as much space as possible.
 	 * Use MTU if total length of the message fits into the MTU.
@@ -1303,6 +1311,10 @@ alloc_new_skb:
 							   sk->sk_allocation);
 				if (unlikely(skb == NULL))
 					err = -ENOBUFS;
+				else
+					/* only the initial fragment is
+					   time stamped */
+					tx_flags = 0;
 			}
 			if (skb == NULL)
 				goto error;
@@ -1314,6 +1326,9 @@ alloc_new_skb:
 			/* reserve for fragmentation */
 			skb_reserve(skb, hh_len+sizeof(struct frag_hdr));
 
+			if (sk->sk_type == SOCK_DGRAM)
+				skb_shinfo(skb)->tx_flags = tx_flags;
+
 			/*
 			 *	Find where to start putting bytes
 			 */

^ permalink raw reply related

* Re: [PATCH] ax88796: depend on HAS_IOMEM not on individual ARCHs
From: Marc Kleine-Budde @ 2011-02-22 21:42 UTC (permalink / raw)
  To: David Miller; +Cc: netdev
In-Reply-To: <20110222.123732.70186533.davem@davemloft.net>

[-- Attachment #1: Type: text/plain, Size: 640 bytes --]

On 02/22/2011 09:37 PM, David Miller wrote:
> I know it's going to cause allmodconfig build errors on sparc64,
> for example.

How to fix?
> drivers/net/ax88796.c:195: error: implicit declaration of function 'readsw'
> drivers/net/ax88796.c:198: error: implicit declaration of function 'readsb'

Use "ioreadX_rep" or add a "!SPARC64" to Kconfig?

Marc

-- 
Pengutronix e.K.                  | Marc Kleine-Budde           |
Industrial Linux Solutions        | Phone: +49-231-2826-924     |
Vertretung West/Dortmund          | Fax:   +49-5121-206917-5555 |
Amtsgericht Hildesheim, HRA 2686  | http://www.pengutronix.de   |


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 262 bytes --]

^ permalink raw reply

* Re: [PATCH ethtool 5/5] ethtool: Add --version option
From: Jeff Garzik @ 2011-02-22 21:35 UTC (permalink / raw)
  To: Ben Hutchings; +Cc: Eric Dumazet, Stephen Hemminger, netdev
In-Reply-To: <1298379945.2861.7.camel@edumazet-laptop>

On 02/22/2011 08:05 AM, Eric Dumazet wrote:
> Le mardi 22 février 2011 à 12:37 +0000, Ben Hutchings a écrit :
>> On Mon, 2011-02-21 at 22:16 -0800, Stephen Hemminger wrote:
>> [...]
>>> The standard convention is to use -V for short form of version option.
>>
>> This is not anywhere near standard.
>>
>> $ cp -V
>> cp: invalid option -- 'V'
>> Try `cp --help' for more information.
>> $ bash -V
>> bash: -V: invalid option
>> [...]
>> $ emacs -V
>> [opens window]
>> $ vim -V
>> chdir(/usr/share/vim)
>> fchdir() to previous dir
>> sourcing "$VIM/vimrc"
>> [...looks like that meant 'verbose'...]
>
> Now try with networking tools, many use -V
>
> (As a matter of fact, ethtool -h already is used to display help)
>
> # ping -V
> ping utility, iputils-sss20071127
> # tc -V
> tc utility, iproute2-ss100823
> # ssh -V
> OpenSSH_5.1p1 Debian-5, OpenSSL 0.9.8g 19 Oct 2007

Stephen is correct, "-V" is a common standard (but by no means 
universal).  The following is what using argp ("info argp") generates 
for any program by default:

> Usage: myprog [OPTION...]
> myprog - a program that does something
>
> [...]
>
>   -?, --help                 Give this help list
>       --usage                Give a short usage message
>   -V, --version              Print program version
>
> Mandatory or optional arguments to long options are also mandatory or optional for any corresponding short options.

Regards,

	Jeff



^ permalink raw reply

* [PATCHv2 2/2] DM9000B: Fix PHY power for network down/up
From: Henry Nestler @ 2011-02-22 21:29 UTC (permalink / raw)
  To: netdev; +Cc: akpm, linux-arm-kernel
In-Reply-To: <20110222.102410.260079835.davem@davemloft.net>

DM9000 revision B needs 1 ms delay after PHY power-on.
PHY must be powered on by writing 0 into register DM9000_GPR before
all other settings will change (see Davicom spec and example code).

Remember, that register DM9000_GPR was not changed by reset sequence.

Without this fix the FIFO is out of sync and sends wrong data after
sequence of "ifconfig ethX down ; ifconfig ethX up".
---
Kernel version 2.6.38-rc5

 drivers/net/dm9000.c |    7 ++++---
 1 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/drivers/net/dm9000.c b/drivers/net/dm9000.c
index 2d4c4fc..5925569 100644
--- a/drivers/net/dm9000.c
+++ b/drivers/net/dm9000.c
@@ -802,10 +802,7 @@ dm9000_init_dm9000(struct net_device *dev)
 	/* Checksum mode */
 	dm9000_set_rx_csum_unlocked(dev, db->rx_csum);

-	/* GPIO0 on pre-activate PHY */
-	iow(db, DM9000_GPR, 0);	/* REG_1F bit0 activate phyxcer */
 	iow(db, DM9000_GPCR, GPCR_GEP_CNTL);	/* Let GPIO0 output */
-	iow(db, DM9000_GPR, 0);	/* Enable PHY */

 	ncr = (db->flags & DM9000_PLATF_EXT_PHY) ? NCR_EXT_PHY : 0;

@@ -1194,6 +1191,10 @@ dm9000_open(struct net_device *dev)
 	if (request_irq(dev->irq, dm9000_interrupt, irqflags, dev->name, dev))
 		return -EAGAIN;

+	/* GPIO0 on pre-activate PHY, Reg 1F is not set by reset */
+	iow(db, DM9000_GPR, 0);	/* REG_1F bit0 activate phyxcer */
+	mdelay(1); /* delay needs by DM9000B */
+
 	/* Initialize DM9000 board */
 	dm9000_reset(db);
 	dm9000_init_dm9000(dev);

^ permalink raw reply related

* Re: [PATCH net-next-2.6] bonding: fix user-controlled queuing issues
From: Andy Gospodarek @ 2011-02-22 21:24 UTC (permalink / raw)
  To: Phil Oester; +Cc: Andy Gospodarek, netdev, Ben Hutchings, Jay Vosburgh
In-Reply-To: <20110222164836.GA15040@linuxace.com>

On Tue, Feb 22, 2011 at 08:48:36AM -0800, Phil Oester wrote:
> On Tue, Feb 22, 2011 at 11:19:41AM -0500, Andy Gospodarek wrote:
> > Phil,
> > 
> > Can you send me the minimal set of tc rules that selects output queue 16
> > and the output of /proc/net/bonding/bond0?
> > 
> > Private email is fine if you do not want to post it to the list.
> > 
> > Thanks,
> > 
> > -andy
> 
> I have no tc rules which select output queue 16 (I have no tc rules at all
> in fact). 
> 
> Output of /proc/net/bonding/bond0 below.  The bond consists of two Intel
> igb nics, which only have 8 queues.  Note, however, that eth0 is an ixgbe,
> which has 16 queues:
> 
> ixgbe 0000:0b:00.0: Multiqueue Enabled: Rx Queue count = 16, Tx Queue count = 16
> 
> which may answer your question as to what is selecting queue 16.  
> 
> Phil 
> 

OK, I've got it now!  I can reproduce this when I recieve frames from a
device not in the bond and transmit those frames out of the bond device.
I suspect that is what you are doing.  That was a case I did not
consider with the original patch.

I will test all of this and post this as a 2-part series with the first
patch being one that should apply to stable as well, so you and others
can have it there.


^ permalink raw reply

* Re: [PATCH ethtool 2/3] ethtool: Regularise handling of offload flags
From: Michał Mirosław @ 2011-02-22 21:17 UTC (permalink / raw)
  To: Ben Hutchings; +Cc: netdev
In-Reply-To: <1298307548.2608.50.camel@bwh-desktop>

On Mon, Feb 21, 2011 at 04:59:08PM +0000, Ben Hutchings wrote:
> Use the new ETHTOOL_{G,S}FEATURES operations where available, and
> use the new structure and netif feature flags in any case.
[...]
> --- a/ethtool.c
> +++ b/ethtool.c
[...]
> +static int dump_offload(const struct ethtool_get_features_block *features)
>  {
[...]
> +	u32 value;
> +	int i;
> +
> +	for (i = 0; i < ARRAY_SIZE(off_feature_def); i++) {
> +		value = off_feature_def[i].value;
> +		printf("%s: %s%s%s\n",
> +		       off_feature_def[i].long_name,
> +		       (features->active & value) ? "on" : "off",
> +		       (features->requested & ~features->active & value) ?
> +		       " [requested on]" : "",
> +		       (~features->available & value) ? " [unchangeable]" : "");
> +	}

This would be clearer if '[requested XXX]' part was shown only when the
offload's state is different than requested.

Best Regards,
Michał Mirosław 

^ permalink raw reply


This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox