[PATCH net-next v4 1/3] flow_offload: move tc indirect block to flow offload

2019-07-27 Thread wenxu
From: wenxu move tc indirect block to flow_offload and rename it to flow indirect block.The nf_tables can use the indr block architecture. Signed-off-by: wenxu --- v3: subsys_initcall for init_flow_indr_rhashtable v4: no change drivers/net/ethernet/mellanox/mlx5/core/en_rep.c | 10 +- .../

[PATCH net-next v4 0/3] flow_offload: add indr-block in nf_table_offload

2019-07-27 Thread wenxu
From: wenxu This series patch make nftables offload support the vlan and tunnel device offload through indr-block architecture. The first patch mv tc indr block to flow offload and rename to flow-indr-block. Because the new flow-indr-block can't get the tcf_block directly. The second patch provi

[PATCH net-next v4 2/3] flow_offload: Support get default block from tc immediately

2019-07-27 Thread wenxu
From: wenxu When thre indr device register, it can get the default block from tc immediately if the block is exist. Signed-off-by: wenxu --- v3: no change v4: get tc default block without callback include/net/pkt_cls.h | 7 +++ net/core/flow_offload.c | 2 ++ net/sched/cls_api.c |

[PATCH net-next v4 3/3] netfilter: nf_tables_offload: support indr block call

2019-07-27 Thread wenxu
From: wenxu nftable support indr-block call. It makes nftable an offload vlan and tunnel device. nft add table netdev firewall nft add chain netdev firewall aclout { type filter hook ingress offload device mlx_pf0vf0 priority - 300 \; } nft add rule netdev firewall aclout ip daddr 10.0.0.1 fwd

Re: [PATCH v3 bpf-next 0/9] Revamp test_progs as a test running framework

2019-07-27 Thread Alexei Starovoitov
On Sat, Jul 27, 2019 at 8:25 PM Andrii Nakryiko wrote: > > This patch set makes a number of changes to test_progs selftest, which is > a collection of many other tests (and sometimes sub-tests as well), to provide > better testing experience and allow to start convering many individual test > prog

[PATCH v3 bpf-next 0/9] Revamp test_progs as a test running framework

2019-07-27 Thread Andrii Nakryiko
This patch set makes a number of changes to test_progs selftest, which is a collection of many other tests (and sometimes sub-tests as well), to provide better testing experience and allow to start convering many individual test programs under selftests/bpf into a single and convenient test runner.

[PATCH v3 bpf-next 5/9] selftest/bpf: centralize libbpf logging management for test_progs

2019-07-27 Thread Andrii Nakryiko
Make test_progs test runner own libbpf logging. Also introduce two levels of verbosity: -v and -vv. First one will be used in subsequent patches to enable test log output always. Second one increases verbosity level of libbpf logging further to include debug output as well. Signed-off-by: Andrii N

[PATCH v3 bpf-next 6/9] selftests/bpf: abstract away test log output

2019-07-27 Thread Andrii Nakryiko
This patch changes how test output is printed out. By default, if test had no errors, the only output will be a single line with test number, name, and verdict at the end, e.g.: #31 xdp:OK If test had any errors, all log output captured during test execution will be output after test completes.

[PATCH v3 bpf-next 2/9] selftests/bpf: revamp test_progs to allow more control

2019-07-27 Thread Andrii Nakryiko
Refactor test_progs to allow better control on what's being run. Also use argp to do argument parsing, so that it's easier to keep adding more options. Signed-off-by: Andrii Nakryiko --- tools/testing/selftests/bpf/Makefile | 8 +-- tools/testing/selftests/bpf/test_progs.c | 84

[PATCH v3 bpf-next 1/9] selftests/bpf: prevent headers to be compiled as C code

2019-07-27 Thread Andrii Nakryiko
Apprently listing header as a normal dependency for a binary output makes it go through compilation as if it was C code. This currently works without a problem, but in subsequent commits causes problems for differently generated test.h for test_progs. Marking those headers as order-only dependency

[PATCH v3 bpf-next 8/9] selftests/bpf: convert bpf_verif_scale.c to sub-tests API

2019-07-27 Thread Andrii Nakryiko
Expose each BPF verifier scale test as individual sub-test to allow independent results output and test selection. Test run results now look like this: $ sudo ./test_progs -t verif/ #3/1 loop3.o:OK #3/2 test_verif_scale1.o:OK #3/3 test_verif_scale2.o:OK #3/4 test_verif_scale3.o:OK #3/

[PATCH v3 bpf-next 3/9] selftests/bpf: add test selectors by number and name to test_progs

2019-07-27 Thread Andrii Nakryiko
Add ability to specify either test number or test name substring to narrow down a set of test to run. Usage: sudo ./test_progs -n 1 sudo ./test_progs -t attach_probe Signed-off-by: Andrii Nakryiko --- tools/testing/selftests/bpf/test_progs.c | 43 +--- 1 file changed, 39 ins

[PATCH v3 bpf-next 7/9] selftests/bpf: add sub-tests support for test_progs

2019-07-27 Thread Andrii Nakryiko
Allow tests to have their own set of sub-tests. Also add ability to do test/subtest selection using `-t /` and `-n /`, as an extension of existing -t/-n selector options. For the format: it's a comma-separated list of either individual test numbers (1-based), or range of test numbers. E.g., all of

[PATCH v3 bpf-next 9/9] selftests/bpf: convert send_signal.c to use subtests

2019-07-27 Thread Andrii Nakryiko
Convert send_signal set of tests to be exposed as three sub-tests. Signed-off-by: Andrii Nakryiko --- tools/testing/selftests/bpf/prog_tests/send_signal.c | 9 ++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/tools/testing/selftests/bpf/prog_tests/send_signal.c b/tools/te

[PATCH v3 bpf-next 4/9] libbpf: return previous print callback from libbpf_set_print

2019-07-27 Thread Andrii Nakryiko
By returning previously set print callback from libbpf_set_print, it's possible to restore it, eventually. This is useful when running many independent test with one default print function, but overriding log verbosity for particular subset of tests. Signed-off-by: Andrii Nakryiko --- tools/lib/

Re: [PATCH v2 bpf-next 0/9] Revamp test_progs as a test running framework

2019-07-27 Thread Andrii Nakryiko
On Sat, Jul 27, 2019 at 7:16 PM Andrii Nakryiko wrote: > > On Sat, Jul 27, 2019 at 6:12 PM Alexei Starovoitov > wrote: > > > > On Sat, Jul 27, 2019 at 12:02 PM Andrii Nakryiko wrote: > > > > > > This patch set makes a number of changes to test_progs selftest, which is > > > a collection of many

Re: [PATCH v2 bpf-next 0/9] Revamp test_progs as a test running framework

2019-07-27 Thread Andrii Nakryiko
On Sat, Jul 27, 2019 at 6:12 PM Alexei Starovoitov wrote: > > On Sat, Jul 27, 2019 at 12:02 PM Andrii Nakryiko wrote: > > > > This patch set makes a number of changes to test_progs selftest, which is > > a collection of many other tests (and sometimes sub-tests as well), to > > provide > > bette

Re: [PATCH net-next v3 0/2] qed*: Support for NVM config attributes.

2019-07-27 Thread David Miller
From: Sudarsana Reddy Kalluru Date: Sat, 27 Jul 2019 18:55:47 -0700 > The patch series adds support for managing the NVM config attributes. > Patch (1) adds functionality to update config attributes via MFW. > Patch (2) adds driver interface for updating the config attributes. > > Changes from p

[PATCH net-next v3 1/2] qed: Add API for configuring NVM attributes.

2019-07-27 Thread Sudarsana Reddy Kalluru
The patch adds API for configuring the NVM config attributes using Management FW (MFW) interfaces. Signed-off-by: Sudarsana Reddy Kalluru Signed-off-by: Ariel Elior --- drivers/net/ethernet/qlogic/qed/qed_hsi.h | 17 drivers/net/ethernet/qlogic/qed/qed_mcp.c | 32 ++

[PATCH net-next v3 0/2] qed*: Support for NVM config attributes.

2019-07-27 Thread Sudarsana Reddy Kalluru
The patch series adds support for managing the NVM config attributes. Patch (1) adds functionality to update config attributes via MFW. Patch (2) adds driver interface for updating the config attributes. Changes from previous versions: --- v3: Removed unused variable. v

[PATCH net-next v3 2/2] qed: Add driver API for flashing the config attributes.

2019-07-27 Thread Sudarsana Reddy Kalluru
The patch adds driver interface for reading the NVM config request and update the attributes on nvm config flash partition. This API can be used by ethtool flash update command (i.e., ethtool -f) to update config attributes in the NVM flash parition. Signed-off-by: Sudarsana Reddy Kalluru Signed-

RE: [PATCH net-next v2 1/2] qed: Add API for configuring NVM attributes.

2019-07-27 Thread Sudarsana Reddy Kalluru
> -Original Message- > From: netdev-ow...@vger.kernel.org On > Behalf Of David Miller > Sent: Sunday, July 28, 2019 2:30 AM > To: Sudarsana Reddy Kalluru > Cc: netdev@vger.kernel.org; Michal Kalderon ; > Ariel Elior > Subject: Re: [PATCH net-next v2 1/2] qed: Add API for configuring NV

Re: [PATCH v2 bpf-next 0/9] Revamp test_progs as a test running framework

2019-07-27 Thread Alexei Starovoitov
On Sat, Jul 27, 2019 at 12:02 PM Andrii Nakryiko wrote: > > This patch set makes a number of changes to test_progs selftest, which is > a collection of many other tests (and sometimes sub-tests as well), to provide > better testing experience and allow to start convering many individual test > pro

[PATCH v3] net: dsa: qca8k: enable port flow control

2019-07-27 Thread xiaofeis
Set phy device advertising to enable MAC flow control. Signed-off-by: Xiaofei Shen --- Changes since V2: drivers/net/dsa/qca8k.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/net/dsa/qca8k.c b/drivers/net/dsa/qca8k.c index 232e8cc..e429e92 100644 --- a/drivers/ne

Re: [PATCH bpf-next 02/10] libbpf: implement BPF CO-RE offset relocation algorithm

2019-07-27 Thread Song Liu
> On Jul 27, 2019, at 12:09 PM, Andrii Nakryiko > wrote: > > On Sat, Jul 27, 2019 at 11:59 AM Song Liu wrote: >> >> >> >>> On Jul 26, 2019, at 11:11 PM, Andrii Nakryiko >>> wrote: >>> >>> On Thu, Jul 25, 2019 at 12:32 PM Song Liu wrote: > On Jul 24, 2019, at 12:2

Re: [PATCH] tcp: add new tcp_mtu_probe_floor sysctl

2019-07-27 Thread Josh Hunt
On 7/27/19 12:05 AM, Eric Dumazet wrote: On Sat, Jul 27, 2019 at 4:23 AM Josh Hunt wrote: The current implementation of TCP MTU probing can considerably underestimate the MTU on lossy connections allowing the MSS to get down to 48. We have found that in almost all of these cases on our network

Re: [PATCH bpf-next 02/10] libbpf: implement BPF CO-RE offset relocation algorithm

2019-07-27 Thread Andrii Nakryiko
On Sat, Jul 27, 2019 at 2:29 PM Yonghong Song wrote: > > > > On 7/27/19 11:24 AM, Andrii Nakryiko wrote: > > On Sat, Jul 27, 2019 at 10:00 AM Alexei Starovoitov wrote: > >> > >> On 7/26/19 11:25 PM, Andrii Nakryiko wrote: > > + } else if (class == BPF_ST && BPF_MODE(insn->code) == BPF_MEM

Re: [PATCH net-next 0/3] mlxsw: spectrum_acl: Forbid unsupported filters

2019-07-27 Thread David Miller
From: Ido Schimmel Date: Sat, 27 Jul 2019 20:32:54 +0300 > From: Ido Schimmel > > Patches #1-#2 make mlxsw reject unsupported egress filters. These > include filters that match on VLAN and filters associated with a > redirect action. Patch #1 rejects such filters when they are configured > on e

Re: [PATCH net] r8169: don't use MSI before RTL8168d

2019-07-27 Thread David Miller
From: Heiner Kallweit Date: Sat, 27 Jul 2019 12:43:31 +0200 > It was reported that after resuming from suspend network fails with > error "do_IRQ: 3.38 No irq handler for vector", see [0]. Enabling WoL > can work around the issue, but the only actual fix is to disable MSI. > So let's mimic the be

Re: [PATCH net] Revert ("r8169: remove 1000/Half from supported modes")

2019-07-27 Thread David Miller
From: Heiner Kallweit Date: Sat, 27 Jul 2019 12:32:28 +0200 > This reverts commit a6851c613fd7fccc5d1f28d5d8a0cbe9b0f4e8cc. > It was reported that RTL8111b successfully finishes 1000/Full autoneg > but no data flows. Reverting the original patch fixes the issue. > It seems to be a HW issue with t

Re: [PATCH bpf-next 02/10] libbpf: implement BPF CO-RE offset relocation algorithm

2019-07-27 Thread Yonghong Song
On 7/27/19 11:24 AM, Andrii Nakryiko wrote: > On Sat, Jul 27, 2019 at 10:00 AM Alexei Starovoitov wrote: >> >> On 7/26/19 11:25 PM, Andrii Nakryiko wrote: > + } else if (class == BPF_ST && BPF_MODE(insn->code) == BPF_MEM) { > + if (insn->imm != orig_off) > +

Re: [PATCH net] net: phylink: Fix flow control for fixed-link

2019-07-27 Thread David Miller
From: René van Dorst Date: Sat, 27 Jul 2019 11:40:11 +0200 > In phylink_parse_fixedlink() the pl->link_config.advertising bits are AND > with pl->supported, pl->supported is zeroed and only the speed/duplex > modes and MII bits are set. > So pl->link_config.advertising always loses the flow contr

Re: [PATCH net-next 3/3] net: dsa: mt7530: Add support for port 5

2019-07-27 Thread René van Dorst
Quoting Russell King - ARM Linux admin : On Wed, Jul 24, 2019 at 09:25:49PM +0200, René van Dorst wrote: Adding support for port 5. Port 5 can muxed/interface to: - internal 5th GMAC of the switch; can be used as 2nd CPU port or as extra port with an external phy for a 6th ethernet port. - i

Re: [PATCH net-next 0/4] r8169: improve HW csum and TSO handling

2019-07-27 Thread David Miller
From: Heiner Kallweit Date: Fri, 26 Jul 2019 21:47:30 +0200 > This series: > - delegates more tasks from the driver to the core > - enables HW csum and TSO per default > - copies quirks for buggy chip versions from vendor driver Series applied, thanks Heiner.

Re: [PATCH net-next] ipv6: remove printk

2019-07-27 Thread David Miller
From: Jonathan Lemon Date: Fri, 26 Jul 2019 12:16:09 -0700 > ipv6_find_hdr() prints a non-rate limited error message > when it cannot find an ipv6 header at a specific offset. > This could be used as a DoS, so just remove it. > > Signed-off-by: Jonathan Lemon Applied.

Re: [PATCH net-next v2] mlx4/en_netdev: allow offloading VXLAN over VLAN

2019-07-27 Thread David Miller
From: Davide Caratti Date: Fri, 26 Jul 2019 20:18:12 +0200 > ConnectX-3 Pro can offload transmission of VLAN packets with VXLAN inside: > enable tunnel offloads in dev->vlan_features, like it's done with other > NIC drivers (e.g. be2net and ixgbe). > > It's no more necessary to change dev->hw_en

Re: [PATCH net-next] r8169: align setting PME with vendor driver

2019-07-27 Thread David Miller
From: Heiner Kallweit Date: Fri, 26 Jul 2019 20:56:20 +0200 > Align setting PME with the vendor driver. PMEnable is writable on > RTL8169 only, on later chip versions it's read-only. PME_SIGNAL is > used on chip versions from RTL8168evl with the exception of the > RTL8168f family. > > Signed-off

Re: [PATCH net-next v2 1/2] qed: Add API for configuring NVM attributes.

2019-07-27 Thread David Miller
From: Sudarsana Reddy Kalluru Date: Fri, 26 Jul 2019 08:52:14 -0700 > +int qed_mcp_nvm_set_cfg(struct qed_hwfn *p_hwfn, struct qed_ptt *p_ptt, > + u16 option_id, u8 entity_id, u16 flags, u8 *p_buf, > + u32 len) > +{ > + u32 mb_param = 0, resp, param; >

Re: [PATCH net-next 2/2] net: stmmac: Do not request stmmaceth clock

2019-07-27 Thread David Miller
From: Thierry Reding Date: Fri, 26 Jul 2019 12:27:41 +0200 > From: Thierry Reding > > The stmmaceth clock is specified by the slave_bus and apb_pclk clocks in > the device tree bindings for snps,dwc-qos-ethernet-4.10 compatible nodes > of this IP. > > The subdrivers for these bindings will be

Re: [PATCH net-next 1/2] net: stmmac: Make MDIO bus reset optional

2019-07-27 Thread David Miller
From: Thierry Reding Date: Fri, 26 Jul 2019 12:27:40 +0200 > From: Thierry Reding > > The Tegra EQOS driver already resets the MDIO bus at probe time via the > reset GPIO specified in the phy-reset-gpios device tree property. There > is no need to reset the bus again later on. > > This avoids

Re: [PATCH bpf-next 02/10] libbpf: implement BPF CO-RE offset relocation algorithm

2019-07-27 Thread Andrii Nakryiko
On Sat, Jul 27, 2019 at 11:59 AM Song Liu wrote: > > > > > On Jul 26, 2019, at 11:11 PM, Andrii Nakryiko > > wrote: > > > > On Thu, Jul 25, 2019 at 12:32 PM Song Liu wrote: > >> > >> > >> > >>> On Jul 24, 2019, at 12:27 PM, Andrii Nakryiko wrote: > >>> > >>> This patch implements the core logi

[PATCH v2 bpf-next 0/9] Revamp test_progs as a test running framework

2019-07-27 Thread Andrii Nakryiko
This patch set makes a number of changes to test_progs selftest, which is a collection of many other tests (and sometimes sub-tests as well), to provide better testing experience and allow to start convering many individual test programs under selftests/bpf into a single and convenient test runner.

[PATCH v2 bpf-next 9/9] selftests/bpf: convert send_signal.c to use subtests

2019-07-27 Thread Andrii Nakryiko
Convert send_signal set of tests to be exposed as three sub-tests. Signed-off-by: Andrii Nakryiko --- tools/testing/selftests/bpf/prog_tests/send_signal.c | 9 ++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/tools/testing/selftests/bpf/prog_tests/send_signal.c b/tools/te

[PATCH v2 bpf-next 6/9] selftests/bpf: abstract away test log output

2019-07-27 Thread Andrii Nakryiko
This patch changes how test output is printed out. By default, if test had no errors, the only output will be a single line with test number, name, and verdict at the end, e.g.: #31 xdp:OK If test had any errors, all log output captured during test execution will be output after test completes.

[PATCH v2 bpf-next 7/9] selftests/bpf: add sub-tests support for test_progs

2019-07-27 Thread Andrii Nakryiko
Allow tests to have their own set of sub-tests. Also add ability to do test/subtest selection using `-t /` and `-n /`, as an extension of existing -t/-n selector options. For the format: it's a comma-separated list of either individual test numbers (1-based), or range of test numbers. E.g., all of

[PATCH v2 bpf-next 2/9] selftests/bpf: revamp test_progs to allow more control

2019-07-27 Thread Andrii Nakryiko
Refactor test_progs to allow better control on what's being run. Also use argp to do argument parsing, so that it's easier to keep adding more options. Signed-off-by: Andrii Nakryiko --- tools/testing/selftests/bpf/Makefile | 8 +-- tools/testing/selftests/bpf/test_progs.c | 84

[PATCH v2 bpf-next 4/9] libbpf: return previous print callback from libbpf_set_print

2019-07-27 Thread Andrii Nakryiko
By returning previously set print callback from libbpf_set_print, it's possible to restore it, eventually. This is useful when running many independent test with one default print function, but overriding log verbosity for particular subset of tests. Signed-off-by: Andrii Nakryiko --- tools/lib/

[PATCH v2 bpf-next 1/9] selftests/bpf: prevent headers to be compiled as C code

2019-07-27 Thread Andrii Nakryiko
Apprently listing header as a normal dependency for a binary output makes it go through compilation as if it was C code. This currently works without a problem, but in subsequent commits causes problems for differently generated test.h for test_progs. Marking those headers as order-only dependency

[PATCH v2 bpf-next 8/9] selftests/bpf: convert bpf_verif_scale.c to sub-tests API

2019-07-27 Thread Andrii Nakryiko
Expose each BPF verifier scale test as individual sub-test to allow independent results output and test selection. Test run results now look like this: $ sudo ./test_progs -t verif/ #3/1 loop3.o:OK #3/2 test_verif_scale1.o:OK #3/3 test_verif_scale2.o:OK #3/4 test_verif_scale3.o:OK #3/

Re: [PATCH bpf-next 02/10] libbpf: implement BPF CO-RE offset relocation algorithm

2019-07-27 Thread Song Liu
> On Jul 26, 2019, at 11:11 PM, Andrii Nakryiko > wrote: > > On Thu, Jul 25, 2019 at 12:32 PM Song Liu wrote: >> >> >> >>> On Jul 24, 2019, at 12:27 PM, Andrii Nakryiko wrote: >>> >>> This patch implements the core logic for BPF CO-RE offsets relocations. >>> All the details are describ

[PATCH v2 bpf-next 3/9] selftests/bpf: add test selectors by number and name to test_progs

2019-07-27 Thread Andrii Nakryiko
Add ability to specify either test number or test name substring to narrow down a set of test to run. Usage: sudo ./test_progs -n 1 sudo ./test_progs -t attach_probe Signed-off-by: Andrii Nakryiko --- tools/testing/selftests/bpf/test_progs.c | 43 +--- 1 file changed, 39 ins

[PATCH v2 bpf-next 5/9] selftest/bpf: centralize libbpf logging management for test_progs

2019-07-27 Thread Andrii Nakryiko
Make test_progs test runner own libbpf logging. Also introduce two levels of verbosity: -v and -vv. First one will be used in subsequent patches to enable test log output always. Second one increases verbosity level of libbpf logging further to include debug output as well. Signed-off-by: Andrii N

Re: [PATCH bpf-next 6/9] selftests/bpf: abstract away test log output

2019-07-27 Thread Andrii Nakryiko
On Fri, Jul 26, 2019 at 3:26 PM Stanislav Fomichev wrote: > > On 07/26, Andrii Nakryiko wrote: > > On Fri, Jul 26, 2019 at 2:31 PM Stanislav Fomichev wrote: > > > > > > On 07/26, Andrii Nakryiko wrote: > > > > This patch changes how test output is printed out. By default, if test > > > > had no e

Re: [PATCH bpf-next 1/9] selftests/bpf: prevent headers to be compiled as C code

2019-07-27 Thread Andrii Nakryiko
On Fri, Jul 26, 2019 at 3:01 PM Stanislav Fomichev wrote: > > On 07/26, Andrii Nakryiko wrote: > > On Fri, Jul 26, 2019 at 2:21 PM Stanislav Fomichev wrote: > > > > > > On 07/26, Andrii Nakryiko wrote: > > > > Apprently listing header as a normal dependency for a binary output > > > > makes it go

Re: [PATCH net-next 3/3] net: dsa: mt7530: Add support for port 5

2019-07-27 Thread Russell King - ARM Linux admin
On Wed, Jul 24, 2019 at 09:25:49PM +0200, René van Dorst wrote: > Adding support for port 5. > > Port 5 can muxed/interface to: > - internal 5th GMAC of the switch; can be used as 2nd CPU port or as > extra port with an external phy for a 6th ethernet port. > - internal PHY of port 0 or 4; Used

Re: [PATCH bpf-next 4/9] libbpf: add libbpf_swap_print to get previous print func

2019-07-27 Thread Andrii Nakryiko
On Fri, Jul 26, 2019 at 5:30 PM Alexei Starovoitov wrote: > > On Fri, Jul 26, 2019 at 02:47:28PM -0700, Andrii Nakryiko wrote: > > On Fri, Jul 26, 2019 at 2:28 PM Stanislav Fomichev wrote: > > > > > > On 07/26, Andrii Nakryiko wrote: > > > > libbpf_swap_print allows to restore previously set prin

Re: [PATCH net-next 1/3] net: dsa: mt7530: Convert to PHYLINK API

2019-07-27 Thread Russell King - ARM Linux admin
Hi, Just a couple of minor points. On Wed, Jul 24, 2019 at 09:25:47PM +0200, René van Dorst wrote: > +static void mt7530_phylink_mac_config(struct dsa_switch *ds, int port, > + unsigned int mode, > + const struct phylink_link_sta

Re: [PATCH net-next 3/3] net: dsa: mt7530: Add support for port 5

2019-07-27 Thread René van Dorst
Quoting David Miller : From: René van Dorst Date: Wed, 24 Jul 2019 21:25:49 +0200 @@ -1167,6 +1236,10 @@ mt7530_setup(struct dsa_switch *ds) u32 id, val; struct device_node *dn; struct mt7530_dummy_poll p; + phy_interface_t interface; + struct device_node *

Re: [PATCH net-next 3/3] net: dsa: mt7530: Add support for port 5

2019-07-27 Thread René van Dorst
Quoting Florian Fainelli : On 7/24/2019 9:25 PM, René van Dorst wrote: Adding support for port 5. Port 5 can muxed/interface to: - internal 5th GMAC of the switch; can be used as 2nd CPU port or as extra port with an external phy for a 6th ethernet port. - internal PHY of port 0 or 4; Used i

Re: [PATCH bpf-next 02/10] libbpf: implement BPF CO-RE offset relocation algorithm

2019-07-27 Thread Andrii Nakryiko
On Sat, Jul 27, 2019 at 10:00 AM Alexei Starovoitov wrote: > > On 7/26/19 11:25 PM, Andrii Nakryiko wrote: > >>> + } else if (class == BPF_ST && BPF_MODE(insn->code) == BPF_MEM) { > >>> + if (insn->imm != orig_off) > >>> + return -EINVAL; > >>> + ins

Re: [PATCH v2 bpf-next 1/4] bpf: unprivileged BPF access via /dev/bpf

2019-07-27 Thread Song Liu
Hi Andy, >>> >>> Well, yes. sys_bpf() is pretty powerful. >>> >>> The goal of /dev/bpf is to enable special users to call sys_bpf(). In >>> the meanwhile, such users should not take down the whole system easily >>> by accident, e.g., with rm -rf /. >> >> That’s easy, though — bpftool c

Re: [PATCH bpf-next 2/6] bpf: add BPF_MAP_DUMP command to dump more than one entry per call

2019-07-27 Thread Yonghong Song
On 7/26/19 4:36 PM, Brian Vazquez wrote: > On Thu, Jul 25, 2019 at 11:10 PM Yonghong Song wrote: >> >> >> >> On 7/25/19 6:47 PM, Alexei Starovoitov wrote: >>> On Thu, Jul 25, 2019 at 6:24 PM Brian Vazquez >>> wrote: On Thu, Jul 25, 2019 at 4:54 PM Alexei Starovoitov wrote:

[PATCH net] mlxsw: spectrum_ptp: Increase parsing depth when PTP is enabled

2019-07-27 Thread Ido Schimmel
From: Petr Machata Spectrum systems have a configurable limit on how far into the packet they parse. By default, the limit is 96 bytes. An IPv6 PTP packet is layered as Ethernet/IPv6/UDP (14+40+8 bytes), and sequence ID of a PTP event is only available 32 bytes into payload, for a total of 94 by

[PATCH net-next 2/3] mlxsw: spectrum_acl: Track rules that forbid egress block bind

2019-07-27 Thread Ido Schimmel
From: Jiri Pirko Some matches and actions are not supported on egress. Track such rules and forbid a bind of block which contains them to egress. With this patch, the kernel tells the user he cannot do that: $ tc qdisc add dev ens16np1 ingress_block 22 clsact $ tc filter add block 22 protocol 80

[PATCH net-next 1/3] mlxsw: spectrum_flower: Forbid to offload mirred redirect on egress

2019-07-27 Thread Ido Schimmel
From: Jiri Pirko Spectrum ASIC does not support redirection on egress, so refuse to insert such flows: $ tc qdisc add dev ens16np1 clsact $ tc filter add dev ens16np1 egress protocol all pref 1 handle 101 flower skip_sw action mirred egress redirect dev ens16np2 Error: mlxsw_spectrum: Redirect

[PATCH net-next 3/3] mlxsw: spectrum_flower: Forbid to offload match on reserved TCP flags bits

2019-07-27 Thread Ido Schimmel
From: Jiri Pirko Matching on reserved TCP flags bits is only supported using custom parser. Since the usecase for that is not known now, just forbid to offload rules that match on these bits. Reported-by: Alex Kushnarov Signed-off-by: Jiri Pirko Signed-off-by: Ido Schimmel --- drivers/net/et

[PATCH net-next 0/3] mlxsw: spectrum_acl: Forbid unsupported filters

2019-07-27 Thread Ido Schimmel
From: Ido Schimmel Patches #1-#2 make mlxsw reject unsupported egress filters. These include filters that match on VLAN and filters associated with a redirect action. Patch #1 rejects such filters when they are configured on egress and patch #2 rejects such filters when they are configured in a s

Re: next-20190723: bpf/seccomp - systemd/journald issue?

2019-07-27 Thread Yonghong Song
On 7/27/19 1:16 AM, Sedat Dilek wrote: > On Sat, Jul 27, 2019 at 9:36 AM Sedat Dilek wrote: >> >> On Sat, Jul 27, 2019 at 4:24 AM Alexei Starovoitov >> wrote: >>> >>> On Fri, Jul 26, 2019 at 2:19 PM Sedat Dilek wrote: On Fri, Jul 26, 2019 at 11:10 PM Yonghong Song wrote: > >

Re: next-20190723: bpf/seccomp - systemd/journald issue?

2019-07-27 Thread Yonghong Song
On 7/27/19 12:36 AM, Sedat Dilek wrote: > On Sat, Jul 27, 2019 at 4:24 AM Alexei Starovoitov > wrote: >> >> On Fri, Jul 26, 2019 at 2:19 PM Sedat Dilek wrote: >>> >>> On Fri, Jul 26, 2019 at 11:10 PM Yonghong Song wrote: On 7/26/19 2:02 PM, Sedat Dilek wrote: > On Fri,

Re: [PATCH bpf-next 02/10] libbpf: implement BPF CO-RE offset relocation algorithm

2019-07-27 Thread Alexei Starovoitov
On 7/26/19 11:25 PM, Andrii Nakryiko wrote: >>> + } else if (class == BPF_ST && BPF_MODE(insn->code) == BPF_MEM) { >>> + if (insn->imm != orig_off) >>> + return -EINVAL; >>> + insn->imm = new_off; >>> + pr_debug("prog '%s': patched insn #%

Re: [PATCH net] net: phylink: Fix flow control for fixed-link

2019-07-27 Thread Russell King - ARM Linux admin
On Sat, Jul 27, 2019 at 11:40:11AM +0200, René van Dorst wrote: > In phylink_parse_fixedlink() the pl->link_config.advertising bits are AND > with pl->supported, pl->supported is zeroed and only the speed/duplex > modes and MII bits are set. > So pl->link_config.advertising always loses the flow co

[PATCH net] net/mlx5e: Fix unnecessary flow_block_cb_is_busy call

2019-07-27 Thread wenxu
From: wenxu When call flow_block_cb_is_busy. The indr_priv is guaranteed to NULL ptr. So there is no need to call flow_bock_cb_is_busy. Fixes: 0d4fd02e7199 ("net: flow_offload: add flow_block_cb_is_busy() and use it") Signed-off-by: wenxu --- drivers/net/ethernet/mellanox/mlx5/core/en_rep.c |

Re: [PATCH 2/2] staging/octeon: Allow test build on !MIPS

2019-07-27 Thread Greg KH
On Sat, Jul 27, 2019 at 07:28:26AM -0700, Matthew Wilcox wrote: > On Sat, Jul 27, 2019 at 12:57:06PM +0200, Greg KH wrote: > > No real objection from me, having this driver able to be built on > > non-mips systems would be great. > > > > But wow, that stubs.h file is huge, you really need all of t

Re: [PATCH 2/2] staging/octeon: Allow test build on !MIPS

2019-07-27 Thread Matthew Wilcox
On Sat, Jul 27, 2019 at 12:57:06PM +0200, Greg KH wrote: > No real objection from me, having this driver able to be built on > non-mips systems would be great. > > But wow, that stubs.h file is huge, you really need all of that? > There's no way to include the files from the mips "core" directly >

Re: [PATCH 2/2] staging/octeon: Allow test build on !MIPS

2019-07-27 Thread Greg KH
On Fri, Jul 26, 2019 at 10:44:25AM -0700, Matthew Wilcox wrote: > From: "Matthew Wilcox (Oracle)" > > Add compile test support by moving all includes of files under > asm/octeon into octeon-ethernet.h, and if we're not on MIPS, > stub out all the calls into the octeon support code in octeon-stubs

[PATCH net] r8169: don't use MSI before RTL8168d

2019-07-27 Thread Heiner Kallweit
It was reported that after resuming from suspend network fails with error "do_IRQ: 3.38 No irq handler for vector", see [0]. Enabling WoL can work around the issue, but the only actual fix is to disable MSI. So let's mimic the behavior of the vendor driver and disable MSI on all chip versions befor

Re: [PATCH 4.4 stable net] net: tcp: Fix use-after-free in tcp_write_xmit

2019-07-27 Thread maowenan
On 2019/7/24 20:13, maowenan wrote: > > > On 2019/7/24 19:05, Greg KH wrote: >> On Wed, Jul 24, 2019 at 05:17:15PM +0800, Mao Wenan wrote: >>> There is one report about tcp_write_xmit use-after-free with version >>> 4.4.136: >>> >>> BUG: KASAN: use-after-free in tcp_skb_pcount include/net/tcp

[PATCH net] r8169: don't use MSI before RTL8168d

2019-07-27 Thread Heiner Kallweit
It was reported that after resuming from suspend network fails with error "do_IRQ: 3.38 No irq handler for vector", see [0]. Enabling WoL can work around the issue, but the only actual fix is to disable MSI. So let's mimic the behavior of the vendor driver and disable MSI on all chip versions befor

[PATCH net] Revert ("r8169: remove 1000/Half from supported modes")

2019-07-27 Thread Heiner Kallweit
This reverts commit a6851c613fd7fccc5d1f28d5d8a0cbe9b0f4e8cc. It was reported that RTL8111b successfully finishes 1000/Full autoneg but no data flows. Reverting the original patch fixes the issue. It seems to be a HW issue with the integrated RTL8211B PHY. This PHY version used also e.g. on RTL8168

Re: [REGRESSION] 5.3-rc1: r8169: remove 1000/Half from supported modes

2019-07-27 Thread Heiner Kallweit
On 26.07.2019 22:45, Bernhard Held wrote: > On 26.07.19 at 22:24, Heiner Kallweit wrote: >> On 26.07.2019 22:16, Bernhard Held wrote: >>> Hi Heiner, >>> >>> with commit a6851c613fd7 "r8169: remove 1000/Half from supported modes" my >>> RTL8111B GB-link stops working. It thinks that it established

Re: [patch iproute2 1/2] devlink: introduce cmdline option to switch to a different namespace

2019-07-27 Thread Toke Høiland-Jørgensen
Jiri Pirko writes: > Sat, Jul 27, 2019 at 12:12:48PM CEST, t...@redhat.com wrote: >>Jiri Pirko writes: >> >>> From: Jiri Pirko >>> >>> Signed-off-by: Jiri Pirko >>> --- >>> devlink/devlink.c | 12 ++-- >>> man/man8/devlink.8 | 4 >>> 2 files changed, 14 insertions(+), 2 deletio

Re: [patch iproute2 1/2] devlink: introduce cmdline option to switch to a different namespace

2019-07-27 Thread Jiri Pirko
Sat, Jul 27, 2019 at 12:12:48PM CEST, t...@redhat.com wrote: >Jiri Pirko writes: > >> From: Jiri Pirko >> >> Signed-off-by: Jiri Pirko >> --- >> devlink/devlink.c | 12 ++-- >> man/man8/devlink.8 | 4 >> 2 files changed, 14 insertions(+), 2 deletions(-) >> >> diff --git a/devlink

Re: [patch iproute2 1/2] devlink: introduce cmdline option to switch to a different namespace

2019-07-27 Thread Toke Høiland-Jørgensen
Jiri Pirko writes: > From: Jiri Pirko > > Signed-off-by: Jiri Pirko > --- > devlink/devlink.c | 12 ++-- > man/man8/devlink.8 | 4 > 2 files changed, 14 insertions(+), 2 deletions(-) > > diff --git a/devlink/devlink.c b/devlink/devlink.c > index d8197ea3a478..9242cc05ad0c 100644

[patch iproute2 1/2] devlink: introduce cmdline option to switch to a different namespace

2019-07-27 Thread Jiri Pirko
From: Jiri Pirko Signed-off-by: Jiri Pirko --- devlink/devlink.c | 12 ++-- man/man8/devlink.8 | 4 2 files changed, 14 insertions(+), 2 deletions(-) diff --git a/devlink/devlink.c b/devlink/devlink.c index d8197ea3a478..9242cc05ad0c 100644 --- a/devlink/devlink.c +++ b/devlink/

[patch iproute2 2/2] devlink: add support for network namespace change

2019-07-27 Thread Jiri Pirko
From: Jiri Pirko Signed-off-by: Jiri Pirko --- devlink/devlink.c| 54 +++- include/uapi/linux/devlink.h | 4 +++ man/man8/devlink-dev.8 | 12 3 files changed, 69 insertions(+), 1 deletion(-) diff --git a/devlink/devlink.c b/devlink/de

[patch net-next 2/3] net: devlink: export devlink net set/get helpers

2019-07-27 Thread Jiri Pirko
From: Jiri Pirko Allow drivers to set/get net struct for devlink instance. Set is only allowed for newly allocated devlink instance. Signed-off-by: Jiri Pirko --- include/net/devlink.h | 3 +++ net/core/devlink.c| 18 ++ 2 files changed, 17 insertions(+), 4 deletions(-) d

Re: KASAN: use-after-free Read in lock_sock_nested

2019-07-27 Thread syzbot
syzbot has found a reproducer for the following crash on: HEAD commit:3ea54d9b Merge tag 'docs-5.3-1' of git://git.lwn.net/linux git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=16a6656460 kernel config: https://syzkaller.appspot.com/x/.config?x=195ab3ca

[patch net-next 0/3] net: devlink: Finish network namespace support

2019-07-27 Thread Jiri Pirko
From: Jiri Pirko Devlink from the beginning counts with network namespaces, but the instances has been fixed to init_net. The first patch allows user to move existing devlink instances into namespaces: $ devlink dev netdevsim/netdevsim1 $ ip netns add ns1 $ devlink dev set netdevsim/netdevsim1 n

[patch net-next 1/3] net: devlink: allow to change namespaces

2019-07-27 Thread Jiri Pirko
From: Jiri Pirko All devlink instances are created in init_net and stay there for a lifetime. Allow user to be able to move devlink instances into namespaces. Signed-off-by: Jiri Pirko --- include/uapi/linux/devlink.h | 4 ++ net/core/devlink.c | 112 +++

[patch net-next 3/3] netdevsim: create devlink and netdev instances in namespace

2019-07-27 Thread Jiri Pirko
From: Jiri Pirko When user does create new netdevsim instance using sysfs bus file, create the devlink instance and related netdev instance in the namespace of the caller. Signed-off-by: Jiri Pirko --- drivers/net/netdevsim/bus.c | 1 + drivers/net/netdevsim/dev.c | 17 +++

[PATCH net] net: phylink: Fix flow control for fixed-link

2019-07-27 Thread René van Dorst
In phylink_parse_fixedlink() the pl->link_config.advertising bits are AND with pl->supported, pl->supported is zeroed and only the speed/duplex modes and MII bits are set. So pl->link_config.advertising always loses the flow control/pause bits. By setting Pause and Asym_Pause bits in pl->supported

Re: [PATCH net-next 3/3] net: dsa: mt7530: Add support for port 5

2019-07-27 Thread Florian Fainelli
On 7/24/2019 9:25 PM, René van Dorst wrote: > Adding support for port 5. > > Port 5 can muxed/interface to: > - internal 5th GMAC of the switch; can be used as 2nd CPU port or as > extra port with an external phy for a 6th ethernet port. > - internal PHY of port 0 or 4; Used in most applicati

Re: [patch iproute2 1/2] tc: action: fix crash caused by incorrect *argv check

2019-07-27 Thread Jiri Pirko
Fri, Jul 26, 2019 at 09:47:07PM CEST, step...@networkplumber.org wrote: >On Tue, 23 Jul 2019 13:25:37 +0200 >Jiri Pirko wrote: > >> From: Jiri Pirko >> >> One cannot depend on *argv being null in case of no arg is left on the >> command line. For example in batch mode, this is not always true. C

Re: next-20190723: bpf/seccomp - systemd/journald issue?

2019-07-27 Thread Sedat Dilek
On Sat, Jul 27, 2019 at 9:36 AM Sedat Dilek wrote: > > On Sat, Jul 27, 2019 at 4:24 AM Alexei Starovoitov > wrote: > > > > On Fri, Jul 26, 2019 at 2:19 PM Sedat Dilek wrote: > > > > > > On Fri, Jul 26, 2019 at 11:10 PM Yonghong Song wrote: > > > > > > > > > > > > > > > > On 7/26/19 2:02 PM, Sed

Re: [PATCH net-next v3 1/3] flow_offload: move tc indirect block to flow offload

2019-07-27 Thread wenxu
在 2019/7/27 8:56, Jakub Kicinski 写道: > On Fri, 26 Jul 2019 21:34:05 +0800, we...@ucloud.cn wrote: >> From: wenxu >> >> move tc indirect block to flow_offload and rename >> it to flow indirect block.The nf_tables can use the >> indr block architecture. >> >> Signed-off-by: wenxu >> diff --git a/

Re: [PATCH net-next v3 2/3] flow_offload: support get tcf block immediately

2019-07-27 Thread wenxu
在 2019/7/27 8:52, Jakub Kicinski 写道: > On Fri, 26 Jul 2019 21:34:06 +0800, we...@ucloud.cn wrote: >> From: wenxu >> >> Because the new flow-indr-block can't get the tcf_block >> directly. >> It provide a callback to find the tcf block immediately >> when the device register and contain a ingress

Re: next-20190723: bpf/seccomp - systemd/journald issue?

2019-07-27 Thread Sedat Dilek
On Sat, Jul 27, 2019 at 4:24 AM Alexei Starovoitov wrote: > > On Fri, Jul 26, 2019 at 2:19 PM Sedat Dilek wrote: > > > > On Fri, Jul 26, 2019 at 11:10 PM Yonghong Song wrote: > > > > > > > > > > > > On 7/26/19 2:02 PM, Sedat Dilek wrote: > > > > On Fri, Jul 26, 2019 at 10:38 PM Sedat Dilek > >

Re: [PATCH] tcp: add new tcp_mtu_probe_floor sysctl

2019-07-27 Thread Eric Dumazet
On Sat, Jul 27, 2019 at 4:23 AM Josh Hunt wrote: > > The current implementation of TCP MTU probing can considerably > underestimate the MTU on lossy connections allowing the MSS to get down to > 48. We have found that in almost all of these cases on our networks these > paths can handle much large