Re: [PATCH v3 2/2] vhost-vdpa: fix page pinning leakage in error path

2020-10-14 Thread Jason Wang
On 2020/10/14 上午7:42, si-wei liu wrote: So what I suggest is to fix the pinning leakage first and do the possible optimization on top (which is still questionable to me). OK. Unfortunately, this was picked and got merged in upstream. So I will post a follow up patch set to 1) revert the com

Re: [PATCH v2 bpf-next 3/4] selftests/bpf: Add profiler test

2020-10-14 Thread Song Liu
> On Oct 13, 2020, at 2:56 PM, Andrii Nakryiko > wrote: [...] > > I'd go with Kconfig + bpf_core_enum_value(), as it's shorter and > nicer. This compiles and works with my Kconfig, but I haven't checked > with CONFIG_CGROUP_PIDS defined. Tested with CONFIG_CGROUP_PIDS, it looks good. Tes

Re: [PATCH bpf-next] bpf: Fix register equivalence tracking.

2020-10-14 Thread Yonghong Song
On 10/14/20 10:46 PM, Yonghong Song wrote: On 10/14/20 10:56 AM, Alexei Starovoitov wrote: From: Alexei Starovoitov The 64-bit JEQ/JNE handling in reg_set_min_max() was clearing reg->id in either true or false branch. In the case 'if (reg->id)' check was done on the other branch the co

Re: [PATCH bpf-next] selftests/bpf: fix compilation error in progs/profiler.inc.h

2020-10-14 Thread Song Liu
> On Oct 14, 2020, at 9:29 PM, Alexei Starovoitov > wrote: > > On Tue, Oct 13, 2020 at 09:36:38PM -0700, Song Liu wrote: >> Fix the following error when compiling selftests/bpf >> >> progs/profiler.inc.h:246:5: error: redefinition of 'pids_cgrp_id' as >> different kind of symbol >> >> pids

Re: [PATCH bpf-next] bpf: Fix register equivalence tracking.

2020-10-14 Thread Yonghong Song
On 10/14/20 10:56 AM, Alexei Starovoitov wrote: From: Alexei Starovoitov The 64-bit JEQ/JNE handling in reg_set_min_max() was clearing reg->id in either true or false branch. In the case 'if (reg->id)' check was done on the other branch the counter part register would have reg->id == 0 when

Re: [PATCH bpf-next] bpf: Fix register equivalence tracking.

2020-10-14 Thread John Fastabend
Alexei Starovoitov wrote: > On Wed, Oct 14, 2020 at 09:27:17PM -0700, John Fastabend wrote: > > Alexei Starovoitov wrote: > > > On Wed, Oct 14, 2020 at 09:04:23PM -0700, John Fastabend wrote: > > > > Andrii Nakryiko wrote: > > > > > On Wed, Oct 14, 2020 at 10:59 AM Alexei Starovoitov > > > > > wro

Re: [Linux-kernel-mentees] [PATCH] net: rose: Fix Null pointer dereference in rose_send_frame()

2020-10-14 Thread Greg KH
On Thu, Oct 15, 2020 at 05:47:12AM +0530, Anmol Karn wrote: > In rose_send_frame(), when comparing two ax.25 addresses, it assigns > rose_call to > either global ROSE callsign or default port, but when the former block > triggers and > rose_call is assigned by (ax25_address *)neigh->dev->dev_ad

Re: [PATCH] net: sockmap: Don't call bpf_prog_put() on NULL pointer

2020-10-14 Thread John Fastabend
Jakub Sitnicki wrote: > On Mon, Oct 12, 2020 at 07:09 PM CEST, Alex Dewar wrote: > > If bpf_prog_inc_not_zero() fails for skb_parser, then bpf_prog_put() is > > called unconditionally on skb_verdict, even though it may be NULL. Fix > > and tidy up error path. > > > > Addresses-Coverity-ID: 1497799:

Re: [PATCH bpf-next] bpf: Fix register equivalence tracking.

2020-10-14 Thread Alexei Starovoitov
On Wed, Oct 14, 2020 at 09:27:17PM -0700, John Fastabend wrote: > Alexei Starovoitov wrote: > > On Wed, Oct 14, 2020 at 09:04:23PM -0700, John Fastabend wrote: > > > Andrii Nakryiko wrote: > > > > On Wed, Oct 14, 2020 at 10:59 AM Alexei Starovoitov > > > > wrote: > > > > > > > > > > From: Alexei S

Re: [PATCH v2 1/7] staging: qlge: replace ql_* with qlge_* to avoid namespace clashes with other qlogic drivers

2020-10-14 Thread Coiby Xu
On Thu, Oct 15, 2020 at 12:26:28PM +0800, Coiby Xu wrote: On Thu, Oct 15, 2020 at 10:01:36AM +0900, Benjamin Poirier wrote: On 2020-10-14 18:43 +0800, Coiby Xu wrote: To avoid namespace clashes with other qlogic drivers and also for the sake of naming consistency, use the "qlge_" prefix as sugg

Re: [PATCH bpf-next] selftests/bpf: fix compilation error in progs/profiler.inc.h

2020-10-14 Thread Alexei Starovoitov
On Tue, Oct 13, 2020 at 09:36:38PM -0700, Song Liu wrote: > Fix the following error when compiling selftests/bpf > > progs/profiler.inc.h:246:5: error: redefinition of 'pids_cgrp_id' as > different kind of symbol > > pids_cgrp_id is used in cgroup code, and included in vmlinux.h. Fix the > error

Re: [PATCH bpf-next] bpf: Fix register equivalence tracking.

2020-10-14 Thread John Fastabend
Alexei Starovoitov wrote: > On Wed, Oct 14, 2020 at 09:04:23PM -0700, John Fastabend wrote: > > Andrii Nakryiko wrote: > > > On Wed, Oct 14, 2020 at 10:59 AM Alexei Starovoitov > > > wrote: > > > > > > > > From: Alexei Starovoitov > > > > > > > > The 64-bit JEQ/JNE handling in reg_set_min_max() w

Re: [PATCH v2 2/7] staging: qlge: Initialize devlink health dump framework

2020-10-14 Thread Coiby Xu
On Wed, Oct 14, 2020 at 04:08:46PM +0300, Dan Carpenter wrote: On Wed, Oct 14, 2020 at 06:43:01PM +0800, Coiby Xu wrote: static int qlge_probe(struct pci_dev *pdev, const struct pci_device_id *pci_entry) { struct net_device *ndev = NULL; struct qlge_adapte

Re: [PATCH v2 1/7] staging: qlge: replace ql_* with qlge_* to avoid namespace clashes with other qlogic drivers

2020-10-14 Thread Coiby Xu
On Thu, Oct 15, 2020 at 10:01:36AM +0900, Benjamin Poirier wrote: On 2020-10-14 18:43 +0800, Coiby Xu wrote: To avoid namespace clashes with other qlogic drivers and also for the sake of naming consistency, use the "qlge_" prefix as suggested in drivers/staging/qlge/TODO. Suggested-by: Benjamin

Re: [PATCH bpf-next] selftests/bpf: fix compilation error in progs/profiler.inc.h

2020-10-14 Thread John Fastabend
Song Liu wrote: > > > > On Oct 13, 2020, at 9:36 PM, Song Liu wrote: > > > > Fix the following error when compiling selftests/bpf > > > > progs/profiler.inc.h:246:5: error: redefinition of 'pids_cgrp_id' as > > different kind of symbol > > > > pids_cgrp_id is used in cgroup code, and include

Re: [PATCH net-next] netfilter: restore NF_INET_NUMHOOKS

2020-10-14 Thread Jakub Kicinski
On Wed, 14 Oct 2020 21:34:32 +0200 Pablo Neira Ayuso wrote: > This definition is used by the iptables legacy UAPI, restore it. > > Fixes: d3519cb89f6d ("netfilter: nf_tables: add inet ingress support") > Reported-by: Jason A. Donenfeld > Tested-by: Jason A. Donenfeld > Signed-off-by: Pablo Neira

Re: [PATCH bpf-next] bpf: Fix register equivalence tracking.

2020-10-14 Thread Alexei Starovoitov
On Wed, Oct 14, 2020 at 09:04:23PM -0700, John Fastabend wrote: > Andrii Nakryiko wrote: > > On Wed, Oct 14, 2020 at 10:59 AM Alexei Starovoitov > > wrote: > > > > > > From: Alexei Starovoitov > > > > > > The 64-bit JEQ/JNE handling in reg_set_min_max() was clearing reg->id in > > > either > > >

Re: [PATCH bpf-next] bpf: Fix register equivalence tracking.

2020-10-14 Thread John Fastabend
Andrii Nakryiko wrote: > On Wed, Oct 14, 2020 at 10:59 AM Alexei Starovoitov > wrote: > > > > From: Alexei Starovoitov > > > > The 64-bit JEQ/JNE handling in reg_set_min_max() was clearing reg->id in > > either > > true or false branch. In the case 'if (reg->id)' check was done on the other > >

Re: [PATCH 1/2] dccp: ccid: move timers to struct dccp_sock

2020-10-14 Thread Jakub Kicinski
On Tue, 13 Oct 2020 19:18:48 +0200 Kleber Sacilotto de Souza wrote: > From: Thadeu Lima de Souza Cascardo > > When dccps_hc_tx_ccid is freed, ccid timers may still trigger. The reason > del_timer_sync can't be used is because this relies on keeping a reference > to struct sock. But as we keep a p

Re: [PATCH 2/2] Revert "dccp: don't free ccid2_hc_tx_sock struct in dccp_disconnect()"

2020-10-14 Thread Jakub Kicinski
On Tue, 13 Oct 2020 19:18:49 +0200 Kleber Sacilotto de Souza wrote: > From: Thadeu Lima de Souza Cascardo > > This reverts commit 2677d20677314101293e6da0094ede7b5526d2b1. > > This fixes an issue that after disconnect, dccps_hc_tx_ccid will still be > kept, allowing the socket to be reused as a

Re: [PATCH v1 1/6] staging: qlge: Initialize devlink health dump framework for the dlge driver

2020-10-14 Thread Coiby Xu
On Tue, Oct 13, 2020 at 09:37:04AM +0900, Benjamin Poirier wrote: On 2020-10-12 19:24 +0800, Coiby Xu wrote: [...] > I think, but didn't check in depth, that in those drivers, the devlink > device is tied to the pci device and can exist independently of the > netdev, at least in principle. > You

Re: [PATCH net-next] net: ptp: get rid of IPV4_HLEN() and OFF_IHL macros

2020-10-14 Thread Richard Cochran
On Wed, Oct 14, 2020 at 01:58:05PM +0200, Christian Eggers wrote: > Both macros are already marked for removal. I'm not sure what Daniel Borkmann meant by that comment, but ... > switch (type & PTP_CLASS_PMASK) { > case PTP_CLASS_IPV4: > - ptr += IPV4_HLEN(ptr) + UDP_HLEN;

Re: [PATCHv3 net-next 00/16] sctp: Implement RFC6951: UDP Encapsulation of SCTP

2020-10-14 Thread Jakub Kicinski
On Tue, 13 Oct 2020 15:27:25 +0800 Xin Long wrote: > Description From the RFC: > >The Main Reasons: > >o To allow SCTP traffic to pass through legacy NATs, which do not > provide native SCTP support as specified in [BEHAVE] and > [NATSUPP]. > >o To allow SCTP to be impl

Re: [ PATCH v2 0/2] ibmveth gso fix.

2020-10-14 Thread Jakub Kicinski
On Tue, 13 Oct 2020 16:20:12 -0700 David Wilder wrote: > The ibmveth driver is a virtual Ethernet driver used on IBM pSeries systems. > Gso packets can be sent between LPARS (virtual hosts) without segmentation, > by flagging gso packets using one of two methods depending on the firmware > version.

Re: [ PATCH v2 1/2] ibmveth: Switch order of ibmveth_helper calls.

2020-10-14 Thread Jakub Kicinski
On Tue, 13 Oct 2020 16:20:13 -0700 David Wilder wrote: > Fixes: 66aa0678efc2 ("ibmveth: Support to enable LSO/CSO for Trunk > VEA.") Please make sure Fixes tags are not wrapped in the future.

Re: selftests: netfilter: nft_nat.sh: /dev/stdin:2:9-15: Error: syntax error, unexpected counter

2020-10-14 Thread Naresh Kamboju
On Thu, 15 Oct 2020 at 01:00, Pablo Neira Ayuso wrote: > > On Wed, Oct 14, 2020 at 05:19:33PM +0530, Naresh Kamboju wrote: > > While running kselftest netfilter test on x86_64 devices linux next > > tag 20201013 kernel > > these errors are noticed. This not specific to kernel version we have > > n

Re: [net-next PATCH 06/10] octeontx2-af: Add NIX1 interfaces to NPC

2020-10-14 Thread Jakub Kicinski
On Tue, 13 Oct 2020 15:56:28 +0530 sundeep.l...@gmail.com wrote: > -static const struct npc_mcam_kex npc_mkex_default = { > +static struct npc_mcam_kex npc_mkex_default = { > .mkex_sign = MKEX_SIGN, > .name = "default", > .kpu_version = NPC_KPU_PROFILE_VER, Why is this no longer

Re: [PATCH 1/1] net: ftgmac100: Fix Aspeed ast2600 TX hang issue

2020-10-14 Thread Joel Stanley
On Thu, 15 Oct 2020 at 01:49, Dylan Hung wrote: > > > I was encountering this issue when I was running the iperf TX test. The > > symptom is the TX descriptors are consumed, but no complete packet is sent > > out. > > > > What parameters are you using for iperf? I did a lot of testing with > > ip

[PATCH v2] Add support for mv88e6393x family of Marvell.

2020-10-14 Thread Pavana Sharma
The Marvell 88E6393X device is a single-chip integration of a 11-port Ethernet switch with eight integrated Gigabit Ethernet (GbE) transceivers and three 10-Gigabit interfaces. This patch adds functionalities specific to mv88e6393x family (88E6393X, 88E6193X and 88E6191X) Signed-off-by: Pavana Sh

RE: [net] tipc: re-configure queue limit for broadcast link

2020-10-14 Thread Hoang Huu Le
Thanks for your reviewing. Yes, in this commit, we intend to fix the queue calculation limited, and, besides we're planning to fix both in another fix. However, it should be used the default (i.e BCLINK_WIN_DEFAULT) one. Since, we keep to choose fix window size for broadcast link. Regards, Hoang

Re: [Patch net v2] ip_gre: set dev->hard_header_len and dev->needed_headroom properly

2020-10-14 Thread Xie He
On Wed, Oct 14, 2020 at 6:38 PM Xie He wrote: > > On Wed, Oct 14, 2020 at 1:19 PM Willem de Bruijn > wrote: > > > > On Wed, Oct 14, 2020 at 3:48 PM Xie He wrote: > > > > > > I thought we agreed that ideally GRE devices would not have > > > header_ops. Currently GRE devices (in normal situations)

Re: [PATCH 1/1] net: ftgmac100: Fix Aspeed ast2600 TX hang issue

2020-10-14 Thread Joel Stanley
On Wed, 14 Oct 2020 at 13:32, Dylan Hung wrote: > > > The new HW arbitration feature on Aspeed ast2600 will cause MAC TX to > > > hang when handling scatter-gather DMA. Disable the problematic > > > feature by setting MAC register 0x58 bit28 and bit27. > > > > Hi Dylan, > > > > What are the sympt

RE: [PATCH 1/1] net: ftgmac100: Fix Aspeed ast2600 TX hang issue

2020-10-14 Thread Dylan Hung
> -Original Message- > From: Joel Stanley [mailto:j...@jms.id.au] > Sent: Thursday, October 15, 2020 6:31 AM > To: Dylan Hung > Cc: David S . Miller ; Jakub Kicinski > ; netdev@vger.kernel.org; Linux Kernel Mailing List > ; Po-Yu Chuang ; > linux-aspeed ; OpenBMC Maillist > ; BMC-SW > Sub

[Regression 5.9][Bisected 1df2bdba528b] Wifi GTK rekeying fails: Sending of EAPol packages broken

2020-10-14 Thread Thomas Deutschmann
Hi, after upgrading to linux-5.9.0 I noticed that my wifi got disassociated every 10 minutes when access point triggered rekeying for GTK. This happened with iwd but not with wpa_supplicant. iwd was logging wlan0: disassociated from aa:bb:cc:dd:ap:01 (Reason: 2=PREV_AUTH_NOT_VALID) wlan0: au

Re: [PATCH] net: phy: Prevent reporting advertised modes when autoneg is off

2020-10-14 Thread Russell King - ARM Linux admin
On Wed, Oct 14, 2020 at 04:39:47PM +0200, Lukasz Stelmach wrote: > It was <2020-10-14 śro 14:32>, when Russell King - ARM Linux admin wrote: > > In any case, the mii.c code does fill in the advertising mask even > > when autoneg is disabled, because, rightly or wrongly, the advertising > > mask con

Re: [PATCH net v3] net: fix pos incrementment in ipv6_route_seq_next

2020-10-14 Thread Andrii Nakryiko
On Wed, Oct 14, 2020 at 2:53 PM Yonghong Song wrote: > > Commit 4fc427e05158 ("ipv6_route_seq_next should increase position index") > tried to fix the issue where seq_file pos is not increased > if a NULL element is returned with seq_ops->next(). See bug > https://bugzilla.kernel.org/show_bug.cg

Re: [PATCH v2 20/20] ppc: propagate the calling conventions change down to csum_partial_copy_generic()

2020-10-14 Thread Al Viro
On Wed, Oct 14, 2020 at 03:51:00PM -0700, Linus Torvalds wrote: > On Wed, Oct 14, 2020 at 3:27 PM Jason A. Donenfeld wrote: > > > > This patch is causing crashes in WireGuard's CI over at > > https://www.wireguard.com/build-status/ . Apparently sending a simple > > network packet winds up triggeri

Re: [PATCH bpf-next] bpf: Fix register equivalence tracking.

2020-10-14 Thread Andrii Nakryiko
On Wed, Oct 14, 2020 at 10:59 AM Alexei Starovoitov wrote: > > From: Alexei Starovoitov > > The 64-bit JEQ/JNE handling in reg_set_min_max() was clearing reg->id in > either > true or false branch. In the case 'if (reg->id)' check was done on the other > branch the counter part register would ha

Re: [Patch net v2] ip_gre: set dev->hard_header_len and dev->needed_headroom properly

2020-10-14 Thread Xie He
On Wed, Oct 14, 2020 at 1:19 PM Willem de Bruijn wrote: > > On Wed, Oct 14, 2020 at 3:48 PM Xie He wrote: > > > > I thought we agreed that ideally GRE devices would not have > > header_ops. Currently GRE devices (in normal situations) indeed do not > > use header_ops (and use ARHPHRD_IPGRE as dev

[Linux-kernel-mentees] [PATCH] net: rose: Fix Null pointer dereference in rose_send_frame()

2020-10-14 Thread Anmol Karn
In rose_send_frame(), when comparing two ax.25 addresses, it assigns rose_call to either global ROSE callsign or default port, but when the former block triggers and rose_call is assigned by (ax25_address *)neigh->dev->dev_addr, a NULL pointer is dereferenced by 'neigh' when dereferencing 'de

Re: [PATCH] powerpc32: don't adjust unmoved stack pointer in csum_partial_copy_generic() epilogue

2020-10-14 Thread Linus Torvalds
Thanks - applied and pushed out. Linus

Re: [PATCH net-next] cxgb4: handle 4-tuple PEDIT to NAT mode translation

2020-10-14 Thread Jakub Kicinski
On Tue, 13 Oct 2020 15:01:29 +0530 Herat Ramani wrote: > The 4-tuple NAT offload via PEDIT always overwrites all the 4-tuple > fields even if they had not been explicitly enabled. If any fields in > the 4-tuple are not enabled, then the hardware overwrites the > disabled fields with zeros, instead

Re: [PATCH v2 1/7] staging: qlge: replace ql_* with qlge_* to avoid namespace clashes with other qlogic drivers

2020-10-14 Thread Benjamin Poirier
On 2020-10-14 18:43 +0800, Coiby Xu wrote: > To avoid namespace clashes with other qlogic drivers and also for the > sake of naming consistency, use the "qlge_" prefix as suggested in > drivers/staging/qlge/TODO. > > Suggested-by: Benjamin Poirier > Signed-off-by: Coiby Xu > --- > drivers/stagi

Re: [PATCH v2 20/20] ppc: propagate the calling conventions change down to csum_partial_copy_generic()

2020-10-14 Thread Linus Torvalds
On Wed, Oct 14, 2020 at 3:51 PM Linus Torvalds wrote: > > I think it's this instruction: > > addir1,r1,16 > > that should be removed from the function exit, because Al removed the > > - stwur1,-16(r1) > > on function entry. > > So I think you end up with a corrupt stack point

Re: [PATCH v2 20/20] ppc: propagate the calling conventions change down to csum_partial_copy_generic()

2020-10-14 Thread Linus Torvalds
On Wed, Oct 14, 2020 at 3:27 PM Jason A. Donenfeld wrote: > > This patch is causing crashes in WireGuard's CI over at > https://www.wireguard.com/build-status/ . Apparently sending a simple > network packet winds up triggering refcount_t's warn-on-saturate code. I Ouch. The C parts look fairly s

[PATCH net-next 9/9] netfilter: flowtable: add vlan support

2020-10-14 Thread Pablo Neira Ayuso
Add the vlan id and proto to the flow tuple to uniquely identify flows from the receive path. Store the vlan id and proto to set it accordingly from the transmit path. This patch includes support for two VLAN headers (Q-in-Q). Signed-off-by: Pablo Neira Ayuso --- include/net/netfilter/nf_flow_ta

[PATCH net-next 4/9] bridge: resolve forwarding path for bridge devices

2020-10-14 Thread Pablo Neira Ayuso
Add .ndo_fill_forward_path for bridge devices. Signed-off-by: Pablo Neira Ayuso --- include/linux/netdevice.h | 1 + net/bridge/br_device.c| 22 ++ 2 files changed, 23 insertions(+) diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h index 6a3370fafe4b..e

[PATCH net-next 5/9] netfilter: flowtable: use dev_fill_forward_path() to obtain ingress device

2020-10-14 Thread Pablo Neira Ayuso
The ingress device in the tuple is obtained from route in the reply direction. Use dev_fill_forward_path() instead to provide the real ingress device for this flow. Signed-off-by: Pablo Neira Ayuso --- include/net/netfilter/nf_flow_table.h | 6 ++- net/netfilter/nf_flow_table_core.c| 3 +-

[PATCH net-next 7/9] netfilter: flowtable: add direct xmit path

2020-10-14 Thread Pablo Neira Ayuso
Add FLOW_OFFLOAD_XMIT_DIRECT to turn on the direct dev_queue_xmit() path to transmit ethernet frames. Cache the source and destination hardware address for flow to use dev_queue_xmit() to transfer packets. Signed-off-by: Pablo Neira Ayuso --- include/net/netfilter/nf_flow_table.h | 5 + net

[PATCH net-next 3/9] net: 8021q: resolve forwarding path for vlan devices

2020-10-14 Thread Pablo Neira Ayuso
Add .ndo_fill_forward_path for vlan devices. For instance, assuming the following topology: IP forwarding / \ eth0.100 eth0 | eth0 . . . ethX ab:cd:

[PATCH net-next 8/9] netfilter: flowtable: bridge port support

2020-10-14 Thread Pablo Neira Ayuso
Update hardware destination address to the master bridge device to emulate the forwarding behaviour. Signed-off-by: Pablo Neira Ayuso --- include/net/netfilter/nf_flow_table.h | 1 + net/netfilter/nf_flow_table_core.c| 4 net/netfilter/nft_flow_offload.c | 6 +- 3 files changed

[PATCH net-next 2/9] net: resolve forwarding path from virtual netdevice and HW destination address

2020-10-14 Thread Pablo Neira Ayuso
This patch adds dev_fill_forward_path() which resolves the path to reach the real netdevice from the IP forwarding step. This function takes as input the netdevice and the destination hardware address and it walks down over the devices calling .ndo_fill_forward_path() for each device until the real

[PATCH net-next 0/9] netfilter: flowtable bridge and vlan enhancements

2020-10-14 Thread Pablo Neira Ayuso
Hi, The following patchset adds infrastructure to augment the Netfilter flowtable fastpath [1] to support for local network topologies that combine IP forwarding, bridge and vlan devices. A typical scenario that can benefit from this infrastructure is composed of several VMs connected to bridge p

[PATCH net-next 6/9] netfilter: flowtable: use dev_fill_forward_path() to obtain egress device

2020-10-14 Thread Pablo Neira Ayuso
The egress device in the tuple is obtained from route. Use dev_fill_forward_path() instead to provide the real ingress device for this flow whenever this is available. Signed-off-by: Pablo Neira Ayuso --- include/net/netfilter/nf_flow_table.h | 4 net/netfilter/nf_flow_table_core.c| 1

[PATCH net-next 1/9] netfilter: flowtable: add xmit path types

2020-10-14 Thread Pablo Neira Ayuso
Add the xmit_type field that defines the two supported xmit paths in the flowtable data plane, which are the neighbour and the xfrm xmit paths. This patch prepares for new flowtable xmit path types to come. Signed-off-by: Pablo Neira Ayuso --- include/net/netfilter/nf_flow_table.h | 6 net

Re: [net] tipc: re-configure queue limit for broadcast link

2020-10-14 Thread Jakub Kicinski
On Tue, 13 Oct 2020 13:18:10 +0700 Hoang Huu Le wrote: > The queue limit of the broadcast link is being calculated base on initial > MTU. However, when MTU value changed (e.g manual changing MTU on NIC > device, MTU negotiation etc.,) we do not re-calculate queue limit. > This gives throughput does

Re: [PATCH 0/2] net: dsa: mv88e6xxx: serdes link without phy

2020-10-14 Thread Jakub Kicinski
On Tue, 13 Oct 2020 15:18:56 +1300 Chris Packham wrote: > This small series gets my hardware into a working state. The key points are to > make sure we don't force the link and that we ask the MAC for the link status. > I also have updated my dts to say `phy-mode = "1000base-x";` and `managed = > "

Re: [PATCH 0/3] l3mdev icmp error route lookup fixes

2020-10-14 Thread Jakub Kicinski
On Mon, 12 Oct 2020 10:50:13 -0400 Mathieu Desnoyers wrote: > Here is a series of fixes for ipv4 and ipv6 which ensure the route > lookup is performed on the right routing table in VRF configurations > when sending TTL expired icmp errors (useful for traceroute). > > It includes tests for both ipv

Re: [PATCH v7,net-next,07/13] crypto: octeontx2: load microcode and create engine groups

2020-10-14 Thread Jakub Kicinski
On Mon, 12 Oct 2020 16:27:13 +0530 Srujana Challa wrote: > +/* tar header as defined in POSIX 1003.1-1990. */ > +struct tar_hdr_t { > + char name[100]; > + char mode[8]; > + char uid[8]; > + char gid[8]; > + char size[12]; > + char mtime[12]; > + char chksum[8]; > +

Re: [PATCH v7,net-next,04/13] drivers: crypto: add Marvell OcteonTX2 CPT PF driver

2020-10-14 Thread Jakub Kicinski
On Mon, 12 Oct 2020 16:27:10 +0530 Srujana Challa wrote: > + err = pci_set_dma_mask(pdev, DMA_BIT_MASK(48)); > + err = pci_set_consistent_dma_mask(pdev, DMA_BIT_MASK(48)); dma_set_mask_and_coherent()

Re: [PATCH v7,net-next,04/13] drivers: crypto: add Marvell OcteonTX2 CPT PF driver

2020-10-14 Thread Jakub Kicinski
On Mon, 12 Oct 2020 16:27:10 +0530 Srujana Challa wrote: > +union otx2_cptx_lf_misc_int { > + u64 u; > + struct otx2_cptx_lf_misc_int_s { > + u64 reserved_0:1; > + u64 nqerr:1; > + u64 irde:1; > + u64 nwrp:1; > + u64 reserved_4:1;

Re: [PATCH v7,net-next,03/13] octeontx2-af: add debugfs entries for CPT block

2020-10-14 Thread Jakub Kicinski
On Mon, 12 Oct 2020 16:27:09 +0530 Srujana Challa wrote: > +static ssize_t rvu_dbg_cpt_cmd_parser(struct file *filp, > + const char __user *buffer, size_t count, > + loff_t *ppos) > +{ > + struct seq_file *s = filp->private_dat

Re: [PATCH v7,net-next,02/13] octeontx2-af: add mailbox interface for CPT

2020-10-14 Thread Jakub Kicinski
On Mon, 12 Oct 2020 16:27:08 +0530 Srujana Challa wrote: > On OcteonTX2 SoC, the admin function (AF) is the only one with all > priviliges to configure HW and alloc resources, PFs and it's VFs > have to request AF via mailbox for all their needs. This patch adds > a mailbox interface for CPT PFs an

Re: [PATCH net v3] net: fix pos incrementment in ipv6_route_seq_next

2020-10-14 Thread Yonghong Song
On 10/14/20 4:14 PM, Andrii Nakryiko wrote: On Wed, Oct 14, 2020 at 2:53 PM Yonghong Song wrote: Commit 4fc427e05158 ("ipv6_route_seq_next should increase position index") tried to fix the issue where seq_file pos is not increased if a NULL element is returned with seq_ops->next(). See bug

Re: [PATCH] net: phy: Prevent reporting advertised modes when autoneg is off

2020-10-14 Thread Lukasz Stelmach
It was <2020-10-14 śro 23:04>, when Russell King - ARM Linux admin wrote: > On Wed, Oct 14, 2020 at 04:39:47PM +0200, Lukasz Stelmach wrote: >> It was <2020-10-14 śro 14:32>, when Russell King - ARM Linux admin wrote: >> > In any case, the mii.c code does fill in the advertising mask even >> > when

Re: [PATCH net-next v5 08/10] bridge: cfm: Netlink GET configuration Interface.

2020-10-14 Thread Jakub Kicinski
On Mon, 12 Oct 2020 14:04:26 + Henrik Bjoernlund wrote: > + if (nla_put_u32(skb, IFLA_BRIDGE_CFM_CC_CCM_TX_SEQ_NO_UPDATE, > + mep->cc_ccm_tx_info.seq_no_update)) > + goto nla_put_failure; > + > + if (nla_put_u32(skb, IFLA_B

Re: [PATCH net-next v5 04/10] bridge: cfm: Kernel space implementation of CFM. MEP create/delete.

2020-10-14 Thread Jakub Kicinski
On Mon, 12 Oct 2020 14:04:22 + Henrik Bjoernlund wrote: > + if (config->mdlevel > 7) { > + NL_SET_ERR_MSG_MOD(extack, > +"MD level is invalid"); > + return -EINVAL; > + } > + /* The MEP-ID is a 13 bit field in the CCM PDU ident

Re: [PATCH net-next v5 06/10] bridge: cfm: Kernel space implementation of CFM. CCM frame RX added.

2020-10-14 Thread Jakub Kicinski
On Mon, 12 Oct 2020 14:04:24 + Henrik Bjoernlund wrote: > + /* This CCM related status is based on the latest received CCM PDU. */ > + u8 port_tlv_value; /* Port Status TLV value */ > + u8 if_tlv_value; /* Interface Status TLV value */ > + > + /* CCM has not been received for 3.

Re: [PATCH net-next v5 06/10] bridge: cfm: Kernel space implementation of CFM. CCM frame RX added.

2020-10-14 Thread Jakub Kicinski
On Mon, 12 Oct 2020 14:04:24 + Henrik Bjoernlund wrote: > +struct br_cfm_status_tlv { > + __u8 type; > + __be16 length; > + __u8 value; > +}; This structure is unused (and likely not what you want, since it will have 2 1 byte while unless you mark length as __packed).

[PATCH] powerpc32: don't adjust unmoved stack pointer in csum_partial_copy_generic() epilogue

2020-10-14 Thread Jason A. Donenfeld
A recent change to the checksum code removed usage of some extra arguments, alongside with storage on the stack for those, and the stack pointer no longer needed to be adjusted in the function prologue. But, a left over subtraction wasn't removed in the function epilogue, causing the function to re

Re: [PATCH net-next v5 04/10] bridge: cfm: Kernel space implementation of CFM. MEP create/delete.

2020-10-14 Thread Jakub Kicinski
On Mon, 12 Oct 2020 14:04:22 + Henrik Bjoernlund wrote: > with restricted management access to each other<80><99>s equipment. Some Unicode funk in this line?

Re: [PATCH net-next v5 05/10] bridge: cfm: Kernel space implementation of CFM. CCM frame TX added.

2020-10-14 Thread Jakub Kicinski
On Mon, 12 Oct 2020 14:04:23 + Henrik Bjoernlund wrote: > + skb = dev_alloc_skb(CFM_CCM_MAX_FRAME_LENGTH); > + if (!skb) > + return NULL; > + > + rcu_read_lock(); > + b_port = rcu_dereference(mep->b_port); > + if (!b_port) { > + rcu_read_unlock(); > +

Re: [PATCH net-next v5 00/10] net: bridge: cfm: Add support for Connectivity Fault Management(CFM)

2020-10-14 Thread Jakub Kicinski
On Mon, 12 Oct 2020 14:04:18 + Henrik Bjoernlund wrote: > Connectivity Fault Management (CFM) is defined in 802.1Q section 12.14. > > Connectivity Fault Management (CFM) comprises capabilities for detecting, > verifying, > and isolating connectivity failures in Virtual Bridged Networks. > The

Re: [PATCH v2 20/20] ppc: propagate the calling conventions change down to csum_partial_copy_generic()

2020-10-14 Thread Jason A. Donenfeld
On Thu, Oct 15, 2020 at 12:53 AM Linus Torvalds wrote: > > On Wed, Oct 14, 2020 at 3:51 PM Linus Torvalds > wrote: > > > > I think it's this instruction: > > > > addir1,r1,16 > > > > that should be removed from the function exit, because Al removed the > > > > - stwur1,-16(r

Re: [PATCH v2 20/20] ppc: propagate the calling conventions change down to csum_partial_copy_generic()

2020-10-14 Thread Jason A. Donenfeld
On Thu, Oct 15, 2020 at 12:51 AM Linus Torvalds wrote: > > On Wed, Oct 14, 2020 at 3:27 PM Jason A. Donenfeld wrote: > > > > This patch is causing crashes in WireGuard's CI over at > > https://www.wireguard.com/build-status/ . Apparently sending a simple > > network packet winds up triggering ref

[iproute2-next v3] devlink: display elapsed time during flash update

2020-10-14 Thread Jacob Keller
For some devices, updating the flash can take significant time during operations where no status can meaningfully be reported. This can be somewhat confusing to a user who sees devlink appear to hang on the terminal waiting for the device to update. Recent changes to the kernel interface allow suc

Re: [PATCH v2 20/20] ppc: propagate the calling conventions change down to csum_partial_copy_generic()

2020-10-14 Thread Jason A. Donenfeld
Hi Al, On Fri, Jul 24, 2020 at 02:25:46AM +0100, Al Viro wrote: > From: Al Viro > > ... and get rid of the pointless fallback in the wrappers. On error it used > to zero the unwritten area and calculate the csum of the entire thing. Not > wanting to do it in assembler part had been very reason

Re: [Patch net v2] ip_gre: set dev->hard_header_len and dev->needed_headroom properly

2020-10-14 Thread Willem de Bruijn
On Wed, Oct 14, 2020 at 3:48 PM Xie He wrote: > > On Wed, Oct 14, 2020 at 8:12 AM Willem de Bruijn > wrote: > > > > On Wed, Oct 14, 2020 at 4:52 AM Xie He wrote: > > > > > > On Sun, Oct 11, 2020 at 2:01 PM Willem de Bruijn > > > wrote: > > > > > > > > There is agreement that hard_header_len sho

kernel panic: Fatal exception (3)

2020-10-14 Thread syzbot
Hello, syzbot found the following issue on: HEAD commit:c77fb07f Merge branch 'netlink-export-policy-on-validation.. git tree: net-next console output: https://syzkaller.appspot.com/x/log.txt?x=1722ff0050 kernel config: https://syzkaller.appspot.com/x/.config?x=fa2bf4058104211 dash

Re: [PATCH net-next 3/3] macb: support the two tx descriptors on at91rm9200

2020-10-14 Thread Claudiu.Beznea
Hi Willy, On 11.10.2020 12:09, Willy Tarreau wrote: > EXTERNAL EMAIL: Do not click links or open attachments unless you know the > content is safe > > The at91rm9200 variant used by a few chips including the MSC313 supports > two Tx descriptors (one frame being serialized and another one queued)

Re: [Patch net v2] ip_gre: set dev->hard_header_len and dev->needed_headroom properly

2020-10-14 Thread Xie He
On Wed, Oct 14, 2020 at 8:12 AM Willem de Bruijn wrote: > > On Wed, Oct 14, 2020 at 4:52 AM Xie He wrote: > > > > On Sun, Oct 11, 2020 at 2:01 PM Willem de Bruijn > > wrote: > > > > > > There is agreement that hard_header_len should be the length of link > > > layer headers visible to the upper

Re: [PATCH nf v2] netfilter: conntrack: connection timeout after re-register

2020-10-14 Thread Florian Westphal
Francesco Ruggeri wrote: > On Wed, Oct 14, 2020 at 1:23 AM Florian Westphal wrote: > > > > Pablo Neira Ayuso wrote: > > > Legacy would still be flawed though. > > > > Its fine too, new rule blob gets handled (and match/target checkentry > > called) before old one is dismantled. > > > > We only h

[PATCH net-next] netfilter: restore NF_INET_NUMHOOKS

2020-10-14 Thread Pablo Neira Ayuso
This definition is used by the iptables legacy UAPI, restore it. Fixes: d3519cb89f6d ("netfilter: nf_tables: add inet ingress support") Reported-by: Jason A. Donenfeld Tested-by: Jason A. Donenfeld Signed-off-by: Pablo Neira Ayuso --- @Jakub: if you please can take this into net-next, it is fix

Re: selftests: netfilter: nft_nat.sh: /dev/stdin:2:9-15: Error: syntax error, unexpected counter

2020-10-14 Thread Pablo Neira Ayuso
On Wed, Oct 14, 2020 at 05:19:33PM +0530, Naresh Kamboju wrote: > While running kselftest netfilter test on x86_64 devices linux next > tag 20201013 kernel > these errors are noticed. This not specific to kernel version we have > noticed these errors > earlier also. > > Am I missing configs ? Wha

Re: [PATCH nf v2] netfilter: conntrack: connection timeout after re-register

2020-10-14 Thread Francesco Ruggeri
On Wed, Oct 14, 2020 at 1:23 AM Florian Westphal wrote: > > Pablo Neira Ayuso wrote: > > Legacy would still be flawed though. > > Its fine too, new rule blob gets handled (and match/target checkentry > called) before old one is dismantled. > > We only have a 0 refcount + hook unregister when rule

Re: [PATCH] IPv6: sr: Fix End.X nexthop to use oif.

2020-10-14 Thread kernel test robot
fig: riscv-randconfig-r035-20201014 (attached as .config) compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project e7fe3c6dfede8d5781bd000741c3dea7088307a4) reproduce (this is a W=1 build): wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/

Re: [PATCH] ixgbe: fail to create xfrm offload of IPsec tunnel mode SA

2020-10-14 Thread Shannon Nelson
On 10/14/20 7:17 AM, Antony Antony wrote: Based on talks and indirect references ixgbe IPsec offlod do not support IPsec tunnel mode offload. It can only support IPsec transport mode offload. Now explicitly fail when creating non transport mode SA with offload to avoid false performance expecta

[PATCH bpf-next] bpf: Fix register equivalence tracking.

2020-10-14 Thread Alexei Starovoitov
From: Alexei Starovoitov The 64-bit JEQ/JNE handling in reg_set_min_max() was clearing reg->id in either true or false branch. In the case 'if (reg->id)' check was done on the other branch the counter part register would have reg->id == 0 when called into find_equal_scalars(). In such case the he

Re: [PATCH net] can: peak_usb: add range checking in decode operations

2020-10-14 Thread Oliver Hartkopp
Hi Stephane, On 14.10.20 15:22, Stéphane Grosjean wrote: Hello Dan, Don't know if this patch is still relevant, but: - there is absolutely no reason for the device firmware to provide a channel index greater than or equal to 2, because the IP core of these USB devices handles 2 channels only

Re: [PATCH net v3] net: fix pos incrementment in ipv6_route_seq_next

2020-10-14 Thread Martin KaFai Lau
On Wed, Oct 14, 2020 at 07:46:12AM -0700, Yonghong Song wrote: > Commit 4fc427e05158 ("ipv6_route_seq_next should increase position index") > tried to fix the issue where seq_file pos is not increased > if a NULL element is returned with seq_ops->next(). See bug > https://bugzilla.kernel.org/show

[PATCH net 0/3] net/smc: fixes 2020-10-14

2020-10-14 Thread Karsten Graul
Please apply the following patch series for smc to netdev's net tree. The first patch fixes a possible use-after-free of delayed llc events. Patch 2 corrects the number of DMB buffer sizes. And patch 3 ensures a correctly formatted return code when smc_ism_register_dmb() fails to create a new DMB.

[PATCH net 1/3] net/smc: fix use-after-free of delayed events

2020-10-14 Thread Karsten Graul
When a delayed event is enqueued then the event worker will send this event the next time it is running and no other flow is currently active. The event handler is called for the delayed event, and the pointer to the event keeps set in lgr->delayed_event. This pointer is cleared later in the proces

[PATCH net 2/3] net/smc: fix valid DMBE buffer sizes

2020-10-14 Thread Karsten Graul
The SMCD_DMBE_SIZES should include all valid DMBE buffer sizes, so the correct value is 6 which means 1MB. With 7 the registration of an ISM buffer would always fail because of the invalid size requested. Fix that and set the value to 6. Fixes: c6ba7c9ba43d ("net/smc: add base infrastructure for S

[PATCH net 3/3] net/smc: fix invalid return code in smcd_new_buf_create()

2020-10-14 Thread Karsten Graul
smc_ism_register_dmb() returns error codes set by the ISM driver which are not guaranteed to be negative or in the errno range. Such values would not be handled by ERR_PTR() and finally the return code will be used as a memory address. Fix that by using a valid negative errno value with ERR_PTR().

Re: [PATCH net] net: sched: Fix suspicious RCU usage while accessing tcf_tunnel_info

2020-10-14 Thread Cong Wang
On Wed, Oct 14, 2020 at 1:56 AM Leon Romanovsky wrote: > > From: Leon Romanovsky > > The access of tcf_tunnel_info() produces the following splat, so fix it > by dereferencing the tcf_tunnel_key_params pointer with marker that > internal tcfa_liock is held. Looks reasonable to me, Acked-by: Con

Re: [PATCH net] net: dsa: ksz: fix padding size of skb

2020-10-14 Thread Vladimir Oltean
On Wed, Oct 14, 2020 at 07:02:13PM +0200, Christian Eggers wrote: > > Otherwise said, the frame must be padded to > > max(skb->len, ETH_ZLEN) + tail tag length. > At first I thought the same when working on this. But IMHO the padding must > only ensure the minimum required size, there is no need to

Re: [PATCH net] net: dsa: ksz: fix padding size of skb

2020-10-14 Thread Christian Eggers
Hi Vladimir, On Wednesday, 14 October 2020, 18:54:10 CEST, Vladimir Oltean wrote: > On Wed, Oct 14, 2020 at 07:47:50PM +0300, Vladimir Oltean wrote: > > On Wed, Oct 14, 2020 at 06:17:19PM +0200, Christian Eggers wrote: > > > __skb_put_padto() is called in order to ensure a minimal size of the > >

Re: [PATCH net] net: dsa: ksz: fix padding size of skb

2020-10-14 Thread Vladimir Oltean
On Wed, Oct 14, 2020 at 07:47:50PM +0300, Vladimir Oltean wrote: > On Wed, Oct 14, 2020 at 06:17:19PM +0200, Christian Eggers wrote: > > __skb_put_padto() is called in order to ensure a minimal size of the > > sk_buff. The required minimal size is ETH_ZLEN + the size required for > > the tail tag.

[PATCH ethtool] netlink: fix allocation failure handling in dump_features()

2020-10-14 Thread Michal Kubecek
On allocation failure, dump_features() would set ret to -ENOMEM but then return 0 anyway. As there is nothing to free in this case anyway, the easiest fix is to simply return -ENOMEM rather than jumping to out_free label - which can be dropped as well as this was its only use. Fixes: f2c17e107900

Re: [PATCH net] net: dsa: ksz: fix padding size of skb

2020-10-14 Thread Vladimir Oltean
On Wed, Oct 14, 2020 at 06:17:19PM +0200, Christian Eggers wrote: > __skb_put_padto() is called in order to ensure a minimal size of the > sk_buff. The required minimal size is ETH_ZLEN + the size required for > the tail tag. > > The current argument misses the size for the tail tag. The expression

  1   2   >