* Re: linux-next: build failure after final merge (net tree)
From: Stephen Rothwell @ 2010-02-17 7:57 UTC (permalink / raw)
To: David Miller; +Cc: netdev, linux-next, linux-kernel, jengelh
In-Reply-To: <20100216.231109.183048308.davem@davemloft.net>
[-- Attachment #1: Type: text/plain, Size: 435 bytes --]
On Tue, 16 Feb 2010 23:11:09 -0800 (PST) David Miller <davem@davemloft.net> wrote:
>
> From: Stephen Rothwell <sfr@canb.auug.org.au>
> Date: Wed, 17 Feb 2010 17:40:15 +1100
>
> > After merging, today's linux-next build (sparc64 defconfig) failed like
> > this:
>
> Fixed for at least 6 hours:
Excellent, thanks.
--
Cheers,
Stephen Rothwell sfr@canb.auug.org.au
http://www.canb.auug.org.au/~sfr/
[-- Attachment #2: Type: application/pgp-signature, Size: 198 bytes --]
^ permalink raw reply
* [PACH] smsc911x: replace manual phy lookup.
From: Denis Kirjanov <kirjanov@gmail.com @ 2010-02-17 7:54 UTC (permalink / raw)
To: davem; +Cc: steve.glendinning, jpirko, netdev
Use phy_find_first() function instead of manual lookup.
Signed-off-by: Denis Kirjanov <kirjanov@gmail.com>
---
drivers/net/smsc911x.c | 24 ++++++++++--------------
1 files changed, 10 insertions(+), 14 deletions(-)
diff --git a/drivers/net/smsc911x.c b/drivers/net/smsc911x.c
index 3c1f9aa..13c0b76 100644
--- a/drivers/net/smsc911x.c
+++ b/drivers/net/smsc911x.c
@@ -770,29 +770,25 @@ static int smsc911x_mii_probe(struct net_device *dev)
{
struct smsc911x_data *pdata = netdev_priv(dev);
struct phy_device *phydev = NULL;
- int phy_addr;
+ int ret;
/* find the first phy */
- for (phy_addr = 0; phy_addr < PHY_MAX_ADDR; phy_addr++) {
- if (pdata->mii_bus->phy_map[phy_addr]) {
- phydev = pdata->mii_bus->phy_map[phy_addr];
- SMSC_TRACE(PROBE, "PHY %d: addr %d, phy_id 0x%08X",
- phy_addr, phydev->addr, phydev->phy_id);
- break;
- }
- }
-
+ phydev = phy_find_first(pdata->mii_bus);
if (!phydev) {
pr_err("%s: no PHY found\n", dev->name);
return -ENODEV;
}
- phydev = phy_connect(dev, dev_name(&phydev->dev),
- &smsc911x_phy_adjust_link, 0, pdata->config.phy_interface);
+ SMSC_TRACE(PROBE, "PHY %d: addr %d, phy_id 0x%08X",
+ phy_addr, phydev->addr, phydev->phy_id);
+
+ ret = phy_connect_direct(dev, phydev,
+ &smsc911x_phy_adjust_link, 0,
+ pdata->config.phy_interface);
- if (IS_ERR(phydev)) {
+ if (ret) {
pr_err("%s: Could not attach to PHY\n", dev->name);
- return PTR_ERR(phydev);
+ return ret;
}
pr_info("%s: attached PHY driver [%s] (mii_bus:phy_addr=%s, irq=%d)\n",
^ permalink raw reply related
* Re: [PATCH] ipv6.h: reassembly: replace calculated magic number with multiplication
From: David Miller @ 2010-02-17 7:38 UTC (permalink / raw)
To: joe; +Cc: kaber, shanwei, netdev, netfilter-devel
In-Reply-To: <1266381604.8446.17.camel@Joe-Laptop.home>
From: Joe Perches <joe@perches.com>
Date: Tue, 16 Feb 2010 20:40:04 -0800
> On Tue, 2010-02-16 at 16:47 +0100, Patrick McHardy wrote:
>> Joe Perches wrote:
>> >> @@ -246,6 +246,8 @@ extern int ipv6_opt_accepted(struct sock *sk, struct sk_buff *skb);
>> >> int ip6_frag_nqueues(struct net *net);
>> >> int ip6_frag_mem(struct net *net);
>> >>
>> >> +#define IPV6_FRAG_HIGH_THRESH 262144 /* == 256*1024 */
>> >> +#define IPV6_FRAG_LOW_THRESH 196608 /* == 192*1024 */
>> >> #define IPV6_FRAG_TIMEOUT (60*HZ) /* 60 seconds */
>> >
>> > 196608 isn't a number I want to remember.
>> > Is this better as:
>> >
>> > #define IPV6_FRAG_HIGH_THRESH (256 * 1024) /* 262144 */
>> > #define IPV6_FRAG_LOW_THRESH (192 * 1024) /* 196608 */
>>
>> Please send a patch, I'll apply it once these patches are in Dave's
>> tree.
>
> Signed-off-by: Joe Perches <joe@perches.com>
Applied.
^ permalink raw reply
* Re: [PATCH] net: remove INIT_RCU_HEAD() usage
From: David Miller @ 2010-02-17 7:38 UTC (permalink / raw)
To: adobriyan; +Cc: netdev
In-Reply-To: <20100212214138.GA5866@x200>
From: Alexey Dobriyan <adobriyan@gmail.com>
Date: Fri, 12 Feb 2010 23:41:39 +0200
> call_rcu() will unconditionally reinitialize RCU head anyway.
>
> Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Applied to net-next-2.6
^ permalink raw reply
* Re: [PATCH] b44: Ratelimit timeout error message.
From: David Miller @ 2010-02-17 7:37 UTC (permalink / raw)
To: jochen; +Cc: zambrano, netdev
In-Reply-To: <1266005514-2731-1-git-send-email-jochen@scram.de>
From: Jochen Friedrich <jochen@scram.de>
Date: Fri, 12 Feb 2010 21:11:54 +0100
> Signed-off-by: Jochen Friedrich <jochen@scram.de>
Applied to net-next-2.6, thanks.
^ permalink raw reply
* Re: [PATCH V2 net-next 2/2] drivers/net/usb: Use netif_<level> logging facilities
From: David Miller @ 2010-02-17 7:37 UTC (permalink / raw)
To: joe; +Cc: david-b, gregkh, tilman, netdev, linux-usb, linux-kernel
In-Reply-To: <c9b38227b55aa3bb46728329bf5290063124f516.1266221693.git.joe@perches.com>
From: Joe Perches <joe@perches.com>
Date: Mon, 15 Feb 2010 00:25:12 -0800
> Convert from:
> if (netif_msg_<foo>(priv))
> dev_<level>(dev...
> to
> netif_<level>(priv, foo, dev...
>
> Also convert a few:
>
> if (i < REG_TIMEOUT) {
> etc...
> return ret;
> }
> to
> if (i >= REG_TIMEOUT)
> goto fail;
> etc...
> return ret;
>
> Signed-off-by: Joe Perches <joe@perches.com>
Applied.
^ permalink raw reply
* Re: [PATCH V2 net-next 1/2] usbnet: Convert dev(dbg|err|warn|info) macros to netdev_<level>
From: David Miller @ 2010-02-17 7:37 UTC (permalink / raw)
To: joe; +Cc: david-b, gregkh, tilman, netdev, linux-usb, linux-kernel
In-Reply-To: <48cb1d6445dceaa7043d1039ca775a8961020d88.1266221693.git.joe@perches.com>
From: Joe Perches <joe@perches.com>
Date: Mon, 15 Feb 2010 00:25:11 -0800
> These macros are too similar to the dev_<level> equivalents
> but take a usbnet * argument. Convert them to the recently
> introduced netdev_<level> macros and remove the old macros.
>
> The old macros had "\n" appended to the format string.
> Add the "\n" to the converted uses.
>
> Some existing uses of the dev<foo> macros in cdc_eem.c
> probably mistakenly had trailing "\n". No "\n" added there.
>
> Fix net1080 this/other log message inversion.
>
> Signed-off-by: Joe Perches <joe@perches.com>
Applied.
^ permalink raw reply
* Re: linux-next: build failure after final merge (net tree)
From: Eric Dumazet @ 2010-02-17 7:13 UTC (permalink / raw)
To: Stephen Rothwell
Cc: David Miller, netdev, linux-next, linux-kernel, Jan Engelhardt
In-Reply-To: <20100217174015.d1a8a478.sfr@canb.auug.org.au>
Le mercredi 17 février 2010 à 17:40 +1100, Stephen Rothwell a écrit :
> Hi Dave,
>
> After merging, today's linux-next build (sparc64 defconfig) failed like
> this:
>
> In file included from include/linux/netfilter_ipv4/ip_tables.h:29,
> from arch/sparc/kernel/sys_sparc32.c:47:
> include/linux/netfilter/x_tables.h:525: error: expected declaration specifiers or '...' before 'nf_hookfn'
>
> Caused by commit 2b95efe7f6bb750256a702cc32d33b0cb2cd8223 ("netfilter:
> xtables: use xt_table for hook instantiation"). Missing direct include
> of linux/netfilter.h?
>
Hi Stephen
David took care of this already.
http://marc.info/?l=linux-netdev&m=126636301220734&w=2
^ permalink raw reply
* Re: linux-next: build failure after final merge (net tree)
From: David Miller @ 2010-02-17 7:11 UTC (permalink / raw)
To: sfr; +Cc: netdev, linux-next, linux-kernel, jengelh
In-Reply-To: <20100217174015.d1a8a478.sfr@canb.auug.org.au>
From: Stephen Rothwell <sfr@canb.auug.org.au>
Date: Wed, 17 Feb 2010 17:40:15 +1100
> After merging, today's linux-next build (sparc64 defconfig) failed like
> this:
Fixed for at least 6 hours:
From 177867ce08f2756fa361e37086fc1792d7b4cf29 Mon Sep 17 00:00:00 2001
From: David S. Miller <davem@davemloft.net>
Date: Tue, 16 Feb 2010 15:23:23 -0800
Subject: [PATCH 641/698] sparc64: Kill bogus ip_tables.h include.
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Fixes the following build failure:
CC arch/sparc/kernel/sys_sparc32.o
In file included from include/linux/netfilter_ipv4/ip_tables.h:28,
from arch/sparc/kernel/sys_sparc32.c:46:
include/linux/netfilter/x_tables.h:525: error: expected declaration specifiers or ‘...’ before ‘nf_hookfn’
Signed-off-by: David S. Miller <davem@davemloft.net>
---
arch/sparc/kernel/sys_sparc32.c | 1 -
1 files changed, 0 insertions(+), 1 deletions(-)
diff --git a/arch/sparc/kernel/sys_sparc32.c b/arch/sparc/kernel/sys_sparc32.c
index dc0ac19..daded3b 100644
--- a/arch/sparc/kernel/sys_sparc32.c
+++ b/arch/sparc/kernel/sys_sparc32.c
@@ -43,7 +43,6 @@
#include <linux/security.h>
#include <linux/compat.h>
#include <linux/vfs.h>
-#include <linux/netfilter_ipv4/ip_tables.h>
#include <linux/ptrace.h>
#include <asm/types.h>
--
1.6.6.1
^ permalink raw reply related
* Re: linux-next: build failure after final merge (net tree)
From: Stephen Rothwell @ 2010-02-17 6:46 UTC (permalink / raw)
To: David Miller, netdev; +Cc: linux-next, linux-kernel
In-Reply-To: <20100217174015.d1a8a478.sfr@canb.auug.org.au>
[-- Attachment #1: Type: text/plain, Size: 419 bytes --]
On Wed, 17 Feb 2010 17:40:15 +1100 Stephen Rothwell <sfr@canb.auug.org.au> wrote:
>
> Caused by commit 2b95efe7f6bb750256a702cc32d33b0cb2cd8223 ("netfilter:
> xtables: use xt_table for hook instantiation"). Missing direct include
> of linux/netfilter.h?
The address for Jan Engelhardt is bouncing ...
--
Cheers,
Stephen Rothwell sfr@canb.auug.org.au
http://www.canb.auug.org.au/~sfr/
[-- Attachment #2: Type: application/pgp-signature, Size: 198 bytes --]
^ permalink raw reply
* [PATCH] mv643xx_eth: fix missing validate_addr hook
From: Denis Kirjanov <kirjanov@gmail.com @ 2010-02-17 6:40 UTC (permalink / raw)
To: davem; +Cc: netdev
Fix missing validate_addr hook.
Signed-off-by: Denis Kirjanov <kirjanov@gmail.com>
---
drivers/net/mv643xx_eth.c | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/drivers/net/mv643xx_eth.c b/drivers/net/mv643xx_eth.c
index e24072a..2733b0a 100644
--- a/drivers/net/mv643xx_eth.c
+++ b/drivers/net/mv643xx_eth.c
@@ -2846,6 +2846,7 @@ static const struct net_device_ops mv643xx_eth_netdev_ops = {
.ndo_start_xmit = mv643xx_eth_xmit,
.ndo_set_rx_mode = mv643xx_eth_set_rx_mode,
.ndo_set_mac_address = mv643xx_eth_set_mac_address,
+ .ndo_validate_addr = eth_validate_addr,
.ndo_do_ioctl = mv643xx_eth_ioctl,
.ndo_change_mtu = mv643xx_eth_change_mtu,
.ndo_tx_timeout = mv643xx_eth_tx_timeout,
^ permalink raw reply related
* Re: [PATCH net-2.6] net: bug fix for vlan + gro issue
From: Herbert Xu @ 2010-02-17 6:40 UTC (permalink / raw)
To: Ajit Khaparde; +Cc: davem, kaber, netdev
In-Reply-To: <20100217062541.GA10350@serverengines.com>
On Wed, Feb 17, 2010 at 11:55:43AM +0530, Ajit Khaparde wrote:
>
> Here is the patch:-
>
> Traffic (tcp) doesnot start on a vlan interface when gro is enabled.
> Even the tcp handshake was not taking place.
> This is because, the eth_type_trans call before the netif_receive_skb
> in napi_gro_finish() resets the skb->dev to napi->dev from the previously
> set vlan netdev interface. This causes the ip_route_input to drop the
> incoming packet considering it as a packet coming from a martian source.
>
> I could repro this on 2.6.32.7 (stable) and 2.6.33-rc7.
> With this fix, the traffic starts and the test runs fine on both vlan
> and non-vlan interfaces.
>
> CC: Herbert Xu <herbert@gondor.apana.org.au>
> CC: Patrick McHardy <kaber@trash.net>
> Signed-off-by: Ajit Khaparde <ajitk@serverengines.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Thanks a lot!
--
Visit Openswan at http://www.openswan.org/
Email: Herbert Xu ~{PmV>HI~} <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
^ permalink raw reply
* linux-next: build failure after final merge (net tree)
From: Stephen Rothwell @ 2010-02-17 6:40 UTC (permalink / raw)
To: David Miller, netdev; +Cc: linux-next, linux-kernel, Jan Engelhardt
[-- Attachment #1: Type: text/plain, Size: 648 bytes --]
Hi Dave,
After merging, today's linux-next build (sparc64 defconfig) failed like
this:
In file included from include/linux/netfilter_ipv4/ip_tables.h:29,
from arch/sparc/kernel/sys_sparc32.c:47:
include/linux/netfilter/x_tables.h:525: error: expected declaration specifiers or '...' before 'nf_hookfn'
Caused by commit 2b95efe7f6bb750256a702cc32d33b0cb2cd8223 ("netfilter:
xtables: use xt_table for hook instantiation"). Missing direct include
of linux/netfilter.h?
I have reverted that commit for today.
--
Cheers,
Stephen Rothwell sfr@canb.auug.org.au
http://www.canb.auug.org.au/~sfr/
[-- Attachment #2: Type: application/pgp-signature, Size: 198 bytes --]
^ permalink raw reply
* [RFC] Large Ethtool Register Dumps
From: Benjamin Li @ 2010-02-17 6:38 UTC (permalink / raw)
To: netdev; +Cc: Jeff Garzik, David Miller, Amir Frankel
Hi All,
Amir and I were planning to include a routine to dump out relevant
register and memory contents from the hardware driven by the bnx2x
driver. This is so we can be better prepared for debugging issues out
in the field. The problem with this is that for an entire
register/memory dump it is about 6MB. Because in the
net/core/ethtool.c:ethtool_get_regs() function, kmalloc() is used to
allocate space for the register dump, sometimes this will fail because
it can't get 6MB of contiguous space.
Currently, we have a patch to the bnx2x driver which will break each
part of the dump into multiple chunks and a chunk would be returned with
every `ethtool -d` call. (This is to get around the memory limiation)
But this is not a very friendly user experience. I was wondering what
would be the preferred way in handling this situation.
1. Modify the user space utility ethtool to call the ethtool ioctl with
the ethtool command, ETHTOOL_GREGS, mutiliple times under the covers in
the routine ethtool.c:do_gregs() only for the bnx2x driver. For
example, the user would only have to run `ethtool -d <eth#>` once; and
underneath if using strace we would see multiple ethool ioctl's being
called for getting the registers. This way none of the kernel code
changes and bnx2x driver would be the first to call the ethool ioctl to
get a register dump multiple times.
2. Modify net/core/ethtool.c:ethtool_get_regs() to use vmalloc() so
that we can allocate enough memory to keep all the register contents at
once? Is it critical that contiguous space be allocated for where the
register dump is going to be stored?
3. Add an additionial ethtool cmd so that there is a new ethtool
command to just read a single register rather then the current ethtool
registers dump. All the business logic in formatting the register dump
is placed in the driver specific user space ethtool application.
4. From Jeff Garzik:
> If we start talking about arbitrarily large outputs, it gets
> increasingly hard to stuff via an ioctl.
>
> I would rather see userspace open a file descriptor that can be
read(2)
> or mmap(2)'d, to access large regions of EEPROM or register space.
>
> Also, it would be preferred to ask this sort of question on
> netdev@vger.kernel.org (cc'ing me if you'd like), so that we all can
> collaborate on design.
>
> Jeff
>
Any guidance anyone could give would be greatly appreciated.
Thanks again.
-Ben
^ permalink raw reply
* Re: [PATCH net-2.6] net: bug fix for vlan + gro issue
From: Ajit Khaparde @ 2010-02-17 6:25 UTC (permalink / raw)
To: Herbert Xu; +Cc: davem, kaber, netdev
In-Reply-To: <20100216114015.GB31642@gondor.apana.org.au>
On 16/02/10 19:40 +0800, Herbert Xu wrote:
> On Fri, Feb 12, 2010 at 11:04:53AM +0530, Ajit Khaparde wrote:
> >
> > diff --git a/net/core/dev.c b/net/core/dev.c
> > index be9924f..16aac06 100644
> > --- a/net/core/dev.c
> > +++ b/net/core/dev.c
> > @@ -2761,7 +2761,10 @@ gro_result_t napi_frags_finish(struct napi_struct *napi, struct sk_buff *skb,
> > switch (ret) {
> > case GRO_NORMAL:
> > case GRO_HELD:
> > - skb->protocol = eth_type_trans(skb, napi->dev);
> > + if (skb->vlan_tci)
> > + skb->protocol = eth_type_trans(skb, skb->dev);
> > + else
> > + skb->protocol = eth_type_trans(skb, napi->dev);
>
> We should be able to just use skb->dev here.
Thanks Herbert. I think you meant something like this:
+ skb->protocol = eth_type_trans(skb, skb->dev);
Here is the patch:-
Traffic (tcp) doesnot start on a vlan interface when gro is enabled.
Even the tcp handshake was not taking place.
This is because, the eth_type_trans call before the netif_receive_skb
in napi_gro_finish() resets the skb->dev to napi->dev from the previously
set vlan netdev interface. This causes the ip_route_input to drop the
incoming packet considering it as a packet coming from a martian source.
I could repro this on 2.6.32.7 (stable) and 2.6.33-rc7.
With this fix, the traffic starts and the test runs fine on both vlan
and non-vlan interfaces.
CC: Herbert Xu <herbert@gondor.apana.org.au>
CC: Patrick McHardy <kaber@trash.net>
Signed-off-by: Ajit Khaparde <ajitk@serverengines.com>
---
net/core/dev.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/net/core/dev.c b/net/core/dev.c
index be9924f..ec87421 100644
--- a/net/core/dev.c
+++ b/net/core/dev.c
@@ -2761,7 +2761,7 @@ gro_result_t napi_frags_finish(struct napi_struct *napi, struct sk_buff *skb,
switch (ret) {
case GRO_NORMAL:
case GRO_HELD:
- skb->protocol = eth_type_trans(skb, napi->dev);
+ skb->protocol = eth_type_trans(skb, skb->dev);
if (ret == GRO_HELD)
skb_gro_pull(skb, -ETH_HLEN);
--
1.6.3.3
^ permalink raw reply related
* Re: [net-next PATCH] via-velocity: Enable scatter/gather IO by default
From: David Miller @ 2010-02-17 6:23 UTC (permalink / raw)
To: simon.kagstrom; +Cc: netdev, krkumar2
In-Reply-To: <20100217071944.14183e50@marrow.netinsight.se>
From: Simon Kagstrom <simon.kagstrom@netinsight.net>
Date: Wed, 17 Feb 2010 07:19:44 +0100
> Well I reenabled it here:
>
> http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=c79992fddee28bbd31b35ac297e1068d32930179
>
> it was also cleaned up to remove all the #ifdefs around that code.
Ok, great.
I'll apply this patch to turn it on by default then.
^ permalink raw reply
* Re: [net-next PATCH] via-velocity: Enable scatter/gather IO by default
From: Simon Kagstrom @ 2010-02-17 6:19 UTC (permalink / raw)
To: David Miller; +Cc: netdev, krkumar2
In-Reply-To: <20100216.162015.77292959.davem@davemloft.net>
On Tue, 16 Feb 2010 16:20:15 -0800 (PST)
David Miller <davem@davemloft.net> wrote:
> > Reduces CPU utilization significantly with sendfile for example.
> >
> > Signed-off-by: Simon Kagstrom <simon.kagstrom@netinsight.net>
>
> I think you need to have a look at this patch before making
> a change like this:
>
> commit 83c98a8cd04dd0f848574370594886ba3bf56750
> Author: Dave Jones <davej@redhat.com>
> Date: Tue Jul 21 09:15:49 2009 +0000
>
> Remove unused zero-copy code from velocity NIC driver.
>
> This code hasn't been enabled in forever.
Well I reenabled it here:
http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=c79992fddee28bbd31b35ac297e1068d32930179
it was also cleaned up to remove all the #ifdefs around that code.
// Simon
^ permalink raw reply
* Re: [PATCH] atm : fix /sys/devices/virtual/atm/X/carrier(ATM_PHY_SIG_UNKNOWN)
From: David Miller @ 2010-02-17 6:16 UTC (permalink / raw)
To: chas3, chas; +Cc: phdm, netdev
In-Reply-To: <201002142134.o1ELYehH019725@thirdoffive.cmf.nrl.navy.mil>
From: "Chas Williams (CONTRACTOR)" <chas@cmf.nrl.navy.mil>
Date: Sun, 14 Feb 2010 16:34:40 -0500
> as i said before there is carrier or there is not. if the driver
> doesnt support checking/knowing the carrier status it should simply
> say 'yes i have carrier'.
I agree %100 and this is how we handle similar situations
for other networking device types.
^ permalink raw reply
* Re: [PATCH 0/2] Staging: Clean up octeon Ethernet some.
From: Greg KH @ 2010-02-17 4:58 UTC (permalink / raw)
To: David Daney; +Cc: Ralf Baechle, linux-mips, Netdev
In-Reply-To: <4B7B4540.1010700@caviumnetworks.com>
On Tue, Feb 16, 2010 at 05:24:16PM -0800, David Daney wrote:
> These two patches clean up some comments and get rid of the code that
> creates a non-standard file in /proc
>
> As with the previous octeon_ethernet patches, these can probably go
> via Ralf's linux-mips.org tree.
Going through Ralf's tree is fine for me.
thanks,
greg k-h
^ permalink raw reply
* [PATCH] ipv6.h: reassembly: replace calculated magic number with multiplication
From: Joe Perches @ 2010-02-17 4:40 UTC (permalink / raw)
To: Patrick McHardy; +Cc: Shan Wei, davem, netdev, netfilter-devel
In-Reply-To: <4B7ABDF8.8010004@trash.net>
On Tue, 2010-02-16 at 16:47 +0100, Patrick McHardy wrote:
> Joe Perches wrote:
> >> @@ -246,6 +246,8 @@ extern int ipv6_opt_accepted(struct sock *sk, struct sk_buff *skb);
> >> int ip6_frag_nqueues(struct net *net);
> >> int ip6_frag_mem(struct net *net);
> >>
> >> +#define IPV6_FRAG_HIGH_THRESH 262144 /* == 256*1024 */
> >> +#define IPV6_FRAG_LOW_THRESH 196608 /* == 192*1024 */
> >> #define IPV6_FRAG_TIMEOUT (60*HZ) /* 60 seconds */
> >
> > 196608 isn't a number I want to remember.
> > Is this better as:
> >
> > #define IPV6_FRAG_HIGH_THRESH (256 * 1024) /* 262144 */
> > #define IPV6_FRAG_LOW_THRESH (192 * 1024) /* 196608 */
>
> Please send a patch, I'll apply it once these patches are in Dave's
> tree.
Signed-off-by: Joe Perches <joe@perches.com>
diff --git a/include/net/ipv6.h b/include/net/ipv6.h
index 639ec53..d067db1 100644
--- a/include/net/ipv6.h
+++ b/include/net/ipv6.h
@@ -246,9 +246,9 @@ extern int ipv6_opt_accepted(struct sock *sk, struct sk_buff *skb);
int ip6_frag_nqueues(struct net *net);
int ip6_frag_mem(struct net *net);
-#define IPV6_FRAG_HIGH_THRESH 262144 /* == 256*1024 */
-#define IPV6_FRAG_LOW_THRESH 196608 /* == 192*1024 */
-#define IPV6_FRAG_TIMEOUT (60*HZ) /* 60 seconds */
+#define IPV6_FRAG_HIGH_THRESH (256 * 1024) /* 262144 */
+#define IPV6_FRAG_LOW_THRESH (192 * 1024) /* 196608 */
+#define IPV6_FRAG_TIMEOUT (60 * HZ) /* 60 seconds */
extern int __ipv6_addr_type(const struct in6_addr *addr);
static inline int ipv6_addr_type(const struct in6_addr *addr)
^ permalink raw reply related
* IxGbE: Node Aware Descriptor (Ring) Allocation
From: Tadepalli, Hari K @ 2010-02-17 4:28 UTC (permalink / raw)
To: netdev@vger.kernel.org
In-Reply-To: <41885A88D9043444B138491FB10E15420476DD1805@azsmsx506.amr.corp.intel.com>
Greetings! This is my first post to this list. So please bear with any protocol violations.
I am looking for hints on NUMA node-aware packet descriptor ring allocation in the IxGbE driver for Intel 82599 (10Gb) NICs, with multi queue feature enabled.
There are three places in the IxGbE source where we need node aware allocation (shown below for TX only; analogous code for RX assumed):
(i) tx_ring, rx_ring control structures of tx/rx rings:
tx_ring->tx_buffer_info = vmalloc_node(size, tx_ring->numa_node);
(ii) descriptor rings in the DMA region: tx_ring->dma, rx_ring->dma
tx_ring->desc = pci_alloc_consistent(pdev, tx_ring->size, &tx_ring->dma);
(iii) packet buffers:
struct sk_buff *skb = netdev_alloc_skb(adapter->netdev,bufsz);
(i) and (iii) are able take a node parameter and accordingly return with node-aware allocation (on x86_64/NUMA enabled kernel with SLUB allocator). But, the same is not true of (ii) for descriptor ring allocation. Adding a node_id parameter to pdev structure with set_dev_node() call has no effect - presumably because the underlying dma_alloc_coherent() call has no node awareness.
I have, hacked pci_alloc_consistent to ingest a node parameter & allocate with dma_generic_alloc_coherent(), which seems to allocate with alloc_pages_node() after stripping node parameter from the pdev->dev object. But, this did not work - I can dump TXD/RXD base addresses with ethregs tool & observe that all allocations are coming from only one of the two nodes present in Nehalem (Xeon 55xx) platforms.
What is the status of node-aware DMA region allocation for IO devices on x86_64 platforms? Any known fixes?
Thanks,
Hari
------------------------------------
Intel/Embedded Comms/Chandler/AZ
^ permalink raw reply
* Re: [PATCH net-next 2/2] percpu: add __percpu sparse annotations to net drivers
From: David Miller @ 2010-02-17 4:21 UTC (permalink / raw)
To: tj; +Cc: linux-kernel, netdev, sfr
In-Reply-To: <4B7B4484.4060909@kernel.org>
From: Tejun Heo <tj@kernel.org>
Date: Wed, 17 Feb 2010 10:21:08 +0900
> Add __percpu sparse annotations to net drivers.
>
> These annotations are to make sparse consider percpu variables to be
> in a different address space and warn if accessed without going
> through percpu accessors. This patch doesn't affect normal builds.
>
> Signed-off-by: Tejun Heo <tj@kernel.org>
> Acked-by: David S. Miller <davem@davemloft.net>
Applied.
^ permalink raw reply
* Re: [PATCH net-next 1/2] percpu: add __percpu sparse annotations to net
From: David Miller @ 2010-02-17 4:21 UTC (permalink / raw)
To: tj; +Cc: linux-kernel, netdev, sfr
In-Reply-To: <4B7B445A.1080108@kernel.org>
From: Tejun Heo <tj@kernel.org>
Date: Wed, 17 Feb 2010 10:20:26 +0900
> Add __percpu sparse annotations to net.
>
> These annotations are to make sparse consider percpu variables to be
> in a different address space and warn if accessed without going
> through percpu accessors. This patch doesn't affect normal builds.
>
> The macro and type tricks around snmp stats make things a bit
> interesting. DEFINE/DECLARE_SNMP_STAT() macros mark the target field
> as __percpu and SNMP_UPD_PO_STATS() macro is updated accordingly. All
> snmp_mib_*() users which used to cast the argument to (void **) are
> updated to cast it to (void __percpu **).
>
> Signed-off-by: Tejun Heo <tj@kernel.org>
> Acked-by: David S. Miller <davem@davemloft.net>
Applied.
^ permalink raw reply
* Re: xfrm: avoid spinlock in get_acqseq() used by xfrm user
From: David Miller @ 2010-02-17 4:20 UTC (permalink / raw)
To: hadi; +Cc: eric.dumazet, netdev
In-Reply-To: <1266321682.6776.254.camel@bigi>
From: jamal <hadi@cyberus.ca>
Date: Tue, 16 Feb 2010 07:01:22 -0500
> Eric's version fixed it for pfkey. This one is for xfrm user.
> I thought about amortizing those two get_acqseq()s but it seems
> reasonable to have two of these sequence spaces for the two different
> interfaces.
Applied, thanks Jamal.
^ permalink raw reply
* Re: [PATCH] netdev: bfin_mac: drop experimental markings on RMII support
From: David Miller @ 2010-02-17 4:20 UTC (permalink / raw)
To: vapier; +Cc: netdev, uclinux-dist-devel
In-Reply-To: <1266280370-18670-1-git-send-email-vapier@gentoo.org>
From: Mike Frysinger <vapier@gentoo.org>
Date: Mon, 15 Feb 2010 19:32:50 -0500
> The code has been around for a long time now and is known to work on a
> bunch of different parts/boards.
>
> Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Applied to net-next-2.6
^ permalink raw reply
page: next (older) | prev (newer) | latest
- recent:[subjects (threaded)|topics (new)|topics (active)]
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox