Netdev List
 help / color / mirror / Atom feed
* [PATCH 0/2] net-next codel enhancements
From: Dave Taht @ 2013-10-22  1:19 UTC (permalink / raw)
  To: netdev, codel

These two patches have been extensively tested in openwrt
and cerowrt. Losing the fq_codel drop statistic as a bug.

Checking for a maxpacket size in the qdisc was somewhat 
correct for ns2 but not for Linux as all the current 
subsystems below htb/hfsc/adsl/bql buffer packets.

IMHO both of these patches are candidates for stable. 

^ permalink raw reply

* BUG: scheduling while atomic dev_set_promiscuity->__dev_notify_flags
From: Alexei Starovoitov @ 2013-10-22  1:04 UTC (permalink / raw)
  To: Nicolas Dichtel; +Cc: netdev

Hi Nicolas,

after commit 991fb3f74c "dev: always advertise rx_flags changes via netlink"
I'm seeing 'sleeping in atomic' bug.

Steps to reproduce:
ip tuntap add dev tap1 mode tap
ifconfig tap1 up
tcpdump -nei tap1
and in different terminal:
ip tuntap del dev tap1 mode tap

[  271.627994] device tap1 left promiscuous mode
[  271.639897] BUG: sleeping function called from invalid context at
mm/slub.c:940
[  271.664491] in_atomic(): 1, irqs_disabled(): 0, pid: 3394, name: ip
[  271.677525] INFO: lockdep is turned off.
[  271.690503] CPU: 0 PID: 3394 Comm: ip Tainted: G        W    3.12.0-rc3+ #73
[  271.703996] Hardware name: System manufacturer System Product
Name/P8Z77 WS, BIOS 3007 07/26/2012
[  271.731254]  ffffffff81a58506 ffff8807f0d57a58 ffffffff817544e5
ffff88082fa0f428
[  271.760261]  ffff8808071f5f40 ffff8807f0d57a88 ffffffff8108bad1
ffffffff81110ff8
[  271.790683]  0000000000000010 00000000000000d0 00000000000000d0
ffff8807f0d57af8
[  271.822332] Call Trace:
[  271.838234]  [<ffffffff817544e5>] dump_stack+0x55/0x76
[  271.854446]  [<ffffffff8108bad1>] __might_sleep+0x181/0x240
[  271.870836]  [<ffffffff81110ff8>] ? rcu_irq_exit+0x68/0xb0
[  271.887076]  [<ffffffff811a80be>] kmem_cache_alloc_node+0x4e/0x2a0
[  271.903368]  [<ffffffff810b4ddc>] ? vprintk_emit+0x1dc/0x5a0
[  271.919716]  [<ffffffff81614d67>] ? __alloc_skb+0x57/0x2a0
[  271.936088]  [<ffffffff810b4de0>] ? vprintk_emit+0x1e0/0x5a0
[  271.952504]  [<ffffffff81614d67>] __alloc_skb+0x57/0x2a0
[  271.968902]  [<ffffffff8163a0b2>] rtmsg_ifinfo+0x52/0x100
[  271.985302]  [<ffffffff8162ac6d>] __dev_notify_flags+0xad/0xc0
[  272.001642]  [<ffffffff8162ad0c>] __dev_set_promiscuity+0x8c/0x1c0
[  272.017917]  [<ffffffff81731ea5>] ? packet_notifier+0x5/0x380
[  272.033961]  [<ffffffff8162b109>] dev_set_promiscuity+0x29/0x50
[  272.049855]  [<ffffffff8172e937>] packet_dev_mc+0x87/0xc0
[  272.065494]  [<ffffffff81732052>] packet_notifier+0x1b2/0x380
[  272.080915]  [<ffffffff81731ea5>] ? packet_notifier+0x5/0x380
[  272.096009]  [<ffffffff81761c66>] notifier_call_chain+0x66/0x150
[  272.110803]  [<ffffffff8108503e>] __raw_notifier_call_chain+0xe/0x10
[  272.125468]  [<ffffffff81085056>] raw_notifier_call_chain+0x16/0x20
[  272.139984]  [<ffffffff81620190>] call_netdevice_notifiers_info+0x40/0x70
[  272.154523]  [<ffffffff816201d6>] call_netdevice_notifiers+0x16/0x20
[  272.168552]  [<ffffffff816224c5>] rollback_registered_many+0x145/0x240
[  272.182263]  [<ffffffff81622641>] rollback_registered+0x31/0x40
[  272.195369]  [<ffffffff816229c8>] unregister_netdevice_queue+0x58/0x90
[  272.208230]  [<ffffffff81547ca0>] __tun_detach+0x140/0x340
[  272.220686]  [<ffffffff81547ed6>] tun_chr_close+0x36/0x60

packet_notifier() does rcu_read_lock() before calling into packet_dev_mc() .

Not sure how to fix it cleanly, other than disabling a notify here.
Any suggestion?

Thanks
Alexei

^ permalink raw reply

* [PATCH] 3c59x: fix incorrect use of spin_lock_bh in interrupts
From: Mikulas Patocka @ 2013-10-21 23:53 UTC (permalink / raw)
  To: Steffen Klassert, David S. Miller; +Cc: netdev

The functions mdio_read and mdio_write may be called from interrupt
context. Consequently, we must use spin_lock_irqsave instead of
spin_lock_bh.

This patch should be backported to stable kernels.

This patch fixes the following warning.

eth0: Host error, FIFO diagnostic register 8000.
eth0: PCI bus error, bus status 80000020
------------[ cut here ]------------
WARNING: at kernel/softirq.c:159 local_bh_enable+0x68/0x90()
Hardware name: Latitude C600
Modules linked in: ipv6 freq_table speedstep_lib parport_pc parport 8250
serial_core apm 8139too bitrev crc32 snd_maestro3 snd_ac97_codec ac97_bus
snd_pcm_oss snd_mixer_oss snd_pcm uhci_hcd microcode
snd_timer snd_page_alloc rtc_cmos ide_cd_mod intel_agp pcspkr usbcore
psmouse snd cdrom intel_gtt soundcore i2c_piix4 3c59x agpgart mii
yenta_socket i2c_core pcmcia_core pcmcia_rsrc usb_common unix
Pid: 1134, comm: ifconfig Tainted: G        W    3.4.66 #2
Call Trace:
[<c101ff38>] ? warn_slowpath_common+0x78/0xb0
[<c1024f58>] ? local_bh_enable+0x68/0x90
[<c1024f58>] ? local_bh_enable+0x68/0x90
[<c101ff89>] ? warn_slowpath_null+0x19/0x20
[<c1024f58>] ? local_bh_enable+0x68/0x90
[<d895a1eb>] ? mdio_read+0x11b/0x160 [3c59x]
[<d895a9d6>] ? vortex_up+0x166/0x6c0 [3c59x]
[<d89590f5>] ? issue_and_wait+0x35/0xd0 [3c59x]
[<d895b2ca>] ? vortex_down+0xda/0x170 [3c59x]
[<d895b72e>] ? vortex_error+0x39e/0x3d0 [3c59x]
[<c1183097>] ? serio_interrupt+0x47/0xa0
[<d895c481>] ? boomerang_interrupt+0x241/0x340 [3c59x]
[<c105db7d>] ? handle_irq_event_percpu+0x2d/0x140
[<c105fd20>] ? cond_unmask_irq+0x40/0x40
[<c105dcc6>] ? handle_irq_event+0x36/0x60
[<c105fd73>] ? handle_level_irq+0x53/0xa0
<IRQ>  [<c1003a8a>] ? do_IRQ+0x3a/0xa0
[<c1210929>] ? common_interrupt+0x29/0x30
[<c105007b>] ? futex_lock_pi.isra.22+0x23b/0x300
[<c105eb26>] ? __setup_irq+0x1d6/0x410
[<d895c240>] ? rx_oom_timer+0x50/0x50 [3c59x]
[<c105ee12>] ? request_threaded_irq+0xb2/0x150
[<d895afc9>] ? vortex_open+0x39/0x1f0 [3c59x]
[<c11a8ec3>] ? __dev_open+0x83/0xe0
[<c11a9139>] ? __dev_change_flags+0x89/0x170
[<c11a78df>] ? dev_get_by_name_rcu+0x4f/0x70
[<c11a92bb>] ? dev_change_flags+0x1b/0x60
[<c11f301e>] ? devinet_ioctl+0x55e/0x6f0
[<c11a9acf>] ? dev_ioctl+0x35f/0x5a0
[<c11944b4>] ? sock_ioctl+0x54/0x260
[<c1087443>] ? handle_mm_fault+0x123/0x180
[<c1194460>] ? sock_fasync+0x90/0x90
[<c10b00c1>] ? do_vfs_ioctl+0x81/0x5e0
[<c10197f1>] ? do_page_fault+0x161/0x420
[<c109e5b7>] ? fd_install+0x47/0x80
[<c10add76>] ? user_path_at+0x16/0x20
[<c109f0ae>] ? sys_faccessat+0x11e/0x1c0
[<c10b064e>] ? sys_ioctl+0x2e/0x60
[<c1210410>] ? sysenter_do_call+0x12/0x26
---[ end trace 5d85da266ec9ff9b ]---

Signed-off-by: Mikulas Patocka <mpatocka@redhat.com>

---
 drivers/net/ethernet/3com/3c59x.c |   10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)

Index: linux-3.4.66/drivers/net/ethernet/3com/3c59x.c
===================================================================
--- linux-3.4.66.orig/drivers/net/ethernet/3com/3c59x.c	2013-10-22 01:34:44.000000000 +0200
+++ linux-3.4.66/drivers/net/ethernet/3com/3c59x.c	2013-10-22 01:35:37.000000000 +0200
@@ -3126,8 +3126,9 @@ static int mdio_read(struct net_device *
 	struct vortex_private *vp = netdev_priv(dev);
 	int read_cmd = (0xf6 << 10) | (phy_id << 5) | location;
 	unsigned int retval = 0;
+	unsigned long flags;
 
-	spin_lock_bh(&vp->mii_lock);
+	spin_lock_irqsave(&vp->mii_lock, flags);
 
 	if (mii_preamble_required)
 		mdio_sync(vp, 32);
@@ -3153,7 +3154,7 @@ static int mdio_read(struct net_device *
 		mdio_delay(vp);
 	}
 
-	spin_unlock_bh(&vp->mii_lock);
+	spin_unlock_irqrestore(&vp->mii_lock, flags);
 
 	return retval & 0x20000 ? 0xffff : retval>>1 & 0xffff;
 }
@@ -3163,8 +3164,9 @@ static void mdio_write(struct net_device
 	struct vortex_private *vp = netdev_priv(dev);
 	int write_cmd = 0x50020000 | (phy_id << 23) | (location << 18) | value;
 	int i;
+	unsigned long flags;
 
-	spin_lock_bh(&vp->mii_lock);
+	spin_lock_irqsave(&vp->mii_lock, flags);
 
 	if (mii_preamble_required)
 		mdio_sync(vp, 32);
@@ -3187,7 +3189,7 @@ static void mdio_write(struct net_device
 		mdio_delay(vp);
 	}
 
-	spin_unlock_bh(&vp->mii_lock);
+	spin_unlock_irqrestore(&vp->mii_lock, flags);
 }
 
 /* ACPI: Advanced Configuration and Power Interface. */

^ permalink raw reply

* Re: [BUG] 3.12.0-rcX IPv6 panic
From: Bob Tracy @ 2013-10-21 23:40 UTC (permalink / raw)
  To: linux-kernel, netdev
In-Reply-To: <20131021155252.GA24158@order.stressinduktion.org>

On Mon, Oct 21, 2013 at 05:52:52PM +0200, Hannes Frederic Sowa wrote:
> On Mon, Oct 21, 2013 at 08:18:46AM -0500, Bob Tracy wrote:
> > Actually, a regression: the 3.11 kernel is rock-solid stable on my
> > Alpha.
> > 
> > Beginning with 3.12.0-rc1, I can reliably trigger a kernel panic by
> > executing the gogo6.net "gw6c" IPv6 client program.  If the networking
> > layer is active, an "Oops" will eventually (within a day) occur regardless
> > of whether I attempt to run "gw6c".  3.12.0-rcX is stable as long as I
> > leave networking completely disabled.  The error has persisted up through
> > -rc6.  Apologies for not mentioning this earlier, but the state of my
> > PWS-433au has been questionable, and I wanted to make sure I had a
> > legitimate bug sighting.
> > 
> > I'll have to transcribe the panic backtrace by hand: nothing makes it
> > into any of the system logs :-(.  I *can* recall that every backtrace
> > I've seen thus far has included one of the skb_copy() variants near the
> > top of the list (first or second function).
> 
> Try to capture the panic via serial console. Otherwise a picture
> would give us a first hint. Please watch out for lines like
> skb_(over|under)_panic.

I'll get a screen capture of some kind for you within the next day or
so.

> gw6c is a tunnel client? Can you post ip -6 tunnel ls?

Assuming you meant "show [NAME]" (no "ls" option for the tunnel object),
that yields the following with "gw6c" running on a 3.11.0 kernel:

smirkin:~# ip -6 tunnel show sit1
sit1: any/ipv6 remote 4056:5874:: local 4500:0:0:4000:4029:: encaplimit 0 hoplimit 0 tclass 0x00 flowlabel 0x00000 (flowinfo 0x00000000)

I'm running the gw6c client in gateway mode: the Alpha is my IPv6
gateway/firewall.

--Bob

^ permalink raw reply

* [PATCH] ixgbe: Reduce memory consumption with larger page sizes
From: Anton Blanchard @ 2013-10-21 23:37 UTC (permalink / raw)
  To: Jeff Kirsher; +Cc: netdev, benh


The ixgbe driver allocates pages for its receive rings. It currently
uses 512 pages, regardless of page size. During receive handling it
adds the unused part of the page back into the rx ring, avoiding the
need for a new allocation.

On a ppc64 box with 64 threads and 64kB pages, we end up with
512 entries * 64 rx queues * 64kB = 2GB memory used. Even more of a
concern is that we use up 2GB of IOMMU space in order to map all this
memory.

The driver makes a number of decisions based on if PAGE_SIZE is less
than 8kB, so use this as the breakpoint and only allocate 128 entries
on 8kB or larger page sizes.

Signed-off-by: Anton Blanchard <anton@samba.org>
---

Jeff: The breakpoint and the ring size I chose was pretty arbitrary,
feel free to adjust as you see fit. Our main concern is we get that 2GB
consumption down to something more reasonable :)

Index: b/drivers/net/ethernet/intel/ixgbe/ixgbe.h
===================================================================
--- a/drivers/net/ethernet/intel/ixgbe/ixgbe.h
+++ b/drivers/net/ethernet/intel/ixgbe/ixgbe.h
@@ -67,7 +67,11 @@
 #define IXGBE_MAX_TXD			   4096
 #define IXGBE_MIN_TXD			     64
 
+#if (PAGE_SIZE < 8192)
 #define IXGBE_DEFAULT_RXD		    512
+#else
+#define IXGBE_DEFAULT_RXD		    128
+#endif
 #define IXGBE_MAX_RXD			   4096
 #define IXGBE_MIN_RXD			     64
 

^ permalink raw reply

* Re: [PATCH net 1/2] sit: allow to use rtnl ops on fb tunnel
From: Willem de Bruijn @ 2013-10-21 23:30 UTC (permalink / raw)
  To: nicolas.dichtel
  Cc: David Miller, netdev, steffen.klassert, pshelar, gregkh, stable
In-Reply-To: <524BC816.1000702@6wind.com>

On Wed, Oct 2, 2013 at 3:15 AM, Nicolas Dichtel
<nicolas.dichtel@6wind.com> wrote:
> Le 01/10/2013 18:59, David Miller a écrit :
>
>> From: Nicolas Dichtel <nicolas.dichtel@6wind.com>
>> Date: Tue,  1 Oct 2013 18:04:59 +0200
>>
>>> rtnl ops where introduced by ba3e3f50a0e5 ("sit: advertise tunnel param
>>> via
>>> rtnl"), but I forget to assign rtnl ops to fb tunnels.
>>>
>>> Now that it is done, we must remove the explicit call to
>>> unregister_netdevice_queue(), because  the fallback tunnel is added to
>>> the queue
>>> in sit_destroy_tunnels() when checking rtnl_link_ops of all netdevices
>>> (this
>>> is valid since commit 5e6700b3bf98 ("sit: add support of x-netns")).
>>>
>>> Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com>
>>
>>
>> Applied and queued up for -stable.
>>
>> But I imagine since the x-netns changes aren't in various -stable
>> branches this will need to be adjusted a bit?
>
> Yes, it's what I've tried to say in the commit log ;-)
>
> In fact, before the x-netns changes, we must keep the
> unregister_netdevice_queue() line.

In 3.11 linux-stable, this patch was merged between 3.11.4 and 3.11.5
in commit 3783100, after the x-netns changes in commit 5e6700b3bf, but
the unregister_netdevice_queue was kept.

I think that caused the following bug. In 3.11.6, a simple `modprobe
sit && rmmod sit` hits the BUG at net/core/dev.c:5039:

  BUG_ON(dev->reg_state != NETREG_REGISTERED);

The device is actually NETREG_RELEASED at one point because the device
is now unregistered twice. The issue goes away by porting the
remainder of the original commit: the one liner that removes the call
to unregister_netdevice_queue.

+++ b/net/ipv6/sit.c
@@ -1708,7 +1708,6 @@ static void __net_exit sit_exit_net(struct net *net)

        sit_destroy_tunnels(sitn, &list);
-       unregister_netdevice_queue(sitn->fb_tunnel_dev, &list);
        unregister_netdevice_many(&list);

If correct, let me know if I should send a proper one-line patch
against 3.11.y. Since I haven't looked at this code before, I found it
safer to report the issue first.

5e6700b3bf was not applied to 3.10 stable, so that branch is not affected.

^ permalink raw reply

* Re: [PATCH net] tcp: initialize passive-side sk_pacing_rate after 3WHS
From: David Miller @ 2013-10-21 22:58 UTC (permalink / raw)
  To: eric.dumazet; +Cc: ncardwell, netdev, edumazet, ycheng
In-Reply-To: <1382387794.3284.87.camel@edumazet-glaptop.roam.corp.google.com>

From: Eric Dumazet <eric.dumazet@gmail.com>
Date: Mon, 21 Oct 2013 13:36:34 -0700

> On Mon, 2013-10-21 at 15:40 -0400, Neal Cardwell wrote:
>> For passive TCP connections, upon receiving the ACK that completes the
>> 3WHS, make sure we set our pacing rate after we get our first RTT
>> sample.
> 
>> Signed-off-by: Neal Cardwell <ncardwell@google.com>
>> Cc: Eric Dumazet <edumazet@google.com>
>> Cc: Yuchung Cheng <ycheng@google.com>
>> ---
>>  net/ipv4/tcp_input.c | 2 ++
>>  1 file changed, 2 insertions(+)
>> 
>> diff --git a/net/ipv4/tcp_input.c b/net/ipv4/tcp_input.c
>> index 53974c7..a16b01b 100644
>> --- a/net/ipv4/tcp_input.c
>> +++ b/net/ipv4/tcp_input.c
>> @@ -5712,6 +5712,8 @@ int tcp_rcv_state_process(struct sock *sk, struct sk_buff *skb,
>>  		} else
>>  			tcp_init_metrics(sk);
>>  
>> +		tcp_update_pacing_rate(sk);
>> +
>>  		/* Prevent spurious tcp_cwnd_restart() on first data packet */
>>  		tp->lsndtime = tcp_time_stamp;
>>  
> 
> Seems good to me, thanks !
> 
> Acked-by: Eric Dumazet <edumazet@google.com>

Applied, thanks everyone.

^ permalink raw reply

* Re: [PATCH] mac802154: correct a typo in ieee802154_alloc_device() prototype
From: David Miller @ 2013-10-21 22:58 UTC (permalink / raw)
  To: alexandre.belloni; +Cc: alex.bluesman.smirnov, netdev, linux-kernel
In-Reply-To: <1382375398-17428-1-git-send-email-alexandre.belloni@free-electrons.com>

From: Alexandre Belloni <alexandre.belloni@free-electrons.com>
Date: Mon, 21 Oct 2013 19:09:58 +0200

> This has no other impact than a cosmetic one.
> 
> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com>

Applied.

^ permalink raw reply

* Re: [PATCH] davinci_emac.c: Fix IFF_ALLMULTI setup
From: David Miller @ 2013-10-21 22:57 UTC (permalink / raw)
  To: mceier+kernel
  Cc: mugunthanvnm, prabhakar.csengg, jg1.han, jiri, netdev,
	linux-kernel
In-Reply-To: <1382377504-24688-1-git-send-email-mceier+kernel@gmail.com>

From: Mariusz Ceier <mceier+kernel@gmail.com>
Date: Mon, 21 Oct 2013 19:45:04 +0200

> When IFF_ALLMULTI flag is set on interface and IFF_PROMISC isn't,
> emac_dev_mcast_set should only enable RX of multicasts and reset
> MACHASH registers.
> 
> It does this, but afterwards it either sets up multicast MACs
> filtering or disables RX of multicasts and resets MACHASH registers
> again, rendering IFF_ALLMULTI flag useless.
> 
> This patch fixes emac_dev_mcast_set, so that multicast MACs filtering and
> disabling of RX of multicasts are skipped when IFF_ALLMULTI flag is set.
> 
> Tested with kernel 2.6.37.
> 
> Signed-off-by: Mariusz Ceier <mceier+kernel@gmail.com>

Applied and queued up for -stable, thanks.

^ permalink raw reply

* Re: [PATCH net] ipv6: probe routes asynchronous in rt6_probe
From: David Miller @ 2013-10-21 22:57 UTC (permalink / raw)
  To: hannes; +Cc: netdev, ja
In-Reply-To: <20131021041715.GH27787@order.stressinduktion.org>

From: Hannes Frederic Sowa <hannes@stressinduktion.org>
Date: Mon, 21 Oct 2013 06:17:15 +0200

> Routes need to be probed asynchronous otherwise the call stack gets
> exhausted when the kernel attemps to deliver another skb inline, like
> e.g. xt_TEE does, and we probe at the same time.
> 
> We update neigh->updated still at once, otherwise we would send to
> many probes.
> 
> Cc: Julian Anastasov <ja@ssi.bg>
> Signed-off-by: Hannes Frederic Sowa <hannes@stressinduktion.org>

Looks good, applied and queued up for -stable, thanks Hannes.

^ permalink raw reply

* Re: [PATCH 1/1] [PATCH] ax88179_178a: Correct the RX error definition in RX header
From: David Miller @ 2013-10-21 22:55 UTC (permalink / raw)
  To: freddy; +Cc: linux-usb, linux-kernel, netdev, louis, allan
In-Reply-To: <1382337460-2036-1-git-send-email-freddy@asix.com.tw>

From: freddy@asix.com.tw
Date: Mon, 21 Oct 2013 14:37:40 +0800

> From: Freddy Xin <freddy@asix.com.tw>
> 
> Correct the definition of AX_RXHDR_CRC_ERR and
> AX_RXHDR_DROP_ERR. They are BIT29 and BIT31 in pkt_hdr
> seperately.
> Add VID:DID for Samsung USB Ethernet Adapter.
> 
> Signed-off-by: Freddy Xin <freddy@asix.com.tw>

Do not do two logically different things in one patch.

Fix the register bit definitions in one patch, then add the
new device IDs in another.

^ permalink raw reply

* Re: [PATCH net-next 0/3] ipv6: sit: Implement TSO/GSO support
From: David Miller @ 2013-10-21 22:50 UTC (permalink / raw)
  To: edumazet; +Cc: netdev, hkchu, eilong, ek, therbert
In-Reply-To: <1382327251-21079-1-git-send-email-edumazet@google.com>

From: Eric Dumazet <edumazet@google.com>
Date: Sun, 20 Oct 2013 20:47:28 -0700

> This patch serie implements GSO/TSO support for SIT tunnels

Looks good, thanks for the descriptive cover posting it helps
a lot.

All applied to net-next.

^ permalink raw reply

* Re: [PATCH v2] chelsio: remove duplicate defines
From: David Miller @ 2013-10-21 22:47 UTC (permalink / raw)
  To: michael.opdenacker; +Cc: divy, netdev, linux-kernel
In-Reply-To: <1382332189-5596-1-git-send-email-michael.opdenacker@free-electrons.com>

From: Michael Opdenacker <michael.opdenacker@free-electrons.com>
Date: Mon, 21 Oct 2013 07:09:49 +0200

> This removes multiple duplicate definitions
> in drivers/net/ethernet/chelsio/cxgb3/regs.h
> 
> Signed-off-by: Michael Opdenacker <michael.opdenacker@free-electrons.com>

Applied.

^ permalink raw reply

* Re: [PATCH] atm: firestream: remove duplicate define
From: David Miller @ 2013-10-21 22:47 UTC (permalink / raw)
  To: chas; +Cc: michael.opdenacker, linux-atm-general, netdev, linux-kernel
In-Reply-To: <20131021075335.5c9e4490@thirdoffive.cmf.nrl.navy.mil>

From: chas williams - CONTRACTOR <chas@cmf.nrl.navy.mil>
Date: Mon, 21 Oct 2013 07:53:35 -0400

> Acked-by: Chas Williams <chas@cmf.nrl.navy.mil>
> 
> On Mon, 21 Oct 2013 10:12:41 +0200
> Michael Opdenacker <michael.opdenacker@free-electrons.com> wrote:
> 
>> This patch removes a duplicate define in drivers/atm/firestream.h
>> 
>> Signed-off-by: Michael Opdenacker <michael.opdenacker@free-electrons.com>

Applied.

^ permalink raw reply

* Re: [PATCH] ethernet: moxa: remove duplicate includes
From: David Miller @ 2013-10-21 22:47 UTC (permalink / raw)
  To: michael.opdenacker; +Cc: netdev, linux-kernel
In-Reply-To: <1382246036-19253-1-git-send-email-michael.opdenacker@free-electrons.com>

From: Michael Opdenacker <michael.opdenacker@free-electrons.com>
Date: Sun, 20 Oct 2013 07:13:56 +0200

> Reported by "make includecheck"
> 
> Tested that drivers/net/ethernet/moxa/moxart_ether.c still compiles
> well on ARM
> 
> Signed-off-by: Michael Opdenacker <michael.opdenacker@free-electrons.com>

Applied.

^ permalink raw reply

* Re: [PATCH] cgxb4: remove duplicate include in cxgb4.h
From: David Miller @ 2013-10-21 22:47 UTC (permalink / raw)
  To: michael.opdenacker; +Cc: dm, netdev, linux-kernel
In-Reply-To: <1382245801-19192-1-git-send-email-michael.opdenacker@free-electrons.com>

From: Michael Opdenacker <michael.opdenacker@free-electrons.com>
Date: Sun, 20 Oct 2013 07:10:01 +0200

> Reported by "make includecheck"
> 
> Tested that C sources including this file still compile well on x86
> 
> Signed-off-by: Michael Opdenacker <michael.opdenacker@free-electrons.com>

Applied.

^ permalink raw reply

* Re: [PATCH] Revert "bridge: only expire the mdb entry when query is received"
From: David Miller @ 2013-10-21 22:45 UTC (permalink / raw)
  To: linus.luessing; +Cc: stephen, netdev, bridge, linux-kernel, amwang
In-Reply-To: <1382223537-10844-1-git-send-email-linus.luessing@web.de>

From: Linus Lüssing <linus.luessing@web.de>
Date: Sun, 20 Oct 2013 00:58:57 +0200

> While this commit was a good attempt to fix issues occuring when no
> multicast querier is present, this commit still has two more issues:
> 
> 1) There are cases where mdb entries do not expire even if there is a
> querier present. The bridge will unnecessarily continue flooding
> multicast packets on the according ports.
> 
> 2) Never removing an mdb entry could be exploited for a Denial of
> Service by an attacker on the local link, slowly, but steadily eating up
> all memory.
> 
> Actually, this commit became obsolete with
> "bridge: disable snooping if there is no querier" (b00589af3b)
> which included fixes for a few more cases.
> 
> Therefore reverting the following commits (the commit stated in the
> commit message plus three of its follow up fixes):
> 
> ---
> Revert "bridge: update mdb expiration timer upon reports."
> This reverts commit f144febd93d5ee534fdf23505ab091b2b9088edc.
> Revert "bridge: do not call setup_timer() multiple times"
> This reverts commit 1faabf2aab1fdaa1ace4e8c829d1b9cf7bfec2f1.
> Revert "bridge: fix some kernel warning in multicast timer"
> This reverts commit c7e8e8a8f7a70b343ca1e0f90a31e35ab2d16de1.
> Revert "bridge: only expire the mdb entry when query is received"
> This reverts commit 9f00b2e7cf241fa389733d41b615efdaa2cb0f5b.
> ---

Cong, and other bridge folks, please review this revert.

Thanks.

^ permalink raw reply

* Re: [PATCH 0/6] ipv4: tcp_memcontrol and userns sysctls
From: David Miller @ 2013-10-21 22:44 UTC (permalink / raw)
  To: ebiederm-aS9lmoZGLiVWk0Htik3J/w
  Cc: netdev-u79uwXL29TY76Z2rM5mHXA,
	containers-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA,
	cgroups-u79uwXL29TY76Z2rM5mHXA
In-Reply-To: <87r4bghml4.fsf-aS9lmoZGLiVWk0Htik3J/w@public.gmane.org>

From: ebiederm-aS9lmoZGLiVWk0Htik3J/w@public.gmane.org (Eric W. Biederman)
Date: Sat, 19 Oct 2013 16:23:19 -0700

> While looking into allowing the ipv4 sysctls to be used in a network
> namespace I stumbled upon the mess that is tcp_memcontrol.
> 
> I remove the dead code, broken code, and excessive abstraction in the
> tcp_memcontrols then I clean up up and allow in the user namespace the
> per net ipv4 sysctls.

I wish we hadn't installed this stuff in the first place, but better
to take care of it now than later.

Series applied, thanks Eric.

^ permalink raw reply

* Re: [PATCH net 2/3] ipv6: fill rt6i_gateway with nexthop address
From: David Miller @ 2013-10-21 22:42 UTC (permalink / raw)
  To: ja; +Cc: hannes, netdev, netfilter-devel, lvs-devel, yoshfuji
In-Reply-To: <alpine.LFD.2.03.1310211009270.1522@ssi.bg>

From: Julian Anastasov <ja@ssi.bg>
Date: Mon, 21 Oct 2013 10:31:06 +0300 (EEST)

> 	Thanks for the review! I don't mind too about
> removing rt6_nexthop. For me it is 51% against 49% to keep it
> as it denotes the places that use nexthop and not gateway.
> May be more opinions will help to decide because I don't know
> if there are any plans to use similar techniques as done for IPv4.

I have no strong opinion about removing rt6_nexthop.

If it is of low cost today and makes the code easier to
undersand and grep, just leave it alone.

^ permalink raw reply

* Re: [PATCH net 0/3] ipv6: use rt6i_gateway as nexthop
From: David Miller @ 2013-10-21 22:40 UTC (permalink / raw)
  To: ja; +Cc: netdev, netfilter-devel, lvs-devel, yoshfuji
In-Reply-To: <1382272985-1528-1-git-send-email-ja@ssi.bg>

From: Julian Anastasov <ja@ssi.bg>
Date: Sun, 20 Oct 2013 15:43:02 +0300

> 	I see the following two alternatives for applying these
> patches:
> 
> 1. Linger patch 2 in net-next to avoid surprises in the upcoming
> release. In this case patch 3 can be reworked not to depend on
> the new rt6_nexthop() definition in patch 2. I guess this is a
> better option, so that patch 2 can be reviewed and tested for
> longer time.
> 
> 2. Include all 3 patches in net tree - more risky because this
> is my first attempt to change IPv6.

I have decided to merge all three patches into -net right now.
I've reviewed these patches several times and they look good
to me.

I'll let them cook upstream for at least a week before submitting them
to -stable to let any last minute errors show themselves and
subsequently get resolved.

Thanks!

^ permalink raw reply

* Re: [PATCH net] netpoll: linearize skb before accessing its data
From: David Miller @ 2013-10-21 22:33 UTC (permalink / raw)
  To: eric.dumazet; +Cc: antonio, netdev
In-Reply-To: <1382394336.3284.92.camel@edumazet-glaptop.roam.corp.google.com>

From: Eric Dumazet <eric.dumazet@gmail.com>
Date: Mon, 21 Oct 2013 15:25:36 -0700

> Anyway, how I see nothing sets rx_hook, what am I missing ?

Only out of tree code makes use of this facility, and it's been
this way since the facility was introduced.

Yes, I'm disappointed and unhappy about this too.

^ permalink raw reply

* Re: [PATCH net v2 0/9] bnx2x: Bug fixes patch series
From: David Miller @ 2013-10-21 22:32 UTC (permalink / raw)
  To: yuvalmin; +Cc: netdev, ariele, eilong
In-Reply-To: <1382280694-8428-1-git-send-email-yuvalmin@broadcom.com>

From: "Yuval Mintz" <yuvalmin@broadcom.com>
Date: Sun, 20 Oct 2013 16:51:25 +0200

> This patch series contains fixes for various flows - several SR-IOV issues
> are fixed, ethtool callbacks (coalescing and register dump) are corrected,
> null pointer dereference on error flows is prevented, etc.
> 
> Changes from V1
> ---------------
>  - Patch 2  "bnx2x: Prevent an illegal pointer dereference during panic"
>    is revised, with improved handling of edge cases.

Series applied, thanks for strengthening the address validation in
patch #2.

^ permalink raw reply

* Re: [PATCH net] netpoll: linearize skb before accessing its data
From: Eric Dumazet @ 2013-10-21 22:25 UTC (permalink / raw)
  To: Antonio Quartulli; +Cc: David S. Miller, netdev
In-Reply-To: <1382391080-1607-1-git-send-email-antonio@meshcoding.com>

On Mon, 2013-10-21 at 23:31 +0200, Antonio Quartulli wrote:
> __netpoll_rx() assumes that the data buffer of the received
> skb is linear and then passes it to rx_hook().
> However this is not true because the skb has not been
> linearized yet.
> 
> This can cause rx_hook() to access non allocated memory
> while parsing the received data.
> 
> Fix __netpoll_rx() by explicitly linearising the skb.
> 
> Signed-off-by: Antonio Quartulli <antonio@meshcoding.com>
> ---
> 
> I checked linux-3.0 and this bug seems to be already there. Please consider
> queueing it for stable.
> 
> 
> Regards,
> 
> 
> 
>  net/core/netpoll.c | 5 +++++
>  1 file changed, 5 insertions(+)
> 
> diff --git a/net/core/netpoll.c b/net/core/netpoll.c
> index fc75c9e..97cff18 100644
> --- a/net/core/netpoll.c
> +++ b/net/core/netpoll.c
> @@ -814,6 +814,9 @@ int __netpoll_rx(struct sk_buff *skb, struct netpoll_info *npinfo)
>  		if (pskb_trim_rcsum(skb, len))
>  			goto out;
>  
> +		if (skb_linearize(skb))
> +			goto out;
> +
>  		iph = (struct iphdr *)skb->data;
>  		if (iph->protocol != IPPROTO_UDP)
>  			goto out;
> @@ -855,6 +858,8 @@ int __netpoll_rx(struct sk_buff *skb, struct netpoll_info *npinfo)
>  			goto out;
>  		if (pskb_trim_rcsum(skb, len + sizeof(struct ipv6hdr)))
>  			goto out;
> +		if (skb_linearize(skb))
> +			goto out;
>  		ip6h = ipv6_hdr(skb);
>  		if (!pskb_may_pull(skb, sizeof(struct udphdr)))
>  			goto out;

Well, if you linearize the skb, no need for pskb_may_pull(),
and it would be better to do it once at the beginning...


Anyway, how I see nothing sets rx_hook, what am I missing ?

# git grep -n rx_hook
include/linux/netpoll.h:27:     void (*rx_hook)(struct netpoll *, int, char *, int);
include/linux/netpoll.h:44:     struct list_head rx_np; /* netpolls that registered an rx_hook */
net/core/netpoll.c:639:                 /* If there are several rx_hooks for the same address,
net/core/netpoll.c:722:                 /* If there are several rx_hooks for the same address,
net/core/netpoll.c:837:                 np->rx_hook(np, ntohs(uh->source),
net/core/netpoll.c:875:                 np->rx_hook(np, ntohs(uh->source),
net/core/netpoll.c:1065:        if (np->rx_hook) {

^ permalink raw reply

* Re: [PATCH stable] inet: fix possible memory corruption with UDP_CORK and UFO
From: David Miller @ 2013-10-21 22:25 UTC (permalink / raw)
  To: hannes; +Cc: netdev, jiri, eric.dumazet
In-Reply-To: <20131021220747.GC24158@order.stressinduktion.org>

From: Hannes Frederic Sowa <hannes@stressinduktion.org>
Date: Tue, 22 Oct 2013 00:07:47 +0200

> This is a replacement patch only for stable which does fix the problems
> handled by the following two commits in -net:
> 
> "ip_output: do skb ufo init for peeked non ufo skb as well" (e93b7d748be887cd7639b113ba7d7ef792a7efb9)
> "ip6_output: do skb ufo init for peeked non ufo skb as well" (c547dbf55d5f8cf615ccc0e7265e98db27d3fb8b)
> 
> Three frames are written on a corked udp socket for which the output
> netdevice has UFO enabled.  If the first and third frame are smaller than
> the mtu and the second one is bigger, we enqueue the second frame with
> skb_append_datato_frags without initializing the gso fields. This leads
> to the third frame appended regulary and thus constructing an invalid skb.
> 
> This fixes the problem by always using skb_append_datato_frags as soon
> as the first frag got enqueued to the skb without marking the packet
> as SKB_GSO_UDP.
> 
> The problem with only two frames for ipv6 was fixed by "ipv6: udp
> packets following an UFO enqueued packet need also be handled by UFO"
> (2811ebac2521ceac84f2bdae402455baa6a7fb47).
> 
> Cc: Jiri Pirko <jiri@resnulli.us>
> Cc: Eric Dumazet <eric.dumazet@gmail.com>
> Cc: David Miller <davem@davemloft.net>
> Signed-off-by: Hannes Frederic Sowa <hannes@stressinduktion.org>

Queued up for -stable, thanks Hannes.

^ permalink raw reply

* Re: [PATCH net] netpoll: linearize skb before accessing its data
From: David Miller @ 2013-10-21 22:23 UTC (permalink / raw)
  To: antonio; +Cc: netdev
In-Reply-To: <1382391080-1607-1-git-send-email-antonio@meshcoding.com>

From: Antonio Quartulli <antonio@meshcoding.com>
Date: Mon, 21 Oct 2013 23:31:20 +0200

> __netpoll_rx() assumes that the data buffer of the received
> skb is linear and then passes it to rx_hook().
> However this is not true because the skb has not been
> linearized yet.
> 
> This can cause rx_hook() to access non allocated memory
> while parsing the received data.
> 
> Fix __netpoll_rx() by explicitly linearising the skb.
> 
> Signed-off-by: Antonio Quartulli <antonio@meshcoding.com>

It is rx_hook's obligation to access the SKB properly and not
assume that the SKB is linear.  It is very expensive to
linearize every SKB just for the sake of improperly implemented
receive hooks.

In particular the rx hooks must make use of interface such
as pskb_may_pull(), just like every other protocol does
on packet input processing, to make sure the area they want
to access is in the linear area.

^ 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