Re: [PATCH net-next 1/4] bridge: vlan: use proper rcu for the vlgrp member

2015-10-12 Thread Ido Schimmel
Mon, Oct 12, 2015 at 02:41:06PM IDT, ra...@blackwall.org wrote: >From: Nikolay Aleksandrov > Hi Nik, Small nitpick: >@@ -825,17 +848,19 @@ unlock: > > int br_vlan_init(struct net_bridge *br) > { >+ struct net_bridge_vlan_group *vg; > int ret = -ENOMEM; > >- br->vlgrp = kzallo

Re: [PATCH net-next 3/4] bridge: vlan: break vlan_flush in two phases to keep old order

2015-10-12 Thread Ido Schimmel
Mon, Oct 12, 2015 at 02:41:08PM IDT, ra...@blackwall.org wrote: >From: Nikolay Aleksandrov > Hi, >Ido Schimmel reported a problem with switchdev devices because of the >order change of del_nbp operations, more specifically the move of >nbp_vlan_flush() which deletes all vlans and frees vlgrp afte

Re: [PATCH net-next] switchdev: enforce no pvid flag in vlan ranges

2015-10-12 Thread Vivien Didelot
Hi guys, On Oct. Monday 12 (42) 02:01 PM, Nikolay Aleksandrov wrote: > From: Nikolay Aleksandrov > > We shouldn't allow BRIDGE_VLAN_INFO_PVID flag in VLAN ranges. > > Signed-off-by: Nikolay Aleksandrov > --- > net/switchdev/switchdev.c | 3 +++ > 1 file changed, 3 insertions(+) > > diff --gi

Re: [PATCH net-next 4/4] bridge: vlan: combine (br|nbp)_vlan_flush into one

2015-10-12 Thread Ido Schimmel
Mon, Oct 12, 2015 at 02:41:09PM IDT, ra...@blackwall.org wrote: >From: Nikolay Aleksandrov > >As Ido Schimmel pointed out the vlan_vid_del() loop in nbp_vlan_flush is >unnecessary (and is actually a remnant of the old vlan code) so we can >remove it and combine both br/nbp vlan_flush functions int

[patch net-next v4 0/7] switchdev: change locking

2015-10-12 Thread Jiri Pirko
From: Jiri Pirko This is something which I'm currently struggling with. Callers of attr_set and obj_add/del often hold not only RTNL, but also spinlock (bridge). So in that case, the driver implementing the op cannot sleep. The way rocker is dealing with this now is just to invoke driver operati

[patch net-next v4 1/7] switchdev: introduce switchdev workqueue

2015-10-12 Thread Jiri Pirko
From: Jiri Pirko This is going to be used for deferred operations. Signed-off-by: Jiri Pirko --- include/net/switchdev.h | 5 + net/switchdev/switchdev.c | 19 +++ 2 files changed, 24 insertions(+) diff --git a/include/net/switchdev.h b/include/net/switchdev.h index 1ce

Re: [PATCH net-next 3/4] bridge: vlan: break vlan_flush in two phases to keep old order

2015-10-12 Thread Nikolay Aleksandrov
On 10/12/2015 07:39 PM, Ido Schimmel wrote: > Mon, Oct 12, 2015 at 02:41:08PM IDT, ra...@blackwall.org wrote: >> From: Nikolay Aleksandrov >> > Hi, > >> Ido Schimmel reported a problem with switchdev devices because of the >> order change of del_nbp operations, more specifically the move of >> nb

[patch net-next v4 7/7] switchdev: assert rtnl mutex when going over lower netdevs

2015-10-12 Thread Jiri Pirko
From: Jiri Pirko netdev_for_each_lower_dev has to be called with rtnl mutex held. So better enforce it in switchdev functions. Signed-off-by: Jiri Pirko --- net/switchdev/switchdev.c | 15 +++ 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/net/switchdev/switchdev.c

[patch net-next v4 5/7] bridge: defer switchdev fdb del call in fdb_del_external_learn

2015-10-12 Thread Jiri Pirko
From: Jiri Pirko Since spinlock is held here, defer the switchdev operation. Signed-off-by: Jiri Pirko --- net/bridge/br_fdb.c | 5 - net/bridge/br_if.c | 3 +++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/net/bridge/br_fdb.c b/net/bridge/br_fdb.c index f5e7da0..c88bd8e

[patch net-next v4 3/7] switchdev: remove pointers from switchdev objects

2015-10-12 Thread Jiri Pirko
From: Jiri Pirko When object is used in deferred work, we cannot use pointers in switchdev object structures because the memory they point at may be already used by someone else. So rather do local copy of the value. Signed-off-by: Jiri Pirko --- drivers/net/ethernet/rocker/rocker.c | 6 +++--

[patch net-next v4 4/7] switchdev: introduce possibility to defer obj_add/del

2015-10-12 Thread Jiri Pirko
From: Jiri Pirko Similar to the attr usecase, the caller knows if he is holding RTNL and is in atomic section. So let the called to decide the correct call variant. This allows drivers to sleep inside their ops and wait for hw to get the operation status. Then the status is propagated into switc

[patch net-next v4 2/7] switchdev: allow caller to explicitly request attr_set as deferred

2015-10-12 Thread Jiri Pirko
From: Jiri Pirko Caller should know if he can call attr_set directly (when holding RTNL) or if he has to defer the att_set processing for later. This also allows drivers to sleep inside attr_set and report operation status back to switchdev core. Switchdev core then warns if status is not ok, in

[patch net-next v4 6/7] rocker: remove nowait from switchdev callbacks.

2015-10-12 Thread Jiri Pirko
From: Jiri Pirko No need to avoid sleeping in switchdev callbacks now, as the switchdev core allows it. Signed-off-by: Jiri Pirko --- drivers/net/ethernet/rocker/rocker.c | 7 +++ 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/drivers/net/ethernet/rocker/rocker.c b/drivers/

Re: [PATCH net-next 3/4] bridge: vlan: break vlan_flush in two phases to keep old order

2015-10-12 Thread Ido Schimmel
Mon, Oct 12, 2015 at 08:55:31PM IDT, niko...@cumulusnetworks.com wrote: >On 10/12/2015 07:39 PM, Ido Schimmel wrote: >> Mon, Oct 12, 2015 at 02:41:08PM IDT, ra...@blackwall.org wrote: >>> From: Nikolay Aleksandrov >>> >> Hi, >> >>> Ido Schimmel reported a problem with switchdev devices because of

Re: [PATCH net-next 4/4] bridge: vlan: combine (br|nbp)_vlan_flush into one

2015-10-12 Thread Vivien Didelot
Hi, On Oct. Monday 12 (42) 08:51 PM, Ido Schimmel wrote: > Mon, Oct 12, 2015 at 02:41:09PM IDT, ra...@blackwall.org wrote: > >From: Nikolay Aleksandrov > > > >As Ido Schimmel pointed out the vlan_vid_del() loop in nbp_vlan_flush is > >unnecessary (and is actually a remnant of the old vlan code) s

Re: [PATCH net-next 3/4] bridge: vlan: break vlan_flush in two phases to keep old order

2015-10-12 Thread Nikolay Aleksandrov
On 10/12/2015 07:55 PM, Nikolay Aleksandrov wrote: > On 10/12/2015 07:39 PM, Ido Schimmel wrote: >> Mon, Oct 12, 2015 at 02:41:08PM IDT, ra...@blackwall.org wrote: >>> From: Nikolay Aleksandrov >>> >> Hi, >> >>> Ido Schimmel reported a problem with switchdev devices because of the >>> order change

Re: [PATCH net-next 4/4] bridge: vlan: combine (br|nbp)_vlan_flush into one

2015-10-12 Thread Ido Schimmel
Mon, Oct 12, 2015 at 09:15:39PM IDT, vivien.dide...@savoirfairelinux.com wrote: >Hi, > >On Oct. Monday 12 (42) 08:51 PM, Ido Schimmel wrote: >> Mon, Oct 12, 2015 at 02:41:09PM IDT, ra...@blackwall.org wrote: >> >From: Nikolay Aleksandrov >> > >> >As Ido Schimmel pointed out the vlan_vid_del() loop

[PATCH net-next v5 00/10] Add new drivers: qed & qede

2015-10-12 Thread Yuval Mintz
From: Ariel Elior This series implements the driver set for Qlogic's new 579xx series. These are 10/20/25/40/50/100 Gig capable converged nics, supporting ethernet (obviously), iscsi, fcoe, roce and iwarp protocols. The overall driver design includes a common module ('qed') and protocol specific

[PATCH net-next v5 07/10] qed: Add link support

2015-10-12 Thread Yuval Mintz
Physical link is handled by the management Firmware. This patch lays the infrastructure for attention handling in the driver, as link change notifications arrive via async. attentions, as well the handling of such notifications. This patch also extends the API with the protocol drivers by adding r

[PATCH net-next v5 10/10] qede: Add basic ethtool support

2015-10-12 Thread Yuval Mintz
From: Sudarsana Kalluru This adds basic ethtool operations to the qed driver, allowing support in: - Statistics gathering [ethtool -S] - Setting of debug level [ethtool -s msglvl] - Getting basic information [ethtool, ethtool -i] In addition it adds the ability to change the MTU. Signed-off

[PATCH net-next v5 04/10] qed: Add slowpath L2 support

2015-10-12 Thread Yuval Mintz
From: Manish Chopra This patch adds to the qed the support to configure various L2 elements, such as channels and basic filtering conditions. It also enhances its public API to allow qede to later utilize this functionality. Signed-off-by: Manish Chopra Signed-off-by: Yuval Mintz Signed-off-by

[PATCH net-next v5 09/10] qed: Add statistics support

2015-10-12 Thread Yuval Mintz
From: Manish Chopra Device statistics can be gathered on-demand. This adds the qed support for reading the statistics [both function and port] from the device, and adds to the public API a method for requesting the current statistics. Signed-off-by: Manish Chopra Signed-off-by: Yuval Mintz Sig

[PATCH net-next v5 05/10] qede: Add basic network device support

2015-10-12 Thread Yuval Mintz
From: Sudarsana Kalluru This patch includes the basic Rx/Tx support for the driver [although carrier will still never be turned on]. Following this patch the driver registers a network device, initializes it and prepares it for traffic. Signed-off-by: Sudarsana Kalluru Signed-off-by: Yuval Mint

[PATCH net-next v5 03/10] qede: Add basic Network driver

2015-10-12 Thread Yuval Mintz
The Qlogic Everest Driver for Ethernet is the Ethernet specifc module for 579xx ethernet products by Qlogic. This patch adds a very minimal PCI driver, one that doesn't yet register a network device, but one that does interact with qed and does a basic initialization of the HW. Signed-off-by: Yuv

[PATCH net-next v5 08/10] qede: Add support for link

2015-10-12 Thread Yuval Mintz
From: Sudarsana Kalluru This adds basic link functionality to qede - driver still doesn't provide users with an API to change any link property, but it does request qed to initialize the link using default configuration, and registers a callback that allows it to get link notifications. This pat

[PATCH net-next v5 02/10] qed: Add basic L2 interface

2015-10-12 Thread Yuval Mintz
From: Manish Chopra This patch adds a public API for a network driver to work on top of QED. The interface itself is very minimal - it's mostly infrastructure, as the only content it has after this patch is a query for HW-based information required for the creation of a network interface [I.e., n

[PATCH net-next v5 06/10] qede: classification configuration

2015-10-12 Thread Yuval Mintz
From: Sudarsana Kalluru Add the ability to configure basic classification in driver by implementing ndo_set_mac_address() and ndo_set_rx_mode(). Signed-off-by: Sudarsana Kalluru Signed-off-by: Yuval Mintz Signed-off-by: Ariel Elior --- drivers/net/ethernet/qlogic/qede/qede.h | 10 ++ d

[Patch net-next 2/4] net_sched: update hierarchical backlog too

2015-10-12 Thread Cong Wang
When the bottom qdisc decides to, for example, drop some packet, it calls qdisc_tree_decrease_qlen() to update the queue length for all its ancestors, we need to update the backlog too to keep the stats on root qdisc accurate. Cc: Jamal Hadi Salim Signed-off-by: Cong Wang --- include/net/codel.

[Patch net-next 0/4] net_sched: update backlog for hierarchical qdisc's

2015-10-12 Thread Cong Wang
For hierarchical qdisc like HTB, we currently only update its qlen but leave its backlog as zero, it is really odd to see: qdisc htb 1: dev eth0 root refcnt 2 r2q 10 default 1 direct_packets_stat 0 ver 3.17 Sent 172680457356 bytes 222469449 pkt (dropped 0, overlimits 123575834 requeues

[Patch net-next 1/4] net_sched: introduce qdisc_replace() helper

2015-10-12 Thread Cong Wang
Remove nearly duplicated code and prepare for the following patch. Cc: Jamal Hadi Salim Signed-off-by: Cong Wang --- include/net/sch_generic.h | 17 + net/sched/sch_cbq.c | 7 +-- net/sched/sch_drr.c | 6 +- net/sched/sch_dsmark.c| 8 +--- net/sche

[Patch net-next 3/4] sch_htb: update backlog as well

2015-10-12 Thread Cong Wang
It is odd to see qlen!=0 but backlog==0, for a real example: qdisc htb 1: dev eth0 root refcnt 2 r2q 10 default 1 direct_packets_stat 0 ver 3.17 Sent 172680457356 bytes 222469449 pkt (dropped 0, overlimits 123575834 requeues 0) backlog 0b 72p requeues 0 So we need to update backlog too when w

[Patch net-next 4/4] sch_dsmark: update backlog as well

2015-10-12 Thread Cong Wang
Similarly, we need to update backlog too when we update qlen. Cc: Jamal Hadi Salim Signed-off-by: Cong Wang --- net/sched/sch_dsmark.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/net/sched/sch_dsmark.c b/net/sched/sch_dsmark.c index cfddb1c..d0dff0c 100644 --- a/net/sched/sch_dsmark.

[PATCH net-next 2/4] net: Export fib6_get_table and nd_tbl

2015-10-12 Thread David Ahern
Signed-off-by: David Ahern --- net/ipv6/ip6_fib.c | 1 + net/ipv6/ndisc.c | 1 + 2 files changed, 2 insertions(+) diff --git a/net/ipv6/ip6_fib.c b/net/ipv6/ip6_fib.c index 7d2e0023c72d..09fddf70cca4 100644 --- a/net/ipv6/ip6_fib.c +++ b/net/ipv6/ip6_fib.c @@ -264,6 +264,7 @@ struct fib6_table

[PATCH net-next 1/4] net: Add IPv6 support to l3mdev

2015-10-12 Thread David Ahern
Add operations to retrieve cached IPv6 dst entry from l3mdev device and lookup IPv6 source address. Signed-off-by: David Ahern --- include/net/l3mdev.h | 46 ++ 1 file changed, 46 insertions(+) diff --git a/include/net/l3mdev.h b/include/net/l3mdev.h

[PATCH net-next 3/4] net: Add IPv6 support to VRF device

2015-10-12 Thread David Ahern
Add support for IPv6 to VRF device driver. Implemenation parallels what has been done for IPv4. Signed-off-by: David Ahern --- drivers/net/Kconfig | 4 +- drivers/net/vrf.c | 273 +++- 2 files changed, 275 insertions(+), 2 deletions(-) diff --

[PATCH net-next 0/4 v3] net: VRF support in IPv6 stack

2015-10-12 Thread David Ahern
Initial support for VRF in IPv6 stack. Makes IPv6 functionality on par with IPv4 -- ping, tcp client/server and udp client/server all work fine. tcpdump on vrf device and external tap (e.g., host side tap device) shows all packets with proper addresses. IPv6 does not need the source address operati

[PATCH net-next 4/4] net: Add VRF support to IPv6 stack

2015-10-12 Thread David Ahern
As with IPv4 support for VRFs added to IPv6 stack by replacing hardcoded table ids with possibly device specific ones and manipulating the oif in the flowi6. The flow flags are used to skip oif compare in nexthop lookups if the device is enslaved to a VRF via the L3 master device. Signed-off-by: D

Re: [PATCH net-next] net: Fix vti use case with oif in dst lookups for IPv6

2015-10-12 Thread David Ahern
On 10/9/15 11:27 AM, David Ahern wrote: On 10/9/15 1:17 AM, Steffen Klassert wrote: diff --git a/net/ipv6/xfrm6_policy.c b/net/ipv6/xfrm6_policy.c index 30caa289c5db..5cedfda4b241 100644 --- a/net/ipv6/xfrm6_policy.c +++ b/net/ipv6/xfrm6_policy.c @@ -37,6 +37,7 @@ static struct dst_entry *xfrm6_

Re: [iproute2 PATCH] iplink: Support VF Trust

2015-10-12 Thread Jeff Kirsher
On Mon, 2015-10-12 at 09:54 -0700, Stephen Hemminger wrote: > On Wed, 7 Oct 2015 10:06:32 + > Hiroshi Shimamoto wrote: > > > From: Hiroshi Shimamoto > > > > Add IFLA_VF_TRUST message to trust the VF. > > PF can accept some privileged operation from the trusted VF. > > For example, ixgbe PF

Re: [RFC PATCH 1/2] perf: Add the flag sample_disable not to output data on samples

2015-10-12 Thread Alexei Starovoitov
On 10/12/15 2:02 AM, Kaixu Xia wrote: diff --git a/include/linux/bpf.h b/include/linux/bpf.h index f57d7fe..25e073d 100644 --- a/include/linux/bpf.h +++ b/include/linux/bpf.h @@ -39,6 +39,7 @@ struct bpf_map { u32 max_entries; const struct bpf_map_ops *ops; struct work_str

Re: [net-next 16/16] i40e: print neato new features

2015-10-12 Thread Jeff Kirsher
On Sat, 2015-10-10 at 22:29 +0300, Or Gerlitz wrote: > On Fri, Oct 9, 2015 at 4:32 AM, Jeff Kirsher > wrote: > > From: Jesse Brandeburg > > > > To help users and developers know what compile options > > and hardware features are enabled at compile time, print > > VxLAN is available. > > What nea

Re: [RFC PATCH 2/2] bpf: Implement bpf_perf_event_sample_enable/disable() helpers

2015-10-12 Thread Alexei Starovoitov
On 10/12/15 2:02 AM, Kaixu Xia wrote: +extern const struct bpf_func_proto bpf_perf_event_sample_enable_proto; +extern const struct bpf_func_proto bpf_perf_event_sample_disable_proto; externs are unnecessary. Just make them static. Also I prefer single helper that takes a flag, so we can extend

Re: [PATCH v4 1/3] net: unix: fix use-after-free in unix_dgram_poll()

2015-10-12 Thread Jason Baron
On 10/09/2015 10:38 AM, Hannes Frederic Sowa wrote: > Hi, > > Jason Baron writes: > >> The unix_dgram_poll() routine calls sock_poll_wait() not only for the wait >> queue associated with the socket s that we are poll'ing against, but also >> calls >> sock_poll_wait() for a remote peer socket p,

[PATCH net-next v2 0/4] bridge: vlan: cleanups & fixes (part 3)

2015-10-12 Thread Nikolay Aleksandrov
From: Nikolay Aleksandrov Hi, Patch 01 converts the vlgrp member to use rcu as it was already used in a similar way so better to make it official and use all the available RCU instrumentation. Patch 02 fixes a bug where the vlan_list can be traversed without rtnl or rcu held which could lead to u

[PATCH net-next v2 2/4] bridge: vlan: use rcu for vlan_list traversal in br_fill_ifinfo

2015-10-12 Thread Nikolay Aleksandrov
From: Nikolay Aleksandrov br_fill_ifinfo is called by br_ifinfo_notify which can be called from many contexts with different locks held, sometimes it relies upon bridge's spinlock only which is a problem for the vlan code, so use explicitly rcu for that to avoid problems. Signed-off-by: Nikolay

[PATCH net-next v2 1/4] bridge: vlan: use proper rcu for the vlgrp member

2015-10-12 Thread Nikolay Aleksandrov
From: Nikolay Aleksandrov The bridge and port's vlgrp member is already used in RCU way, currently we rely on the fact that it cannot disappear while the port exists but that is error-prone and we might miss places with improper locking (either RCU or RTNL must be held to walk the vlan_list). So

[PATCH net-next v2 3/4] bridge: vlan: drop unnecessary flush code

2015-10-12 Thread Nikolay Aleksandrov
From: Nikolay Aleksandrov As Ido Schimmel pointed out the vlan_vid_del() code in nbp_vlan_flush is unnecessary (and is actually a remnant of the old vlan code) so we can remove it. Signed-off-by: Nikolay Aleksandrov --- v2: new patch net/bridge/br_vlan.c | 9 + 1 file changed, 1 inser

[PATCH net-next v2 4/4] bridge: vlan: move back vlan_flush

2015-10-12 Thread Nikolay Aleksandrov
From: Nikolay Aleksandrov Ido Schimmel reported a problem with switchdev devices because of the order change of del_nbp operations, more specifically the move of nbp_vlan_flush() which deletes all vlans and frees vlgrp after the rx_handler has been unregistered. So in order to fix this move vlan_

Re: [PATCH v4 0/3] net: unix: fix use-after-free

2015-10-12 Thread Jason Baron
On 10/11/2015 07:55 AM, David Miller wrote: > From: Jason Baron > Date: Fri, 9 Oct 2015 00:15:59 -0400 > >> These patches are against mainline, I can re-base to net-next, please >> let me know. >> >> They have been tested against: https://lkml.org/lkml/2015/9/13/195, >> which causes the use-afte

a question about the kcm proposal

2015-10-12 Thread Sowmini Varadhan
Thinking back a bit about the kcm proposal: https://www.mail-archive.com/netdev@vger.kernel.org/msg78696.html I had a question: If the user-space has decided to encrypt the http/2 header using tls, the len (and other http/2 fields) is no longer in the clear for the kernel. My understanding is t

Re: [PATCH net-next 4/4] bridge: vlan: combine (br|nbp)_vlan_flush into one

2015-10-12 Thread Vivien Didelot
On Oct. Monday 12 (42) 09:27 PM, Ido Schimmel wrote: > Mon, Oct 12, 2015 at 09:15:39PM IDT, vivien.dide...@savoirfairelinux.com > wrote: > >Hi, > > > >On Oct. Monday 12 (42) 08:51 PM, Ido Schimmel wrote: > >> Mon, Oct 12, 2015 at 02:41:09PM IDT, ra...@blackwall.org wrote: > >> >From: Nikolay Aleks

Re: [PATCH net-next 2/3] ipv4: Pass struct net into ip_defrag and ip_check_defrag

2015-10-12 Thread Pablo Neira Ayuso
On Fri, Oct 09, 2015 at 01:44:54PM -0500, Eric W. Biederman wrote: > The function ip_defrag is called on both the input and the output > paths of the networking stack. In particular conntrack when it is > tracking outbound packets from the local machine calls ip_defrag. > > So add a struct net pa

Re: [PATCH net-next 3/3] ipv6: Pass struct net into nf_ct_frag6_gather

2015-10-12 Thread Pablo Neira Ayuso
On Fri, Oct 09, 2015 at 01:44:55PM -0500, Eric W. Biederman wrote: > The function nf_ct_frag6_gather is called on both the input and the > output paths of the networking stack. In particular ipv6_defrag which > calls nf_ct_frag6_gather is called from both the the PRE_ROUTING chain > on input and t

Re: [PATCH v2] sunrpc: fix waitqueue_active without memory barrier in sunrpc

2015-10-12 Thread J. Bruce Fields
On Mon, Oct 12, 2015 at 10:41:06AM +, Kosuke Tatsukawa wrote: > J. Bruce Fields wrote: > > On Fri, Oct 09, 2015 at 06:29:44AM +, Kosuke Tatsukawa wrote: > >> Neil Brown wrote: > >> > Kosuke Tatsukawa writes: > >> > > >> >> There are several places in net/sunrpc/svcsock.c which calls > >>

Re: NULL pointer dereference in rt6_get_cookie()

2015-10-12 Thread Martin KaFai Lau
On Sat, Oct 10, 2015 at 03:24:37PM +0200, Phil Sutter wrote: > Using printk-debugging I could track down the problem to > rt6_get_cookie() function in include/net/ip6_fib.h: > > The conditional at the start of the function evaluates true, since > 'rt->rt6i_flags & RTF_PCPU' is non-zero. Due to that

Re: [PATCH v2 1/3] unix: fix use-after-free in unix_dgram_poll()

2015-10-12 Thread Rainer Weikusat
Jason Baron writes: > On 10/05/2015 12:31 PM, Rainer Weikusat wrote: [...] >> Here's a more simple idea which _might_ work. The underlying problem >> seems to be that the second sock_poll_wait introduces a covert reference >> to the peer socket which isn't accounted for. The basic idea behind th

[PATCH net-next] net: vrf: Documentation update, ip commands

2015-10-12 Thread David Ahern
Add ip commands with examples for creating VRF devics, enslaving interfaces and dumping VRF-focused data (address, neighbors, routes). Signed-off-by: David Ahern --- Documentation/networking/vrf.txt | 301 ++- 1 file changed, 299 insertions(+), 2 deletions(-)

Re: a question about the kcm proposal

2015-10-12 Thread Tom Herbert
> > If the user-space has decided to encrypt the http/2 header using tls, > the len (and other http/2 fields) is no longer in the clear for the kernel. > > My understanding is that http header encryption is common practice/BCP, > since the http hdr may contain a lot of identity, session and tenanc

Re: a question about the kcm proposal

2015-10-12 Thread Sowmini Varadhan
On (10/12/15 15:05), Tom Herbert wrote: > > There is a different but related problem in this space- existing TLS/DTLS > > libraries (openssl, gnutls etc) only know how to work with tcp > > or udp sockets - they do not know anything about PF_RDS or the > > newly proposed kcm socket type. > > > TLS-i

[PATCH] - gre: add eth_p_teb gro-handler for OVS with gre tunnels

2015-10-12 Thread Ramu Ramamurthy
Problem: When using OVS with GRE tunnels, and GRO is enabled on the nic, We find that GRO doesnt really take effect. As a result, TCP stream performance on a 10G nic is around 2-3Gbps. Root Cause: --- The protocol field set in GRE (by OVS) is ETH_P_TEB. The code in gre_gro_rec

Re: [PATCH net-next v5 01/10] qed: Add module with basic common support

2015-10-12 Thread Francois Romieu
Yuval Mintz : > The Qlogic Everest Driver is the backend module for the 579xx ethernet > products by Qlogic. > > This module serves two main purposes: > 1. It's responsible to contain all the common code that will be shared > between the various drivers that would be used with said line of >

Re: [PATCH] - gre: add eth_p_teb gro-handler for OVS with gre tunnels

2015-10-12 Thread Jesse Gross
On Mon, Oct 12, 2015 at 3:26 PM, Ramu Ramamurthy wrote: > > Problem: > > > When using OVS with GRE tunnels, and GRO is enabled on the nic, > We find that GRO doesnt really take effect. As a result, TCP stream > performance on a 10G nic is around 2-3Gbps. > > Root Cause: > --- > >

Re: [PATCH net] ipv6: Don't call with rt6_uncached_list_flush_dev

2015-10-12 Thread Martin KaFai Lau
On Mon, Oct 12, 2015 at 11:02:08AM -0500, Eric W. Biederman wrote: > > As originally written rt6_uncached_list_flush_dev makes no sense when > called with dev == NULL as it attempts to flush all uncached routes > regardless of network namespace when dev == NULL. Which is simply > incorrect behavio

Re: [PATCH] - gre: add eth_p_teb gro-handler for OVS with gre tunnels

2015-10-12 Thread Ramu Ramamurthy
On 2015-10-12 16:47, Jesse Gross wrote: On Mon, Oct 12, 2015 at 3:26 PM, Ramu Ramamurthy wrote: Problem: When using OVS with GRE tunnels, and GRO is enabled on the nic, We find that GRO doesnt really take effect. As a result, TCP stream performance on a 10G nic is around 2-3Gbps. Ro

[PATCH] netlink: trim skb to exact size to avoid MSG_TRUNC

2015-10-12 Thread Ronen Arad
The available room in the skb allocated in netlink_dump for iproute2 show requests (e.g. "ip link [show]", "bridge [-c] vlan show") should be trimmed to the exact size requested in order to avoid MSG_TRUNC flag set in netlink_recvmg. This was handled properly for small skb allocated when no interfa

Re: [PATCH v4 0/3] net: unix: fix use-after-free

2015-10-12 Thread David Miller
From: Jason Baron Date: Mon, 12 Oct 2015 15:50:30 -0400 > I'm happy to re-post the series or whatever makes things easiest for > you. This is what you should always do, reposting a single patch within a series is not sufficient. Thanks. -- To unsubscribe from this list: send the line "unsubscri

Re: [PATCH] - gre: add eth_p_teb gro-handler for OVS with gre tunnels

2015-10-12 Thread David Miller
From: Ramu Ramamurthy Date: Mon, 12 Oct 2015 17:49:13 -0700 > We are using the 3.x kernels and thats why I could not see your fix in > my tests. It is inappropriate to submit patches not targetted and tested against the current sources. -- To unsubscribe from this list: send the line "unsubscrib

[PATCH net-next] net:hisilicon: supports promisc mode

2015-10-12 Thread yankejian
this patch adds support to set promisc mode. it configs the queue on init seq when it is on promisc mode.and being enabled or disabled promisc mode by upper level user. Signed-off-by: yankejian Signed-off-by: Yisen Zhuang --- drivers/net/ethernet/hisilicon/hns/hnae.h | 1 + drivers

Re: Issue with /proc/sys/net/ipv4/tcp_mem

2015-10-12 Thread Eric Dumazet
On Mon, 2015-10-12 at 11:37 -0500, Eric W. Biederman wrote: > wangyufen writes: > > > Hi, > > > > I tried on linux-4.1: > > linux:~# cat /proc/sys/net/ipv4/tcp_mem > > 8388608 1258291216777216 > > linux:~# echo 1234 >/proc/sys/net/ipv4/tcp_mem > > -bash: echo: write erro

[PATCH v4 4/4] Adds hardware supported cross timestamp

2015-10-12 Thread Christopher S. Hall
Modern Intel systems supports cross timestamping of the network device clock and Always Running Timer (ART) in hardware. This allows the device time and system time to be precisely correlated. The timestamp pair is exposed through the *_get_ts callback used by get_correlated_timestamp(). The hardw

[PATCH v4 2/4] Always running timer correlated clocksource

2015-10-12 Thread Christopher S. Hall
On modern Intel systems TSC is derived from the new Always Running Timer (ART). In addition, ART can be captured simultaneous to the capture of audio and network device clocks, allowing a correlation between timebases to be constructed. Upon capture, the driver converts the captured ART value to th

[PATCH v4 3/4] Add PTP_SYS_OFFSET_PRECISE for driver crosstimestamping

2015-10-12 Thread Christopher S. Hall
Currently, network /system cross-timestamping is performed in the PTP_SYS_OFFSET ioctl. The PTP clock driver reads gettimeofday() and the gettime64() callback provided by the driver. The cross-timestamp is best effort where the latency between the capture of system time (getnstimeofday()) and the d

[PATCH v4 1/4] Produce system time from correlated clocksource

2015-10-12 Thread Christopher S. Hall
From: Thomas Gleixner Modern Intel hardware provides the so called Always Running Timer (ART). The TSC which is usually used for timekeeping is derived from ART and runs with a fixed frequency ratio to it. ART is routed to devices and allows to take atomic timestamp samples from the device clock

[PATCH v4 0/4] Patchset enabling hardware based cross-timestamps for next gen Intel platforms

2015-10-12 Thread Christopher S. Hall
Modern Intel hardware adds an Always Running Timer (ART) that allows the network and audio device clocks to precisely cross timestamp the device clock with the system clock. This allows a precise correlation of the device time and system time. v4 adds a history which enables the audio DSP (a "slow

Re: [PATCH v4 2/4] Always running timer correlated clocksource

2015-10-12 Thread kbuild test robot
Hi Christopher, [auto build test ERROR on net/master -- if it's inappropriate base, please suggest rules for selecting the more suitable base] url: https://github.com/0day-ci/linux/commits/Christopher-S-Hall/Patchset-enabling-hardware-based-cross-timestamps-for-next-gen-Intel-platforms/20151

[PATCH net-next] BNX2: free temp_stats_blk on error path

2015-10-12 Thread Weidong Wang
In bnx2_init_board, missing free temp_stats_blk on error path when some operations do failed. Just add the 'kfree' operation. Signed-off-by: Wang Weidong --- drivers/net/ethernet/broadcom/bnx2.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/net/ethernet/broadcom/bnx2.c b/drivers

Re: [PATCH v2 net-next 0/3] bpf: unprivileged

2015-10-12 Thread David Miller
From: Alexei Starovoitov Date: Wed, 7 Oct 2015 22:23:20 -0700 > v1-v2: > - this set logically depends on cb patch > "bpf: fix cb access in socket filter programs": > http://patchwork.ozlabs.org/patch/527391/ > which is must have to allow unprivileged programs. > Thanks Daniel for finding

Re: [PATCH net-next 1/2] sock: support per-packet fwmark

2015-10-12 Thread David Miller
From: Edward Hyunkoo Jee Date: Thu, 8 Oct 2015 14:56:48 -0700 > It's useful to allow users to set fwmark for an individual packet, > without changing the socket state. The function this patch adds in > sock layer can be used by the protocols that need such a feature. > > Signed-off-by: Edward H

Re: [PATCH net-next 2/2] packet: support per-packet fwmark for af_packet sendmsg

2015-10-12 Thread David Miller
From: Edward Hyunkoo Jee Date: Thu, 8 Oct 2015 14:56:49 -0700 > Signed-off-by: Edward Hyunkoo Jee > Signed-off-by: Eric Dumazet Applied. -- 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 http://vg

Re: [PATCH v4 4/4] Adds hardware supported cross timestamp

2015-10-12 Thread kbuild test robot
Hi Christopher, [auto build test ERROR on net/master -- if it's inappropriate base, please suggest rules for selecting the more suitable base] url: https://github.com/0day-ci/linux/commits/Christopher-S-Hall/Patchset-enabling-hardware-based-cross-timestamps-for-next-gen-Intel-platforms/20151

Re: [PATCH v4 4/4] Adds hardware supported cross timestamp

2015-10-12 Thread kbuild test robot
Hi Christopher, [auto build test ERROR on net/master -- if it's inappropriate base, please suggest rules for selecting the more suitable base] url: https://github.com/0day-ci/linux/commits/Christopher-S-Hall/Patchset-enabling-hardware-based-cross-timestamps-for-next-gen-Intel-platforms/20151

Re: [PATCH v3 net-next 0/4] tcp: better smp listener behavior

2015-10-12 Thread David Miller
From: Eric Dumazet Date: Thu, 8 Oct 2015 19:33:20 -0700 > As promised in last patch series, we implement a better SO_REUSEPORT > strategy, based on cpu affinities if selected by the application. > > We also moved sk_refcnt out of the cache line containing the lookup > keys, as it was considerab

Re: [PATCH v2 net-next 0/4] tcp: better smp listener behavior

2015-10-12 Thread David Miller
From: Eric Dumazet Date: Thu, 8 Oct 2015 14:58:53 -0700 > As promised in last patch series, we implement a better SO_REUSEPORT > strategy, based on cpu hints if given by the application. > > We also moved sk_refcnt out of the cache line containing the lookup > keys, as it was considerably slowi

Re: [PATCH net] ppp: don't override sk->sk_state in pppoe_flush_dev()

2015-10-12 Thread Denys Fedoryshchenko
On 2015-10-07 15:12, Guillaume Nault wrote: On Mon, Oct 05, 2015 at 02:08:44PM +0200, Guillaume Nault wrote: if (po) { struct sock *sk = sk_pppox(po); - bh_lock_sock(sk); - - /* If the user has locked the socket, just ignore -*

Re: [PATCH v4 4/4] Adds hardware supported cross timestamp

2015-10-12 Thread David Miller
From: "Christopher S. Hall" Date: Mon, 12 Oct 2015 11:45:22 -0700 > @@ -25,6 +25,8 @@ > */ > > #include "e1000.h" > +#include You cannot include an architecture specific header file in a driver that's compiled on several architectures. -- To unsubscribe from this list: send the line "unsub

Re: [PATCH net-next] BNX2: free temp_stats_blk on error path

2015-10-12 Thread David Miller
From: Weidong Wang Date: Tue, 13 Oct 2015 10:05:19 +0800 > In bnx2_init_board, missing free temp_stats_blk on error path when > some operations do failed. Just add the 'kfree' operation. > > Signed-off-by: Wang Weidong Applied, thanks. -- To unsubscribe from this list: send the line "unsubscri

Re: [patch net-next] bridge: try switchdev op first in __vlan_vid_add/del

2015-10-12 Thread David Miller
From: Jiri Pirko Date: Fri, 9 Oct 2015 13:54:11 +0200 > From: Jiri Pirko > > Some drivers need to implement both switchdev vlan ops and > vid_add/kill ndos. For that to work in bridge code, we need to try > switchdev op first when adding/deleting vlan id. > > Signed-off-by: Jiri Pirko > Sign

Re: [PATCH net] ipv4/icmp: redirect messages can use the ingress daddr as source

2015-10-12 Thread David Miller
From: Paolo Abeni Date: Fri, 9 Oct 2015 14:34:31 +0200 > This patch allows configuring how the source address of ICMP > redirect messages is selected; by default the old behaviour is > retained, while setting icmp_redirects_use_orig_daddr force the > usage of the destination address of the packe

Re: pull-request: wireless-drivers-next 2015-10-09

2015-10-12 Thread David Miller
From: Kalle Valo Date: Fri, 09 Oct 2015 18:13:22 +0300 > here's first wireless-drivers pull request for 4.4. New features and > bugfixes but not really anything out of ordinary. Please let me know if > there are any problems. Pulled, thanks Kalle. -- To unsubscribe from this list: send the line

Re: [PATCH] rtnetlink: fix gcc -Wconversion warning

2015-10-12 Thread David Miller
From: Ronen Arad Date: Fri, 9 Oct 2015 10:35:47 -0700 > RTA_ALIGNTO is currently define as 4. It has to be 4U to prevent warning > for RTA_ALIGN and RTA_DATA expansions when -Wconversion gcc option is > enabled. > This follows NLMSG_ALIGNTO definition in . > > Signed-off-by: Ronen Arad Applie

Re: [PATCH net-next] packet: fix match_fanout_group()

2015-10-12 Thread David Miller
From: Eric Dumazet Date: Fri, 09 Oct 2015 11:29:32 -0700 > From: Eric Dumazet > > Recent TCP listener patches exposed a prior af_packet bug : > match_fanout_group() blindly assumes it is always safe > to cast sk to a packet socket to compare fanout with af_packet_priv > > But SYNACK packets ca

Re: [PATCH net-next 0/3] net: Pass net into defragmentation

2015-10-12 Thread David Miller
From: ebied...@xmission.com (Eric W. Biederman) Date: Fri, 09 Oct 2015 13:42:20 -0500 > > This is the next installment of my work to pass struct net through the > output path so the code does not need to guess how to figure out which > network namespace it is in, and ultimately routes can have ou

Re: [RFC PATCH 1/2] perf: Add the flag sample_disable not to output data on samples

2015-10-12 Thread xiakaixu
于 2015/10/13 3:20, Alexei Starovoitov 写道: > On 10/12/15 2:02 AM, Kaixu Xia wrote: >> diff --git a/include/linux/bpf.h b/include/linux/bpf.h >> index f57d7fe..25e073d 100644 >> --- a/include/linux/bpf.h >> +++ b/include/linux/bpf.h >> @@ -39,6 +39,7 @@ struct bpf_map { >> u32 max_entries; >>

Re: [PATCH net-next] tun: use sk_fullsock() before reading sk->sk_tsflags

2015-10-12 Thread David Miller
From: Eric Dumazet Date: Fri, 09 Oct 2015 15:42:21 -0700 > From: Eric Dumazet > > timewait or request sockets are small and do not contain sk->sk_tsflags > > Without this fix, we might read garbage, and crash later in > > __skb_complete_tx_timestamp() > -> sock_queue_err_skb() > > (These ps

Re: [PATCH net-next] net: hns: fix the unknown phy_nterface_t type error

2015-10-12 Thread David Miller
From: huangdaode Date: Sat, 10 Oct 2015 17:20:38 +0800 > This patch fix the building error reported by Jiri Pirko > > drivers/net/ethernet/hisilicon/hns/hnae.h:465:2: error: unknown type > name 'phy_interface_t' > phy_interface_t phy_if; > ^ > the full build log is on https://list

Re: [PATCH net-next v2] ipv6 route: use err pointers instead of returning pointer by reference

2015-10-12 Thread David Miller
From: Roopa Prabhu Date: Sat, 10 Oct 2015 08:26:36 -0700 > From: Roopa Prabhu > > This patch makes ip6_route_info_create return err pointer instead of > returning the rt pointer by reference as suggested by Dave > > Signed-off-by: Roopa Prabhu > --- > v1 - v2: remove unnecessary NULL initial

Re: [PATCH 2/2] atm: iphase: fix misleading indention

2015-10-12 Thread David Miller
From: Tillmann Heidsieck Date: Sat, 10 Oct 2015 21:47:19 +0200 > Fix a smatch warning: > drivers/atm/iphase.c:1178 rx_pkt() warn: curly braces intended? > > The code is correct, the indention is misleading. In case the allocation > of skb fails, we want to skip to the end. > > Signed-off-by: Ti

Re: [PATCH 1/2] atm: iphase: return -ENOMEM instead of -1 in case of failed kmalloc()

2015-10-12 Thread David Miller
From: Tillmann Heidsieck Date: Sat, 10 Oct 2015 21:47:18 +0200 > Smatch complains about returning hard coded error codes, silence this > warning. > > drivers/atm/iphase.c:115 ia_enque_rtn_q() warn: returning -1 instead of > -ENOMEM is sloppy > > Signed-off-by: Tillmann Heidsieck Applied to n

Re: [PATCH net-next V15 0/3] openvswitch: Add support for 802.1ad

2015-10-12 Thread David Miller
From: Thomas F Herbert Date: Sat, 10 Oct 2015 19:40:30 -0400 > Thomas F Herbert (3): > openvswitch: 802.1ad uapi changes. > Check for vlan ethernet types for 8021.q or 802.1ad > 802.1AD: Flow handling, actions, vlan parsing and netlink attributes I think this patch series has gone long eno

Re: [PATCH net-next] bridge: vlan: enforce no pvid flag in vlan ranges

2015-10-12 Thread David Miller
From: Nikolay Aleksandrov Date: Sun, 11 Oct 2015 12:49:56 +0200 > From: Nikolay Aleksandrov > > Currently it's possible for someone to send a vlan range to the kernel > with the pvid flag set which will result in the pvid bouncing from a > vlan to vlan and isn't correct, it also introduces prob

<    1   2   3   >