Re: Question on DSA switches, IGMP forwarding and switchdev

2020-06-19 Thread Daniel Mack
On 6/20/20 12:36 AM, Andrew Lunn wrote: >> I've run into the same issue. To resolve it, In my case, in the same file, >> I've had to send all IGMP control traffic to the CPU: >> skb->offload_fwd_mark = 1; >> switch (ih->type) { >> case IGMP_HOST_MEMBERSHIP_REPORT: >>

Re: [PATCH/RFC 1/5] dt-bindings: net: renesas,ravb: Document internal clock delay properties

2020-06-19 Thread Oleksij Rempel
Hi Geert, Am 19.06.20 um 21:15 schrieb Geert Uytterhoeven: > Some EtherAVB variants support internal clock delay configuration, which > can add larger delays than the delays that are typically supported by > the PHY (using an "rgmii-*id" PHY mode, and/or "[rt]xc-skew-ps" > properties). > > Add pro

Re: Question on DSA switches, IGMP forwarding and switchdev

2020-06-19 Thread Daniel Mack
Hi Andrew, Thanks a lot for the quick reply! On 6/19/20 11:58 PM, Andrew Lunn wrote: > On Fri, Jun 19, 2020 at 11:31:04PM +0200, Daniel Mack wrote: >> When an IGMP query enters the switch, it is redirected to the CPU port >> as all 'external' ports are configured for IGMP/MLP snooping by the >>

[PATCH v2 04/16] b43: Remove uninitialized_var() usage

2020-06-19 Thread Kees Cook
Using uninitialized_var() is dangerous as it papers over real bugs[1] (or can in the future), and suppresses unrelated compiler warnings (e.g. "unused variable"). If the compiler thinks it is uninitialized, either simply initialize the variable or make compiler changes. As a precursor to removing[2

[PATCH v2 06/16] ide: Remove uninitialized_var() usage

2020-06-19 Thread Kees Cook
Using uninitialized_var() is dangerous as it papers over real bugs[1] (or can in the future), and suppresses unrelated compiler warnings (e.g. "unused variable"). If the compiler thinks it is uninitialized, either simply initialize the variable or make compiler changes. As a precursor to removing[2

[PATCH v2 03/16] drbd: Remove uninitialized_var() usage

2020-06-19 Thread Kees Cook
Using uninitialized_var() is dangerous as it papers over real bugs[1] (or can in the future), and suppresses unrelated compiler warnings (e.g. "unused variable"). If the compiler thinks it is uninitialized, either simply initialize the variable or make compiler changes. As a precursor to removing[2

[PATCH v2 05/16] rtlwifi: rtl8192cu: Remove uninitialized_var() usage

2020-06-19 Thread Kees Cook
Using uninitialized_var() is dangerous as it papers over real bugs[1] (or can in the future), and suppresses unrelated compiler warnings (e.g. "unused variable"). If the compiler thinks it is uninitialized, either simply initialize the variable or make compiler changes. As a precursor to removing[2

[PATCH v2 02/16] x86/mm/numa: Remove uninitialized_var() usage

2020-06-19 Thread Kees Cook
Using uninitialized_var() is dangerous as it papers over real bugs[1] (or can in the future), and suppresses unrelated compiler warnings (e.g. "unused variable"). If the compiler thinks it is uninitialized, either simply initialize the variable or make compiler changes. As a precursor to removing[2

[PATCH v2 10/16] KVM: PPC: Book3S PR: Remove uninitialized_var() usage

2020-06-19 Thread Kees Cook
Using uninitialized_var() is dangerous as it papers over real bugs[1] (or can in the future), and suppresses unrelated compiler warnings (e.g. "unused variable"). If the compiler thinks it is uninitialized, either simply initialize the variable or make compiler changes. As a precursor to removing[2

[PATCH v2 01/16] docs: deprecated.rst: Add uninitialized_var()

2020-06-19 Thread Kees Cook
Nothing should be using this macro, and the entire idea of tricking the compiler into silencing such warnings is a mistake. Signed-off-by: Kees Cook --- Documentation/process/deprecated.rst | 18 ++ 1 file changed, 18 insertions(+) diff --git a/Documentation/process/deprecated.r

[PATCH v2 12/16] f2fs: Eliminate usage of uninitialized_var() macro

2020-06-19 Thread Kees Cook
From: Jason Yan This is an effort to eliminate the uninitialized_var() macro[1]. The use of this macro is the wrong solution because it forces off ANY analysis by the compiler for a given variable. It even masks "unused variable" warnings. Quoted from Linus[2]: "It's a horrible thing to use, i

[PATCH v2 07/16] clk: st: Remove uninitialized_var() usage

2020-06-19 Thread Kees Cook
Using uninitialized_var() is dangerous as it papers over real bugs[1] (or can in the future), and suppresses unrelated compiler warnings (e.g. "unused variable"). If the compiler thinks it is uninitialized, either simply initialize the variable or make compiler changes. As a precursor to removing[2

[PATCH v2 11/16] media: sur40: Remove uninitialized_var() usage

2020-06-19 Thread Kees Cook
Using uninitialized_var() is dangerous as it papers over real bugs[1] (or can in the future), and suppresses unrelated compiler warnings (e.g. "unused variable"). If the compiler thinks it is uninitialized, either simply initialize the variable or make compiler changes. As a precursor to removing[2

[PATCH v2 14/16] checkpatch: Remove awareness of uninitialized_var() macro

2020-06-19 Thread Kees Cook
Using uninitialized_var() is dangerous as it papers over real bugs[1] (or can in the future), and suppresses unrelated compiler warnings (e.g. "unused variable"). If the compiler thinks it is uninitialized, either simply initialize the variable or make compiler changes. In preparation for removing

[PATCH v2 16/16] compiler: Remove uninitialized_var() macro

2020-06-19 Thread Kees Cook
Using uninitialized_var() is dangerous as it papers over real bugs[1] (or can in the future), and suppresses unrelated compiler warnings (e.g. "unused variable"). If the compiler thinks it is uninitialized, either simply initialize the variable or make compiler changes. As recommended[2] by[3] Lin

[PATCH v2 15/16] treewide: Remove uninitialized_var() usage

2020-06-19 Thread Kees Cook
Using uninitialized_var() is dangerous as it papers over real bugs[1] (or can in the future), and suppresses unrelated compiler warnings (e.g. "unused variable"). If the compiler thinks it is uninitialized, either simply initialize the variable or make compiler changes. I preparation for removing[

[PATCH v2 13/16] mm/debug_vm_pgtable: Remove uninitialized_var() usage

2020-06-19 Thread Kees Cook
Using uninitialized_var() is dangerous as it papers over real bugs[1] (or can in the future), and suppresses unrelated compiler warnings (e.g. "unused variable"). If the compiler thinks it is uninitialized, either simply initialize the variable or make compiler changes. As a precursor to removing[2

Re: [Patch net] cgroup: fix cgroup_sk_alloc() for sk_clone_lock()

2020-06-19 Thread Cong Wang
On Fri, Jun 19, 2020 at 5:51 PM Zefan Li wrote: > > 在 2020/6/20 8:45, Zefan Li 写道: > > On 2020/6/20 3:51, Cong Wang wrote: > >> On Thu, Jun 18, 2020 at 11:40 PM Zefan Li wrote: > >>> > >>> On 2020/6/19 5:09, Cong Wang wrote: > On Thu, Jun 18, 2020 at 12:36 PM Roman Gushchin wrote: > > >

[PATCH v2 09/16] clk: spear: Remove uninitialized_var() usage

2020-06-19 Thread Kees Cook
Using uninitialized_var() is dangerous as it papers over real bugs[1] (or can in the future), and suppresses unrelated compiler warnings (e.g. "unused variable"). If the compiler thinks it is uninitialized, either simply initialize the variable or make compiler changes. As a precursor to removing[2

[PATCH v2 00/16] Remove uninitialized_var() macro

2020-06-19 Thread Kees Cook
v2: - more special-cased fixes - add reviews v1: https://lore.kernel.org/lkml/20200603233203.1695403-1-keesc...@chromium.org Using uninitialized_var() is dangerous as it papers over real bugs[1] (or can in the future), and suppresses unrelated compiler warnings (e.g. "unused variable"). If the com

[PATCH v2 08/16] spi: davinci: Remove uninitialized_var() usage

2020-06-19 Thread Kees Cook
Using uninitialized_var() is dangerous as it papers over real bugs[1] (or can in the future), and suppresses unrelated compiler warnings (e.g. "unused variable"). If the compiler thinks it is uninitialized, either simply initialize the variable or make compiler changes. As a precursor to removing[2

Re: [PATCH net v2] selftests/net: report etf errors correctly

2020-06-19 Thread David Miller
From: Willem de Bruijn Date: Thu, 18 Jun 2020 12:40:43 -0400 > From: Willem de Bruijn > > The ETF qdisc can queue skbs that it could not pace on the errqueue. > > Address a few issues in the selftest > > - recv buffer size was too small, and incorrectly calculated > - compared errno to ee_cod

Re: [PATCH net] ibmveth: Fix max MTU limit

2020-06-19 Thread David Miller
From: Thomas Falcon Date: Thu, 18 Jun 2020 10:43:46 -0500 > The max MTU limit defined for ibmveth is not accounting for > virtual ethernet buffer overhead, which is twenty-two additional > bytes set aside for the ethernet header and eight additional bytes > of an opaque handle reserved for use by

Re: [PATCH net-next 2/4] net: mvpp2: add mvpp2_phylink_to_port() helper

2020-06-19 Thread David Miller
From: Russell King Date: Thu, 18 Jun 2020 16:38:51 +0100 > diff --git a/drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c > b/drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c > index 7653277d03b7..8c8314715efd 100644 > --- a/drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c > +++ b/drivers/net/ethern

Re: [PATCH][next] net/sched: cls_u32: Use struct_size() in kzalloc()

2020-06-19 Thread David Miller
From: "Gustavo A. R. Silva" Date: Thu, 18 Jun 2020 09:53:42 -0500 > Make use of the struct_size() helper instead of an open-coded version > in order to avoid any potential type mistakes. > > This code was detected with the help of Coccinelle and, audited and > fixed manually. > > Signed-off-by:

Re: [PATCH][next] taprio: Use struct_size() in kzalloc()

2020-06-19 Thread David Miller
From: "Gustavo A. R. Silva" Date: Thu, 18 Jun 2020 09:46:48 -0500 > Make use of the struct_size() helper instead of an open-coded version > in order to avoid any potential type mistakes. Also, remove unnecessary > variable _size_. > > This code was detected with the help of Coccinelle and, audit

Re: [PATCH 0/9] Clause 45 PHY probing improvements

2020-06-19 Thread David Miller
From: Russell King - ARM Linux admin Date: Thu, 18 Jun 2020 14:45:00 +0100 > Last time this series was posted back in May, Florian reviewed the > patches, which was the only feedback I received. I'm now posting > them without the RFC tag. > > This series aims to improve the probing for Clause 4

Re: [PATCH][next] tipc: Use struct_size() helper

2020-06-19 Thread David Miller
From: "Gustavo A. R. Silva" Date: Thu, 18 Jun 2020 08:35:00 -0500 > Make use of the struct_size() helper instead of an open-coded version > in order to avoid any potential type mistakes. > > This code was detected with the help of Coccinelle and, audited and > fixed manually. > > Signed-off-by:

Re: [PATCH -next] macvlan: Fix memleak in macvlan_changelink_sources

2020-06-19 Thread David Miller
From: Zheng Bin Date: Thu, 18 Jun 2020 21:26:29 +0800 > macvlan_changelink_sources > if (addr) > ret = macvlan_hash_add_source(vlan, addr) > nla_for_each_attr(nla, head, len, rem) > ret = macvlan_hash_add_source(vlan, addr) > -->If fail, need to free previous malloc memory > > Fi

Re: [PATCH net v5 0/4] several fixes for indirect flow_blocks offload

2020-06-19 Thread David Miller
From: we...@ucloud.cn Date: Thu, 18 Jun 2020 20:49:07 +0800 > From: wenxu > > v2: > patch2: store the cb_priv of representor to the flow_block_cb->indr.cb_priv > in the driver. And make the correct check with the statments > this->indr.cb_priv == cb_priv > > patch4: del the driver list only in

Re: [PATCH net] geneve: allow changing DF behavior after creation

2020-06-19 Thread David Miller
From: Sabrina Dubroca Date: Thu, 18 Jun 2020 12:13:22 +0200 > Currently, trying to change the DF parameter of a geneve device does > nothing: > > # ip -d link show geneve1 > 14: geneve1: > link/ether > geneve id 1 remote 10.0.0.1 ttl auto df set dstport 6081 > # ip

Re: [PATCH net] enetc: Fix HW_VLAN_CTAG_TX|RX toggling

2020-06-19 Thread David Miller
From: Claudiu Manoil Date: Thu, 18 Jun 2020 12:16:52 +0300 > VLAN tag insertion/extraction offload is correctly > activated at probe time but deactivation of this feature > (i.e. via ethtool) is broken. Toggling works only for > Tx/Rx ring 0 of a PF, and is ignored for the other rings, > includi

Re: [Patch net] cgroup: fix cgroup_sk_alloc() for sk_clone_lock()

2020-06-19 Thread Cong Wang
On Fri, Jun 19, 2020 at 6:14 PM Roman Gushchin wrote: > > On Sat, Jun 20, 2020 at 09:00:40AM +0800, Zefan Li wrote: > > I think so, though I'm not familiar with the bfp cgroup code. > > > > > If so, we might wanna fix it in a different way, > > > just checking if (!(css->flags & CSS_NO_REF)) in cg

Re: [PATCH v2] net: macb: undo operations in case of failure

2020-06-19 Thread David Miller
From: Claudiu Beznea Date: Thu, 18 Jun 2020 11:37:40 +0300 > Undo previously done operation in case macb_phylink_connect() > fails. Since macb_reset_hw() is the 1st undo operation the > napi_exit label was renamed to reset_hw. > > Fixes: 7897b071ac3b ("net: macb: convert to phylink") > Signed-of

Re: [PATCH net 0/3] rxrpc: Performance drop fix and other fixes

2020-06-19 Thread David Miller
From: David Howells Date: Thu, 18 Jun 2020 08:50:15 +0100 > > Here are three fixes for rxrpc: > > (1) Fix a trace symbol mapping. It doesn't seem to let you map to "". > > (2) Fix the handling of the remote receive window size when it increases > beyond the size we can support for our

Re: [Patch net] cgroup: fix cgroup_sk_alloc() for sk_clone_lock()

2020-06-19 Thread Zefan Li
>>> If so, we might wanna fix it in a different way, >>> just checking if (!(css->flags & CSS_NO_REF)) in cgroup_bpf_put() >>> like in cgroup_put(). It feels more reliable to me. >>> >> >> Yeah I also have this idea in my mind. > > I wonder if the following patch will fix the issue? > I guess so

[PATCH resend] net: cxgb4: fix return error value in t4_prep_fw

2020-06-19 Thread Li Heng
t4_prep_fw goto bye tag with positive return value when something bad happened and which can not free resource in adap_init0. so fix it to return negative value. Fixes: 16e47624e76b ("cxgb4: Add new scheme to update T4/T5 firmware") Reported-by: Hulk Robot Signed-off-by: Li Heng Signed-off-by: J

Re: [PATCH 0/3] Add Marvell 88E1340S, 88E1548P support

2020-06-19 Thread David Miller
From: Кочетков Максим Date: Sat, 20 Jun 2020 00:31:29 +0300 > It is based on 5.7.0 You need to post your patches against the tree onto which it will be applied, which in this case is net-next.

Re: [PATCH 0/6] Add Microchip MCP25XXFD CAN driver

2020-06-19 Thread Manivannan Sadhasivam
On Thu, Jun 18, 2020 at 02:25:33PM +0530, Manivannan Sadhasivam wrote: > Hi, > > On 0611, Marc Kleine-Budde wrote: > > On 6/10/20 9:44 AM, Manivannan Sadhasivam wrote: > > > Hello, > > > > > > This series adds CAN network driver support for Microchip MCP25XXFD CAN > > > Controller with MCP2517FD

Re: [PATCH net-next 1/3] net/sched: Introduce action hash

2020-06-19 Thread Ariel Levkovich
On 6/19/20 12:13 PM, Davide Caratti wrote: hello Ariel, (I'm doing a resend because I suspect that my original reply was dropped somewhere). Thanks for your patch! some comments/questions below: On Fri, 2020-06-19 at 01:15 +0300, Ariel Levkovich wrote: Allow setting a hash value to a packet f

Re: [PATCH] mt76: mt76x2: fix pci suspend

2020-06-19 Thread kernel test robot
in https://git-scm.com/docs/git-format-patch] url: https://github.com/0day-ci/linux/commits/Lorenzo-Bianconi/mt76-mt76x2-fix-pci-suspend/20200618-192056 base: https://git.kernel.org/pub/scm/linux/kernel/git/kvalo/wireless-drivers-next.git master config: x86_64-randconfig-a013-20200619

[PATCH] net Add MODULE_DESCRIPTION entries to network modules

2020-06-19 Thread Rob Gill
The user tool modinfo is used to get information on kernel modules, including a description where it is available. This patch adds a brief MODULE_DESCRIPTION to the following modules: 9p drop_monitor esp4_offload esp6_offload fou fou6 ila sch_fq sch_fq_codel sch_hhf Signed-off-by: Rob Gill ---

Re: [PATCH v2 net-next] ipv6: icmp6: avoid indirect call for icmpv6_send()

2020-06-19 Thread kernel test robot
-next.git 0fb9fbab405351aa0c18973881c4103e4da886b6 config: nds32-randconfig-r002-20200619 (attached as .config) compiler: nds32le-linux-gcc (GCC) 9.3.0 reproduce (this is a W=1 build): wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross

Re: [PATCH v3 bpf-next 9/9] tools/bpftool: add documentation and sample output for process info

2020-06-19 Thread Quentin Monnet
2020-06-19 16:17 UTC-0700 ~ Andrii Nakryiko > Add statements about bpftool being able to discover process info, holding > reference to BPF map, prog, link, or BTF. Show example output as well. > > Signed-off-by: Andrii Nakryiko Reviewed-by: Quentin Monnet Thanks!

Re: [PATCH v3 bpf-next 8/9] tools/bpftool: show info for processes holding BPF map/prog/link/btf FDs

2020-06-19 Thread Quentin Monnet
2020-06-19 16:17 UTC-0700 ~ Andrii Nakryiko > Add bpf_iter-based way to find all the processes that hold open FDs against > BPF object (map, prog, link, btf). bpftool always attempts to discover this, > but will silently give up if kernel doesn't yet support bpf_iter BPF programs. > Process name a

Re: [Patch net] cgroup: fix cgroup_sk_alloc() for sk_clone_lock()

2020-06-19 Thread Roman Gushchin
On Sat, Jun 20, 2020 at 09:00:40AM +0800, Zefan Li wrote: > On 2020/6/20 8:51, Roman Gushchin wrote: > > On Fri, Jun 19, 2020 at 02:40:19PM +0800, Zefan Li wrote: > >> On 2020/6/19 5:09, Cong Wang wrote: > >>> On Thu, Jun 18, 2020 at 12:36 PM Roman Gushchin wrote: > > On Thu, Jun 18, 202

Re: [Patch net] cgroup: fix cgroup_sk_alloc() for sk_clone_lock()

2020-06-19 Thread Zefan Li
On 2020/6/20 8:51, Roman Gushchin wrote: > On Fri, Jun 19, 2020 at 02:40:19PM +0800, Zefan Li wrote: >> On 2020/6/19 5:09, Cong Wang wrote: >>> On Thu, Jun 18, 2020 at 12:36 PM Roman Gushchin wrote: On Thu, Jun 18, 2020 at 12:19:13PM -0700, Cong Wang wrote: > On Wed, Jun 17, 2020 at

Re: [Patch net] cgroup: fix cgroup_sk_alloc() for sk_clone_lock()

2020-06-19 Thread Zefan Li
在 2020/6/20 8:45, Zefan Li 写道: > On 2020/6/20 3:51, Cong Wang wrote: >> On Thu, Jun 18, 2020 at 11:40 PM Zefan Li wrote: >>> >>> On 2020/6/19 5:09, Cong Wang wrote: On Thu, Jun 18, 2020 at 12:36 PM Roman Gushchin wrote: > > On Thu, Jun 18, 2020 at 12:19:13PM -0700, Cong Wang wrote: >

Re: [Patch net] cgroup: fix cgroup_sk_alloc() for sk_clone_lock()

2020-06-19 Thread Roman Gushchin
On Fri, Jun 19, 2020 at 02:40:19PM +0800, Zefan Li wrote: > On 2020/6/19 5:09, Cong Wang wrote: > > On Thu, Jun 18, 2020 at 12:36 PM Roman Gushchin wrote: > >> > >> On Thu, Jun 18, 2020 at 12:19:13PM -0700, Cong Wang wrote: > >>> On Wed, Jun 17, 2020 at 6:44 PM Zefan Li wrote: > > Cc: R

Re: [Patch net] cgroup: fix cgroup_sk_alloc() for sk_clone_lock()

2020-06-19 Thread Zefan Li
On 2020/6/20 3:51, Cong Wang wrote: > On Thu, Jun 18, 2020 at 11:40 PM Zefan Li wrote: >> >> On 2020/6/19 5:09, Cong Wang wrote: >>> On Thu, Jun 18, 2020 at 12:36 PM Roman Gushchin wrote: On Thu, Jun 18, 2020 at 12:19:13PM -0700, Cong Wang wrote: > On Wed, Jun 17, 2020 at 6:44 PM Ze

Re: [PATCH v2 net-next] ipv6: icmp6: avoid indirect call for icmpv6_send()

2020-06-19 Thread kernel test robot
-next.git 0fb9fbab405351aa0c18973881c4103e4da886b6 config: riscv-randconfig-r033-20200619 (attached as .config) compiler: clang version 11.0.0 (https://github.com/llvm/llvm-project 487ca07fcc75d52755c9fe2ee05bcb3b6c44) reproduce (this is a W=1 build): wget https

[PATCH] Bluetooth: Add hci_dev_lock to get/set device flags

2020-06-19 Thread Abhishek Pandit-Subedi
Adding hci_dev_lock since hci_conn_params_(lookup|add) require this lock. Suggested-by: Miao-chen Chou Signed-off-by: Abhishek Pandit-Subedi --- net/bluetooth/mgmt.c | 8 1 file changed, 8 insertions(+) diff --git a/net/bluetooth/mgmt.c b/net/bluetooth/mgmt.c index 2a732cab1dc99d..5e

Re: [PATCH 06/12] xen-blkfront: add callbacks for PM suspend and hibernation]

2020-06-19 Thread Anchal Agarwal
On Wed, Jun 17, 2020 at 10:35:28AM +0200, Roger Pau Monné wrote: > CAUTION: This email originated from outside of the organization. Do not click > links or open attachments unless you can confirm the sender and know the > content is safe. > > > > On Tue, Jun 16, 2020 at 09:49:25PM +, Ancha

Re: [PATCH bpf-next 1/2] bpf: switch most helper return values from 32-bit int to 64-bit long

2020-06-19 Thread Andrii Nakryiko
On Fri, Jun 19, 2020 at 3:21 PM Daniel Borkmann wrote: > > On 6/19/20 8:41 PM, Andrii Nakryiko wrote: > > On Fri, Jun 19, 2020 at 6:08 AM Daniel Borkmann > > wrote: > >> On 6/19/20 2:39 AM, John Fastabend wrote: > >>> John Fastabend wrote: > Andrii Nakryiko wrote: > > On Thu, Jun 18, 20

[PATCH bpf] libbpf: fix CO-RE relocs against .text section

2020-06-19 Thread Andrii Nakryiko
bpf_object__find_program_by_title(), used by CO-RE relocation code, doesn't return .text "BPF program", if it is a function storage for sub-programs. Because of that, any CO-RE relocation in helper non-inlined functions will fail. Fix this by searching for .text-corresponding BPF program manually.

[PATCH v2 bpf-next 7/8] samples/bpf: xdp_redirect_cpu: load a eBPF program on cpumap

2020-06-19 Thread Lorenzo Bianconi
Extend xdp_redirect_cpu_{usr,kern}.c adding the possibility to load a XDP program on cpumap entries. The following options have been added: - mprog-name: cpumap entry program name - mprog-filename: cpumap entry program filename - redirect-device: output interface if the cpumap program performs a

[PATCH v2 bpf-next 6/8] libbpf: add SEC name for xdp programs attached to CPUMAP

2020-06-19 Thread Lorenzo Bianconi
As for DEVMAP, support SEC("xdp_cpumap*") as a short cut for loading the program with type BPF_PROG_TYPE_XDP and expected attach type BPF_XDP_CPUMAP. Signed-off-by: Lorenzo Bianconi --- tools/lib/bpf/libbpf.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tools/lib/bpf/libbpf.c b/tools/li

[PATCH v2 bpf-next 5/8] bpf: cpumap: implement XDP_REDIRECT for eBPF programs attached to map entries

2020-06-19 Thread Lorenzo Bianconi
Introduce XDP_REDIRECT support for eBPF programs attached to cpumap entries. This patch has been tested on Marvell ESPRESSObin using a modified version of xdp_redirect_cpu sample in order to attach a XDP program to CPUMAP entries to perform a redirect on the mvneta interface. In particular the foll

[PATCH v2 bpf-next 8/8] selftest: add tests for XDP programs in CPUMAP entries

2020-06-19 Thread Lorenzo Bianconi
Similar to what have been done for DEVMAP, introduce tests to verify ability to add a XDP program to an entry in a CPUMAP. Verify CPUMAP programs can not be attached to devices as a normal XDP program, and only programs with BPF_XDP_CPUMAP attach type can be loaded in a CPUMAP. Signed-off-by: Lore

[net-next,v1,1/5] l3mdev: add infrastructure for table to VRF mapping

2020-06-19 Thread Andrea Mayer
Add infrastructure to l3mdev (the core code for Layer 3 master devices) in order to find out the corresponding VRF device for a given table id. Therefore, the l3mdev implementations: - can register a callback that returns the device index of the l3mdev associated with a given table id; - can o

[PATCH v2 bpf-next 1/8] net: Refactor xdp_convert_buff_to_frame

2020-06-19 Thread Lorenzo Bianconi
From: David Ahern Move the guts of xdp_convert_buff_to_frame to a new helper, xdp_update_frame_from_buff so it can be reused removing code duplication Suggested-by: Jesper Dangaard Brouer Co-developed-by: Lorenzo Bianconi Signed-off-by: Lorenzo Bianconi Signed-off-by: David Ahern --- includ

[net-next,v1,2/5] vrf: track associations between VRF devices and tables

2020-06-19 Thread Andrea Mayer
Add the data structures and the processing logic to keep track of the associations between VRF devices and routing tables. When a VRF is instantiated, it needs to refer to a given routing table. For each table, we explicitly keep track of the existing VRFs that refer to the table. Signed-off-by: A

[net-next,v1,5/5] selftests: add selftest for the VRF strict mode

2020-06-19 Thread Andrea Mayer
The new strict mode functionality is tested in different configurations and on different network namespaces. Signed-off-by: Andrea Mayer --- .../selftests/net/vrf_strict_mode_test.sh | 390 ++ 1 file changed, 390 insertions(+) create mode 100755 tools/testing/selftests/net/v

[net-next,v1,4/5] vrf: add l3mdev registration for table to VRF device lookup

2020-06-19 Thread Andrea Mayer
During the initialization phase of the VRF module, the callback for table to VRF device lookup is registered in l3mdev. Signed-off-by: Andrea Mayer --- drivers/net/vrf.c | 59 +++ 1 file changed, 55 insertions(+), 4 deletions(-) diff --git a/drivers/n

[PATCH v2 bpf-next 3/8] cpumap: formalize map value as a named struct

2020-06-19 Thread Lorenzo Bianconi
As it has been already done for devmap, introduce 'struct bpf_cpumap_val' to formalize the expected values that can be passed in for a CPUMAP. Update cpumap code to use the struct. Signed-off-by: Lorenzo Bianconi --- include/uapi/linux/bpf.h | 9 + kernel/bpf/cpumap.c|

[PATCH v2 bpf-next 4/8] bpf: cpumap: add the possibility to attach an eBPF program to cpumap

2020-06-19 Thread Lorenzo Bianconi
Introduce the capability to attach an eBPF program to cpumap entries. The idea behind this feature is to add the possibility to define on which CPU run the eBPF program if the underlying hw does not support RSS. Current supported verdicts are XDP_DROP and XDP_PASS. This patch has been tested on Ma

[PATCH v2 bpf-next 0/8] introduce support for XDP programs in CPUMAP

2020-06-19 Thread Lorenzo Bianconi
Similar to what David Ahern proposed in [1] for DEVMAPs, introduce the capability to attach and run a XDP program to CPUMAP entries. The idea behind this feature is to add the possibility to define on which CPU run the eBPF program if the underlying hw does not support RSS. I respin patch 1/6 from

[PATCH v2 bpf-next 2/8] samples/bpf: xdp_redirect_cpu_user: do not update bpf maps in option loop

2020-06-19 Thread Lorenzo Bianconi
Do not update xdp_redirect_cpu maps running while option loop but defer it after all available options have been parsed. This is a preliminary patch to pass the program name we want to attach to the map entries as a user option Signed-off-by: Lorenzo Bianconi --- samples/bpf/xdp_redirect_cpu_use

[net-next,v1,3/5] vrf: add sysctl parameter for strict mode

2020-06-19 Thread Andrea Mayer
Add net.vrf.strict_mode sysctl parameter. When net.vrf.strict_mode=0 (default) it is possible to associate multiple VRF devices to the same table. Conversely, when net.vrf.strict_mode=1 a table can be associated to a single VRF device. When switching from net.vrf.strict_mode=0 to net.vrf.strict_m

[net-next,v1,0/5] Strict mode for VRF

2020-06-19 Thread Andrea Mayer
This patch set adds the new "strict mode" functionality to the Virtual Routing and Forwarding infrastructure (VRF). Hereafter we discuss the requirements and the main features of the "strict mode" for VRF. On VRF creation, it is necessary to specify the associated routing table used during the loo

[PATCH net] rxrpc: Fix notification call on completion of discarded calls

2020-06-19 Thread David Howells
When preallocated service calls are being discarded, they're passed to ->discard_new_call() to have the caller clean up any attached higher-layer preallocated pieces before being marked completed. However, the act of marking them completed now invokes the call's notification function - which cause

Re: Question on DSA switches, IGMP forwarding and switchdev

2020-06-19 Thread Andrew Lunn
> I've run into the same issue. To resolve it, In my case, in the same file, > I've had to send all IGMP control traffic to the CPU: > skb->offload_fwd_mark = 1; > switch (ih->type) { > case IGMP_HOST_MEMBERSHIP_REPORT: > case IGMPV2_HOST_MEMBERSHIP_REPORT:

RE: Question on DSA switches, IGMP forwarding and switchdev

2020-06-19 Thread Jason Cobham
> -Original Message- > From: netdev-ow...@vger.kernel.org [mailto:netdev- > ow...@vger.kernel.org] On Behalf Of Andrew Lunn > Sent: Friday, June 19, 2020 2:58 PM > To: Daniel Mack > Cc: netdev@vger.kernel.org; Ido Schimmel; Jiri Pirko; Ivan Vecera; Florian > Fainelli > Subject: Re: Quest

Re: [PATCH bpf-next] tools/bpftool: relicense bpftool's BPF profiler prog as dual-license GPL/BSD

2020-06-19 Thread Daniel Borkmann
On 6/20/20 12:20 AM, Andrii Nakryiko wrote: Relicense it to be compatible with the rest of bpftool files. Cc: Song Liu Suggested-by: Quentin Monnet Signed-off-by: Andrii Nakryiko Applied, thanks!

Re: net-next test error: KASAN: use-after-free Write in afs_wake_up_async_call

2020-06-19 Thread David Howells
syzbot wrote: > This crash does not have a reproducer. I cannot test it. This should do it: insmod fs/afs/kafs.ko; rmmod kafs David

Re: [PATCH bpf-next 1/2] bpf: switch most helper return values from 32-bit int to 64-bit long

2020-06-19 Thread Daniel Borkmann
On 6/19/20 8:41 PM, Andrii Nakryiko wrote: On Fri, Jun 19, 2020 at 6:08 AM Daniel Borkmann wrote: On 6/19/20 2:39 AM, John Fastabend wrote: John Fastabend wrote: Andrii Nakryiko wrote: On Thu, Jun 18, 2020 at 11:58 AM John Fastabend wrote: [...] That would be great. Self-tests do work,

[PATCH bpf-next] tools/bpftool: relicense bpftool's BPF profiler prog as dual-license GPL/BSD

2020-06-19 Thread Andrii Nakryiko
Relicense it to be compatible with the rest of bpftool files. Cc: Song Liu Suggested-by: Quentin Monnet Signed-off-by: Andrii Nakryiko --- tools/bpf/bpftool/skeleton/profiler.bpf.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/bpf/bpftool/skeleton/profiler.bpf.c

Re: [PATCH v2 bpf-next 1/9] libbpf: generalize libbpf externs support

2020-06-19 Thread Andrii Nakryiko
On Fri, Jun 19, 2020 at 2:57 PM Hao Luo wrote: > > Only two small places on this version, otherwise it looks good to me. > I can offer my reviewed-by, if need. :) > > Thanks for the patch! > > Reviewed-by: Hao Luo > > On Fri, Jun 19, 2020 at 1:34 PM Andrii Nakryiko wrote: > > > > Switch existing

Re: Re: net-next test error: KASAN: use-after-free Write in afs_wake_up_async_call

2020-06-19 Thread syzbot
> #syz test: > git://git.kernel.org/pub/scm/linux/kernel/git/dhowells/linux-fs.git > 559f5964f95ce6096ae0aa858eaee202500ab9ca This crash does not have a reproducer. I cannot test it. >

Re: net-next test error: KASAN: use-after-free Write in afs_wake_up_async_call

2020-06-19 Thread David Howells
#syz test: git://git.kernel.org/pub/scm/linux/kernel/git/dhowells/linux-fs.git 559f5964f95ce6096ae0aa858eaee202500ab9ca

Re: bpf test error: KASAN: use-after-free Write in afs_wake_up_async_call

2020-06-19 Thread David Howells
#sys dup: net-next test error: KASAN: use-after-free Write in afs_wake_up_async_call

Re: bpf-next test error: KASAN: use-after-free Write in afs_wake_up_async_call

2020-06-19 Thread David Howells
#syz dup: net-next test error: KASAN: use-after-free Write in afs_wake_up_async_call

Re: net test error: KASAN: use-after-free Write in afs_wake_up_async_call

2020-06-19 Thread David Howells
#syz dup: net-next test error: KASAN: use-after-free Write in afs_wake_up_async_call

Re: Question on DSA switches, IGMP forwarding and switchdev

2020-06-19 Thread Andrew Lunn
On Fri, Jun 19, 2020 at 11:31:04PM +0200, Daniel Mack wrote: > Hi, > > I'm working on a custom board featuring a Marvell mv88e6085 Ethernet > switch controlled by the Linux DSA driver, and I'm facing an issue with > IGMP packet flows. > > Consider two Ethernet stations, each connected to the swit

Question on DSA switches, IGMP forwarding and switchdev

2020-06-19 Thread Daniel Mack
Hi, I'm working on a custom board featuring a Marvell mv88e6085 Ethernet switch controlled by the Linux DSA driver, and I'm facing an issue with IGMP packet flows. Consider two Ethernet stations, each connected to the switch on a dedicated port. A Linux bridge combines the two ports. In my setup,

Re: [PATCH net v2 0/2] net: phy: MDIO bus scanning fixes

2020-06-19 Thread David Miller
From: Florian Fainelli Date: Fri, 19 Jun 2020 11:47:45 -0700 > This patch series fixes two problems with the current MDIO bus scanning > logic which was identified while moving from 4.9 to 5.4 on devices that > do rely on scanning the MDIO bus at runtime because they use pluggable > cards. > > C

Re: [PATCH][next] net: dsa: sja1105: Use struct_size() in kzalloc()

2020-06-19 Thread David Miller
From: "Gustavo A. R. Silva" Date: Fri, 19 Jun 2020 13:10:07 -0500 > Make use of the struct_size() helper instead of an open-coded version > in order to avoid any potential type mistakes. > > This code was detected with the help of Coccinelle and, audited and > fixed manually. > > Addresses-KSPP

Re: [PATCH][next] cxgb4: Use struct_size() helper

2020-06-19 Thread David Miller
From: "Gustavo A. R. Silva" Date: Fri, 19 Jun 2020 13:01:49 -0500 > Make use of the struct_size() helper instead of an open-coded version > in order to avoid any potential type mistakes. > > This code was detected with the help of Coccinelle and, audited and > fixed manually. > > Addresses-KSPP

Re: [PATCH][next] net: stmmac: selftests: Use struct_size() in kzalloc()

2020-06-19 Thread David Miller
From: "Gustavo A. R. Silva" Date: Fri, 19 Jun 2020 12:41:54 -0500 > Make use of the struct_size() helper instead of an open-coded version > in order to avoid any potential type mistakes. > > This code was detected with the help of Coccinelle and, audited and > fixed manually. > > Addresses-KSPP

Re: [PATCH][next] ethernet: ti: am65-cpsw-qos: Use struct_size() in devm_kzalloc()

2020-06-19 Thread David Miller
From: "Gustavo A. R. Silva" Date: Fri, 19 Jun 2020 12:37:15 -0500 > Make use of the struct_size() helper instead of an open-coded version > in order to avoid any potential type mistakes. Also, remove unnecessary > variable _size_. > > This code was detected with the help of Coccinelle and, audit

Re: [PATCH net-next] ipv6: icmp6: avoid indirect call for icmpv6_send()

2020-06-19 Thread David Miller
From: Eric Dumazet Date: Fri, 19 Jun 2020 10:27:48 -0700 > If IPv6 is builtin, we do not need an expensive indirect call > to reach cmp6_send(). ^ 'icmp6_send', I fixed this up for you. > > Signed-off-by: Eric Dumazet Applied, thanks.

Re: [PATCH 0/3] Add Marvell 88E1340S, 88E1548P support

2020-06-19 Thread David Miller
From: Andrew Lunn Date: Fri, 19 Jun 2020 16:58:02 +0200 > On Fri, Jun 19, 2020 at 11:49:01AM +0300, Maxim Kochetkov wrote: >> This patch series add new PHY id support. >> Russell King asked to use single style for referencing functions. > > Hi Maxim > > In future, please put which tree this pat

Re: [PATCH net-next 0/5] cxgb4: add support for ethtool n-tuple filters

2020-06-19 Thread David Miller
From: Vishal Kulkarni Date: Fri, 19 Jun 2020 19:51:34 +0530 > Patch 1: Adds data structure to maintain list of filters and handles > init/dinit >of the same. > > Patch 2: Handles addition of filters via ETHTOOL_SRXCLSRLINS. > > Patch 3: Handles deletion of filtes via ETHTOOL_SRXCLSRLDE

Re: [PATCH 1/2] docs: net: ieee802154: change link to new project URL

2020-06-19 Thread Stefan Schmidt
Hello. On 19.06.20 21:56, David Miller wrote: From: Stefan Schmidt Date: Fri, 19 Jun 2020 09:14:22 +0200 I see you marked both patches here as awaiting upstream in patchwork. I am not really sure what to do best now. Am I supposed to pick them up myself and send them in my usual ieee802154 pu

pull-request: ieee802154 for net 2020-06-19

2020-06-19 Thread Stefan Schmidt
Hello Dave. An update from ieee802154 for your *net* tree. Just two small maintenance fixes to update references to the new project homepage. regards Stefan Schmidt The following changes since commit 0ad6f6e767ec2f613418cbc7ebe5ec4c35af540c: net: increment xmit_recursion level in dev_direct

Re: [PATCH net-next 0/3] cls_flower: Offload unmasked key

2020-06-19 Thread David Miller
You are giving no context on what hardware and with what driver your changes make a difference for. This kind of context and information is required in order for anyone to understand your changes. We're not accepting these changes until you explain all of this. Thank you.

Re: [PATCH 1/1] net: ethernet: neterion: vxge: fix spelling mistake

2020-06-19 Thread David Miller
From: Flavio Suligoi Date: Fri, 19 Jun 2020 11:02:04 +0200 > Fix typo: "trigered" --> "triggered" > > Signed-off-by: Flavio Suligoi Applied.

Re: [PATCH 1/1] net: ethernet: oki-semi: pch_gbe: fix spelling mistake

2020-06-19 Thread David Miller
From: Flavio Suligoi Date: Fri, 19 Jun 2020 11:18:11 +0200 > Fix typo: "Triger" --> "Trigger" > > Signed-off-by: Flavio Suligoi Applied.

Re: pull request (net): ipsec 2020-06-19

2020-06-19 Thread David Miller
From: Steffen Klassert Date: Fri, 19 Jun 2020 09:43:37 +0200 > 1) Fix double ESP trailer insertion in IPsec crypto offload if >netif_xmit_frozen_or_stopped is true. From Huy Nguyen. > > 2) Merge fixup for "remove output_finish indirection from >xfrm_state_afinfo". From Stephen Rothwell.

Re: [PATCH 1/2] docs: net: ieee802154: change link to new project URL

2020-06-19 Thread David Miller
From: Stefan Schmidt Date: Fri, 19 Jun 2020 09:14:22 +0200 > I see you marked both patches here as awaiting upstream in > patchwork. I am not really sure what to do best now. Am I supposed to > pick them up myself and send them in my usual ieee802154 pull request? > > Before you had been picking

  1   2   3   >