Re: [PATCH net v2] af-unix: fix use-after-free with concurrent readers while splicing

2015-11-10 Thread Hannes Frederic Sowa
On Tue, Nov 10, 2015, at 16:18, Eric Dumazet wrote: > Please Hannes include the Fixes: tag. Yep, sorry, is done in v3. > As you might already know, patchwork does not catch it later > > Fixes: 2b514574f7e8 ("net: af_unix: implement splice for stream af_unix > sockets") > Acked-by: Eric Dumazet

[PATCH v2 0/6] net: dsa: mv88e6060: cleanup and fix setup

2015-11-10 Thread Neil Armstrong
This patchset introduces some fixes and a registers addressing cleanup for the mv88e6060 DSA driver. The first patch removes the poll_link as mv88e6xxx. The 3 following patches fixes the setup in regards of the datasheet. The 2 last patches introduces a clean header and replaces all magic values.

[PATCH v2 2/6] net: dsa: mv88e6060: use the correct InitReady bit

2015-11-10 Thread Neil Armstrong
According to the mv88e6060 datasheet, the InitReady bit position is 11 and the polarity is inverted. Use the bit correctly to detect the end of initialization. Acked-by: Andrew Lunn Signed-off-by: Neil Armstrong --- drivers/net/dsa/mv88e6060.c | 2 +- 1

Re: [PATCH v2 0/6] net: dsa: mv88e6060: cleanup and fix setup

2015-11-10 Thread Andrew Lunn
On Tue, Nov 10, 2015 at 04:51:09PM +0100, Neil Armstrong wrote: > This patchset introduces some fixes and a registers addressing cleanup for > the mv88e6060 DSA driver. Hi Neil It is normal for netdev to put into the email subject of patches which tree these patches are for. "net" would be the

[PATCH] mac80211: Remove kerneldoc for beacon_loss_count

2015-11-10 Thread Thierry Reding
;tred...@nvidia.com> --- Applies on top of next-20151110. net/mac80211/sta_info.h | 1 - 1 file changed, 1 deletion(-) diff --git a/net/mac80211/sta_info.h b/net/mac80211/sta_info.h index 2cafb21b422f..fb77ece9a8c8 100644 --- a/net/mac80211/sta_info.h +++ b/net/mac80211/sta_info.h @@ -370,7

Re: [PATCH 5/6] net: dsa: mv88e6060: add register defines header file

2015-11-10 Thread Vivien Didelot
On Nov. Tuesday 10 (46) 03:42 PM, Neil Armstrong wrote: > On 11/10/2015 03:25 PM, Vivien Didelot wrote: > > Hi Neil, > > > > On Nov. Tuesday 10 (46) 02:25 PM, Neil Armstrong wrote: > >> To align with the mv88e6xxx code, add a similar header file > >> with all the register defines. > >> The file

[PATCH net v3] af-unix: fix use-after-free with concurrent readers while splicing

2015-11-10 Thread Hannes Frederic Sowa
During splicing an af-unix socket to a pipe we have to drop all af-unix socket locks. While doing so we allow another reader to enter unix_stream_read_generic which can read, copy and finally free another skb. If exactly this skb is just in process of being spliced we get a use-after-free report

Re: [PATCH v2 5/6] net: dsa: mv88e6060: add register defines header file

2015-11-10 Thread Vivien Didelot
On Nov. Tuesday 10 (46) 04:51 PM, Neil Armstrong wrote: > To align with the mv88e6xxx code, add a similar header file > with all the register defines. > The file is based on the mv88e6xxx header for coherency. > > Acked-by: Andrew Lunn > Signed-off-by: Neil Armstrong

Re: [PATCH v2 2/6] net: dsa: mv88e6060: use the correct InitReady bit

2015-11-10 Thread Vivien Didelot
On Nov. Tuesday 10 (46) 04:51 PM, Neil Armstrong wrote: > According to the mv88e6060 datasheet, the InitReady bit position > is 11 and the polarity is inverted. > Use the bit correctly to detect the end of initialization. > > Acked-by: Andrew Lunn > Signed-off-by: Neil Armstrong

[PATCH v5] net: ethernet: add driver for Aurora VLSI NB8800 Ethernet controller

2015-11-10 Thread Mans Rullgard
This adds a driver for the Aurora VLSI NB8800 Ethernet controller. It is an almost complete rewrite of a driver originally found in a Sigma Designs 2.6.22 tree. Signed-off-by: Mans Rullgard --- Changes: - Refactored mdio access functions - Refactored register access helpers -

Re: [PATCH] netfilter: Fix removal of GRE expectation entries created by PPTP

2015-11-10 Thread Pablo Neira Ayuso
On Tue, Nov 10, 2015 at 05:36:29PM +0100, Pablo Neira Ayuso wrote: > From: Anthony Lineham > > The uninitialized tuple structure caused incorrect hash calculation > and the lookup failed. Please, ignore this. This patch is already in the nf tree, it just

Re: PING: [PATCH] net: smsc911x: Reset PHY during initialization

2015-11-10 Thread David Miller
From: Pavel Fedin Date: Tue, 10 Nov 2015 09:36:24 +0300 > Hello! So, what should we do with this? If you think I should reconsider the patch, you should resubmit it. The ball is always in your court. -- To unsubscribe from this list: send the line "unsubscribe netdev" in

Re: [PATCH net v2] af-unix: fix use-after-free with concurrent readers while splicing

2015-11-10 Thread Eric Dumazet
On Tue, 2015-11-10 at 15:47 +0100, Hannes Frederic Sowa wrote: > During splicing an af-unix socket to a pipe we have to drop all > af-unix socket locks. While doing so we allow another reader to enter > unix_stream_read_generic which can read, copy and finally free another > skb. If exactly this

[PATCH v2 3/6] net: dsa: mv88e6060: use the correct MaxFrameSize bit

2015-11-10 Thread Neil Armstrong
According to the mv88e6060 datasheet, the MaxFrameSize bit position is 10 instead of 11 which is reserved. Use the bit correctly to setup max frame size to 1536. Acked-by: Andrew Lunn Signed-off-by: Neil Armstrong --- drivers/net/dsa/mv88e6060.c | 2 +-

[PATCH v2 1/6] net: dsa: mv88e6060: remove poll_link callback

2015-11-10 Thread Neil Armstrong
As of mv88e6xxx remove the poll_link callback since the link state change polling is now handled by the phylib. Tested on a mv88e6060 B0 device with a TI DM816X SoC. Suggested-by: Andrew Lunn Acked-by: Andrew Lunn Signed-off-by: Neil Armstrong

[PATCH v2 4/6] net: dsa: mv88e6060: use the correct bit shift for mac0

2015-11-10 Thread Neil Armstrong
According to the mv88e6060 datasheet, the first mac byte must be at position 9 instead of 8 since the bit 8 is used to select if the mac address must differ for each port for Pause frames. Use the correct shift and set the same mac address for all port. Acked-by: Andrew Lunn

[PATCH v2 5/6] net: dsa: mv88e6060: add register defines header file

2015-11-10 Thread Neil Armstrong
To align with the mv88e6xxx code, add a similar header file with all the register defines. The file is based on the mv88e6xxx header for coherency. Acked-by: Andrew Lunn Signed-off-by: Neil Armstrong --- drivers/net/dsa/mv88e6060.h | 111

[PATCH v2 6/6] net: dsa: mv88e6060: replace magic values with register defines

2015-11-10 Thread Neil Armstrong
To align with the mv88e6xxx code, use the register defines to access all the register addresses and bit fields. Acked-by: Andrew Lunn Signed-off-by: Neil Armstrong --- drivers/net/dsa/mv88e6060.c | 64 ++--- 1

[PATCH nf 2/2] netfilter: nf_tables: add clone interface to expression operations

2015-11-10 Thread Pablo Neira Ayuso
With the conversion of the counter expressions to make it percpu, we need to clone the percpu memory area, otherwise we crash when using counters from flow tables. Signed-off-by: Pablo Neira Ayuso --- include/net/netfilter/nf_tables.h | 16 +++--

[PATCH] netfilter: Fix removal of GRE expectation entries created by PPTP

2015-11-10 Thread Pablo Neira Ayuso
From: Anthony Lineham The uninitialized tuple structure caused incorrect hash calculation and the lookup failed. Link: https://bugzilla.kernel.org/show_bug.cgi?id=106441 Signed-off-by: Anthony Lineham --- Original patch

[PATCH nf 1/2] net: add __netdev_alloc_pcpu_stats() to indicate gfp flags

2015-11-10 Thread Pablo Neira Ayuso
nf_tables may create percpu counters from the packet path through its dynamic set instantiation infrastructure, so we need a way to allocate this through GFP_ATOMIC. Signed-off-by: Pablo Neira Ayuso --- include/linux/netdevice.h | 27 +++ 1 file

[PATCH net v2] af-unix: fix use-after-free with concurrent readers while splicing

2015-11-10 Thread Hannes Frederic Sowa
During splicing an af-unix socket to a pipe we have to drop all af-unix socket locks. While doing so we allow another reader to enter unix_stream_read_generic which can read, copy and finally free another skb. If exactly this skb is just in process of being spliced we get a use-after-free report

Re: [PATCH, REPORT] bpf_trace: build error without PERF_EVENTS

2015-11-10 Thread Alexei Starovoitov
On Tue, Nov 10, 2015 at 09:25:01AM -0500, Steven Rostedt wrote: > On Tue, 10 Nov 2015 14:31:38 +0100 > Daniel Borkmann wrote: > > > On 11/10/2015 01:55 PM, Arnd Bergmann wrote: > > > In my ARM randconfig tests, I'm getting a build error for > > > newly added code in

[PATCH -stable] virtio-net: drop NETIF_F_FRAGLIST

2015-11-10 Thread Charles (Chas) Williams
Dave, could you please add commit 48900cb6af4282fa0fb6ff4d72a81aa3dadb5c39 virtio-net: drop NETIF_F_FRAGLIST to your stable queues for 3.14.y and 4.1.y? This fixes CVE-2015-5156, https://security-tracker.debian.org/tracker/CVE-2015-5156 -- To unsubscribe from this list: send the line

Re: [PATCH, REPORT] bpf_trace: build error without PERF_EVENTS

2015-11-10 Thread Daniel Borkmann
On 11/10/2015 06:14 PM, Alexei Starovoitov wrote: On Tue, Nov 10, 2015 at 09:25:01AM -0500, Steven Rostedt wrote: On Tue, 10 Nov 2015 14:31:38 +0100 Daniel Borkmann wrote: On 11/10/2015 01:55 PM, Arnd Bergmann wrote: In my ARM randconfig tests, I'm getting a build

Re: [PATCH v5] net: ethernet: add driver for Aurora VLSI NB8800 Ethernet controller

2015-11-10 Thread Måns Rullgård
Eric Dumazet writes: > On Tue, 2015-11-10 at 16:14 +, Mans Rullgard wrote: >> This adds a driver for the Aurora VLSI NB8800 Ethernet controller. >> It is an almost complete rewrite of a driver originally found in >> a Sigma Designs 2.6.22 tree. > > ... > >> + >>

Re: [PATCH v5] net: ethernet: add driver for Aurora VLSI NB8800 Ethernet controller

2015-11-10 Thread Mason
On 10/11/2015 17:14, Mans Rullgard wrote: > This adds a driver for the Aurora VLSI NB8800 Ethernet controller. > It is an almost complete rewrite of a driver originally found in > a Sigma Designs 2.6.22 tree. > > Signed-off-by: Mans Rullgard > --- > Changes: > - Refactored mdio

Re: [PATCH] unix: avoid use-after-free in ep_remove_wait_queue

2015-11-10 Thread Rainer Weikusat
Jason Baron writes: > On 11/09/2015 09:40 AM, Rainer Weikusat wrote: [...] >> -if (unix_peer(other) != sk && unix_recvq_full(other)) { >> +if (!unix_dgram_peer_recv_ready(sk, other)) { >> if (!timeo) { >> -err = -EAGAIN; >> -

Re: [PATCH v5] net: ethernet: add driver for Aurora VLSI NB8800 Ethernet controller

2015-11-10 Thread Måns Rullgård
Eric Dumazet writes: > On Tue, 2015-11-10 at 16:14 +, Mans Rullgard wrote: >> This adds a driver for the Aurora VLSI NB8800 Ethernet controller. >> It is an almost complete rewrite of a driver originally found in >> a Sigma Designs 2.6.22 tree. > > ... > >> + >>

Re: [PATCH nf 2/2] netfilter: nf_tables: add clone interface to expression operations

2015-11-10 Thread Patrick McHardy
On 10.11, Pablo Neira Ayuso wrote: > On Tue, Nov 10, 2015 at 06:30:34PM +, Patrick McHardy wrote: > > > __module_get(src->ops->type->owner); > > > - memcpy(dst, src, src->ops->size); > > > + if (src->ops->clone) { > > > + memcpy(dst, src, sizeof(*src)); > > > > Why copy if we clone?

Re: [PATCH nf 2/2] netfilter: nf_tables: add clone interface to expression operations

2015-11-10 Thread Patrick McHardy
On 10.11, Pablo Neira Ayuso wrote: > With the conversion of the counter expressions to make it percpu, we > need to clone the percpu memory area, otherwise we crash when using > counters from flow tables. > > Signed-off-by: Pablo Neira Ayuso > --- >

Re: [PATCH v5] net: ethernet: add driver for Aurora VLSI NB8800 Ethernet controller

2015-11-10 Thread Måns Rullgård
Mason writes: > On 10/11/2015 17:14, Mans Rullgard wrote: > >> This adds a driver for the Aurora VLSI NB8800 Ethernet controller. >> It is an almost complete rewrite of a driver originally found in >> a Sigma Designs 2.6.22 tree. >> >> Signed-off-by: Mans Rullgard

Re: [PATCH nf 2/2] netfilter: nf_tables: add clone interface to expression operations

2015-11-10 Thread Patrick McHardy
On 10.11, Pablo Neira Ayuso wrote: > On Tue, Nov 10, 2015 at 06:58:05PM +, Patrick McHardy wrote: > > On 10.11, Pablo Neira Ayuso wrote: > > > On Tue, Nov 10, 2015 at 06:30:34PM +, Patrick McHardy wrote: > > > > > __module_get(src->ops->type->owner); > > > > > - memcpy(dst, src,

Re: [PATCH] unix: avoid use-after-free in ep_remove_wait_queue

2015-11-10 Thread Rainer Weikusat
David Miller writes: > From: Rainer Weikusat > Date: Mon, 09 Nov 2015 14:40:48 + > >> +__remove_wait_queue(_sk(u->peer_wake.private)->peer_wait, >> +>peer_wake); > > This is more simply: > >

Re: [PATCH -stable] virtio-net: drop NETIF_F_FRAGLIST

2015-11-10 Thread David Miller
From: "Charles (Chas) Williams" <3ch...@gmail.com> Date: Tue, 10 Nov 2015 13:26:05 -0500 > Dave, could you please add > > commit 48900cb6af4282fa0fb6ff4d72a81aa3dadb5c39 > virtio-net: drop NETIF_F_FRAGLIST > > to your stable queues for 3.14.y and 4.1.y? Ok, queued up. -- To unsubscribe from

Re: [PATCH v8] can: xilinx: Convert to runtime_pm

2015-11-10 Thread Marc Kleine-Budde
On 10/26/2015 07:11 AM, Kedareswara rao Appana wrote: > Instead of enabling/disabling clocks at several locations in the driver, > Use the runtime_pm framework. This consolidates the actions for runtime PM > In the appropriate callbacks and makes the driver more readable and > mantainable. > >

Re: [PATCH v5] net: ethernet: add driver for Aurora VLSI NB8800 Ethernet controller

2015-11-10 Thread Måns Rullgård
David Miller writes: > From: Måns Rullgård > Date: Tue, 10 Nov 2015 18:05:15 + > >> Because I haven't been following the netdev list closely for the last >> five years, and no documentation I read mentioned this function. I can >> certainly change it. >

Re: [PATCH] bpf_trace: Make dependent on PERF_EVENTS

2015-11-10 Thread Steven Rostedt
On Tue, 10 Nov 2015 15:40:35 -0500 (EST) David Miller wrote: > I'll apply this, thanks Steven et al. Thanks David. -- Steve -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majord...@vger.kernel.org More majordomo info at

Re: [PATCH v5] net: ethernet: add driver for Aurora VLSI NB8800 Ethernet controller

2015-11-10 Thread David Miller
From: Måns Rullgård Date: Tue, 10 Nov 2015 20:53:19 + > David Miller writes: > >> From: Måns Rullgård >> Date: Tue, 10 Nov 2015 18:05:15 + >> >>> Because I haven't been following the netdev list closely for the last >>> five years,

Re: [PATCH] arm64: bpf: fix JIT stack setup

2015-11-10 Thread Shi, Yang
On 11/9/2015 12:00 PM, Z Lim wrote: On Mon, Nov 9, 2015 at 10:08 AM, Shi, Yang wrote: I added it to stay align with ARMv8 AAPCS to maintain the correct FP during function call. It makes us get correct stack backtrace. I think we'd better to keep compliant with ARMv8 AAPCS

Re: [PATCH v5] net: ethernet: add driver for Aurora VLSI NB8800 Ethernet controller

2015-11-10 Thread David Miller
From: Måns Rullgård Date: Tue, 10 Nov 2015 18:05:15 + > Because I haven't been following the netdev list closely for the last > five years, and no documentation I read mentioned this function. I can > certainly change it. It is always advisable to mimick what other drivers

[PATCH] bpf_trace: Make dependent on PERF_EVENTS

2015-11-10 Thread Steven Rostedt
Arnd Bergmann reported: In my ARM randconfig tests, I'm getting a build error for newly added code in bpf_perf_event_read and bpf_perf_event_output whenever CONFIG_PERF_EVENTS is disabled: kernel/trace/bpf_trace.c: In function 'bpf_perf_event_read': kernel/trace/bpf_trace.c:203:11:

Re: [PATCH] Revert "bridge: Allow forward delay to be cfgd when STP enabled"

2015-11-10 Thread David Miller
From: Vladislav Yasevich Date: Tue, 10 Nov 2015 06:15:32 -0500 > This reverts commit 34c2d9fb0498c066afbe610b15e18995fd8be792. > > There are 2 reasons for this revert: > 1) The commit in question doesn't do what it says it does. The > description reads: "Allow

Re: [PATCH] bpf_trace: Make dependent on PERF_EVENTS

2015-11-10 Thread Arnd Bergmann
On Tuesday 10 November 2015 15:28:17 Steven Rostedt wrote: > Arnd Bergmann reported: > > In my ARM randconfig tests, I'm getting a build error for > newly added code in bpf_perf_event_read and bpf_perf_event_output > whenever CONFIG_PERF_EVENTS is disabled: > > kernel/trace/bpf_trace.c:

Re: [PATCH nf 1/2] net: add __netdev_alloc_pcpu_stats() to indicate gfp flags

2015-11-10 Thread David Miller
From: Pablo Neira Ayuso Date: Tue, 10 Nov 2015 17:36:28 +0100 > nf_tables may create percpu counters from the packet path through its > dynamic set instantiation infrastructure, so we need a way to allocate > this through GFP_ATOMIC. > > Signed-off-by: Pablo Neira Ayuso

Re: [PATCH] bpf_trace: Make dependent on PERF_EVENTS

2015-11-10 Thread David Miller
From: Steven Rostedt Date: Tue, 10 Nov 2015 15:28:17 -0500 > > Arnd Bergmann reported: > > In my ARM randconfig tests, I'm getting a build error for > newly added code in bpf_perf_event_read and bpf_perf_event_output > whenever CONFIG_PERF_EVENTS is disabled: > >

Re: [RFC PATCH net-next v2 7/8] openvswitch: Delay conntrack helper call for new connections.

2015-11-10 Thread Jarno Rajahalme
> On Nov 9, 2015, at 5:26 AM, Patrick McHardy wrote: > > On 06.11, Jarno Rajahalme wrote: >> There is no need to help connections that are not confirmed, so we can >> delay helping new connections to the time when they are confirmed. >> This change is needed for NAT support,

Re: [PATCH v5] net: ethernet: add driver for Aurora VLSI NB8800 Ethernet controller

2015-11-10 Thread Måns Rullgård
David Miller writes: > From: Måns Rullgård > Date: Tue, 10 Nov 2015 20:53:19 + > >> David Miller writes: >> >>> From: Måns Rullgård >>> Date: Tue, 10 Nov 2015 18:05:15 + >>> Because I haven't been

Re: [PATCH v5] net: ethernet: add driver for Aurora VLSI NB8800 Ethernet controller

2015-11-10 Thread Eric Dumazet
On Tue, 2015-11-10 at 21:21 +, Måns Rullgård wrote: > Even ixgbe uses napi_complete() while netdevice.h says one should > "consider using napi_complete_done() instead." Did the author consider > it and decide not to, or has the driver simply not been updated? napi_complete_done() is quite

Re: [PATCH net v2 3/3] packet: fix tpacket_snd max frame and vlan handling

2015-11-10 Thread Daniel Borkmann
On 11/10/2015 11:52 PM, Willem de Bruijn wrote: if (sock->type == SOCK_DGRAM) { - err = dev_hard_header(skb, dev, ntohs(proto), addr, - NULL, tp_len); + /* In DGRAM sockets, we expect struct sockaddr_ll was filled +

Re: [PATCH net v2 3/3] packet: fix tpacket_snd max frame and vlan handling

2015-11-10 Thread Willem de Bruijn
> if (sock->type == SOCK_DGRAM) { > - err = dev_hard_header(skb, dev, ntohs(proto), addr, > - NULL, tp_len); > + /* In DGRAM sockets, we expect struct sockaddr_ll was filled > +* via struct msghdr, so we have dest

Re: [PATCH] unix: avoid use-after-free in ep_remove_wait_queue

2015-11-10 Thread Rainer Weikusat
An AF_UNIX datagram socket being the client in an n:1 association with some server socket is only allowed to send messages to the server if the receive queue of this socket contains at most sk_max_ack_backlog datagrams. This implies that prospective writers might be forced to go to sleep despite

[PATCH 1/2] arm64: bpf: add 'store immediate' instruction

2015-11-10 Thread Yang Shi
aarch64 doesn't have native store immediate instruction, such operation has to be implemented by the below instruction sequence: Load immediate to register Store register Signed-off-by: Yang Shi CC: Zi Shen Lim CC: Xi Wang ---

[PATCH 2/2] arm64: bpf: add BPF XADD instruction

2015-11-10 Thread Yang Shi
aarch64 doesn't have native support for XADD instruction, implement it by the below instruction sequence: Load (dst + off) to a register Add src to it Store it back to (dst + off) Signed-off-by: Yang Shi CC: Zi Shen Lim CC: Xi Wang

Re: [PATCH v5] net: ethernet: add driver for Aurora VLSI NB8800 Ethernet controller

2015-11-10 Thread Måns Rullgård
Andy Shevchenko writes: > On Wed, Nov 11, 2015 at 12:34 AM, Måns Rullgård wrote: >> Andy Shevchenko writes: >> +static inline void nb8800_maskb(struct nb8800_priv *priv, int reg, + u32

Re: [PATCH 2/2] arm64: bpf: add BPF XADD instruction

2015-11-10 Thread Eric Dumazet
On Tue, 2015-11-10 at 14:41 -0800, Yang Shi wrote: > aarch64 doesn't have native support for XADD instruction, implement it by > the below instruction sequence: > > Load (dst + off) to a register > Add src to it > Store it back to (dst + off) Not really what is needed ? See this BPF_XADD as an

Re: [PATCH v5] net: ethernet: add driver for Aurora VLSI NB8800 Ethernet controller

2015-11-10 Thread Andy Shevchenko
On Tue, Nov 10, 2015 at 6:14 PM, Mans Rullgard wrote: > This adds a driver for the Aurora VLSI NB8800 Ethernet controller. > It is an almost complete rewrite of a driver originally found in > a Sigma Designs 2.6.22 tree. Few nitpicks below. > > Signed-off-by: Mans Rullgard

Re: [PATCH v5] net: ethernet: add driver for Aurora VLSI NB8800 Ethernet controller

2015-11-10 Thread Måns Rullgård
Andy Shevchenko writes: >> +static inline void nb8800_maskb(struct nb8800_priv *priv, int reg, >> + u32 mask, u32 val) >> +{ >> + u32 old = nb8800_readb(priv, reg); >> + u32 new = (old & ~mask) | val; > > Shoudn't be "… | (val

Re: [PATCH net v2 3/3] packet: fix tpacket_snd max frame and vlan handling

2015-11-10 Thread Willem de Bruijn
On Tue, Nov 10, 2015 at 6:12 PM, Daniel Borkmann wrote: > On 11/10/2015 11:52 PM, Willem de Bruijn wrote: >>> >>> if (sock->type == SOCK_DGRAM) { >>> - err = dev_hard_header(skb, dev, ntohs(proto), addr, >>> - NULL,

Re: [PATCH net v2 3/3] packet: fix tpacket_snd max frame and vlan handling

2015-11-10 Thread Daniel Borkmann
On 11/11/2015 12:24 AM, Willem de Bruijn wrote: On Tue, Nov 10, 2015 at 6:12 PM, Daniel Borkmann wrote: On 11/10/2015 11:52 PM, Willem de Bruijn wrote: if (sock->type == SOCK_DGRAM) { - err = dev_hard_header(skb, dev, ntohs(proto), addr, -

Re: [PATCH stable <= 3.18] net: add length argument to skb_copy_and_csum_datagram_iovec

2015-11-10 Thread Josh Hunt
On Thu, Oct 29, 2015 at 5:00 AM, Sabrina Dubroca wrote: > 2015-10-15, 14:25:03 +0200, Sabrina Dubroca wrote: >> Without this length argument, we can read past the end of the iovec in >> memcpy_toiovec because we have no way of knowing the total length of the >> iovec's

[PATCH] qed: select ZLIB_INFLATE

2015-11-10 Thread Arnd Bergmann
The newly added qlogic qed driver uses the zlib library, but misses the dependency: drivers/built-in.o: In function `qed_alloc_stream_mem': drivers/net/ethernet/qlogic/qed/qed_main.c:707: undefined reference to `zlib_inflate_workspacesize' drivers/built-in.o: In function `qed_unzip_data':

Re: [PATCH RFC 5/6] net/faraday: Enable NCSI interface

2015-11-10 Thread Benjamin Herrenschmidt
On Tue, 2015-11-10 at 17:12 +1100, Gavin Shan wrote: > > > So we require the interface to be opened to talk, so far so good, > > the NC-SI stack doesn't even need to open it itself, it's acceptable > > to require userspace to do it. IE. Userspace will chose what interface > > to use, open it (for

Re: network stream fairness

2015-11-10 Thread Niklas Cassel
On 11/09/2015 06:23 PM, Eric Dumazet wrote: > On Mon, 2015-11-09 at 17:50 +0100, Niklas Cassel wrote: > >> >> for i in `seq 1 20`; do ss -temoi dst 192.168.0.141; sleep 1; done > ... >> ESTAB 0 0192.168.0.1:54578 >>

RE: [PATCH v8] can: xilinx: Convert to runtime_pm

2015-11-10 Thread Appana Durga Kedareswara Rao
Ping!! > -Original Message- > From: Kedareswara rao Appana [mailto:appana.durga@xilinx.com] > Sent: Monday, October 26, 2015 11:42 AM > To: Anirudha Sarangi; w...@grandegger.com; m...@pengutronix.de; Michal > Simek; Soren Brinkmann > Cc: linux-...@vger.kernel.org;

[PATCH] netfilter: nfnetlink_log: work around uninitialized variable warning

2015-11-10 Thread Arnd Bergmann
After a recent (correct) change, gcc started warning about the use of the 'flags' variable in nfulnl_recv_config() net/netfilter/nfnetlink_log.c: In function 'nfulnl_recv_config': net/netfilter/nfnetlink_log.c:320:14: warning: 'flags' may be used uninitialized in this function

[iproute PATCH] iproute: restrict hoplimit values to be in range [1;255]

2015-11-10 Thread Phil Sutter
Technically, the range of possible hoplimit values are defined by IPv4 and IPv6 header formats. Both define the field to be eight bits in size, which leads to a value range of [0;255]. Setting a packet's hoplimit field to 0 though makes not much sense, as the next hop would immediately drop the

[PATCH, REPORT] bpf_trace: build error without PERF_EVENTS

2015-11-10 Thread Arnd Bergmann
In my ARM randconfig tests, I'm getting a build error for newly added code in bpf_perf_event_read and bpf_perf_event_output whenever CONFIG_PERF_EVENTS is disabled: kernel/trace/bpf_trace.c: In function 'bpf_perf_event_read': kernel/trace/bpf_trace.c:203:11: error: 'struct perf_event' has no

Re: [PATCH v5] net: ethernet: add driver for Aurora VLSI NB8800 Ethernet controller

2015-11-10 Thread Andy Shevchenko
On Wed, Nov 11, 2015 at 1:07 AM, Måns Rullgård wrote: > Andy Shevchenko writes: > + nb8800_writel(priv, NB8800_TX_DESC_ADDR, txb->dma_desc); > + wmb(); /* ensure desc addr is written before starting > DMA */

Re: [PATCH v5] net: ethernet: add driver for Aurora VLSI NB8800 Ethernet controller

2015-11-10 Thread David Miller
From: Måns Rullgård Date: Wed, 11 Nov 2015 00:40:09 + > When the DMA complete interrupt arrives, the next chain should be > kicked off as quickly as possible, and I don't see why that would > benefit from being done in napi context. NAPI isn't about low latency, it's about

Re: [PATCH] drivers: net: cpsw: add support for fixed-links.

2015-11-10 Thread Daniel Trautmann
On Mon, Nov 09, 2015 at 10:49:51PM -0500, David Miller wrote: > From: Daniel Trautmann > Date: Mon, 9 Nov 2015 20:24:14 +0100 > > > Add support for fixed-links in configurations without PHY. > > (e.g. connection to a switch, SGMII point to point, SFPs) > > > > Check:

[PATCH] Revert "bridge: Allow forward delay to be cfgd when STP enabled"

2015-11-10 Thread Vladislav Yasevich
This reverts commit 34c2d9fb0498c066afbe610b15e18995fd8be792. There are 2 reasons for this revert: 1) The commit in question doesn't do what it says it does. The description reads: "Allow bridge forward delay to be configured when Spanning Tree is enabled." This was already the case

Re: [iproute PATCH v2 4/6] ipaddress: fix ipaddr_flush for Linux >= 3.1

2015-11-10 Thread Phil Sutter
On Mon, Nov 09, 2015 at 09:58:50PM +0300, Sergei Shtylyov wrote: > On 11/09/2015 09:51 PM, Sergei Shtylyov wrote: > > >> Linux version 3.1 introduced a consistency check for netlink dumps in > >> commit 670dc28 ("netlink: advertise incomplete dumps"). This bites > > > > The

Re: [PATCH 2/2] arm64: bpf: add BPF XADD instruction

2015-11-10 Thread Alexei Starovoitov
On Tue, Nov 10, 2015 at 04:26:02PM -0800, Shi, Yang wrote: > On 11/10/2015 4:08 PM, Eric Dumazet wrote: > >On Tue, 2015-11-10 at 14:41 -0800, Yang Shi wrote: > >>aarch64 doesn't have native support for XADD instruction, implement it by > >>the below instruction sequence: > >> > >>Load (dst + off)

Re: [PATCH v5] net: ethernet: add driver for Aurora VLSI NB8800 Ethernet controller

2015-11-10 Thread Måns Rullgård
Francois Romieu writes: > Mans Rullgard : >> diff --git a/drivers/net/ethernet/aurora/nb8800.c >> b/drivers/net/ethernet/aurora/nb8800.c >> new file mode 100644 >> index 000..11cd389 >> --- /dev/null >> +++ b/drivers/net/ethernet/aurora/nb8800.c >

Re: [PATCH 1/1] net: Add SO_REUSEPORT_LISTEN_OFF socket option as drain mode

2015-11-10 Thread Eric Dumazet
On Tue, 2015-11-10 at 21:41 -0800, Tom Herbert wrote: > Tolga, are you still planning to respin this patch (when tree opens?) I was planning to add an union on skc_tx_queue_mapping and sk_max_ack_backlog, so that adding a check on sk_max_ack_backlog in listener lookup would not add an additional

[PATCH net] af-unix: fix use-after-free with concurrent readers while splicing

2015-11-10 Thread Hannes Frederic Sowa
During splicing an af-unix socket to a pipe we have to drop all af-unix socket locks. While doing so we allow another reader to enter unix_stream_read_generic which can read, copy and finally free another skb. If exactly this skb is just in process of being spliced we get a use-after-free report

Re: [PATCH, REPORT] bpf_trace: build error without PERF_EVENTS

2015-11-10 Thread Steven Rostedt
On Tue, 10 Nov 2015 14:31:38 +0100 Daniel Borkmann wrote: > On 11/10/2015 01:55 PM, Arnd Bergmann wrote: > > In my ARM randconfig tests, I'm getting a build error for > > newly added code in bpf_perf_event_read and bpf_perf_event_output > > whenever CONFIG_PERF_EVENTS is

Re: [PATCH 5/6] net: dsa: mv88e6060: add register defines header file

2015-11-10 Thread Andrew Lunn
On Tue, Nov 10, 2015 at 09:25:51AM -0500, Vivien Didelot wrote: > Hi Neil, > > On Nov. Tuesday 10 (46) 02:25 PM, Neil Armstrong wrote: > > To align with the mv88e6xxx code, add a similar header file > > with all the register defines. > > The file is based on the mv88e6xxx header for coherency. >

Re: [PATCH net] af-unix: fix use-after-free with concurrent readers while splicing

2015-11-10 Thread Hannes Frederic Sowa
On Tue, Nov 10, 2015, at 15:26, Hannes Frederic Sowa wrote: > net/unix/af_unix.c | 18 +- > 1 file changed, 17 insertions(+), 1 deletion(-) > > diff --git a/net/unix/af_unix.c b/net/unix/af_unix.c > index aaa0b58..b2c4131 100644 > --- a/net/unix/af_unix.c > +++

Re: [PATCH 5/6] net: dsa: mv88e6060: add register defines header file

2015-11-10 Thread Vivien Didelot
On Nov. Tuesday 10 (46) 03:30 PM, Andrew Lunn wrote: > On Tue, Nov 10, 2015 at 09:25:51AM -0500, Vivien Didelot wrote: > > Hi Neil, > > > > On Nov. Tuesday 10 (46) 02:25 PM, Neil Armstrong wrote: > > > To align with the mv88e6xxx code, add a similar header file > > > with all the register

Re: [PATCH 5/6] net: dsa: mv88e6060: add register defines header file

2015-11-10 Thread Neil Armstrong
On 11/10/2015 03:25 PM, Vivien Didelot wrote: > Hi Neil, > > On Nov. Tuesday 10 (46) 02:25 PM, Neil Armstrong wrote: >> To align with the mv88e6xxx code, add a similar header file >> with all the register defines. >> The file is based on the mv88e6xxx header for coherency. >> >> Signed-off-by:

[PATCH] netfilter: fix xt_TEE and xt_TPROXY dependencies

2015-11-10 Thread Arnd Bergmann
Kconfig is too smart for its own good: a Kconfig line that states select NF_DEFRAG_IPV6 if IP6_NF_IPTABLES means that if IP6_NF_IPTABLES is set to 'm', then NF_DEFRAG_IPV6 will also be set to 'm', regardless of the state of the symbol from which it is selected. When the xt_TEE driver is

Re: [PATCH] net: netfilter: fix GCC uninitialized warning

2015-11-10 Thread Pablo Neira Ayuso
On Fri, Nov 06, 2015 at 10:13:16PM +0300, Dmitry Safonov wrote: > I thought, it was decided to use 0/NULL/whatever, than uninitialized_var()? > Is right now? > http://thread.gmane.org/gmane.linux.kernel/1383415 I overlook that one. We should stick to mainstream policies as much as possible. Arnd

Re: [PATCH 0/6] net: dsa: mv88e6060: cleanup and fix setup

2015-11-10 Thread Andrew Lunn
On Tue, Nov 10, 2015 at 02:25:05PM +0100, Neil Armstrong wrote: > This patchset introduces somes fixes and a registers addressing cleanup for > the mv88e6060 DSA driver. Hi Neil I gave my Acked-by to the RFC version. It is normal to include that in following versions, so long as there has not

Re: [PATCH 5/6] net: dsa: mv88e6060: add register defines header file

2015-11-10 Thread Vivien Didelot
Hi Neil, On Nov. Tuesday 10 (46) 02:25 PM, Neil Armstrong wrote: > To align with the mv88e6xxx code, add a similar header file > with all the register defines. > The file is based on the mv88e6xxx header for coherency. > > Signed-off-by: Neil Armstrong In the RFC

[PATCH net v2 0/3] packet fixes

2015-11-10 Thread Daniel Borkmann
Fixes a couple of issues in packet sockets, i.e. on TX ring side. See individual patches for details. v1 -> v2: - Added patch 2 as suggested by Dave - Rest is unchanged from previous submission Daniel Borkmann (3): packet: do skb_probe_transport_header when we actually have data packet:

[PATCH net v2 2/3] packet: always probe for transport header

2015-11-10 Thread Daniel Borkmann
We concluded that the skb_probe_transport_header() should better be called unconditionally. Avoiding the call into the flow dissector has also not really much to do with the direct xmit mode. While it seems that only virtio_net code makes use of GSO from non RX/TX ring packet socket paths, we

[PATCH net v2 3/3] packet: fix tpacket_snd max frame and vlan handling

2015-11-10 Thread Daniel Borkmann
There seem to be a couple of issues in tpacket_snd() path. Since it's introduction in commit 69e3c75f4d54 ("net: TX_RING and packet mmap"), TX_RING could be used from SOCK_DGRAM and SOCK_RAW side. When used with SOCK_DGRAM only, the size_max > dev->mtu + reserve check should have reserve as 0, but

[PATCH 1/6] net: dsa: mv88e6060: remove poll_link callback

2015-11-10 Thread Neil Armstrong
As of mv88e6xxx remove the poll_link callback since the link state change polling is now handled by the phylib. Tested on a mv88e6060 B0 device with a TI DM816X SoC. Suggested-by: Andrew Lunn Signed-off-by: Neil Armstrong ---

[PATCH 0/6] net: dsa: mv88e6060: cleanup and fix setup

2015-11-10 Thread Neil Armstrong
This patchset introduces somes fixes and a registers addressing cleanup for the mv88e6060 DSA driver. The first patch removes the poll_link as mv88e6xxx. The 3 following patches fixes the setup in regards of the datasheet. The 2 last patches introduces a clean header and replaces all magic

[PATCH 1/1] can: sja1000: clear interrupts on start

2015-11-10 Thread Mirza Krak
From: Mirza Krak According to SJA1000 data sheet error-warning (EI) interrupt is not cleared by setting the controller in to reset-mode. Then if we have the following case: - system is suspended (echo mem > /sys/power/state) and SJA1000 is left in operating state -

[PATCH 6/6] net: dsa: mv88e6060: replace magic values with register defines

2015-11-10 Thread Neil Armstrong
To align with the mv88e6xxx code, use the register defines to access all the register addresses and bit fields. Signed-off-by: Neil Armstrong --- drivers/net/dsa/mv88e6060.c | 64 ++--- 1 file changed, 37 insertions(+), 27

[PATCH 3/6] net: dsa: mv88e6060: use the correct MaxFrameSize bit

2015-11-10 Thread Neil Armstrong
According to the mv88e6060 datasheet, the MaxFrameSize bit position is 10 instead of 11 which is reserved. Use the bit correctly to setup max frame size to 1536. Signed-off-by: Neil Armstrong --- drivers/net/dsa/mv88e6060.c | 2 +- 1 file changed, 1 insertion(+), 1

[PATCH 4/6] net: dsa: mv88e6060: use the correct bit shift for mac0

2015-11-10 Thread Neil Armstrong
According to the mv88e6060 datasheet, the first mac byte must be at position 9 instead of 8 since the bit 8 is used to select if the mac address must differ for each port for Pause frames. Use the correct shift and set the same mac address for all port. Signed-off-by: Neil Armstrong

[PATCH 2/6] net: dsa: mv88e6060: use the correct InitReady bit

2015-11-10 Thread Neil Armstrong
According to the mv88e6060 datasheet, the InitReady bit position is 11 and the polarity is inverted. Use the bit correctly to detect the end of initialization. Signed-off-by: Neil Armstrong --- drivers/net/dsa/mv88e6060.c | 2 +- 1 file changed, 1 insertion(+), 1

[PATCH 5/6] net: dsa: mv88e6060: add register defines header file

2015-11-10 Thread Neil Armstrong
To align with the mv88e6xxx code, add a similar header file with all the register defines. The file is based on the mv88e6xxx header for coherency. Signed-off-by: Neil Armstrong --- drivers/net/dsa/mv88e6060.h | 108 1 file

Re: [PATCH, REPORT] bpf_trace: build error without PERF_EVENTS

2015-11-10 Thread Daniel Borkmann
On 11/10/2015 01:55 PM, Arnd Bergmann wrote: In my ARM randconfig tests, I'm getting a build error for newly added code in bpf_perf_event_read and bpf_perf_event_output whenever CONFIG_PERF_EVENTS is disabled: kernel/trace/bpf_trace.c: In function 'bpf_perf_event_read':

Re: [PATCH] arm64: bpf: fix JIT stack setup

2015-11-10 Thread Z Lim
On Tue, Nov 10, 2015 at 11:46 AM, Shi, Yang wrote: > On 11/9/2015 12:00 PM, Z Lim wrote: >> >> How about splitting this into two patches? One for the BPF-related >> bug, and another for A64 FP-handling. > > I'm not sure if this is a good approach or not. IMHO, they are kind

kasan r8169 use-after-free trace.

2015-11-10 Thread Dave Jones
This happens during boot, (and then there's a flood of traces that happen so fast afterwards it completely overwhelms serial console; not sure if they're the same/related or not). == BUG: KASAN: use-after-free in

  1   2   >