Re: [PATCH bpf-next 2/2] selftest/bpf: remove unused bpf tunnel testing code

2020-11-06 Thread Hangbin Liu
On Fri, Nov 06, 2020 at 03:55:47PM +0800, Hangbin Liu wrote: > > > - key.remote_ipv6[0] = bpf_htonl(0x2401db00); > > > - key.tunnel_ttl = 64; > > The code logic is same. It set tunnel remote addr to dst IPv6 address, as > they are both testing IP(v4 or v6) over IPv6 tunnel. OK, I decide to keep t

[PATCH] net: core: fix spelling typo in flow_dissector.c

2020-11-06 Thread Wang Qing
withing should be within. Signed-off-by: Wang Qing --- net/core/flow_dissector.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/net/core/flow_dissector.c b/net/core/flow_dissector.c index e21950a..6f1adba --- a/net/core/flow_dissector.c +++ b/net/core/flow_dissector.c @@ -48

[PATCH] net/ieee802154: remove unused macros to tame gcc

2020-11-06 Thread Alex Shi
Signed-off-by: Alex Shi Cc: Alexander Aring Cc: Stefan Schmidt Cc: "David S. Miller" Cc: Jakub Kicinski Cc: linux-w...@vger.kernel.org Cc: netdev@vger.kernel.org Cc: linux-ker...@vger.kernel.org --- net/ieee802154/nl802154.c | 4 1 file changed, 4 deletions(-) diff --git a/net/ie

Re: [PATCH] xdp: auto off xdp by bond fd

2020-11-06 Thread Björn Töpel
On Fri, 6 Nov 2020 at 08:41, Xuan Zhuo wrote: > > By default, off xdp is implemented by actively calling netlink on the > command line or in the program. This is very inconvenient for apps based > on xdp. For example, an app based on xdp + xsk exits abnormally, but xdp > is still working, which ma

Re: [PATCH v3 bpf-next] bpf: make verifier log more relevant by default

2020-11-06 Thread Jiri Benc
On Thu, 5 Nov 2020 14:57:13 -0800, Jakub Kicinski wrote: > If you're saying the driver message would still be there if > verification or translation failed that's perfectly fine, we > can definitely adjust the test. But some check that driver > message reporting is working is needed, don't just r

Re: [PATCH v3 bpf-next] bpf: make verifier log more relevant by default

2020-11-06 Thread Jiri Benc
On Thu, 5 Nov 2020 13:22:12 -0800, Andrii Nakryiko wrote: > test_progs is the only test runner that's run continuously on every > patch. libbpf CI also runs test_maps and test_verifier. All the other > test binaries/scripts rely on humans to not forget about them. Which > works so-so, as you can se

Re: [PATCH net-next v2 03/10] tun: switch to net core provided statistics counters

2020-11-06 Thread Heiner Kallweit
On 06.11.2020 08:48, Heiner Kallweit wrote: > On 06.11.2020 02:14, Jakub Kicinski wrote: >> On Wed, 4 Nov 2020 15:25:24 +0100 Heiner Kallweit wrote: >>> @@ -1066,7 +1054,7 @@ static netdev_tx_t tun_net_xmit(struct sk_buff *skb, >>> struct net_device *dev) >>> return NETDEV_TX_OK; >>> >>> dr

Re: [PATCH] net/dsa: remove unused macros to tame gcc warning

2020-11-06 Thread Alex Shi
在 2020/11/6 下午2:36, Joe Perches 写道: > On Fri, 2020-11-06 at 13:37 +0800, Alex Shi wrote: >> There are some macros unused, they causes much gcc warnings. Let's >> remove them to tame gcc. > > I believe these to be essentially poor warnings. > > Aren't these warnings generated only when adding

Re: [net 21/27] can: mcp251xfd: mcp251xfd_regmap_crc_read(): increase severity of CRC read error messages

2020-11-06 Thread Marc Kleine-Budde
On 11/5/20 7:14 PM, Manivannan Sadhasivam wrote: > On Thu, Nov 05, 2020 at 05:39:31PM +0100, Marc Kleine-Budde wrote: >> On 11/5/20 5:24 PM, Manivannan Sadhasivam wrote: >>> Hi Marc, >>> >>> On Tue, Nov 03, 2020 at 11:06:30PM +0100, Marc Kleine-Budde wrote: During debugging it turned out that

[PATCH] netfilter: remove unused macro DUMP_INIT to tame gcc

2020-11-06 Thread Alex Shi
net/netfilter/ipset/ip_set_core.c:1416:0: warning: macro "DUMP_INIT" is not used [-Wunused-macros] This macro unused and cause above warning. So let's remove it. Signed-off-by: Alex Shi Cc: Pablo Neira Ayuso Cc: Jozsef Kadlecsik Cc: Florian Westphal Cc: "David S. Miller" Cc: netfilter-de

RE: [PATCH net-next v2 6/7] drivers: net: smc911x: Fix cast from pointer to integer of different size

2020-11-06 Thread David Laight
From: Jakub Kicinski > Sent: 05 November 2020 22:47 > > On Wed, 4 Nov 2020 16:48:57 +0100 Andrew Lunn wrote: > > - buf = (char*)((u32)skb->data & ~0x3); > > - len = (skb->len + 3 + ((u32)skb->data & 3)) & ~0x3; > > - cmdA = (((u32)skb->data & 0x3) << 16) | > > + offset = (unsigned long)sk

Re: [PATCHv3 iproute2-next 0/5] iproute2: add libbpf support

2020-11-06 Thread Jiri Benc
On Thu, 5 Nov 2020 12:19:00 -0800, Andrii Nakryiko wrote: > I'll just quote myself here for your convenience. Sorry, I missed your original email for some reason. > Submodule is a way that I know of to make this better for end users. > If there are other ways to pull this off with shared libr

Re: [PATCH] sctp: Fix sending when PMTU is less than SCTP_DEFAULT_MINSEGMENT

2020-11-06 Thread Marcelo Ricardo Leitner
On Thu, Nov 05, 2020 at 11:39:47AM +0100, Petr Malat wrote: > Function sctp_dst_mtu() never returns lower MTU than > SCTP_TRUNC4(SCTP_DEFAULT_MINSEGMENT) even when the actual MTU is less, > in which case we rely on the IP fragmentation and must enable it. This should be being handled at sctp_packe

[PATCH] trace: Fix passing zero to 'PTR_ERR' warning

2020-11-06 Thread Wang Qing
Fix smatch warning. Signed-off-by: Wang Qing --- kernel/trace/bpf_trace.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kernel/trace/bpf_trace.c b/kernel/trace/bpf_trace.c index 4517c8b..2cb9c45 --- a/kernel/trace/bpf_trace.c +++ b/kernel/trace/bpf_trace.c @@ -1198,7 +1198,

RE: [PATCH net-next v2 1/7] drivers: net: smc91x: Fix set but unused W=1 warning

2020-11-06 Thread David Laight
From: Jakub Kicinski > Sent: 05 November 2020 22:38 > On Wed, 4 Nov 2020 16:48:52 +0100 Andrew Lunn wrote: > > drivers/net/ethernet/smsc/smc91x.c:706:51: warning: variable ‘pkt_len’ set > > but not used [-Wunused- > but-set-variable] > > 706 | unsigned int saved_packet, packet_no, tx_status, p

Re: [PATCH] net/dsa: remove unused macros to tame gcc warning

2020-11-06 Thread Joe Perches
On Fri, 2020-11-06 at 16:28 +0800, Alex Shi wrote: > > 在 2020/11/6 下午2:36, Joe Perches 写道: > > On Fri, 2020-11-06 at 13:37 +0800, Alex Shi wrote: > > > There are some macros unused, they causes much gcc warnings. Let's > > > remove them to tame gcc. > > > > I believe these to be essentially poor

Re: lan78xx: /sys/class/net/eth0/carrier stuck at 1

2020-11-06 Thread Juerg Haefliger
On Tue, 3 Nov 2020 16:27:23 +0100 Andrew Lunn wrote: > On Tue, Nov 03, 2020 at 01:47:12PM +0100, Juerg Haefliger wrote: > > On Fri, 23 Oct 2020 15:05:19 +0200 > > Andrew Lunn wrote: > > > > > On Fri, Oct 23, 2020 at 08:29:59AM +0200, Juerg Haefliger wrote: > > > > On Wed, 21 Oct 2020 21:35:

Re: [PATCH v3 net-next 2/2] net/sched: act_frag: add implict packet fragment support.

2020-11-06 Thread Marcelo Ricardo Leitner
On Thu, Nov 05, 2020 at 06:41:33PM +0800, we...@ucloud.cn wrote: > From: wenxu I see Davide's and Jakub's comments. Other than those, I don't have further comments. LGTM!

Re: [PATCH] net/dsa: remove unused macros to tame gcc warning

2020-11-06 Thread Alex Shi
在 2020/11/6 下午4:52, Joe Perches 写道: > On Fri, 2020-11-06 at 16:28 +0800, Alex Shi wrote: >> >> 在 2020/11/6 下午2:36, Joe Perches 写道: >>> On Fri, 2020-11-06 at 13:37 +0800, Alex Shi wrote: There are some macros unused, they causes much gcc warnings. Let's remove them to tame gcc. >>> >>>

Re: [PATCHv3 iproute2-next 0/5] iproute2: add libbpf support

2020-11-06 Thread Jiri Benc
On Thu, 5 Nov 2020 12:45:39 -0800, Andrii Nakryiko wrote: > That's not true. If you need new functionality like BTF, CO-RE, > function-by-function verification, etc., then yes, you have to update > kernel, compiler, libbpf, sometimes pahole. But if you have an BPF > application that doesn't use and

[PATCHv2 net 0/2] Remove unused test_ipip.sh test and add missed ip6ip6 test

2020-11-06 Thread Hangbin Liu
In comment 173ca26e9b51 ("samples/bpf: add comprehensive ipip, ipip6, ip6ip6 test") we added some bpf tunnel tests. In commit 933a741e3b82 ("selftests/bpf: bpf tunnel test.") when we moved it to the current folder, we missed some points: 1. ip6ip6 test is not added 2. forgot to remove test_ipip.sh

[PATCHv2 net 1/2] selftest/bpf: add missed ip6ip6 test back

2020-11-06 Thread Hangbin Liu
In comment 173ca26e9b51 ("samples/bpf: add comprehensive ipip, ipip6, ip6ip6 test") we added ip6ip6 test for bpf tunnel testing. But in commit 933a741e3b82 ("selftests/bpf: bpf tunnel test.") when we moved it to the current folder, we didn't add it. This patch add the ip6ip6 test back to bpf tunne

[PATCHv2 net 2/2] samples/bpf: remove unused test_ipip.sh

2020-11-06 Thread Hangbin Liu
The tcbpf2_kern.o and related kernel sections are moved to bpf selftest folder since b05cd7404323 ("samples/bpf: remove the bpf tunnel testsuite."). Remove this one as well. Fixes: b05cd7404323 ("samples/bpf: remove the bpf tunnel testsuite.") Signed-off-by: Hangbin Liu --- v2: move test_tunnel_

RE: [PATCH net-next] net: x25_asy: Delete the x25_asy driver

2020-11-06 Thread David Laight
From: Xie He > Sent: 05 November 2020 22:47 > > On Thu, Nov 5, 2020 at 12:40 PM Arnd Bergmann wrote: > > > > > I think this driver never worked. Looking at the original code in > > > Linux 2.1.31, it already has the problems I fixed in commit > > > 8fdcabeac398. > > > > > > I guess when people (o

[PATCH v4 net-next 1/2] net/sched: act_mirred: refactor the handle of xmit

2020-11-06 Thread wenxu
From: wenxu This one is prepare for the next patch. Signed-off-by: wenxu --- v4: no change include/net/sch_generic.h | 5 - net/sched/act_mirred.c| 21 +++-- 2 files changed, 15 insertions(+), 11 deletions(-) diff --git a/include/net/sch_generic.h b/include/net/sch_g

[PATCH v4 net-next 2/2] net/sched: act_frag: add implict packet fragment support.

2020-11-06 Thread wenxu
From: wenxu Currently kernel tc subsystem can do conntrack in act_ct. But when several fragment packets go through the act_ct, function tcf_ct_handle_fragments will defrag the packets to a big one. But the last action will redirect mirred to a device which maybe lead the reassembly big packet ove

[PATCH] samples/bpf: remove duplicate include

2020-11-06 Thread menglong8 . dong
From: Menglong Dong Obviously, 'bpf/bpf.h' in 'samples/bpf/hbm.c' is duplicated. Signed-off-by: Menglong Dong --- samples/bpf/hbm.c | 1 - 1 file changed, 1 deletion(-) diff --git a/samples/bpf/hbm.c b/samples/bpf/hbm.c index ff4c533..400e741 100644 --- a/samples/bpf/hbm.c +++ b/samples/bpf/h

Re: [PATCH v4 net-next 1/2] net/sched: act_mirred: refactor the handle of xmit

2020-11-06 Thread Marcelo Ricardo Leitner
On Fri, Nov 06, 2020 at 05:14:15PM +0800, we...@ucloud.cn wrote: > From: wenxu > > This one is prepare for the next patch. > > Signed-off-by: wenxu Acked-by: Marcelo Ricardo Leitner

RE: [PATCH] net/dsa: remove unused macros to tame gcc warning

2020-11-06 Thread David Laight
From: Joe Perches > Sent: 06 November 2020 06:36 > > On Fri, 2020-11-06 at 13:37 +0800, Alex Shi wrote: > > There are some macros unused, they causes much gcc warnings. Let's > > remove them to tame gcc. > > I believe these to be essentially poor warnings. Indeed. One 'solution' is to move the

Re: [PATCH v4 net-next 2/2] net/sched: act_frag: add implict packet fragment support.

2020-11-06 Thread Marcelo Ricardo Leitner
On Fri, Nov 06, 2020 at 05:14:16PM +0800, we...@ucloud.cn wrote: > From: wenxu > > Currently kernel tc subsystem can do conntrack in act_ct. But when several > fragment packets go through the act_ct, function tcf_ct_handle_fragments > will defrag the packets to a big one. But the last action will

[PATCH net-next 1/1] stmmac: intel: change all EHL/TGL to auto detect phy addr

2020-11-06 Thread Wong Vee Khee
From: Voon Weifeng Set all EHL/TGL phy_addr to -1 so that the driver will automatically detect it at run-time by probing all the possible 32 addresses. Signed-off-by: Voon Weifeng Signed-off-by: Wong Vee Khee --- drivers/net/ethernet/stmicro/stmmac/dwmac-intel.c | 6 +- 1 file changed, 1

Re: [PATCH] sctp: Fix sending when PMTU is less than SCTP_DEFAULT_MINSEGMENT

2020-11-06 Thread Petr Malat
On Fri, Nov 06, 2020 at 05:46:34AM -0300, Marcelo Ricardo Leitner wrote: > On Thu, Nov 05, 2020 at 11:39:47AM +0100, Petr Malat wrote: > > Function sctp_dst_mtu() never returns lower MTU than > > SCTP_TRUNC4(SCTP_DEFAULT_MINSEGMENT) even when the actual MTU is less, > > in which case we rely on the

Re: [PATCH] sctp: Fix sending when PMTU is less than SCTP_DEFAULT_MINSEGMENT

2020-11-06 Thread Marcelo Ricardo Leitner
On Fri, Nov 06, 2020 at 10:48:24AM +0100, Petr Malat wrote: > On Fri, Nov 06, 2020 at 05:46:34AM -0300, Marcelo Ricardo Leitner wrote: > > On Thu, Nov 05, 2020 at 11:39:47AM +0100, Petr Malat wrote: > > > Function sctp_dst_mtu() never returns lower MTU than > > > SCTP_TRUNC4(SCTP_DEFAULT_MINSEGMENT

WARNING: bad unlock balance in ieee80211_unregister_hw

2020-11-06 Thread syzbot
Hello, syzbot found the following issue on: HEAD commit:cb5dc5b0 Merge branch 'bpf: safeguard hashtab locking in N.. git tree: bpf-next console output: https://syzkaller.appspot.com/x/log.txt?x=13498a0c50 kernel config: https://syzkaller.appspot.com/x/.config?x=58a4ca757d776bfe das

[PATCH V5 2/5] dt-bindings: can: flexcan: add fsl,scu-index property to indicate a resource

2020-11-06 Thread Joakim Zhang
For SoCs with SCU support, need setup stop mode via SCU firmware, so this property can help indicate a resource in SCU firmware. Signed-off-by: Joakim Zhang --- .../devicetree/bindings/net/can/fsl,flexcan.yaml | 11 +++ 1 file changed, 11 insertions(+) diff --git a/Documentation/de

[PATCH V5 3/5] can: flexcan: rename macro FLEXCAN_QUIRK_SETUP_STOP_MODE -> FLEXCAN_QUIRK_SETUP_STOP_MODE_GPR

2020-11-06 Thread Joakim Zhang
This patch intends to rename FLEXCAN_QUIRK_SETUP_STOP_MODE quirk to FLEXCAN_QUIRK_SETUP_STOP_MODE_GRP for non-scu SoCs, coming patch will add quirk for scu SoCs. For non-scu SoCs, setup stop mode with GPR register. For scu SoCs, setup stop mode with SCU firmware. Signed-off-by: Joakim Zhang ---

[PATCH V5 5/5] can: flexcan: add CAN wakeup function for i.MX8QM

2020-11-06 Thread Joakim Zhang
The System Controller Firmware (SCFW) is a low-level system function which runs on a dedicated Cortex-M core to provide power, clock, and resource management. It exists on some i.MX8 processors. e.g. i.MX8QM (QM, QP), and i.MX8QX (QXP, DX). SCU driver manages the IPC interface between host CPU and

[PATCH V5 4/5] dt-bindings: firmware: add IMX_SC_R_CAN(x) macro for CAN

2020-11-06 Thread Joakim Zhang
Add IMX_SC_R_CAN(x) macro for CAN. Suggested-by: Marc Kleine-Budde Acked-by: Shawn Guo Signed-off-by: Joakim Zhang --- include/dt-bindings/firmware/imx/rsrc.h | 1 + 1 file changed, 1 insertion(+) diff --git a/include/dt-bindings/firmware/imx/rsrc.h b/include/dt-bindings/firmware/imx/rsrc.h

[PATCH V5 0/5] can: flexcan: add stop mode support for i.MX8QM

2020-11-06 Thread Joakim Zhang
Add stop mode support for i.MX8QM. ChangeLogs: V4->V5: * remove patch:firmware: imx: always export SCU symbols, since it done by commit: 95de5094f5ac firmware: imx: add dummy functions * rebase to fsl,flexcan.yaml V3->V4: * can_idx->scu_idx. * return imx_sc

[PATCH V5 1/5] dt-bindings: can: flexcan: fix fsl,clk-source property

2020-11-06 Thread Joakim Zhang
Correct fsl,clk-source example since flexcan driver uses "of_property_read_u8" to get this property. Fixes: 9d733992772d ("dt-bindings: can: flexcan: add PE clock source property to device tree") Signed-off-by: Joakim Zhang --- Documentation/devicetree/bindings/net/can/fsl,flexcan.yaml | 4 ++--

Re: [PATCH net-next] net: x25_asy: Delete the x25_asy driver

2020-11-06 Thread Xie He
On Fri, Nov 6, 2020 at 1:03 AM David Laight wrote: > > Hmmm LAPB would expect to have an X.25 level 3 and maybe ISO > transport (class 0, 2 or 3) sat on top of it. I actually used AF_PACKET sockets to transport data directly over LAPB and it worked. LAPB doesn't need anything from layer 3. I

Re: INFO: rcu detected stall in ip_list_rcv

2020-11-06 Thread David Howells
#syz fix: afs: Fix cell removal

Re: [PATCH V5 0/5] can: flexcan: add stop mode support for i.MX8QM

2020-11-06 Thread Marc Kleine-Budde
On 11/6/20 11:56 AM, Joakim Zhang wrote: > Add stop mode support for i.MX8QM. > > ChangeLogs: > V4->V5: > * remove patch:firmware: imx: always export SCU symbols, since > it done by commit: 95de5094f5ac firmware: imx: add dummy functions > * rebase to fsl,flexcan.yaml > > V3->V4

Re: [PATCH] net/ethernet: update ret when ptp_clock is ERROR

2020-11-06 Thread Grygorii Strashko
On 06/11/2020 09:56, Wang Qing wrote: We always have to update the value of ret, otherwise the error value may be the previous one. Signed-off-by: Wang Qing --- drivers/net/ethernet/ti/am65-cpts.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/net/ethernet

Re: INFO: rcu detected stall in security_file_open (3)

2020-11-06 Thread David Howells
#syz fix: afs: Fix cell removal

Re: [PATCH] net/ethernet: update ret when ptp_clock is ERROR

2020-11-06 Thread Arnd Bergmann
On Fri, Nov 6, 2020 at 12:35 PM Grygorii Strashko wrote: > On 06/11/2020 09:56, Wang Qing wrote: > > +++ b/drivers/net/ethernet/ti/am65-cpts.c > > @@ -1001,8 +1001,7 @@ struct am65_cpts *am65_cpts_create(struct device > > *dev, void __iomem *regs, > > there is > cpts->ptp_clock = ptp_clo

[PATCH net 2/2] MAINTAINERS: remove Ursula Braun as s390 network maintainer

2020-11-06 Thread Julian Wiedmann
From: Ursula Braun I am retiring soon. Thus this patch removes myself from the MAINTAINERS file (s390 network). Signed-off-by: Ursula Braun [jwi: fix up the subject] Signed-off-by: Julian Wiedmann --- MAINTAINERS | 3 --- 1 file changed, 3 deletions(-) diff --git a/MAINTAINERS b/MAINTAINERS

[PATCH net 0/2] net/iucv: fixes 2020-11-06

2020-11-06 Thread Julian Wiedmann
Hi Jakub, please apply the following patch series to netdev's net tree. One fix in the shutdown path for af_iucv sockets. This is relevant for stable as well. Also sending along an update for the Maintainers file. Thanks, Julian Ursula Braun (2): net/af_iucv: fix null pointer dereference on s

[PATCH net 1/2] net/af_iucv: fix null pointer dereference on shutdown

2020-11-06 Thread Julian Wiedmann
From: Ursula Braun syzbot reported the following KASAN finding: BUG: KASAN: nullptr-dereference in iucv_send_ctrl+0x390/0x3f0 net/iucv/af_iucv.c:385 Read of size 2 at addr 021e by task syz-executor907/519 CPU: 0 PID: 519 Comm: syz-executor907 Not tainted 5.9.0-syzkaller-07043-gbcf

Re: [PATCH] net/ethernet: update ret when ptp_clock is ERROR

2020-11-06 Thread Kurt Kanzenbach
On Fri Nov 06 2020, Arnd Bergmann wrote: > On Fri, Nov 6, 2020 at 12:35 PM Grygorii Strashko > wrote: >> On 06/11/2020 09:56, Wang Qing wrote: > >> > +++ b/drivers/net/ethernet/ti/am65-cpts.c >> > @@ -1001,8 +1001,7 @@ struct am65_cpts *am65_cpts_create(struct device >> > *dev, void __iomem *regs

[PATCH net v2] ipv6/netfilter: Discard first fragment not including all headers

2020-11-06 Thread Georg Kohmann
Packets are processed even though the first fragment don't include all headers through the upper layer header. This breaks TAHI IPv6 Core Conformance Test v6LC.1.3.6. Referring to RFC8200 SECTION 4.5: "If the first fragment does not include all headers through an Upper-Layer header, then that frag

Re: [net-next v4 8/8] net: xfrm: convert tasklets to use new tasklet_setup() API

2020-11-06 Thread Steffen Klassert
On Thu, Nov 05, 2020 at 04:48:18PM -0800, Jakub Kicinski wrote: > On Tue, 3 Nov 2020 14:48:23 +0530 Allen Pais wrote: > > From: Allen Pais > > > > In preparation for unconditionally passing the > > struct tasklet_struct pointer to all tasklet > > callbacks, switch to using the new tasklet_setup(

Re: [PATCH] net/ieee802154: remove unused macros to tame gcc

2020-11-06 Thread Stefan Schmidt
Hello. On 06.11.20 09:10, Alex Shi wrote: Signed-off-by: Alex Shi Cc: Alexander Aring Cc: Stefan Schmidt Cc: "David S. Miller" Cc: Jakub Kicinski Cc: linux-w...@vger.kernel.org Cc: netdev@vger.kernel.org Cc: linux-ker...@vger.kernel.org --- net/ieee802154/nl802154.c | 4 1 file chan

Re: [RESEND PATCH] net: macb: fix NULL dereference due to no pcs_config method

2020-11-06 Thread Nicolas Ferre
On 05/11/2020 at 18:58, Parshuram Thombare wrote: This patch fixes NULL pointer dereference due to NULL pcs_config in pcs_ops. Reported-by: Nicolas Ferre Link: https://lore.kernel.org/netdev/2db854c7-9ffb-328a-f346-f68982723...@microchip.com/ Signed-off-by: Parshuram Thombare Acked-by: Nico

[PATCH v2] lan743x: correctly handle chips with internal PHY

2020-11-06 Thread Sven Van Asbroeck
From: Sven Van Asbroeck Commit 6f197fb63850 ("lan743x: Added fixed link and RGMII support") assumes that chips with an internal PHY will never have a devicetree entry. This is incorrect: even for these chips, a devicetree entry can be useful e.g. to pass the mac address from bootloader to chip:

Re: [PATCH] net/dsa: remove unused macros to tame gcc warning

2020-11-06 Thread Andrew Lunn
On Fri, Nov 06, 2020 at 01:37:30PM +0800, Alex Shi wrote: > There are some macros unused, they causes much gcc warnings. Let's > remove them to tame gcc. > > net/dsa/tag_brcm.c:51:0: warning: macro "BRCM_EG_RC_SWITCH" is not used > [-Wunused-macros] > net/dsa/tag_brcm.c:53:0: warning: macro "BRCM_

Re: [PATCH] net/ethernet: update ret when ptp_clock is ERROR

2020-11-06 Thread Grygorii Strashko
On 06/11/2020 14:58, Kurt Kanzenbach wrote: On Fri Nov 06 2020, Arnd Bergmann wrote: On Fri, Nov 6, 2020 at 12:35 PM Grygorii Strashko wrote: On 06/11/2020 09:56, Wang Qing wrote: +++ b/drivers/net/ethernet/ti/am65-cpts.c @@ -1001,8 +1001,7 @@ struct am65_cpts *am65_cpts_create(struct de

RE: [PATCH net-next v2 6/7] drivers: net: smc911x: Fix cast from pointer to integer of different size

2020-11-06 Thread Nicolas Pitre
On Fri, 6 Nov 2020, David Laight wrote: > From: Jakub Kicinski > > Sent: 05 November 2020 22:47 > > > > On Wed, 4 Nov 2020 16:48:57 +0100 Andrew Lunn wrote: > > > - buf = (char*)((u32)skb->data & ~0x3); > > > - len = (skb->len + 3 + ((u32)skb->data & 3)) & ~0x3; > > > - cmdA = (((u32)skb->data &

Re: linux-next: Tree for Nov 3 (drivers/net/ethernet/marvell/prestera/prestera_switchdev.o)

2020-11-06 Thread Vadym Kochan
Hi Randy, Randy Dunlap writes: > On 11/2/20 11:19 PM, Stephen Rothwell wrote: >> Hi all, >> >> Changes since 20201102: >> > > on x86_64: > > when CONFIG_BRIDGE=m: > > ld: drivers/net/ethernet/marvell/prestera/prestera_switchdev.o: in function > `prestera_bridge_port_event': > prestera_switc

Re: [PATCHv3 iproute2-next 0/5] iproute2: add libbpf support

2020-11-06 Thread Jamal Hadi Salim
On 2020-11-05 4:01 p.m., Andrii Nakryiko wrote: On Thu, Nov 5, 2020 at 6:05 AM Jamal Hadi Salim wrote: On 2020-11-04 10:19 p.m., David Ahern wrote: [..] [..] 2cents feedback from a dabbler in ebpf on user experience: What David described above *has held me back*. Over time it seems thing

RE: [PATCH net-next v2 6/7] drivers: net: smc911x: Fix cast from pointer to integer of different size

2020-11-06 Thread David Laight
From: Nicolas Pitre > Sent: 06 November 2020 15:06 > > On Fri, 6 Nov 2020, David Laight wrote: > > > From: Jakub Kicinski > > > Sent: 05 November 2020 22:47 > > > > > > On Wed, 4 Nov 2020 16:48:57 +0100 Andrew Lunn wrote: > > > > - buf = (char*)((u32)skb->data & ~0x3); > > > > - len

Re: [RFC, net-next 2/3] net: dsa: felix: add preempt queues set support for vsc9959

2020-11-06 Thread Vladimir Oltean
On Tue, Oct 20, 2020 at 12:04:57PM +0800, Xiaoliang Yang wrote: > +static int vsc9959_port_get_preempt(struct ocelot *ocelot, int port, > + struct ethtool_fp *fpcmd) > +{ > + struct ocelot_port *ocelot_port = ocelot->ports[port]; > + u32 val; > + > + val

[PATCH RFC v2] ipvs: add genetlink cmd to dump all services and destinations

2020-11-06 Thread Cezar Sa Espinola
A common operation for userspace applications managing ipvs is to dump all services and all destinations and then sort out what needs to be done. Previously this could only be accomplished by issuing 1 netlink IPVS_CMD_GET_SERVICE dump command followed by N IPVS_CMD_GET_DEST dump commands. For a dy

RE: [PATCH net-next v2 6/7] drivers: net: smc911x: Fix cast from pointer to integer of different size

2020-11-06 Thread Nicolas Pitre
On Fri, 6 Nov 2020, David Laight wrote: > From: Nicolas Pitre > > Sent: 06 November 2020 15:06 > > > > On Fri, 6 Nov 2020, David Laight wrote: > > > > > From: Jakub Kicinski > > > > Sent: 05 November 2020 22:47 > > > > > > > > On Wed, 4 Nov 2020 16:48:57 +0100 Andrew Lunn wrote: > > > > > -

Re: [PATCH v10 1/2] bus: mhi: Add mhi_queue_is_full function

2020-11-06 Thread Jakub Kicinski
On Fri, 6 Nov 2020 10:43:53 +0530 Manivannan Sadhasivam wrote: > On Thu, Nov 05, 2020 at 04:57:08PM -0800, Jakub Kicinski wrote: > > On Tue, 3 Nov 2020 18:23:53 +0100 Loic Poulain wrote: > > > This function can be used by client driver to determine whether it's > > > possible to queue new elemen

Re: [PATCH v2] net/x25: Fix null-ptr-deref in x25_connect

2020-11-06 Thread Jakub Kicinski
On Fri, 06 Nov 2020 07:23:05 +0100 Martin Schiller wrote: > On 2020-10-06 07:45, Martin Schiller wrote: > > This fixes a regression for blocking connects introduced by commit > > 4becb7ee5b3d ("net/x25: Fix x25_neigh refcnt leak when x25 > > disconnect"). > > > > The x25->neighbour is already set

[PATCH net] net: marvell: prestera: fix compilation with CONFIG_BRIDGE=m

2020-11-06 Thread Vadym Kochan
With CONFIG_BRIDGE=m the compilation fails: ld: drivers/net/ethernet/marvell/prestera/prestera_switchdev.o: in function `prestera_bridge_port_event': prestera_switchdev.c:(.text+0x2ebd): undefined reference to `br_vlan_enabled' in case the driver is statically enabled. Fix it by adding

Re: [PATCH] net/xdp: remove unused macro REG_STATE_NEW

2020-11-06 Thread Jesper Dangaard Brouer
On Fri, 6 Nov 2020 13:43:51 +0800 Alex Shi wrote: > To tame gcc warning on it: > net/core/xdp.c:20:0: warning: macro "REG_STATE_NEW" is not used > [-Wunused-macros] Hmm... REG_STATE_NEW is zero, so it is implicitly set via memset zero. But it is true that it is technically not directly used or

Re: [RESEND PATCH] bonding: wait for sysfs kobject destruction before freeing struct slave

2020-11-06 Thread Eric Dumazet
On 11/5/20 7:11 PM, Jamie Iles wrote: > Hi Eric, > > On Thu, Nov 05, 2020 at 01:49:03PM +0100, Eric Dumazet wrote: >> On 11/5/20 9:41 AM, Jamie Iles wrote: >>> syzkaller found that with CONFIG_DEBUG_KOBJECT_RELEASE=y, releasing a >>> struct slave device could result in the following splat: >>>

Re: [PATCH net-next v2 03/10] tun: switch to net core provided statistics counters

2020-11-06 Thread Jakub Kicinski
On Fri, 6 Nov 2020 09:27:45 +0100 Heiner Kallweit wrote: > On 06.11.2020 08:48, Heiner Kallweit wrote: > > On 06.11.2020 02:14, Jakub Kicinski wrote: > >> On Wed, 4 Nov 2020 15:25:24 +0100 Heiner Kallweit wrote: > >>> @@ -1066,7 +1054,7 @@ static netdev_tx_t tun_net_xmit(struct sk_buff > >>> *

Re: [PATCH v10 1/2] bus: mhi: Add mhi_queue_is_full function

2020-11-06 Thread Manivannan Sadhasivam
On 6 November 2020 9:34:45 PM IST, Jakub Kicinski wrote: >On Fri, 6 Nov 2020 10:43:53 +0530 Manivannan Sadhasivam wrote: >> On Thu, Nov 05, 2020 at 04:57:08PM -0800, Jakub Kicinski wrote: >> > On Tue, 3 Nov 2020 18:23:53 +0100 Loic Poulain wrote: >> > > This function can be used by client dr

Re: [PATCH v10 1/2] bus: mhi: Add mhi_queue_is_full function

2020-11-06 Thread Jakub Kicinski
On Fri, 06 Nov 2020 21:58:12 +0530 Manivannan Sadhasivam wrote: >>> Since you've applied now, what would you propose? >> >> Do you need mhi_queue_is_full() in other branches, or are you just >> concerned about the conflicts? > > Yes, I need this patch in mhi-next. > >> I'm assuming the concern

Re: [PATCH] net/dsa: remove unused macros to tame gcc warning

2020-11-06 Thread Florian Fainelli
On 11/6/2020 6:18 AM, Andrew Lunn wrote: > On Fri, Nov 06, 2020 at 01:37:30PM +0800, Alex Shi wrote: >> There are some macros unused, they causes much gcc warnings. Let's >> remove them to tame gcc. >> >> net/dsa/tag_brcm.c:51:0: warning: macro "BRCM_EG_RC_SWITCH" is not used >> [-Wunused-macros

Re: [PATCH v2 iproute2-next] bridge: add support for L2 multicast groups

2020-11-06 Thread David Ahern
On 10/29/20 4:28 PM, Vladimir Oltean wrote: > @@ -168,9 +176,14 @@ static void print_mdb_entry(FILE *f, int ifindex, const > struct br_mdb_entry *e, > print_string(PRINT_ANY, "port", " port %s", >ll_index_to_name(e->ifindex)); > > + if (af == AF_INET || af == AF_INE

RE: [PATCH net-next 2/3] drivers: net: xilinx_emaclite: Fix -Wpointer-to-int-cast warnings with W=1

2020-11-06 Thread Radhey Shyam Pandey
> -Original Message- > From: Andrew Lunn > Sent: Wednesday, November 4, 2020 4:58 AM > To: Radhey Shyam Pandey > Cc: Michal Simek ; Jakub Kicinski ; > netdev > Subject: Re: [PATCH net-next 2/3] drivers: net: xilinx_emaclite: Fix > -Wpointer- > to-int-cast warnings with W=1 > > > > > /

Re: [PATCH net v2] ipv6/netfilter: Discard first fragment not including all headers

2020-11-06 Thread Jakub Kicinski
On Fri, 6 Nov 2020 14:08:03 +0100 Georg Kohmann wrote: > diff --git a/net/ipv6/reassembly.c b/net/ipv6/reassembly.c > index c8cf1bb..e6173f5 100644 > --- a/net/ipv6/reassembly.c > +++ b/net/ipv6/reassembly.c > @@ -325,7 +325,7 @@ static int ipv6_frag_rcv(struct sk_buff *skb) > const struct i

Re: [PATCH net 1/2] net/af_iucv: fix null pointer dereference on shutdown

2020-11-06 Thread Jakub Kicinski
On Fri, 6 Nov 2020 13:50:07 +0100 Julian Wiedmann wrote: > From: Ursula Braun > > syzbot reported the following KASAN finding: > > BUG: KASAN: nullptr-dereference in iucv_send_ctrl+0x390/0x3f0 > net/iucv/af_iucv.c:385 > Read of size 2 at addr 021e by task syz-executor907/519 > > C

[PATCH net] tunnels: Fix off-by-one in lower MTU bounds for ICMP/ICMPv6 replies

2020-11-06 Thread Stefano Brivio
Jianlin reports that a bridged IPv6 VXLAN endpoint, carrying IPv6 packets over a link with a PMTU estimation of exactly 1350 bytes, won't trigger ICMPv6 Packet Too Big replies when the encapsulated datagrams exceed said PMTU value. VXLAN over IPv6 adds 70 bytes of overhead, so an ICMPv6 reply indic

Re: [PATCH v2 net-next 6/8] ionic: flatten calls to ionic_lif_rx_mode

2020-11-06 Thread Jakub Kicinski
On Thu, 5 Nov 2020 16:12:18 -0800 Shannon Nelson wrote: > + work = kzalloc(sizeof(*work), GFP_ATOMIC); > + if (!work) { > + netdev_err(lif->netdev, "%s OOM\n", __func__); > + return; > +

Re: [PATCH v2 net-next 6/8] ionic: flatten calls to ionic_lif_rx_mode

2020-11-06 Thread Shannon Nelson
On 11/6/20 9:03 AM, Jakub Kicinski wrote: On Thu, 5 Nov 2020 16:12:18 -0800 Shannon Nelson wrote: + work = kzalloc(sizeof(*work), GFP_ATOMIC); + if (!work) { + netdev_err(lif->netdev, "%s OOM\n", __func__); +

[PATCH v2 1/5] net: qrtr: Fix port ID for control messages

2020-11-06 Thread Loic Poulain
The port ID for control messages was uncorrectly set with broadcast node ID value, causing message to be dropped on remote side since not passing packet filtering (cb->dst_port != QRTR_PORT_CTRL). Fixes: d27e77a3de28 ("net: qrtr: Reset the node and port ID of broadcast messages") Signed-off-by: L

[PATCH v2 0/5] net: qrtr: Add distant node support

2020-11-06 Thread Loic Poulain
QRTR protocol allows a node to communicate with an other non-immediate node via an intermdediate immediate node acting as a 'bridge': node-0 <=> node-1 <=> node-2 This is currently not supported in this upstream version and this series aim to fix that. This series is V2 because changes 1, 2 and

[PATCH v2 2/5] net: qrtr: Allow forwarded services

2020-11-06 Thread Loic Poulain
A remote endpoint (immediate neighbors node) can forward services from other nodes (non-immadiate), in that case ctrl packet node ID (offering distant service) can differ from the qrtr source node (forwarding the packet). Signed-off-by: Loic Poulain Reviewed-by: Bjorn Andersson Reviewed-by: Mani

[PATCH v2 5/5] net: qrtr: Release distant nodes along the bridge node

2020-11-06 Thread Loic Poulain
Distant QRTR nodes can be accessed via an other node that acts as a bridge. When the a QRTR endpoint associated to a bridge node is released, all the linked distant nodes should also be released. This patch fixes endpoint release by: - Submitting QRTR BYE message locally on behalf of all the nodes

[PATCH v2 4/5] net: qrtr: Add GFP flags parameter to qrtr_alloc_ctrl_packet

2020-11-06 Thread Loic Poulain
This will be requested for allocating control packet in atomic context. Signed-off-by: Loic Poulain --- net/qrtr/qrtr.c | 12 +++- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/net/qrtr/qrtr.c b/net/qrtr/qrtr.c index 1d12408..a05d01e 100644 --- a/net/qrtr/qrtr.c +++ b/net

[PATCH v2 3/5] net: qrtr: Allow non-immediate node routing

2020-11-06 Thread Loic Poulain
In order to reach non-immediate remote node services that are accessed through an intermediate node, the route to the remote node needs to be saved. E.g for a [node1 <=> node2 <=> node3] network - node2 forwards node3 service to node1 - node1 must save node2 as route for reaching node3 Signed-off

[PATCH net-next v3 2/4] net: socket: rework SIOC?IFMAP ioctls

2020-11-06 Thread Arnd Bergmann
From: Arnd Bergmann SIOCGIFMAP and SIOCSIFMAP currently require compat_alloc_user_space() and copy_in_user() for compat mode. Move the compat handling into the location where the structures are actually used, to avoid using those interfaces and get a clearer implementation. Signed-off-by: Arnd

[PATCH net-next v3 3/4] net: socket: simplify dev_ifconf handling

2020-11-06 Thread Arnd Bergmann
From: Arnd Bergmann The dev_ifconf() calling conventions make compat handling more complicated than necessary, simplify this by moving the in_compat_syscall() check into the function. The implementation can be simplified further, based on the knowledge that the dynamic registration is only ever u

[PATCH net-next v3 0/4] remove compat_alloc_user_space()

2020-11-06 Thread Arnd Bergmann
From: Arnd Bergmann This is the third version of my seires, now spanning four patches instead of two, with a new approach for handling struct ifreq compatibility after I realized that my earlier approach introduces additional problems. The idea here is to always push down the compat conversion d

[PATCH net-next v3 1/4] ethtool: improve compat ioctl handling

2020-11-06 Thread Arnd Bergmann
From: Arnd Bergmann The ethtool compat ioctl handling is hidden away in net/socket.c, which introduces a couple of minor oddities: - The implementation may end up diverging, as seen in the RXNFC extension in commit 84a1d9c48200 ("net: ethtool: extend RXNFC API to support RSS spreading of fil

[PATCH net-next v3 4/4] net: socket: rework compat_ifreq_ioctl()

2020-11-06 Thread Arnd Bergmann
From: Arnd Bergmann compat_ifreq_ioctl() is one of the last users of copy_in_user() and compat_alloc_user_space(), as it attempts to convert the 'struct ifreq' arguments from 32-bit to 64-bit format as used by dev_ioctl() and a couple of socket family specific interpretations. The current implem

Re: [PATCH net-next v2 1/7] drivers: net: smc91x: Fix set but unused W=1 warning

2020-11-06 Thread Jakub Kicinski
On Fri, 6 Nov 2020 08:48:47 + David Laight wrote: > > > +#define SMC_GET_PKT_HDR_STATUS(lp, status) > > > \ > > > + do {\ > > > + if (SMC_32BIT(lp)) {\ > > > +

Re: [PATCH net v2] ipv6/netfilter: Discard first fragment not including all headers

2020-11-06 Thread Georg Kohmann (geokohma)
On 06.11.2020 17:58, Jakub Kicinski wrote: > On Fri, 6 Nov 2020 14:08:03 +0100 Georg Kohmann wrote: >> diff --git a/net/ipv6/reassembly.c b/net/ipv6/reassembly.c >> index c8cf1bb..e6173f5 100644 >> --- a/net/ipv6/reassembly.c >> +++ b/net/ipv6/reassembly.c >> @@ -325,7 +325,7 @@ static int ipv6_fr

[PATCH net-next 2/2] selftests/net: test max_num_members, fanout_args in psock_fanout

2020-11-06 Thread Tanner Love
From: Tanner Love Add an additional control test that verifies: -specifying two different max_num_members values fails -specifying max_num_members > PACKET_FANOUT_MAX fails In datapath tests, set max_num_members to PACKET_FANOUT_MAX. Signed-off-by: Tanner Love --- tools/testing/selftests/net/

[PATCH net-next 0/2] net/packet: make packet_fanout.arr size configurable up to 64K

2020-11-06 Thread Tanner Love
From: Tanner Love First patch makes the change; second patch adds unit tests. Tanner Love (2): net/packet: make packet_fanout.arr size configurable up to 64K selftests/net: test max_num_members, fanout_args in psock_fanout include/uapi/linux/if_packet.h | 12 net/packet/af

[PATCH net-next 1/2] net/packet: make packet_fanout.arr size configurable up to 64K

2020-11-06 Thread Tanner Love
From: Tanner Love One use case of PACKET_FANOUT is lockless reception with one socket per CPU. 256 is a practical limit on increasingly many machines. Increase PACKET_FANOUT_MAX to 64K. Expand setsockopt PACKET_FANOUT to take an extra argument max_num_members. Also explicitly define a fanout_arg

Re: [PATCH v4 net-next 2/2] net/sched: act_frag: add implict packet fragment support.

2020-11-06 Thread Vlad Buslov
On Fri 06 Nov 2020 at 11:14, we...@ucloud.cn wrote: > From: wenxu > > Currently kernel tc subsystem can do conntrack in act_ct. But when several > fragment packets go through the act_ct, function tcf_ct_handle_fragments > will defrag the packets to a big one. But the last action will redirect > mi

[PATCH v4 net-next 0/5] xdp: introduce bulking for page_pool tx return path

2020-11-06 Thread Lorenzo Bianconi
XDP bulk APIs introduce a defer/flush mechanism to return pages belonging to the same xdp_mem_allocator object (identified via the mem.id field) in bulk to optimize I-cache and D-cache since xdp_return_frame is usually run inside the driver NAPI tx completion loop. Convert mvneta, mvpp2 and mlx5 dr

[PATCH v4 net-next 2/5] net: page_pool: add bulk support for ptr_ring

2020-11-06 Thread Lorenzo Bianconi
Introduce the capability to batch page_pool ptr_ring refill since it is usually run inside the driver NAPI tx completion loop. Suggested-by: Jesper Dangaard Brouer Signed-off-by: Lorenzo Bianconi --- include/net/page_pool.h | 26 net/core/page_pool.c| 66 +++

[PATCH v4 net-next 5/5] net: mlx5: add xdp tx return bulking support

2020-11-06 Thread Lorenzo Bianconi
Convert mlx5 driver to xdp_return_frame_bulk APIs. XDP_REDIRECT (upstream codepath): 8.5Mpps XDP_REDIRECT (upstream codepath + bulking APIs): 10.1Mpps Signed-off-by: Lorenzo Bianconi --- drivers/net/ethernet/mellanox/mlx5/core/en/xdp.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-)

  1   2   3   >