Re: [PATCH 5/7] slub: support for bulk free with SLUB freelists

2015-09-29 Thread Jesper Dangaard Brouer
On Mon, 28 Sep 2015 11:30:00 -0500 (CDT) Christoph Lameter wrote: > On Mon, 28 Sep 2015, Jesper Dangaard Brouer wrote: > > > Not knowing SLUB as well as you, it took me several hours to realize > > init_object() didn't overwrite the freepointer in the object. Thus, I > >

Re: [net] skbuff: Fix skb checksum flag on skb pull

2015-09-29 Thread Andrey Vagin
On Tue, Sep 29, 2015 at 03:27:03AM +0300, Pravin Shelar wrote: > On Mon, Sep 28, 2015 at 2:46 AM, Andrew Vagin wrote: > > Hi, > > > > With this patch, I can't connect two local tcp ipv6 sockets. > > > > [root@fc22-vm criu]# strace -e network python ipv6.py > > socket(PF_INET6,

Re: [PATCH] [net] orinoco_usb:Fix error handling in ezusb_probe()

2015-09-29 Thread Kalle Valo
RUC_Soft_Sec writes: > Current code assigns 0 to variable 'retval', which makes ezusb_probe() to > return success even if alloc_orinocodev() fails. > > The related code snippets in mantis_dma_init() is as following. > > 1573 static int ezusb_probe(struct usb_interface

Re: unregister_netdevice warnings when deleting netns

2015-09-29 Thread Julian Anastasov
Hello, On Mon, 28 Sep 2015, Eric W. Biederman wrote: > Julian Anastasov writes: > > > On Mon, 28 Sep 2015, Anand Gurram wrote: > > > >> I am currently using kernel version 3.16.7 on a linux switch. > >> While creating and destroying network namespaces I am observing below

Re: [RFC PATCH] Fix false positives in can_checksum_protocol()

2015-09-29 Thread David Woodhouse
On Mon, 2015-09-28 at 12:37 -0700, Tom Herbert wrote: > I think it's easier to just call skb_checksum_help from the driver > when the packet is actually sent to the device (should be no cost for > late binding). That's true for checksum. Not for things like TSO though, and I wonder if it's worth

Re: mwifiex: Make mwifiex_dbg a function, reduce object size

2015-09-29 Thread Kalle Valo
> The mwifiex_dbg macro has two tests that could be consolidated > into a function reducing overall object size ~10KB (~4%). > > So convert the macro into a function. > > $ size drivers/net/wireless/mwifiex/built-in.o* (x86-64 defconfig) >text data bss dec hex filename

Re: [PATCH net-next 0/6] make non-modular code explicitly non-modular

2015-09-29 Thread Finn Thain
Hi Paul, On Mon, 28 Sep 2015, Paul Gortmaker wrote: > On 28/09/2015 (Mon 23:09) Geert Uytterhoeven wrote: > > > Hi Paul, ... > > > > Why did you choose this approach? > > What about changing the "bool"s to "tristate"s in Kconfig instead? > > Long answer is here: > >

Re: unregister_netdevice warnings when deleting netns

2015-09-29 Thread Eric W. Biederman
Anand Gurram writes: >>If the message just spits out a few times and then goes away it simply >>means that something is taking a while to cleanup and drop it's >>reference. > > The message just spits out few times and then goes away, I am trying > to debug why cleanup

Re: BUG: Mellanox crash with iommu=soft and swiotlb=force

2015-09-29 Thread Christoffer Dall
On Tue, Sep 29, 2015 at 12:59:35AM +0300, Or Gerlitz wrote: > On Tue, Sep 29, 2015 at 12:04 AM, Christoffer Dall > wrote: > > Hi, > > > > In doing some performance experiments I found that using a 10G Mellanox > > MX354A Dual port FDR CX3 device on a server running

RE: [RFC v2 net-next 05/10] qede: Add basic network device support

2015-09-29 Thread Yuval Mintz
> > >> > +struct qede_rx_queue { > > >> > + __le16 *hw_cons_ptr; > > >> > > >> The __ variants of constants should be reserved for use in user > > >> visible API's > > > > > > Really? If so, this needs to be fixed not only here but in lots of > > > places in the series [e.g.,

Re: [v3,1/2] airo: fix IW_AUTH_ALG_OPEN_SYSTEM

2015-09-29 Thread Kalle Valo
> IW_AUTH_ALG_OPEN_SYSTEM is ambiguous in set_auth for WEP as > wpa_supplicant uses it for both no encryption and WEP open system. > Cache the last mode set (only of these two) and use it here. > > This allows wpa_supplicant to work with unencrypted APs. > > Signed-off-by: Ondrej Zary

Re: [PATCH RFC 2/7] netfilter: nft_meta: look at pkt->sk rather than skb->sk

2015-09-29 Thread kbuild test robot
Hi Daniel, [auto build test results on v4.3-rc3 -- if it's inappropriate base, please ignore] config: m68k-sun3_defconfig (attached as .config) reproduce: wget https://git.kernel.org/cgit/linux/kernel/git/wfg/lkp-tests.git/plain/sbin/make.cross -O ~/bin/make.cross chmod +x

Re: unregister_netdevice warnings when deleting netns

2015-09-29 Thread Anand Gurram
Thanks Julian, I will check if these two commits work for me. >I think, they will appear in other stable versions too... Yes, I saw them in other versions, the fix which is suggested in those branches didn't work for me. Hope the above two commits help. Regards, Anand On Tue, Sep 29, 2015 at

Re: unregister_netdevice warnings when deleting netns

2015-09-29 Thread Anand Gurram
>If the message just spits out a few times and then goes away it simply >means that something is taking a while to cleanup and drop it's >reference. The message just spits out few times and then goes away, I am trying to debug why cleanup is taking long, and where it is still referenced. Any

Re: [RFC PATCH] Fix false positives in can_checksum_protocol()

2015-09-29 Thread David Woodhouse
On Mon, 2015-09-28 at 20:04 -0700, Tom Herbert wrote: > > > I've been pondering a bit of a redesign in this space. I think the > > skb struct should be explicit in its instructions to hardware for > > which offloads to do for each packet. > > > > In this way, the stack would be *directly*

Re: [PATCH 5/7] slub: support for bulk free with SLUB freelists

2015-09-29 Thread Jesper Dangaard Brouer
On Mon, 28 Sep 2015 11:28:15 -0500 (CDT) Christoph Lameter wrote: > On Mon, 28 Sep 2015, Jesper Dangaard Brouer wrote: > > > > Do you really need separate parameters for freelist_head? If you just want > > > to deal with one object pass it as freelist_head and set cnt = 1? > > >

[PATCH 0/5] net: m68k: Allow modular build

2015-09-29 Thread Geert Uytterhoeven
Hi David, Paul, This patch series makes the remaining m68k Ethernet drivers modular. It's an alternative to the last 3 patches of Paul Gortmaker's series "[PATCH net-next 0/6] make non-modular code explicitly non-modular". Note that "[PATCH 5/5] net: macmace: Allow modular build" depends

[PATCH 3/5] net: hplance: Allow modular build

2015-09-29 Thread Geert Uytterhoeven
Signed-off-by: Geert Uytterhoeven --- drivers/net/ethernet/amd/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/amd/Kconfig b/drivers/net/ethernet/amd/Kconfig index afc62ea804fc35d4..0038709fd317d83c 100644 ---

[PATCH 5/5] net: macmace: Allow modular build

2015-09-29 Thread Geert Uytterhoeven
Signed-off-by: Geert Uytterhoeven --- This depends on "[PATCH 4/5] m68k/mac: Export Peripheral System Controller (PSC) base address to modules". --- drivers/net/ethernet/apple/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

[PATCH 2/5] net: 7990: Export lance_poll() to modules

2015-09-29 Thread Geert Uytterhoeven
If CONFIG_HPLANCE=m and CONFIG_NET_POLL_CONTROLLER=y: ERROR: "lance_poll" [drivers/net/ethernet/amd/hplance.ko] undefined! Add the missing export to fix this. Signed-off-by: Geert Uytterhoeven --- drivers/net/ethernet/amd/7990.c | 1 + 1 file changed, 1 insertion(+)

[PATCH 4/5] m68k/mac: Export Peripheral System Controller (PSC) base address to modules

2015-09-29 Thread Geert Uytterhoeven
If CONFIG_MACMACE=m: ERROR: psc [drivers/net/ethernet/apple/macmace.ko] undefined! Add the missing export to fix this. Signed-off-by: Geert Uytterhoeven --- I'm OK with this going in through the netdev tree, as "net: macmace: Allow modular build" depends on it. ---

[PATCH 1/5] net: mac8390: Allow modular build

2015-09-29 Thread Geert Uytterhoeven
The modular driver supports only one card, just like the built-in driver. Note that this limitation is a problem which affects all Nubus card drivers, because they have to do all their own bus matching, because Nubus still lacks the necessary driver model support. Suggested-by: Finn Thain

Re: Per-flow IPv4 ECMP

2015-09-29 Thread Peter Nørlund
On Mon, 28 Sep 2015 06:48:09 -0700 roopa wrote: > On 9/28/15, 1:57 AM, Matthew Dupre wrote: > > Hi, > > > > I'm interested in the Linux kernel's support for per-flow IPv4 ECMP > > (i.e. consistent path selection based on a hash of the connection > > tuple). I'd been

RE: [PATCH v4 net-next 0/2] ipv4: Hash-based multipath routing

2015-09-29 Thread David Laight
From: Peter Nørlund > Sent: 29 September 2015 12:29 ... > As for using L4 hashing with anycast, CloudFlare apparently does L4 > hashing - they could have disabled it, but they didn't. Besides, > analysis of my own load balancers showed that only one in every > 500,000,000 packets is fragmented.

Re: [PATCH net-next 0/6] make non-modular code explicitly non-modular

2015-09-29 Thread Paul Gortmaker
[Re: [PATCH net-next 0/6] make non-modular code explicitly non-modular] On 29/09/2015 (Tue 16:32) Finn Thain wrote: > > Hi Paul, > > On Mon, 28 Sep 2015, Paul Gortmaker wrote: > > > On 28/09/2015 (Mon 23:09) Geert Uytterhoeven wrote: > > > > > Hi Paul, > ... > > > > > > Why did you choose

Re: [PATCH v4 net-next 0/2] ipv4: Hash-based multipath routing

2015-09-29 Thread Peter Nørlund
On Mon, 28 Sep 2015 19:55:41 -0700 (PDT) David Miller wrote: > From: David Miller > Date: Mon, 28 Sep 2015 19:33:55 -0700 (PDT) > > > From: Peter Nørlund > > Date: Wed, 23 Sep 2015 21:49:35 +0200 > > > >> When the routing cache was

[PATCH RFC 4/7] net: tcp_ipv4, udp_ipv4: hook up LOCAL_SOCKET_IN netfilter chains

2015-09-29 Thread Daniel Mack
Run the NF_INET_LOCAL_SOCKET_IN netfilter chain rules after the destination socket for IPv4 unicast and multicast ports have been looked up. Signed-off-by: Daniel Mack --- net/ipv4/netfilter/nf_tables_ipv4.c | 10 +- net/ipv4/tcp_ipv4.c | 8

[PATCH RFC 5/7] net: tcp_ipv6, udp_ipv6: hook up LOCAL_SOCKET_IN netfilter chains

2015-09-29 Thread Daniel Mack
Run the NF_INET_LOCAL_SOCKET_IN netfilter chain rules after the destination socket for IPv6 unicast and multicast ports have been looked up. Signed-off-by: Daniel Mack --- net/ipv6/netfilter/nf_tables_ipv6.c | 14 -- net/ipv6/tcp_ipv6.c | 8

[PATCH RFC 3/7] netfilter: add NF_INET_LOCAL_SOCKET_IN chain type

2015-09-29 Thread Daniel Mack
Add a new chain type NF_INET_LOCAL_SOCKET_IN which is ran after the input demux is complete and the final destination socket (if any) has been determined. This helps filtering packets based on information stored in the destination socket, such as cgroup controller supplied net class IDs. Note

[PATCH RFC 7/7] net: dccp: hook up LOCAL_SOCKET_IN netfilter chains

2015-09-29 Thread Daniel Mack
Run the NF_INET_LOCAL_SOCKET_IN netfilter chain rules after the destination socket for DCCP packets have been looked up. Signed-off-by: Daniel Mack --- net/dccp/ipv4.c | 14 +- net/dccp/ipv6.c | 14 +- 2 files changed, 26 insertions(+), 2 deletions(-)

[PATCH RFC 0/7] netfilter: introduce new chain type for local socket input

2015-09-29 Thread Daniel Mack
Here is a patch set that enables for full support for match rules that take into account information about the local receiver socket. Such rules allow administrators to implement per-application or per-container firewalls which filter any type of network traffic directed to or originated from a

[PATCH RFC 2/7] netfilter: nft_meta: look at pkt->sk rather than skb->sk

2015-09-29 Thread Daniel Mack
pkt->sk is set to whatever was passed to nh_hook() by the caller, and for post demux chains, this is the one that should be looked at, as skb->sk is still NULL at this point in time. Signed-off-by: Daniel Mack --- net/netfilter/nft_meta.c | 7 --- 1 file changed, 4

[PATCH RFC 1/7] netfilter: add socket to struct nft_pktinfo

2015-09-29 Thread Daniel Mack
The high-level netfilter hook API already enables users to pass a socket, but that information is lost when the chains are walked. In order to let internal eval callbacks use the passed filter rather than skb->sk, add a pointer of type 'struct sock' to 'struct nft_pktinfo' and set that field via

[PATCH RFC 6/7] net: sctp: hook up LOCAL_SOCKET_IN netfilter chains

2015-09-29 Thread Daniel Mack
Run the NF_INET_LOCAL_SOCKET_IN netfilter chain rules after the destination socket for SCTP packets have been looked up. Signed-off-by: Daniel Mack --- net/sctp/input.c | 11 ++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/net/sctp/input.c

Re: 4.3-rc3 Regression: NFS access stall by commit 6ae459bdaaee

2015-09-29 Thread Takashi Iwai
On Tue, 29 Sep 2015 02:35:04 +0200, Pravin Shelar wrote: > > On Mon, Sep 28, 2015 at 6:12 AM, Takashi Iwai wrote: > > [I resent this since the previous mail didn't go out properly, as it > > seems; apologies if you already read it, please disregard] > > > > Hi, > > > > I noticed

[PATCH 1/1] xfrm: Fix state threshold configuration from userspace

2015-09-29 Thread Michael Rossberg
Allow to change the replay threshold (XFRMA_REPLAY_THRESH) and expiry timer (XFRMA_ETIMER_THRESH) of a state without having to set other attributes like replay counter and byte lifetime. Changing these other values while traffic flows will break the state. Signed-off-by: Michael Rossberg

[PATCH net-next 4/6] net: switchdev: pass callback to dump operation

2015-09-29 Thread Vivien Didelot
Similar to the notifier_call callback of a notifier_block, change the function signature of switchdev dump operation to: int switchdev_port_obj_dump(struct net_device *dev, enum switchdev_obj_id id, void *obj, int (*cb)(void

[PATCH net-next 0/6] net: switchdev: use specific switchdev_obj_*

2015-09-29 Thread Vivien Didelot
This patchset changes switchdev add, del, dump operations from this: int (*switchdev_port_obj_add)(struct net_device *dev, struct switchdev_obj *obj, struct switchdev_trans *trans); int

[PATCH net-next 00/14] tcp: listener refactoring preparations

2015-09-29 Thread Eric Dumazet
This patch series makes changes to TCP/DCCP stacks so that we can switch listener code to lockless mode. This is done by marking const the listener socket in all appropriate paths. FastOpen code had to be changed to not dynamically allocate a very small structure to make code simpler for

[PATCH net-next 03/14] tcp: remove tcp_rcv_state_process() tcp_hdr argument

2015-09-29 Thread Eric Dumazet
Factorize code to get tcp header from skb. It makes no sense to duplicate code in callers. Signed-off-by: Eric Dumazet --- include/net/tcp.h| 3 +-- net/ipv4/tcp_input.c | 4 ++-- net/ipv4/tcp_ipv4.c | 2 +- net/ipv4/tcp_minisocks.c | 2 +-

[PATCH net-next 04/14] dccp: use inet6_csk_route_req() helper

2015-09-29 Thread Eric Dumazet
Before changing dccp_v6_request_recv_sock() sock argument to const, we need to get rid of security_sk_classify_flow(), and it seems doable by reusing inet6_csk_route_req() helper. We need to add a proto parameter to inet6_csk_route_req(), not assume it is TCP. Signed-off-by: Eric Dumazet

[PATCH net-next 14/14] tcp: prepare fastopen code for upcoming listener changes

2015-09-29 Thread Eric Dumazet
While auditing TCP stack for upcoming 'lockless' listener changes, I found I had to change fastopen_init_queue() to properly init the object before publishing it. Otherwise an other cpu could try to lock the spinlock before it gets properly initialized. Instead of adding appropriate barriers,

[PATCH net-next 13/14] tcp: constify tcp_syn_flood_action() socket argument

2015-09-29 Thread Eric Dumazet
tcp_syn_flood_action() will soon be called with unlocked socket. In order to avoid SYN flood warning being emitted multiple times, use xchg(). Extend max_qlen_log and synflood_warned fields in struct listen_sock to u32 Signed-off-by: Eric Dumazet ---

[PATCH net-next 11/14] tcp: cookie_init_sequence() cleanups

2015-09-29 Thread Eric Dumazet
Some common IPv4/IPv6 code can be factorized. Also constify cookie_init_sequence() socket argument. Signed-off-by: Eric Dumazet --- include/net/tcp.h | 19 ++- net/ipv4/syncookies.c | 6 +- net/ipv6/syncookies.c | 5 + 3 files changed, 12

[PATCH net-next 09/14] tcp: constify tcp_create_openreq_child() socket argument

2015-09-29 Thread Eric Dumazet
This method does not touch the listener socket. Signed-off-by: Eric Dumazet --- include/net/tcp.h| 2 +- net/ipv4/tcp_minisocks.c | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/include/net/tcp.h b/include/net/tcp.h index

[PATCH net-next 10/14] tcp/dccp: constify syn_recv_sock() method sock argument

2015-09-29 Thread Eric Dumazet
We'll soon no longer hold listener socket lock, these functions do not modify the socket in any way. Signed-off-by: Eric Dumazet --- include/net/inet_connection_sock.h | 2 +- include/net/tcp.h | 2 +- net/dccp/dccp.h| 2 +-

[PATCH net-next 12/14] tcp: constify tcp_v{4|6}_route_req() sock argument

2015-09-29 Thread Eric Dumazet
These functions do not change the listener socket. Goal is to make sure tcp_conn_request() is not messing with listener in a racy way. Signed-off-by: Eric Dumazet --- include/net/tcp.h | 2 +- net/ipv4/tcp_ipv4.c | 3 ++- net/ipv6/tcp_ipv6.c | 3 ++- 3 files changed, 5

[PATCH net-next 2/6] net: switchdev: move dev in switchdev_fdb_dump

2015-09-29 Thread Vivien Didelot
The FDB dump callback requires the related net_device so move it to the struct switchdev_fdb_dump superset instead of using a callback param. With this done, it'll be simpler to change the dump function signature. Signed-off-by: Vivien Didelot ---

Re: [PATCH v2 1/1] net sysfs: Print link speed as signed integer

2015-09-29 Thread Jeremy Harris
On 28/09/15 14:05, Alexander Stein wrote: Otherwise 4294967295 (MBit/s) (-1) will be printed when there is no link. Documentation/ABI/testing/sysfs-class-net does not state if this shall be signed or unsigned. Also remove the now unused variable fmt_udec. [...] - ret =

[PATCH net-next 3/6] net: switchdev: remove dev from switchdev_obj cb

2015-09-29 Thread Vivien Didelot
The net_device associated to a dump operation does not have to be passed to the callback. switchdev stores it in a superset struct, if needed. Also some drivers (such as DSA drivers) may not have easy access to it. This will simplify pushing the callback function down to the drivers.

[PATCH net-next 1/6] net: switchdev: remove dev in port_vlan_dump_put

2015-09-29 Thread Vivien Didelot
The static switchdev_port_vlan_dump_put function don't need the net_device parameter, so remove it. Signed-off-by: Vivien Didelot --- net/switchdev/switchdev.c | 11 +-- 1 file changed, 5 insertions(+), 6 deletions(-) diff --git

[PATCH net-next 06/14] inet: constify __inet_inherit_port() sock argument

2015-09-29 Thread Eric Dumazet
socket is not touched, make it const. Signed-off-by: Eric Dumazet --- include/net/inet_hashtables.h | 2 +- net/ipv4/inet_hashtables.c| 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/include/net/inet_hashtables.h b/include/net/inet_hashtables.h

[PATCH net-next 05/14] inet: constify inet_csk_route_child_sock() socket argument

2015-09-29 Thread Eric Dumazet
The socket points to the (shared) listener. Signed-off-by: Eric Dumazet --- include/net/inet_connection_sock.h | 3 ++- net/ipv4/inet_connection_sock.c| 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/include/net/inet_connection_sock.h

[PATCH net-next 08/14] dccp: constify dccp_create_openreq_child() sock argument

2015-09-29 Thread Eric Dumazet
socket no longer needs to be read/write Signed-off-by: Eric Dumazet --- net/dccp/dccp.h | 2 +- net/dccp/minisocks.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/net/dccp/dccp.h b/net/dccp/dccp.h index 8ed1df2771bd..2409619b7043 100644 ---

[PATCH net-next 07/14] net: constify sk_gfp_atomic() sock argument

2015-09-29 Thread Eric Dumazet
Signed-off-by: Eric Dumazet --- include/net/sock.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/net/sock.h b/include/net/sock.h index 94dff7f566f5..dfe2eb8e1132 100644 --- a/include/net/sock.h +++ b/include/net/sock.h @@ -759,7 +759,7 @@ static

[PATCH net-next 02/14] tcp: remove unused len argument from tcp_rcv_state_process()

2015-09-29 Thread Eric Dumazet
Once we realize tcp_rcv_synsent_state_process() does not use its 'len' argument and we get rid of it, then it becomes clear this argument is no longer used in tcp_rcv_state_process() Signed-off-by: Eric Dumazet --- include/net/tcp.h| 2 +- net/ipv4/tcp_input.c |

[PATCH net-next 01/14] tcp/dccp: constify send_synack and send_reset socket argument

2015-09-29 Thread Eric Dumazet
None of these functions need to change the socket, make it const. Signed-off-by: Eric Dumazet --- include/net/request_sock.h | 4 ++-- net/dccp/dccp.h| 2 +- net/dccp/ipv4.c| 2 +- net/dccp/ipv6.c| 2 +- net/dccp/minisocks.c |

[PATCH net-next 6/6] net: switchdev: extract struct switchdev_obj_*

2015-09-29 Thread Vivien Didelot
Now that switchdev and its drivers directly use specific switchdev_obj_* structures, move them out of the switchdev_obj union and get rif of this outer structure. Signed-off-by: Vivien Didelot --- include/net/switchdev.h | 53

[PATCH v2] net/mlx4: Handle return codes in mlx4_qp_attach_common

2015-09-29 Thread Robb Manes
Both new_steering_entry() and existing_steering_entry() return values based on their success or failure, but currently they fall through silently. This can make troubleshooting difficult, as we were unable to tell which one of these two functions returned errors or specifically what code was

question about potential integer truncation in mwifiex_set_wapi_ie and mwifiex_set_wps_ie

2015-09-29 Thread PaX Team
hi all, in drivers/net/wireless/mwifiex/sta_ioctl.c the following functions mwifiex_set_wpa_ie_helper mwifiex_set_wapi_ie mwifiex_set_wps_ie can truncate the incoming ie_len argument from u16 to u8 when it gets stored in mwifiex_private.wpa_ie_len,

[PATCH net-next 5/6] net: switchdev: abstract object in add/del ops

2015-09-29 Thread Vivien Didelot
Similar to the notifier_call callback of a notifier_block, change the function signature of switchdev add and del operations to: int switchdev_port_obj_add/del(struct net_device *dev, enum switchdev_obj_id id, void *obj); This allows the caller to pass a

[PATCH v2 net-next 5/6] net: switchdev: abstract object in add/del ops

2015-09-29 Thread Vivien Didelot
Similar to the notifier_call callback of a notifier_block, change the function signature of switchdev add and del operations to: int switchdev_port_obj_add/del(struct net_device *dev, enum switchdev_obj_id id, void *obj); This allows the caller to pass a

Re: [RFT] geneve: implement support for IPv6-based tunnels

2015-09-29 Thread Jiri Benc
On Mon, 28 Sep 2015 15:20:33 -0400, John W. Linville wrote: > > To be really useful, geneve should open both IPv4 and IPv6 socket when > > it's metadata based. Take a look at my recent patchset that does this > > for vxlan: http://thread.gmane.org/gmane.linux.network/379282 > > OK, that seems

Re: [PATCH net-next] net: dsa: fix preparation of a port STP update

2015-09-29 Thread Andrew Lunn
On Tue, Sep 29, 2015 at 12:38:36PM -0400, Vivien Didelot wrote: > Because of the default 0 value of ret in dsa_slave_port_attr_set, a > driver may return -EOPNOTSUPP from the commit phase of a STP state, > which triggers a WARN() from switchdev. > > This happened on a 6185 switch which does not

Re: [MM PATCH V4 5/6] slub: support for bulk free with SLUB freelists

2015-09-29 Thread Alexander Duyck
On 09/29/2015 08:48 AM, Jesper Dangaard Brouer wrote: Make it possible to free a freelist with several objects by adjusting API of slab_free() and __slab_free() to have head, tail and an objects counter (cnt). Tail being NULL indicate single object free of head object. This allow compiler

[MM PATCH V4 3/6] slub: mark the dangling ifdef #else of CONFIG_SLUB_DEBUG

2015-09-29 Thread Jesper Dangaard Brouer
The #ifdef of CONFIG_SLUB_DEBUG is located very far from the associated #else. For readability mark it with a comment. Signed-off-by: Jesper Dangaard Brouer Acked-by: Christoph Lameter --- mm/slub.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-)

[MM PATCH V4 0/6] Further optimizing SLAB/SLUB bulking

2015-09-29 Thread Jesper Dangaard Brouer
Most important part of this patchset is the introducing of what I call detached freelist, for improving SLUB performance of object freeing in the "slowpath" of kmem_cache_free_bulk. Tagging patchset with "V4" to avoid confusion with "V2": (V2) http://thread.gmane.org/gmane.linux.kernel.mm/137469

[PATCH v2 net-next 2/6] net: switchdev: move dev in switchdev_fdb_dump

2015-09-29 Thread Vivien Didelot
The FDB dump callback requires the related net_device so move it to the struct switchdev_fdb_dump superset instead of using a callback param. With this done, it'll be simpler to change the dump function signature. Signed-off-by: Vivien Didelot ---

[PATCH net-next] net: dsa: fix preparation of a port STP update

2015-09-29 Thread Vivien Didelot
Because of the default 0 value of ret in dsa_slave_port_attr_set, a driver may return -EOPNOTSUPP from the commit phase of a STP state, which triggers a WARN() from switchdev. This happened on a 6185 switch which does not support hardware bridging. Reported-by: Andrew Lunn

[PATCH v2 net-next 1/6] net: switchdev: remove dev in port_vlan_dump_put

2015-09-29 Thread Vivien Didelot
The static switchdev_port_vlan_dump_put function does not need the net_device parameter, so remove it. Signed-off-by: Vivien Didelot --- net/switchdev/switchdev.c | 11 +-- 1 file changed, 5 insertions(+), 6 deletions(-) diff --git

[PATCH v2 net-next 4/6] net: switchdev: pass callback to dump operation

2015-09-29 Thread Vivien Didelot
Similar to the notifier_call callback of a notifier_block, change the function signature of switchdev dump operation to: int switchdev_port_obj_dump(struct net_device *dev, enum switchdev_obj_id id, void *obj, int (*cb)(void

Re: unregister_netdevice warnings when deleting netns

2015-09-29 Thread Anand Gurram
Hi Julian and Eric I tried both the patches which you have suggested, the issue is still seen, I am observing same warning message thrown on the console "unregister_netdevice: waiting for lo to become free. Usage count = 1". >Sometimes people have addressed this class of issue with code

Re: [PATCH net-next 4/6] net: switchdev: pass callback to dump operation

2015-09-29 Thread kbuild test robot
Hi Vivien, [auto build test results on next-20150929 -- if it's inappropriate base, please ignore] config: i386-randconfig-s1-201539 (attached as .config) reproduce: git checkout b215cce51157820c4fb92ecfdc72f281a4286676 # save the attached .config to linux build tree make ARCH=i386 All

[PATCH] testptp: Silence compiler warnings on ppc64

2015-09-29 Thread Thomas Huth
When compiling Documentation/ptp/testptp.c the following compiler warnings are printed out: Documentation/ptp/testptp.c: In function ‘main’: Documentation/ptp/testptp.c:367:11: warning: format ‘%lld’ expects argument of type ‘long long int’, but argument 3 has type ‘__s64’ [-Wformat=]

[MM PATCH V4 6/6] slub: optimize bulk slowpath free by detached freelist

2015-09-29 Thread Jesper Dangaard Brouer
This change focus on improving the speed of object freeing in the "slowpath" of kmem_cache_free_bulk. The calls slab_free (fastpath) and __slab_free (slowpath) have been extended with support for bulk free, which amortize the overhead of the (locked) cmpxchg_double. To use the new bulking

[PATCH v2 net-next 6/6] net: switchdev: extract struct switchdev_obj_*

2015-09-29 Thread Vivien Didelot
Now that switchdev and its drivers directly use specific switchdev_obj_* structures, move them out of the switchdev_obj union and get rif of this outer structure. Signed-off-by: Vivien Didelot --- include/net/switchdev.h | 53

Re: [MM PATCH V4 5/6] slub: support for bulk free with SLUB freelists

2015-09-29 Thread Jesper Dangaard Brouer
On Tue, 29 Sep 2015 09:38:30 -0700 Alexander Duyck wrote: > On 09/29/2015 08:48 AM, Jesper Dangaard Brouer wrote: > > Make it possible to free a freelist with several objects by adjusting > > API of slab_free() and __slab_free() to have head, tail and an objects > >

Fw: [Bug 105221] New: system panics under load on mlx4_en interfaces

2015-09-29 Thread Stephen Hemminger
Begin forwarded message: Date: Tue, 29 Sep 2015 07:19:32 + From: "bugzilla-dae...@bugzilla.kernel.org" To: "shemmin...@linux-foundation.org" Subject: [Bug 105221] New: system panics under load on mlx4_en interfaces

[MM PATCH V4 4/6] slab: implement bulking for SLAB allocator

2015-09-29 Thread Jesper Dangaard Brouer
Implement a basic approach of bulking in the SLAB allocator. Simply use local_irq_{disable,enable} and call single alloc/free in a loop. This simple implementation approach is surprising fast. Notice the normal SLAB fastpath is: 96 cycles (24.119 ns). Below table show that single object bulking

[v4.3.0-rc2->3] Regression: BIG networking performance loss

2015-09-29 Thread Jörg Otte
With kernels vmlinuz-4.3.0-rc2-00228-gd4a748a and earlier it is no problem for me to stream HD-videos (700-800 Kbyte/s) from YouTube. With the same video material and kernels vmlinuz-4.3.0-rc2-00438-gd8cc397 and later I only reach 70-80 KByte/s. That's a one-tenth than before. The merges between

[PATCH v2 net-next 0/6] net: switchdev: use specific switchdev_obj_*

2015-09-29 Thread Vivien Didelot
This patchset changes switchdev add, del, dump operations from this: int (*switchdev_port_obj_add)(struct net_device *dev, struct switchdev_obj *obj, struct switchdev_trans *trans); int

[PATCH v2 net-next 3/6] net: switchdev: remove dev from switchdev_obj cb

2015-09-29 Thread Vivien Didelot
The net_device associated to a dump operation does not have to be passed to the callback. switchdev stores it in a superset struct, if needed. Also some drivers (such as DSA drivers) may not have easy access to it. This will simplify pushing the callback function down to the drivers.

[PATCH net-next v2] net: Add support for filtering neigh dump by master device

2015-09-29 Thread David Ahern
Add support for filtering neighbor dumps by master device by adding the NDA_MASTER attribute to the dump request. A new netlink flag, NLM_F_DUMP_FILTERED, is added to indicate the kernel supports the request and output is filtered as requested. Signed-off-by: David Ahern

[MM PATCH V4 5/6] slub: support for bulk free with SLUB freelists

2015-09-29 Thread Jesper Dangaard Brouer
Make it possible to free a freelist with several objects by adjusting API of slab_free() and __slab_free() to have head, tail and an objects counter (cnt). Tail being NULL indicate single object free of head object. This allow compiler inline constant propagation in slab_free() and

[MM PATCH V4 2/6] slub: Avoid irqoff/on in bulk allocation

2015-09-29 Thread Jesper Dangaard Brouer
From: Christoph Lameter NOTICE: Accepted by AKPM http://ozlabs.org/~akpm/mmots/broken-out/slub-avoid-irqoff-on-in-bulk-allocation.patch Use the new function that can do allocation while interrupts are disabled. Avoids irq on/off sequences. Signed-off-by: Christoph Lameter

[MM PATCH V4 1/6] slub: create new ___slab_alloc function that can be called with irqs disabled

2015-09-29 Thread Jesper Dangaard Brouer
From: Christoph Lameter NOTICE: Accepted by AKPM http://ozlabs.org/~akpm/mmots/broken-out/slub-create-new-___slab_alloc-function-that-can-be-called-with-irqs-disabled.patch Bulk alloc needs a function like that because it enables interrupts before calling __slab_alloc which

Re: [PATCH bluetooth-next 1/4] netlink: add nla_get for le32 and le64

2015-09-29 Thread Marcel Holtmann
Hi Dave, > This patch adds missing inline wrappers for nla_get_le32 and > nla_get_le64. The 802.15.4 MAC byteorder is little endian and we keep > the byteorder for fields like address configuration in the same > byteorder as it comes from the MAC layer. > > To provide these fields for nl802154

Re: [PATCH] net: ipv6: Add RT6_LOOKUP_F_IFACE flag if oif is set

2015-09-29 Thread David Miller
From: David Ahern Date: Mon, 28 Sep 2015 10:12:13 -0700 > Wolfgang reported that IPv6 stack is ignoring oif in output route lookups: ... > The stack does consider the oif but a mismatch in rt6_device_match is not > considered fatal because RT6_LOOKUP_F_IFACE is not set

Re: RESEND: [PATCH v3 net-next] sky2: use random address if EEPROM is bad

2015-09-29 Thread David Miller
From: Liviu Dudau Date: Mon, 28 Sep 2015 17:51:51 +0100 > On some embedded systems the EEPROM does not contain a valid MAC address. > In that case it is better to fallback to a generated mac address and > let init scripts fix the value later. > > Reported-by: Liviu Dudau

[PATCH 0/3] use napi_schedule_irqoff()

2015-09-29 Thread Alexander Duyck
This patch set is meant to replace the calls to napi_schedule with napi_schedule_irqoff as this should help to reduce the interrupt overhead slightly by removing the unneeded call to local_irq_save and local_irq_restore. --- Alexander Duyck (3): ixgbe/ixgbevf: use napi_schedule_irqoff()

[PATCH 2/3] i40e/i40evf: use napi_schedule_irqoff()

2015-09-29 Thread Alexander Duyck
The i40e_intr and i40e/i40evf_msix_clean_rings functions run from hard interrupt context or with interrupts already disabled in netpoll. They can use napi_schedule_irqoff() instead of napi_schedule() Signed-off-by: Alexander Duyck ---

[PATCH 3/3] fm10k: use napi_schedule_irqoff()

2015-09-29 Thread Alexander Duyck
The fm10k_msix_clean_rings function runs from hard interrupt context or with interrupts already disabled in netpoll. It can use napi_schedule_irqoff() instead of napi_schedule() Signed-off-by: Alexander Duyck --- drivers/net/ethernet/intel/fm10k/fm10k_pci.c |2 +- 1

Re: [PATCH net] skbuff: Fix skb checksum partial check.

2015-09-29 Thread David Miller
From: Pravin B Shelar Date: Mon, 28 Sep 2015 17:24:25 -0700 > Earlier patch 6ae459bda tried to detect void ckecksum partial > skb by comparing pull length to checksum offset. But it does > not work for all cases since checksum-offset depends on > updates to skb->data. > >

Re: [PATCH net-next v2 00/11] net: L3 master device

2015-09-29 Thread David Ahern
On 9/29/15 5:23 PM, David Miller wrote: From: David Ahern Date: Mon, 28 Sep 2015 10:16:50 -0700 v2 - rebased to top of net-next - addressed Niks comments (checking master, removing extra lines, and flipping the order of patches 1 and 2) This still needs some

Re: [PATCH 3/3] 802.1AD: Flow handling, actions, vlan parsing and netlink attributes

2015-09-29 Thread Pravin Shelar
On Fri, Sep 25, 2015 at 3:35 PM, Thomas F Herbert wrote: > Pravin, > > Another comment and question. Please seen inline below. > > Thanks, > > --Tom > > On 9/24/15 7:42 PM, Pravin Shelar wrote: >> >> On Thu, Sep 24, 2015 at 10:58 AM, Thomas F Herbert >>

Poor IPv6 TCP performance in 4.3-rc3

2015-09-29 Thread Russell King - ARM Linux
Hi, I'm seeing really poor IPv6 performance compared to IPv4. I've checked using two different ARM platforms - an iMX6 platform using the FEC driver, and an Armada 38x using mvneta. The following was captured using iperf between the target system and my laptop. The problem only occurs one-way.

Re: [PATCH net-next] bridge: vlan: add per-vlan struct and move to rhashtables

2015-09-29 Thread David Miller
From: Nikolay Aleksandrov Date: Fri, 25 Sep 2015 19:00:11 +0200 > This patch changes the bridge vlan implementation to use rhashtables > instead of bitmaps. This seems to be taking the code in a good direction, and I'm kinda happy to see more rhashtable users in the tree as

Re: [PATCH v2 1/1] net sysfs: Print link speed as signed integer

2015-09-29 Thread David Miller
From: Alexander Stein Date: Mon, 28 Sep 2015 15:05:33 +0200 > Otherwise 4294967295 (MBit/s) (-1) will be printed when there is no link. > Documentation/ABI/testing/sysfs-class-net does not state if this shall be > signed or unsigned. > Also remove the now

[PATCH net-next 0/6] ila: Optimization to preserve value of early demux

2015-09-29 Thread Tom Herbert
In the current implementation of ILA, LWT is used to perform translation on both the input and output paths. This is functional, however there is a big performance hit in the receive path. Early demux occurs before the routing lookup (a hit actually obviates the route lookup). Therefore the stack

[PATCH net-next 2/6] rhashtable: add function to replace an element

2015-09-29 Thread Tom Herbert
Add the rhashtable_replace_fast function. This replaces one object in the table with another atomically. The hashes of the new and old objects must be equal. Signed-off-by: Tom Herbert --- include/linux/rhashtable.h | 82 ++ 1

  1   2   3   >