iputils ping -I interface no longer functional for ipv4 addresses (unknown iface)

2016-05-23 Thread Chris Severance
% ping -V ping utility, iputils-s20160308 # https://www.archlinux.org/packages/core/x86_64/iputils/ % ping -I enp3s0 192.168.50.1 PING 192.168.50.1 (192.168.50.1) from 192.168.50.10 enp3s0: 56(84) bytes of data. 64 bytes from 192.168.50.1: icmp_seq=1 ttl=64 time=0.127 ms % ip addr 2: enp3s0: mtu

Re: [net PATCH v2 1/1] net sched actions: policer missing timestamp processing

2016-05-23 Thread Cong Wang
On Mon, May 23, 2016 at 6:07 PM, Jamal Hadi Salim wrote: > From: Jamal Hadi Salim > > Policer was not dumping or updating timestamps > > Signed-off-by: Jamal Hadi Salim Acked-by: Cong Wang Thanks.

[PATCH net 3/3] Documentation: networking: dsa: Describe port_vlan_filtering

2016-05-23 Thread Florian Fainelli
Described what the port_vlan_filtering function is supposed to accomplish. Fixes: fb2dabad69f0 ("net: dsa: support VLAN filtering switchdev attr") Signed-off-by: Florian Fainelli --- Documentation/networking/dsa/dsa.txt | 6 ++ 1 file changed, 6 insertions(+) diff --git a/Documentation/netw

[PATCH net 1/3] Documentation: networking: dsa: Remove poll_link description

2016-05-23 Thread Florian Fainelli
This function has been removed in 4baee937b8d5 ("net: dsa: remove DSA link polling") in favor of using the PHYLIB polling mechanism. Signed-off-by: Florian Fainelli --- Documentation/networking/dsa/dsa.txt | 5 - 1 file changed, 5 deletions(-) diff --git a/Documentation/networking/dsa/dsa.t

[PATCH net 0/3] Documentation: dsa: misc fixes

2016-05-23 Thread Florian Fainelli
Hi David, Here are some miscelaneous documentation fixes for DSA, I targeted "net" because these are not functional code changes, but still documentation fixes per-se. Florian Fainelli (3): Documentation: networking: dsa: Remove poll_link description Documentation: networking: dsa: Remove pri

[PATCH net 2/3] Documentation: networking: dsa: Remove priv_size description

2016-05-23 Thread Florian Fainelli
We no longer have a priv_size structure member since 5feebd0a8a79 ("net: dsa: Remove allocation of driver private memory") Signed-off-by: Florian Fainelli --- Documentation/networking/dsa/dsa.txt | 2 -- 1 file changed, 2 deletions(-) diff --git a/Documentation/networking/dsa/dsa.txt b/Documen

Re: [PATCH v2] ip_tunnel: enclose a code block in macro IS_ENABLED(CONFIG_IPV6)

2016-05-23 Thread David Miller
From: 严海双 Date: Tue, 24 May 2016 11:55:31 +0800 > >> On May 24, 2016, at 11:14 AM, Eric Dumazet wrote: >> >> On Tue, 2016-05-24 at 10:39 +0800, Haishuang Yan wrote: >>> For ipv6 case, enclose the code block in macro IS_ENABLED(CONFIG_IPV6). >>> >>> --- >>> Changes in v2: >>> - Place the "#if

Re: [PATCH v2] ip_tunnel: enclose a code block in macro IS_ENABLED(CONFIG_IPV6)

2016-05-23 Thread 严海双
> On May 24, 2016, at 11:14 AM, Eric Dumazet wrote: > > On Tue, 2016-05-24 at 10:39 +0800, Haishuang Yan wrote: >> For ipv6 case, enclose the code block in macro IS_ENABLED(CONFIG_IPV6). >> >> --- >> Changes in v2: >> - Place the "#if IS_ENABLED" block before the "} else if >> (..) {" piece an

Re: [RFC PATCH 3/7] ipv4: Support TOU

2016-05-23 Thread Eric Dumazet
On Mon, 2016-05-23 at 15:48 -0700, Tom Herbert wrote: ... > static int > ip_fragment(struct net *net, struct sock *sk, struct sk_buff *skb, > @@ -382,11 +383,36 @@ int ip_queue_xmit(struct sock *sk, struct sk_buff *skb, > struct flowi *fl) > struct rtable *rt; > struct iphdr *iph;

Re: [PATCH v2] ip_tunnel: enclose a code block in macro IS_ENABLED(CONFIG_IPV6)

2016-05-23 Thread Eric Dumazet
On Tue, 2016-05-24 at 10:39 +0800, Haishuang Yan wrote: > For ipv6 case, enclose the code block in macro IS_ENABLED(CONFIG_IPV6). > > --- > Changes in v2: > - Place the "#if IS_ENABLED" block before the "} else if > (..) {" piece and the "#endif" before the closing brace and this > becomes much

[PATCH v2] ip_tunnel: enclose a code block in macro IS_ENABLED(CONFIG_IPV6)

2016-05-23 Thread Haishuang Yan
For ipv6 case, enclose the code block in macro IS_ENABLED(CONFIG_IPV6). --- Changes in v2: - Place the "#if IS_ENABLED" block before the "} else if (..) {" piece and the "#endif" before the closing brace and this becomes much easier to look at. Signed-off-by: Haishuang Yan --- net/ipv4/ip_tun

Re: [PATCH v2] ethernet:arc: Fix racing of TX ring buffer

2016-05-23 Thread Lino Sanfilippo
On 23.05.2016 13:36, Shuyu Wei wrote: > On Sun, May 22, 2016 at 01:30:27PM +0200, Lino Sanfilippo wrote: >> > > Hi Lino, > This patch worked after a whole night of stress testing. > Thats great! I will nevertheless make the changes discussed with Francois and hopefully we have a final soluti

Re: [PATCH v2] ethernet:arc: Fix racing of TX ring buffer

2016-05-23 Thread Lino Sanfilippo
On 23.05.2016 00:36, Francois Romieu wrote: > Lino Sanfilippo : > [...] >> --- a/drivers/net/ethernet/arc/emac_main.c >> +++ b/drivers/net/ethernet/arc/emac_main.c >> @@ -159,12 +159,22 @@ static void arc_emac_tx_clean(struct net_device *ndev) >> unsigned int *txbd_dirty = &priv->txbd

[net PATCH v2 1/1] net sched actions: policer missing timestamp processing

2016-05-23 Thread Jamal Hadi Salim
From: Jamal Hadi Salim Policer was not dumping or updating timestamps Signed-off-by: Jamal Hadi Salim --- include/uapi/linux/pkt_cls.h | 4 +++- net/sched/act_police.c | 11 +++ 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/include/uapi/linux/pkt_cls.h b/include

[iproute2 1/1] tc simple action: bug fix

2016-05-23 Thread Jamal Hadi Salim
From: Jamal Hadi Salim Failed compile m_simple.c: In function ‘parse_simple’: m_simple.c:154:6: warning: too many arguments for format [-Wformat-extra-args] *argv); ^ m_simple.c:103:14: warning: unused variable ‘maybe_bind’ [-Wunused-variable] Reported-by: Daniel Borkmann Signed-off

Re: [iproute2 PATCH v2 1/1] tc simple action update and breakage

2016-05-23 Thread Jamal Hadi Salim
On 16-05-23 06:39 PM, Daniel Borkmann wrote: m_simple.c: In function ‘parse_simple’: m_simple.c:154:6: warning: too many arguments for format [-Wformat-extra-args] *argv); ^ m_simple.c:103:14: warning: unused variable ‘maybe_bind’ [-Wunused-variable] int ok = 0, maybe_bind = 0;

Re: [net PATCH 1/1] net sched actions: policer missing timestamp processing

2016-05-23 Thread Jamal Hadi Salim
On 16-05-23 04:52 PM, Cong Wang wrote: + tcf_tm_dump(&t, &police->tcf_tm); This depends on a previous patch you sent, right? Sigh. There goes my git foo. Will resubmit an updated version. cheers, jamal

Re: [PATCH iproute2 v3 5/5] ip: add MACsec support

2016-05-23 Thread Stephen Hemminger
On Wed, 18 May 2016 17:35:13 +0200 Sabrina Dubroca wrote: > + > +static void print_rx_sc(const char *prefix, __u64 sci, __u8 active, struct > rtattr *rxsc_stats, struct rtattr *sa) > +{ Overall, this looks fine, but could you break some of the really long lines. In general, I like iproute2 to f

Re: [iproute2 PATCH 1/1] tc fix ife late binding

2016-05-23 Thread Stephen Hemminger
On Sun, 22 May 2016 13:11:16 -0400 Jamal Hadi Salim wrote: > From: Jamal Hadi Salim > > following late binding didn't work > > sudo tc actions add action ife encode \ > type 0xDEAD allow mark dst 02:15:15:15:15:15 index 1 > > Signed-off-by: Jamal Hadi Salim Applied

Re: [PATCH iproute2 -master] f_bpf: fix filling of handle when no further arg is provided

2016-05-23 Thread Stephen Hemminger
On Wed, 18 May 2016 11:58:41 +0200 Daniel Borkmann wrote: > We need to fill handle when provided by the user, even if no further > argument is provided. Thus, move the test for arg to the correct location, > so that it works correctly: > > # tc filter show dev foo egress > filter protocol al

Re: [PATCH iproute2] ipaddress: needs to include

2016-05-23 Thread Stephen Hemminger
On Thu, 19 May 2016 14:29:46 -0300 Gustavo Zacarias wrote: > It's using MIN() now, otherwise it breaks for musl libc. > > Signed-off-by: Gustavo Zacarias Makes sense. Applied

Re: [PATCH iproute2 v3 1/5] add missing if_macsec.h header from kernel

2016-05-23 Thread Stephen Hemminger
On Wed, 18 May 2016 17:35:09 +0200 Sabrina Dubroca wrote: > Signed-off-by: Sabrina Dubroca > Acked-by: Phil Sutter This header already exists in master branch of iproute2, with current version from upstream kernel (with PAD values).

[RFC PATCH 6/7] tcp6: Support for TOU

2016-05-23 Thread Tom Herbert
Need to adjust MSS to account for encapsulation overhead. This is done by add encpasulation header length into icsk_ext_hdr_len. Signed-off-by: Tom Herbert --- net/ipv6/tcp_ipv6.c | 11 ++- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/net/ipv6/tcp_ipv6.c b/net/ipv6/tcp_i

[RFC PATCH 5/7] ipv6: Support TOU

2016-05-23 Thread Tom Herbert
In transmit path (inet6_csk_xmit) check if encapsulation is enabled and call the build header op if it is. Add IP_TOU_ENCAP setsockopt for IPv6 sockets. Signed-off-by: Tom Herbert --- include/uapi/linux/in6.h | 1 + net/ipv6/inet6_connection_sock.c | 56 +

[RFC PATCH 3/7] ipv4: Support TOU

2016-05-23 Thread Tom Herbert
Add tou_encap structure to inet_sock. In transmit path (ip_queue_xmit) check if encapsulation is enabled and call the build header op if it is. Add IP_TOU_ENCAP setsockopt for IPv4 sockets. Signed-off-by: Tom Herbert --- include/net/inet_sock.h | 1 + include/uapi/linux/in.h | 1 + net/ipv4/ip

[RFC PATCH 4/7] tcp: Support for TOU

2016-05-23 Thread Tom Herbert
Need to adjust MSS to account for encapsulation overhead. This is done by add encpasulation header length into icsk_ext_hdr_len. Signed-off-by: Tom Herbert --- net/ipv4/tcp_ipv4.c | 9 + 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/net/ipv4/tcp_ipv4.c b/net/ipv4/tcp_ipv4

[RFC PATCH 0/7] tou: Transports over UDP - part I

2016-05-23 Thread Tom Herbert
Transports over UDP is intended to encapsulate TCP and other transport protocols directly and securely in UDP. The goal of this work is twofold: 1) Allow applications to run their own transport layer stack (i.e.from userspace). This eliminates dependencies on the OS (e.g. solves a major dep

[RFC PATCH 2/7] tou: Base infrastructure for Transport over UDP

2016-05-23 Thread Tom Herbert
Add tou.c that implements common setsockopt functionality. This includes initialization and argument structure for the setsockopt. Signed-off-by: Tom Herbert --- include/uapi/linux/if_tunnel.h | 10 net/ipv4/Makefile | 3 +- net/ipv4/af_inet.c | 4 ++ net/ipv4/

[RFC PATCH 7/7] tou: Support for GSO

2016-05-23 Thread Tom Herbert
Add SKB_GSO_TOU. In udp[64]_ufo_fragment check for SKB_GSO_TOU. If this is set call skb_udp_tou_segment. skb_udp_tou_segment is very similar to skb_udp_tunnel_segment except that we only need to deal with the L4 headers. Signed-off-by: Tom Herbert --- include/linux/skbuff.h | 2 + in

[RFC PATCH 1/7] fou: Get net from sock_net if dev_net unavailable

2016-05-23 Thread Tom Herbert
With the implementation of Transports over UDP fou and gue build header may be called before skb->dev is set. This patch checks skb->dev and if it is not set then tries to get net from sock_net. Signed-off-by: Tom Herbert --- net/ipv4/fou.c | 22 ++ 1 file changed, 18 inserti

[PATCH iproute2 -master] ip, token: add del command

2016-05-23 Thread Daniel Borkmann
For convenience also add a del command for deleting a token and update the man page accordingly. Signed-off-by: Daniel Borkmann --- ip/iptoken.c| 26 ++ man/man8/ip-token.8 | 13 +++-- 2 files changed, 25 insertions(+), 14 deletions(-) diff --git a/ip/ipt

Re: [iproute2 PATCH v2 1/1] tc simple action update and breakage

2016-05-23 Thread Daniel Borkmann
On 05/08/2016 05:02 PM, Jamal Hadi Salim wrote: From: Jamal Hadi Salim Brings it closer to more serious actions (adding branching and allowing for late binding) Unfortunately this breaks old syntax of the simple action. But because simple is a pedagogical example unlikely to be used in product

Re: bpf: use-after-free in array_map_alloc

2016-05-23 Thread Alexei Starovoitov
On Mon, May 23, 2016 at 05:35:01PM -0400, Tejun Heo wrote: > Hello, > > Can you please test whether this patch resolves the issue? While > adding support for atomic allocations, I reduced alloc_mutex covered > region too much. after the patch the use-after-free is no longer seen. Tested-by: Alex

Re: [PATCH net-next 0/5] hv_netvsc: cleanup after untangling the pointer mess

2016-05-23 Thread David Miller
From: Vitaly Kuznetsov Date: Mon, 23 May 2016 17:50:33 +0200 > After we made traveling through our internal structures explicit it became > obvious that some functions take arguments they don't need just to do > redundant pointer travel and get to what they really need while their > callers alrea

Re: [patch] qed: signedness bug in qed_dcbx_process_tlv()

2016-05-23 Thread David Miller
From: Dan Carpenter Date: Mon, 23 May 2016 13:19:35 +0300 > "priority" needs to be signed for the error handling to work. > > Fixes: 39651abd2814 ('qed: add support for dcbx.') > Signed-off-by: Dan Carpenter Applied.

Re: [PATCH net-next 0/4] qed/qede support for dcbnl.

2016-05-23 Thread David Miller
From: Sudarsana Reddy Kalluru Date: Mon, 23 May 2016 05:17:39 -0400 > This series adds the dcbnl functionality to the driver. Patch (1) fixes a > coding issue in earlier submission. Patch (2) adds the qed infrastucture > for querying/configuring the dcbx parameters. Patch (3) adds the qed > infra

Re: [PATCH net] bpf, inode: disallow userns mounts

2016-05-23 Thread David Miller
From: Daniel Borkmann Date: Sun, 22 May 2016 23:16:18 +0200 > Follow-up to commit e27f4a942a0e ("bpf: Use mount_nodev not mount_ns > to mount the bpf filesystem"), which removes the FS_USERNS_MOUNT flag. > > The original idea was to have a per mountns instance instead of a > single global fs ins

Re: [PATCH 32/54] MAINTAINERS: Add file patterns for net device tree bindings

2016-05-23 Thread David Miller
From: Geert Uytterhoeven Date: Sun, 22 May 2016 11:06:09 +0200 > Submitters of device tree binding documentation may forget to CC > the subsystem maintainer if this is missing. > > Signed-off-by: Geert Uytterhoeven Applied.

Re: [PATCH] net/tipc: fix potential null pointer dereference in several tipc netlink compat functions

2016-05-23 Thread David Miller
From: Baozeng Ding Date: Sun, 22 May 2016 00:22:48 +0800 > @@ -916,10 +970,16 @@ static int tipc_nl_compat_sk_dump(struct > tipc_nl_compat_msg *msg, > static int tipc_nl_compat_media_dump(struct tipc_nl_compat_msg *msg, > struct nlattr **attrs) > { > +int err; > s

Re: __napi_alloc_skb failures locking up the box

2016-05-23 Thread Aaro Koskinen
Hi, On Sat, Apr 30, 2016 at 12:54:12PM -0700, Eric Dumazet wrote: > On Sat, 2016-04-30 at 22:24 +0300, Aaro Koskinen wrote: > > Hi, > > > > I have old NAS box (Thecus N2100) with 512 MB RAM, where rsync from NFS -> > > disk reliably results in temporary out-of-memory conditions. > > > > When thi

Re: bpf: use-after-free in array_map_alloc

2016-05-23 Thread Tejun Heo
Hello, Can you please test whether this patch resolves the issue? While adding support for atomic allocations, I reduced alloc_mutex covered region too much. Thanks. diff --git a/mm/percpu.c b/mm/percpu.c index 0c59684..bd2df70 100644 --- a/mm/percpu.c +++ b/mm/percpu.c @@ -162,7 +162,7 @@ stat

Re: [PATCH] ipv4: Fix non-initialized TTL when CONFIG_SYSCTL=n

2016-05-23 Thread David Miller
From: Ezequiel Garcia Date: Fri, 20 May 2016 13:21:10 -0300 > Commit fa50d974d104 ("ipv4: Namespaceify ip_default_ttl sysctl knob") > moves the default TTL assignment, and as side-effect IPv4 TTL now > has a default value only if sysctl support is enabled (CONFIG_SYSCTL=y). > > The sysctl_ip_def

Re: [PATCH] Added NLM_F_EXCL support to fib_nl_newrule

2016-05-23 Thread David Miller
From: Mateusz Bajorski Date: Fri, 20 May 2016 17:58:23 +0200 Please format your Subject line properly, it should be of the form: [PATCH] $SUBSYSTEM: Description. In this case "fib_fules: " would be an appropriate subsystem specification. > diff --git a/net/core/fib_rules.c b/net/core/

[PATCH net] net_sched: avoid too many hrtimer_start() calls

2016-05-23 Thread Eric Dumazet
From: Eric Dumazet I found a serious performance bug in packet schedulers using hrtimers. sch_htb and sch_fq are definitely impacted by this problem. We constantly rearm high resolution timers if some packets are throttled in one (or more) class, and other packets are flying through qdisc on an

Re: [PATCH net v2] fou: avoid using sk_user_data before it is initialised

2016-05-23 Thread Cong Wang
On Mon, May 23, 2016 at 1:59 PM, David Miller wrote: > From: Simon Horman > Date: Fri, 20 May 2016 14:57:17 +0900 > >> During initialisation sk->sk_user_data should not be used before >> it is initialised. >> >> Found by bisection after noticing the following: > ... >> Fixes: d92283e338f6 ("fou:

Re: [PATCH] wan: cosa: use memdup_user().

2016-05-23 Thread David Miller
From: Muhammad Falak R Wani Date: Fri, 20 May 2016 17:50:06 +0530 > Use memdup_user to duplicate a memory region from user-space to > kernel-space, instead of open coding using kmalloc & copy_from_user. > > Signed-off-by: Muhammad Falak R Wani > --- > drivers/net/wan/cosa.c | 11 +++ >

Re: [PATCH] ptp: use memdup_user().

2016-05-23 Thread David Miller
From: Muhammad Falak R Wani Date: Fri, 20 May 2016 17:51:02 +0530 > Use memdup_user to duplicate a memory region from user-space to > kernel-space, instead of open coding using kmalloc & copy_from_user. > > Signed-off-by: Muhammad Falak R Wani Applied.

Re: [PATCH net-next v2 0/7] Driver: Vmxnet3: Version 3

2016-05-23 Thread David Miller
From: Shrikrishna Khare Date: Thu, 19 May 2016 23:53:05 -0700 > This patchset upgrades Vmxnet3 to Version 3. net-next is closed, therefore is it inappropriate to submit new features at this time. Thank you.

Re: [PATCH net v2] fou: avoid using sk_user_data before it is initialised

2016-05-23 Thread David Miller
From: Simon Horman Date: Fri, 20 May 2016 14:57:17 +0900 > During initialisation sk->sk_user_data should not be used before > it is initialised. > > Found by bisection after noticing the following: ... > Fixes: d92283e338f6 ("fou: change to use UDP socket GRO") > Signed-off-by: Simon Horman >

Re: [PATCH v2 1/1] net: hns: avoid null pointer dereference

2016-05-23 Thread David Miller
From: Heinrich Schuchardt Date: Thu, 19 May 2016 21:20:55 +0200 > In the statement > assert(priv || priv->ae_handle); > the right side of || is only evaluated if priv is null. > > v2: > As suggested by David Leight and David Miller the assert > statements are removed. > > Signed-o

Re: [PATCH net-next] tools: hv: Add a script for bonding synthetic and VF NICs

2016-05-23 Thread David Miller
From: Haiyang Zhang Date: Thu, 19 May 2016 10:23:38 -0700 > This example script creates bonding network devices based on synthetic NIC > (the virtual network adapter usually provided by Hyper-V) and the matching > VF NIC (SRIOV virtual function). So the synthetic NIC and VF NIC can > function as

Re: [PATCH v5 2/2] skb_array: ring test

2016-05-23 Thread Michael S. Tsirkin
On Mon, May 23, 2016 at 03:09:18PM +0200, Jesper Dangaard Brouer wrote: > On Mon, 23 May 2016 13:43:46 +0300 > "Michael S. Tsirkin" wrote: > > > Add ringtest based unit test for skb array. > > > > Signed-off-by: Michael S. Tsirkin > > --- > > tools/virtio/ringtest/skb_array.c | 167 > > +++

Re: [net PATCH 1/1] net sched actions: policer missing timestamp processing

2016-05-23 Thread Cong Wang
On Sun, May 22, 2016 at 9:43 AM, Jamal Hadi Salim wrote: > @@ -340,6 +345,11 @@ tcf_act_police_dump(struct sk_buff *skb, struct > tc_action *a, int bind, int ref) > if (police->tcfp_ewma_rate && > nla_put_u32(skb, TCA_POLICE_AVRATE, police->tcfp_ewma_rate)) > g

Re: [PATCH] net/atm: sk_err_soft must be positive

2016-05-23 Thread David Miller
From: Stefan Hajnoczi Date: Wed, 18 May 2016 17:42:13 -0700 > The sk_err and sk_err_soft fields are positive errno values and > userspace applications rely on this when using getsockopt(SO_ERROR). > > ATM code places an -errno into sk_err_soft in sigd_send() and returns it > from svc_addparty()/

Re: [PATCH 1/1] net: pegasus: simplify logical constraint

2016-05-23 Thread David Miller
From: Heinrich Schuchardt Date: Wed, 18 May 2016 20:40:51 +0200 > If !count is true, count < 4 is also true. > > Signed-off-by: Heinrich Schuchardt Applied.

Re: [PATCH v5 0/2] skb_array: array based FIFO for skbs

2016-05-23 Thread Michael S. Tsirkin
On Mon, May 23, 2016 at 06:31:46AM -0700, Eric Dumazet wrote: > On Mon, 2016-05-23 at 13:43 +0300, Michael S. Tsirkin wrote: > > This is in response to the proposal by Jason to make tun > > rx packet queue lockless using a circular buffer. > > My testing seems to show that at least for the common u

pktgen issue with "Observe needed_headroom of the device"

2016-05-23 Thread Ben Greear
Regarding this commit: 879c7220e828af8bd82ea9d774c7e45c46b976e4 net: pktgen: Observe needed_headroom of the device Allocate enough space so as not to force the outgoing net device to do skb_realloc_headroom(). Signed-off-by: Bogdan Hamciuc Signed-off-by: David S. Miller I t

[RFC 12/12] 6lowpan: add support for 802.15.4 short addr handling

2016-05-23 Thread Alexander Aring
This patch adds necessary handling for use the short address for 802.15.4 6lowpan. It contains support for IPHC address compression and new matching algorithmn to decide which link layer address will be used for 802.15.4 frame. Reviewed-by: Stefan Schmidt Signed-off-by: Alexander Aring --- net/

[RFC 05/12] ndisc: get rid off dev parameter in ndisc_opt_addr_data

2016-05-23 Thread Alexander Aring
This patch removes the net_device parameter from ndisc_opt_addr_data function. This can be useful for calling such functionality which doesn't depends on dev parameter. For current existing functionality which depends on dev parameter, we introduce ndisc_dev_opt_addr_data to have an easy replacemen

[RFC 02/12] 6lowpan: add 802.15.4 short addr slaac

2016-05-23 Thread Alexander Aring
This patch adds the autoconfiguration if a valid 802.15.4 short address is available for 802.15.4 6LoWPAN interfaces. Cc: David S. Miller Cc: Alexey Kuznetsov Cc: James Morris Cc: Hideaki YOSHIFUJI Cc: Patrick McHardy Acked-by: Hannes Frederic Sowa Reviewed-by: Stefan Schmidt Signed-off-by:

[RFC 01/12] 6lowpan: add private neighbour data

2016-05-23 Thread Alexander Aring
This patch will introduce a 6lowpan neighbour private data. Like the interface private data we handle private data for generic 6lowpan and for link-layer specific 6lowpan. The current first use case if to save the short address for a 802.15.4 6lowpan neighbour. Cc: David S. Miller Reviewed-by: S

[RFC 03/12] 6lowpan: remove ipv6 module request

2016-05-23 Thread Alexander Aring
Since we use exported function from ipv6 kernel module we don't need to request the module anymore to have ipv6 functionality. Acked-by: Hannes Frederic Sowa Reviewed-by: Stefan Schmidt Signed-off-by: Alexander Aring --- net/6lowpan/core.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/n

[RFC 00/12] 6lowpan: introduce 6lowpan-nd

2016-05-23 Thread Alexander Aring
Hi, this patch series introduces the ndisc ops callback structure to add different handling for IPv6 neighbour discovery cache functionality. It implements at first the two following use-cases: - 6CO handling as userspace option (For all 6LoWPAN layers, BTLE/802.15.4) [0] - short address handl

[RFC 07/12] addrconf: put prefix address add in an own function

2016-05-23 Thread Alexander Aring
This patch moves the functionality to add a RA PIO prefix generated address in an own function. This move prepares to add a hook for adding a second address for a second link-layer address. E.g. short address for 802.15.4 6LoWPAN. Cc: David S. Miller Cc: Alexey Kuznetsov Cc: James Morris Cc: Hi

[RFC 04/12] ndisc: get rid off dev parameter in ndisc_opt_addr_space

2016-05-23 Thread Alexander Aring
This patch removes the net_device parameter from ndisc_opt_addr_space function. This can be useful for calling such functionality which doesn't depends on dev parameter. For current existing functionality which depends on dev parameter, we introduce ndisc_dev_opt_addr_space to have an easy replacem

[RFC 09/12] ipv6: export several functions

2016-05-23 Thread Alexander Aring
This patch exports some neighbour discovery functions which can be used by 6lowpan neighbour discovery ops functionality then. Cc: David S. Miller Cc: Alexey Kuznetsov Cc: James Morris Cc: Hideaki YOSHIFUJI Cc: Patrick McHardy Signed-off-by: Alexander Aring --- include/net/addrconf.h | 7 +

[RFC 08/12] ipv6: introduce neighbour discovery ops

2016-05-23 Thread Alexander Aring
This patch introduces neighbour discovery ops callback structure. The idea is to separate the handling for 6LoWPAN into the 6lowpan module. These callback offers 6lowpan different handling, such as 802.15.4 short address handling or RFC6775 (Neighbor Discovery Optimization for IPv6 over 6LoWPANs).

[RFC 11/12] 6lowpan: add support for getting short address

2016-05-23 Thread Alexander Aring
In case of sending RA messages we need some way to get the short address from an 802.15.4 6LoWPAN interface. This patch will add a temporary debugfs entry for experimental userspace api. Signed-off-by: Alexander Aring --- net/6lowpan/debugfs.c | 35 +++ 1 file cha

[RFC 10/12] 6lowpan: introduce 6lowpan-nd

2016-05-23 Thread Alexander Aring
This patch introduce different 6lowpan handling for receive and transmit NS/NA messages for the ipv6 neighbour discovery. The first use-case is for supporting 802.15.4 short addresses inside the option fields and handling for RFC6775 6CO option field as userspace option. Cc: David S. Miller Cc: A

[RFC 06/12] ndisc: get rid off dev parameter in ndisc_fill_addr_option

2016-05-23 Thread Alexander Aring
This patch removes the net_device parameter from ndisc_fill_addr_option function. This can be useful for calling such functionality which doesn't depends on dev parameter. For current existing functionality which depends on dev parameter, we introduce ndisc_dev_fill_addr_option to have an easy repl

Re: IPv6 extension header privileges

2016-05-23 Thread Tom Herbert
On Sun, May 22, 2016 at 4:56 AM, Sowmini Varadhan wrote: > >> > Tom Herbert wrote: >> > If you don't mind I'll change this to make specific options are >> > privileged and not all hbh and destopt. There is talk in IETF about >> > reinventing IP extensibility within UDP since the kernel

[PATCH net-next 0/5] hv_netvsc: cleanup after untangling the pointer mess

2016-05-23 Thread Vitaly Kuznetsov
After we made traveling through our internal structures explicit it became obvious that some functions take arguments they don't need just to do redundant pointer travel and get to what they really need while their callers already have the required information. This is just a cleanup series with n

[PATCH net-next 2/5] hv_netvsc: introduce {net,hv}_device_to_netvsc_device() helpers

2016-05-23 Thread Vitaly Kuznetsov
Make it easier to get 'struct netvsc_device' from 'struct net_device' and 'struct hv_device' by introducing inline helpers. Signed-off-by: Vitaly Kuznetsov --- drivers/net/hyperv/hyperv_net.h | 12 drivers/net/hyperv/netvsc.c | 11 +++ drivers/net/hyperv/rndis_filter

[PATCH net-next 1/5] hv_netvsc: remove redundant assignment in netvsc_recv_callback()

2016-05-23 Thread Vitaly Kuznetsov
net_device_ctx is assigned in the very beginning of the function and 'net' pointer doesn't change. Signed-off-by: Vitaly Kuznetsov --- drivers/net/hyperv/netvsc_drv.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/net/hyperv/netvsc_drv.c b/drivers/net/hyperv/netvsc_drv.c index 6a69b5

[PATCH net-next 3/5] hv_netvsc: pass struct netvsc_device to rndis_filter_{open,close}()

2016-05-23 Thread Vitaly Kuznetsov
Both rndis_filter_open()/rndis_filter_close() use struct hv_device to reach to struct netvsc_device only and all callers have it already. While on it, rename net_device to nvdev in rndis_filter_open() as net_device is misleading. Signed-off-by: Vitaly Kuznetsov --- drivers/net/hyperv/hyperv_net.

[PATCH net-next 5/5] hv_netvsc: pass struct net_device to rndis_filter_set_offload_params()

2016-05-23 Thread Vitaly Kuznetsov
The only caller rndis_filter_device_add() has 'struct net_device' pointer already. Signed-off-by: Vitaly Kuznetsov --- drivers/net/hyperv/rndis_filter.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/net/hyperv/rndis_filter.c b/drivers/net/hyperv/rndis_filter.c

[PATCH net-next 4/5] hv_netvsc: pass struct net_device to rndis_filter_set_device_mac()

2016-05-23 Thread Vitaly Kuznetsov
We unpack 'struct net_device' in netvsc_set_mac_addr() to get to 'struct hv_device' pointer which we use in rndis_filter_set_device_mac() to get back to 'struct net_device'. Signed-off-by: Vitaly Kuznetsov --- drivers/net/hyperv/hyperv_net.h | 2 +- drivers/net/hyperv/netvsc_drv.c | 4 +---

Re: [PATCH 0/2 (linux-stable-4.5.y)] net: stmmac: MDIO fixes

2016-05-23 Thread Greg KH
On Mon, May 23, 2016 at 03:17:41PM +0200, Giuseppe Cavallaro wrote: > These patches port some recent fixes for linux-4.5.y stable branch. > They fix the MDIO settings trying to cover the all possible scenario > when the stmmac is connected to a real transceiver or a switch. > > These patches are n

Re: [PATCH v5 0/2] skb_array: array based FIFO for skbs

2016-05-23 Thread Eric Dumazet
On Mon, 2016-05-23 at 13:43 +0300, Michael S. Tsirkin wrote: > This is in response to the proposal by Jason to make tun > rx packet queue lockless using a circular buffer. > My testing seems to show that at least for the common usecase > in networking, which isn't lockless, circular buffer > with i

Re: 4.5.0 on sun7i-a20-olinuxino-lime2: libphy: PHY stmmac-0:ffffffff not found (regression from rc7)

2016-05-23 Thread Giuseppe CAVALLARO
Hello On 5/22/2016 11:30 AM, Marc Zyngier wrote: On Sat, 21 May 2016 17:47:05 +0200 Bert Lindner wrote: Hi, On 2016-05-20 12:36, Marc Zyngier wrote: On 20/05/16 11:30, Andre Heider wrote: Hi, On Fri, May 20, 2016 at 10:14 AM, Giuseppe CAVALLARO wrote: On 5/20/2016 9:56 AM, Marc Zyngier

[PATCH 1/2 (linux-stable-4.5.y)] Revert "stmmac: Fix 'eth0: No PHY found' regression"

2016-05-23 Thread Giuseppe Cavallaro
From: Giuseppe CAVALLARO This reverts commit 88f8b1bb41c6208f81b6a480244533ded7b59493. due to problems on GeekBox and Banana Pi M1 board when connected to a real transceiver instead of a switch via fixed-link. Signed-off-by: Giuseppe Cavallaro Cc: Gabriel Fernandez Cc: Andreas Färber Cc: Fran

[PATCH 2/2 (linux-stable-4.5.y)] stmmac: fix MDIO settings

2016-05-23 Thread Giuseppe Cavallaro
Initially the phy_bus_name was added to manipulate the driver name but it was recently just used to manage the fixed-link and then to take some decision at run-time. So the patch uses the is_pseudo_fixed_link and removes the phy_bus_name variable not necessary anymore. The driver can manage the md

[PATCH 0/2 (linux-stable-4.5.y)] net: stmmac: MDIO fixes

2016-05-23 Thread Giuseppe Cavallaro
These patches port some recent fixes for linux-4.5.y stable branch. They fix the MDIO settings trying to cover the all possible scenario when the stmmac is connected to a real transceiver or a switch. These patches are needed for Kernel 4.5 where Lime2, BananaPi and Cubieboard2 show problems when

Re: [PATCH v5 2/2] skb_array: ring test

2016-05-23 Thread Jesper Dangaard Brouer
On Mon, 23 May 2016 13:43:46 +0300 "Michael S. Tsirkin" wrote: > Add ringtest based unit test for skb array. > > Signed-off-by: Michael S. Tsirkin > --- > tools/virtio/ringtest/skb_array.c | 167 > ++ > tools/virtio/ringtest/Makefile| 4 +- Patch didn'

Re: bpf: use-after-free in array_map_alloc

2016-05-23 Thread Vlastimil Babka
On 05/23/2016 02:01 PM, Vlastimil Babka wrote: >> if I read the report correctly it's not about bpf, but rather points to >> the issue inside percpu logic. >> First __alloc_percpu_gfp() is called, then the memory is freed with >> free_percpu() which triggers async pcpu_balance_work and then >> pcpu

Re: [RFC] NET: PHY: adds driver for Lantiq PHY11G

2016-05-23 Thread Andrew Lunn
> +static int lantiq_gphy_config_init(struct phy_device *phydev) > +{ > + int err; > + > + /* Mask all interrupts */ > + err = phy_write(phydev, MII_VR9_11G_IMASK, 0); > + if (err) > + return err; > + > + /* Clear all pending interrupts */ > + phy_read(phydev, MI

Re: bpf: use-after-free in array_map_alloc

2016-05-23 Thread Vlastimil Babka
[+CC Christoph, linux-mm] On 04/17/2016 07:29 PM, Alexei Starovoitov wrote: > On Sun, Apr 17, 2016 at 12:58:21PM -0400, Sasha Levin wrote: >> Hi all, >> >> I've hit the following while fuzzing with syzkaller inside a KVM tools guest >> running the latest -next kernel: > > thanks for the report. A

Re: [RFC] NET: PHY: adds driver for Lantiq PHY11G

2016-05-23 Thread Andrew Lunn
> > I doubt the device tree maintainers will accept this. You don't normally put > > register values in device tree. > > Me too ;-) > > I will look into this: > http://lists.openwall.net/netdev/2016/03/23/61 and also try to make > the device tree interface more generic. Please take more notice

RE: [patch] qed: signedness bug in qed_dcbx_process_tlv()

2016-05-23 Thread Sudarsana Kalluru
Thanks, Dan. Acked-by: Sudarsana Reddy Kalluru -Original Message- From: Dan Carpenter [mailto:dan.carpen...@oracle.com] Sent: 23 May 2016 15:50 To: Yuval Mintz ; Sudarsana Kalluru Cc: Ariel Elior ; Dept-Eng Everest Linux L2 ; netdev ; kernel-janit...@vger.kernel.org Subject: [patch]

Re: [PATCH v2] ethernet:arc: Fix racing of TX ring buffer

2016-05-23 Thread Shuyu Wei
On Sun, May 22, 2016 at 01:30:27PM +0200, Lino Sanfilippo wrote: > > Thanks for testing. However that extra check for skb not being NULL should > not be > necessary if the code were correct. The changes I suggested were all about > having > skb and info consistent with txbd_curr. > But I just re

RE: drivers/net/ethernet/qlogic/qed/qed_dcbx.c:210: pointless test ?

2016-05-23 Thread Yuval Mintz
> Hello there, > > drivers/net/ethernet/qlogic/qed/qed_dcbx.c:210:16: warning: comparison is > always false due to limited range of data type [-Wtype-limits] > > Source code is > >if (priority < 0) { > > but > > u8 tc, priority, priority_map; > > > Regards > > David Binderman H

Re: Missing INET6_PROTO_FINAL in l2tp_ip6_protocol?

2016-05-23 Thread Shmulik Ladkani
Hi, On Mon, 23 May 2016 13:05:50 +0200, han...@stressinduktion.org wrote: > > However, one more thing WRT to INET6_PROTO_FINAL not being set - we're > > also missing the multicast filtering of 'ip6_input_finish': > > > > if (ipv6_addr_is_multicast(&hdr->daddr) && > >

drivers/net/ethernet/qlogic/qed/qed_dcbx.c:210: pointless test ?

2016-05-23 Thread David Binderman
Hello there, drivers/net/ethernet/qlogic/qed/qed_dcbx.c:210:16: warning: comparison is always false due to limited range of data type [-Wtype-limits] Source code is if (priority < 0) { but u8 tc, priority, priority_map; Regards David Binderman

Re: Missing INET6_PROTO_FINAL in l2tp_ip6_protocol?

2016-05-23 Thread Hannes Frederic Sowa
On 21.05.2016 22:02, Shmulik Ladkani wrote: > On Sat, 21 May 2016 17:55:59 +0200 Hannes Frederic Sowa > wrote: >> On 21.05.2016 14:50, Shmulik Ladkani wrote: >>> Hi, >>> >>> inet6_protocol's INET6_PROTO_FINAL flag denotes handler is expected not >>> to request resubmission for local delivery. >>>

[PATCH v5 2/2] skb_array: ring test

2016-05-23 Thread Michael S. Tsirkin
Add ringtest based unit test for skb array. Signed-off-by: Michael S. Tsirkin --- tools/virtio/ringtest/skb_array.c | 167 ++ tools/virtio/ringtest/Makefile| 4 +- 2 files changed, 170 insertions(+), 1 deletion(-) create mode 100644 tools/virtio/ringtes

[PATCH v5 0/2] skb_array: array based FIFO for skbs

2016-05-23 Thread Michael S. Tsirkin
This is in response to the proposal by Jason to make tun rx packet queue lockless using a circular buffer. My testing seems to show that at least for the common usecase in networking, which isn't lockless, circular buffer with indices does not perform that well, because each index access causes a c

[PATCH v5 1/2] skb_array: array based FIFO for skbs

2016-05-23 Thread Michael S. Tsirkin
A simple array based FIFO of pointers. Intended for net stack so uses skbs for type safety, but we can replace with with void * if others find it useful outside of net stack. Signed-off-by: Michael S. Tsirkin --- include/linux/skb_array.h | 127 ++ 1

[patch] qed: signedness bug in qed_dcbx_process_tlv()

2016-05-23 Thread Dan Carpenter
"priority" needs to be signed for the error handling to work. Fixes: 39651abd2814 ('qed: add support for dcbx.') Signed-off-by: Dan Carpenter --- Applies to the main net tree. diff --git a/drivers/net/ethernet/qlogic/qed/qed_dcbx.c b/drivers/net/ethernet/qlogic/qed/qed_dcbx.c index cbf58e1..a06

Re: [PATCH 1/1 RFC] net/phy: Add Lantiq PHY driver

2016-05-23 Thread Mathias Kresin
2016-05-23 11:49 GMT+02:00 Alexander Stein : >> The registers are set to some reset values after the chip is coming out of >> reset, but we should set them all to the same value, Mathias said that all >> except for one board he knows are using only one LED per port, but they are >> often using di

[PATCH net-next 3/4] qed: Add dcbnl support.

2016-05-23 Thread Sudarsana Reddy Kalluru
This patch adds the implementation for both cee/ieee dcbnl callbacks by using the qed query/config APIs. Signed-off-by: Sudarsana Reddy Kalluru Signed-off-by: Yuval Mintz --- drivers/net/ethernet/qlogic/qed/qed_dcbx.c | 1090 drivers/net/ethernet/qlogic/qed/qed_l2.c

  1   2   >