Re: [PATCH 0/5] Taprio qdisc fixes

2019-04-20 Thread David Miller
From: Andre Guedes Date: Fri, 19 Apr 2019 17:00:47 -0700 > This series contains some minor improvements (patches 1 and 2) and > fixes (patches 3-5) to taprio qdisc. This series does not apply cleanly at all to the net tree.

Re: [PATCH net] net/tls: don't leak IV and record seq when offload fails

2019-04-20 Thread David Miller
From: Jakub Kicinski Date: Fri, 19 Apr 2019 16:52:19 -0700 > When device refuses the offload in tls_set_device_offload_rx() > it calls tls_sw_free_resources_rx() to clean up software context > state. > > Unfortunately, tls_sw_free_resources_rx() does not free all > the state tls_set_sw_offload()

Re: [PATCH net] net/tls: avoid potential deadlock in tls_set_device_offload_rx()

2019-04-20 Thread David Miller
From: Jakub Kicinski Date: Fri, 19 Apr 2019 16:51:38 -0700 > If device supports offload, but offload fails tls_set_device_offload_rx() > will call tls_sw_free_resources_rx() which (unhelpfully) releases > and reacquires the socket lock. > > For a small fix release and reacquire the device_offloa

[PATCH 7/7] net: strparser: make it explicitly non-modular

2019-04-20 Thread Paul Gortmaker
The Kconfig currently controlling compilation of this code is: net/strparser/Kconfig:config STREAM_PARSER net/strparser/Kconfig: def_bool n ...meaning that it currently is not being built as a module by anyone. Lets remove the modular code that is essentially orphaned, so that when reading the

[PATCH 6/7] net: bpfilter: dont use module_init in non-modular code

2019-04-20 Thread Paul Gortmaker
The Kconfig controlling this code is: bpfilter/Kconfig:menuconfig BPFILTER bpfilter/Kconfig: bool "BPF based packet filtering framework (BPFILTER)" Since it isn't a module, we shouldn't use module_init(). Instead we use device_initcall() - which is exactly what module_init() defaults to for no

[PATCH 5/7] cgroup: net: remove left over MODULE_LICENSE tag

2019-04-20 Thread Paul Gortmaker
The Kconfig currently controlling compilation of this code is: net/Kconfig:config CGROUP_NET_PRIO net/Kconfig:bool "Network priority cgroup" ...meaning that it currently is not being built as a module by anyone, as module support was discontinued in 2014. We delete the MODULE_LICENSE tag sin

[PATCH -next 0/7] clean up needless use of module infrastructure

2019-04-20 Thread Paul Gortmaker
People can embed modular includes and modular exit functions into code that never use any of it, and they won't get any errors or warnings. Using modular infrastructure in non-modules might seem harmless, but some of the downfalls this leads to are: (1) it is easy to accidentally write unused mo

[PATCH 2/7] net: ife: drop include of module.h from net/ife.h

2019-04-20 Thread Paul Gortmaker
Ideally, header files under include/linux shouldn't be adding includes of other headers, in anticipation of their consumers, but just the headers needed for the header itself to pass parsing with CPP. The module.h is particularly bad in this sense, as it itself does include a whole bunch of other

[PATCH 3/7] net: fib: drop include of module.h from fib_notifier.h

2019-04-20 Thread Paul Gortmaker
Ideally, header files under include/linux shouldn't be adding includes of other headers, in anticipation of their consumers, but just the headers needed for the header itself to pass parsing with CPP. The module.h is particularly bad in this sense, as it itself does include a whole bunch of other

[PATCH 4/7] net: tc_act: drop include of module.h from tc_ife.h

2019-04-20 Thread Paul Gortmaker
Ideally, header files under include/linux shouldn't be adding includes of other headers, in anticipation of their consumers, but just the headers needed for the header itself to pass parsing with CPP. The module.h is particularly bad in this sense, as it itself does include a whole bunch of other

[PATCH 1/7] net: psample: drop include of module.h from psample.h

2019-04-20 Thread Paul Gortmaker
Ideally, header files under include/linux shouldn't be adding includes of other headers, in anticipation of their consumers, but just the headers needed for the header itself to pass parsing with CPP. The module.h is particularly bad in this sense, as it itself does include a whole bunch of other

Re: [PATCH iproute2-next v2] ip fou: Support binding FOU ports

2019-04-20 Thread David Ahern
On 4/18/19 6:19 AM, Kristian Evensen wrote: > @@ -77,6 +84,38 @@ static int fou_parse_opt(int argc, char **argv, struct > nlmsghdr *n, > gue_set = true; > } else if (!matches(*argv, "-6")) { > family = AF_INET6; > + } else if (!

[net-next:master 254/261] net//core/sock.c:3007:23: error: expected '}' before ';' token

2019-04-20 Thread kbuild test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next.git master head: 5313794b7915f61d1f503bfa54fbec47ffd8be0b commit: c7cbdbf29f488a19982cd9f4a109887f18028bbb [254/261] net: rework SIOCGSTAMP ioctl handling config: sparc-allmodconfig (attached as .config) compiler: sparc64-li

[PATCH iproute2-next] Update tc-bpf.8 man page examples

2019-04-20 Thread Lucas Siba
From: Lucas Siba @ 2019-04-20 11:40 UTC To: netdev This patch updates the tc-bpf.8 example application for changes to the struct bpf_elf_map definition. In it's current form, things compile, but the resulting object file is rejected by the verifier when attempting to load it through tc. Signed-of

[PATCH net-next] ipv6: Remove fib6_info_nh_lwt

2019-04-20 Thread David Ahern
From: David Ahern fib6_info_nh_lwt is no longer used; remove it. Signed-off-by: David Ahern --- include/net/ip6_fib.h | 6 -- 1 file changed, 6 deletions(-) diff --git a/include/net/ip6_fib.h b/include/net/ip6_fib.h index 6b7557b71c8c..352f767bea81 100644 --- a/include/net/ip6_fib.h +++ b

[PATCH net-next] net: Rename net/nexthop.h net/rtnh.h

2019-04-20 Thread David Ahern
From: David Ahern The header contains rtnh_ macros so rename the file accordingly. Allows a later patch to use the nexthop.h name for the new nexthop code. Signed-off-by: David Ahern --- include/net/{nexthop.h => rtnh.h} | 4 ++-- net/core/lwtunnel.c | 2 +- net/decnet/dn_fib.c

[PATCH] include/net/tcp.h: whitespace cleanup at tcp_v4_check

2019-04-20 Thread Daniel T. Lee
This patch makes trivial whitespace fix to the function tcp_v4_check at include/net/tcp.h file. It has stylistic issue, which is "space required after that ','" and it can be confirmed with ./scripts/checkpatch.pl tool. ERROR: space required after that ',' (ctx:VxV) #29: FILE: include/net

[PATCH bpf 1/2] bpf: mark registers as safe or unknown in all frames

2019-04-20 Thread Paul Chaignon
In case of a null check on a pointer inside a subprog, we should mark all registers with this pointer as either safe or unknown, in both the current and previous frames. Currently, only spilled registers and registers in the current frame are marked. This patch also marks registers in previous fr

[PATCH bpf 2/2] selftests/bpf: test case for pointer null check in subprog

2019-04-20 Thread Paul Chaignon
This test case is equivalent to the following pseudo-code. It checks that the verifier does not complain on line 6 and recognizes that ptr isn't null. 1: ptr = bpf_map_lookup_elem(map, &key); 2: ret = subprog(ptr) { 3: return ptr != NULL; 4: } 5: if (ret) 6: value = *ptr; Signed-off-by: Paul

[PATCH bpf 0/2] bpf: mark registers as safe or unknown in all frames

2019-04-20 Thread Paul Chaignon
In case of a null check on a pointer inside a subprog, we should mark all registers with this pointer as either safe or unknown, in both the current and previous frames. Currently, only spilled registers and registers in the current frame are marked. This first patch also marks registers in previ

[PATCH iproute2-next] iplink_vlan: add support for VLAN bridge binding flag

2019-04-20 Thread Mike Manning
This patch adds support for the VLAN bridge binding flag that is provided in net-next kernel by the series merged by 1ab839281cf7 ("net-support-binding-vlan-dev-link-state-to-vlan-member-bridge-ports") Signed-off-by: Mike Manning --- include/uapi/linux/if_vlan.h | 9 + ip/iplink_vlan.c

[patch net-next v2 07/16] netdevsim: use ida for bus device ids

2019-04-20 Thread Jiri Pirko
From: Jiri Pirko Instead of increments of u32 value, use ida to manage bus device ids. Signed-off-by: Jiri Pirko --- drivers/net/netdevsim/bus.c | 13 ++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/drivers/net/netdevsim/bus.c b/drivers/net/netdevsim/bus.c index 5b

[patch net-next v2 12/16] netdevsim: change debugfs tree topology

2019-04-20 Thread Jiri Pirko
From: Jiri Pirko With the model where dev is represented by devlink and ports are represented by devlink ports, make debugfs file names independent on netdev names. Change the topology to the one illustrated by the following example: $ ls /sys/kernel/debug/netdevsim/ netdevsim1 $ ls /sys/kernel/

[patch net-next v2 06/16] netdevsim: add stub netdevsim driver implementation

2019-04-20 Thread Jiri Pirko
From: Jiri Pirko In order to bus probing to work correctly, register a simple netdevsim driver implementation. Signed-off-by: Jiri Pirko --- drivers/net/netdevsim/bus.c | 21 - 1 file changed, 20 insertions(+), 1 deletion(-) diff --git a/drivers/net/netdevsim/bus.c b/driv

[patch net-next v2 11/16] netdevsim: generate random switch id instead of using dev id

2019-04-20 Thread Jiri Pirko
From: Jiri Pirko Current implementation of parent_id/switch_id does not follow the original idea of being unique. The values are "0", "1", etc. Instead of that, generate 32 random bytes. Signed-off-by: Jiri Pirko --- drivers/net/netdevsim/dev.c | 3 +++ drivers/net/netdevsim/netdev.c

[patch net-next v2 03/16] netdevsim: rename devlink.c to dev.c to contain per-dev(asic) items

2019-04-20 Thread Jiri Pirko
From: Jiri Pirko The existing devlink.c code is going to be extended to represent asic device on a bus. As this is about more than just devlink, rename the file. Do appropriate prefix renaming alongside with that. Signed-off-by: Jiri Pirko --- rfc->v1: - remove the trailing "\" from the makefil

[patch net-next v2 09/16] netdevsim: rename dev_init/exit() functions and make them independent on ns

2019-04-20 Thread Jiri Pirko
From: Jiri Pirko These functions are going to be called from bus probe/release(), therefore make them independent on ns struct and rename accordingly. Signed-off-by: Jiri Pirko --- drivers/net/netdevsim/dev.c | 31 --- drivers/net/netdevsim/netdev.c| 14 ++

[patch net-next v2 05/16] netdevsim: move device registration and related code to bus.c

2019-04-20 Thread Jiri Pirko
From: Jiri Pirko Move netdevsim device registration into bus.c and alongside with that the related sysfs attributes. Introduce new struct nsim_bus_dev to represent a netdevsim device on netdevsim bus. Signed-off-by: Jiri Pirko --- drivers/net/netdevsim/bus.c | 142 +-

[patch net-next v2 13/16] netdevsim: implement dev probe/remove skeleton with port initialization

2019-04-20 Thread Jiri Pirko
From: Jiri Pirko Implement netdevsim bus probing of netdevsim devices. For every probed device create a devlink instance. According to the user-passed value, create a number of ports represented by devlink port instances. Signed-off-by: Jiri Pirko --- v1->v2: - changed port array to port list -

[patch net-next v2 15/16] netdevsim: move netdev creation/destruction to dev probe

2019-04-20 Thread Jiri Pirko
From: Jiri Pirko Remove the existing way to create netdevsim over rtnetlink and move the netdev creation/destruction to dev probe, so for every probed port, a netdevsim-netdev instance is created. Adjust selftests to work with new interface. Signed-off-by: Jiri Pirko --- v1->v2: - rebased - us

[patch net-next v2 08/16] netdevsim: add bus attributes to add new and delete devices

2019-04-20 Thread Jiri Pirko
From: Jiri Pirko Add a way to add new netdevsim device on netdevsim bus and also to delete existing netdevsim device from the bus. Track the bus devices in using a list. Signed-off-by: Jiri Pirko --- drivers/net/netdevsim/bus.c | 97 ++- drivers/net/netdevsim/

[patch net-next v2 14/16] netdevsim: extend device attrs to support port addition and deletion

2019-04-20 Thread Jiri Pirko
From: Jiri Pirko In order to test flows in core, it is beneficial to maintain previously supported possibility to add and delete ports during netdevsim lifetime. Do it by extending device sysfs attrs by "new_port" and "del_port". Signed-off-by: Jiri Pirko --- v1->v2: - new patch --- drivers/ne

[patch net-next v2 10/16] netdevsim: merge sdev into dev

2019-04-20 Thread Jiri Pirko
From: Jiri Pirko As previously introduce dev which is mapped 1:1 to a bus device covers the purpose of the original shared device, merge the sdev code into dev. Signed-off-by: Jiri Pirko --- rfc->v1: - rebased --- drivers/net/netdevsim/Makefile | 2 +- drivers/net/netdevsim/bpf.c

[patch net-next v2 16/16] netdevsim: implement ndo_get_devlink_port

2019-04-20 Thread Jiri Pirko
From: Jiri Pirko Implement ndo_get_devlink_port and allow switch_id and port_name to be handled by devlink. Signed-off-by: Jiri Pirko --- drivers/net/netdevsim/netdev.c | 8 1 file changed, 8 insertions(+) diff --git a/drivers/net/netdevsim/netdev.c b/drivers/net/netdevsim/netdev.c i

[patch net-next v2 00/16] netdevsim: impement proper device model

2019-04-20 Thread Jiri Pirko
From: Jiri Pirko Currently the model of netdevsim is a bit odd in multiple ways. 1) devlink instance is not in any way related with actual netdevsim netdevices. Instead, it is created per-namespace. 2) multi-port netdevsim device is done using "link" attribute. 3) netdevsim bus is there only t

[patch net-next v2 01/16] netdevsim: move device registration on bus to be done earlier in init

2019-04-20 Thread Jiri Pirko
From: Jiri Pirko As a dependency of the subsequent patch, mode device registration to be done earlier, directly in nsim_newlink(). Signed-off-by: Jiri Pirko --- drivers/net/netdevsim/netdev.c | 26 +- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/drive

[patch net-next v2 04/16] netdevsim: put netdevsim bus code into separate file

2019-04-20 Thread Jiri Pirko
From: Jiri Pirko As the code related to netdevsim bus is going to get bigger, move the existing code to a separate file. Signed-off-by: Jiri Pirko --- rfc->v1: - rebased --- drivers/net/netdevsim/Makefile| 2 +- drivers/net/netdevsim/bus.c | 24 drivers/net/

[patch net-next v2 02/16] netdevsim: create devlink instance per netdevsim instance

2019-04-20 Thread Jiri Pirko
From: Jiri Pirko Currently there is one devlink instance created per network namespace. That is quite odd considering the fact that devlink instance should represent an ASIC. The following patches are going to move the devlink instance even more down to a bus device, but until then, have one devl

Re: [PATCH v4 net-next 3/6] exthdrs: Registration of TLV handlers and parameters

2019-04-20 Thread kbuild test robot
Hi Tom, Thank you for the patch! Yet something to improve: [auto build test ERROR on net-next/master] url: https://github.com/0day-ci/linux/commits/Tom-Herbert/exthdrs-Make-ext-headers-options-useful-Part-I/20190419-170926 config: mips-allmodconfig (attached as .config) compiler: mips-linux-