Re: [PATCH] vsock/virtio: fix kernel panic from virtio_transport_reset_no_sock

2019-03-06 Thread Stefano Garzarella
Hi Adalbert, thanks for catching this issue, I have a comment below. On Tue, Mar 05, 2019 at 08:01:45PM +0200, Adalbert Lazăr wrote: > Previous to commit 22b5c0b63f32 ("vsock/virtio: fix kernel panic after device > hot-unplug"), > vsock_core_init() was called from virtio_vsock_probe(). Now, > vir

[PATCH net] net: hns3: Fix a logical vs bitwise typo

2019-03-06 Thread Dan Carpenter
There were a couple logical ORs accidentally mixed in with the bitwise ORs. Fixes: e8149933b1fa ("net: hns3: remove hnae3_get_bit in data path") Signed-off-by: Dan Carpenter --- Very recent bug. drivers/net/ethernet/hisilicon/hns3/hns3_enet.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletio

Re: [RFC PATCH net-next] failover: allow name change on IFF_UP slave interfaces

2019-03-06 Thread si-wei liu
On 3/5/2019 11:23 PM, Michael S. Tsirkin wrote: On Tue, Mar 05, 2019 at 11:15:06PM -0800, si-wei liu wrote: On 3/5/2019 10:43 PM, Michael S. Tsirkin wrote: On Tue, Mar 05, 2019 at 04:51:00PM -0800, si-wei liu wrote: On 3/5/2019 4:36 PM, Michael S. Tsirkin wrote: On Tue, Mar 05, 2019 at 04

Re: [PATCH] net/sched: avoid unused-label warning

2019-03-06 Thread Arnd Bergmann
On Wed, Mar 6, 2019 at 1:28 AM Cong Wang wrote: > On Mon, Mar 4, 2019 at 12:40 PM Arnd Bergmann wrote: > > diff --git a/net/sched/act_tunnel_key.c b/net/sched/act_tunnel_key.c > > index 2a5f215ae876..3beb4717d3b7 100644 > > --- a/net/sched/act_tunnel_key.c > > +++ b/net/sched/act_tunnel_key.c > >

Re: [PATCH] net/rds: Accept peer connection reject messages due to incompatible version

2019-03-06 Thread Yanjun Zhu
On 2019/3/6 15:04, Gerd Rausch wrote: Prior to commit d021fabf525ff ("rds: rdma: add consumer reject") function "rds_rdma_cm_event_handler_cmn" would always honor a rejected connection attempt by issuing a "rds_conn_drop". The commit mentioned above added a "break", eliminating the "fallthrou

Re: [PATCH] vsock/virtio: fix kernel panic from virtio_transport_reset_no_sock

2019-03-06 Thread Stefan Hajnoczi
On Tue, Mar 05, 2019 at 08:01:45PM +0200, Adalbert Lazăr wrote: Thanks for the patch, Adalbert! Please add a Signed-off-by tag so your patch can be merged (see Documentation/process/submitting-patches.rst Chapter 11 for details on the Developer's Certificate of Origin). > static int virtio_tran

Re: [PATCH bpf] bpf: fix sanitation rewrite in case of non-pointers

2019-03-06 Thread Jakub Sitnicki
On Tue, Mar 05, 2019 at 03:30 PM CET, Daniel Borkmann wrote: > On 03/05/2019 03:12 PM, Jakub Sitnicki wrote: > [...] >> Could you please queue it for -stable which has d3bd7413e0ca ("bpf: fix >> sanitation of alu op with pointer / scalar type from different paths")? > > Already done here yesterday

Re: [PATCH net] net: hns3: Fix a logical vs bitwise typo

2019-03-06 Thread Yunsheng Lin
On 2019/3/6 16:12, Dan Carpenter wrote: > There were a couple logical ORs accidentally mixed in with the bitwise > ORs. Thanks for the fix. Reviewed-by: Yunsheng Lin > > Fixes: e8149933b1fa ("net: hns3: remove hnae3_get_bit in data path") > Signed-off-by: Dan Carpenter > --- > Very recent bug

[PATCH net v2] ipv4/route: fail early when inet dev is missing

2019-03-06 Thread Paolo Abeni
If a non local multicast packet reaches ip_route_input_rcu() while the ingress device IPv4 private data (in_dev) is NULL, we end up doing a NULL pointer dereference in IN_DEV_MFORWARD(). Since the later call to ip_route_input_mc() is going to fail if !in_dev, we can fail early in such scenario and

[PATCH 1/2] net: phy: mscc: add support for VSC8514 PHY

2019-03-06 Thread Kavyasree.Kotagiri
From: Kavya Sree Kotagiri The VSC8514 PHY is a 4-ports PHY that is 10/100/1000BASE-T, 100BASE-FX, 1000BASE-X, can communicate with the MAC via QSGMII. The MAC interface protocol for each port within QSGMII can be either 1000BASE-X or SGMII, if the QSGMII MAC that the VSC8514 is connecting to supp

[PATCH 2/2] net: phy: vitesse: Remove support for VSC8514

2019-03-06 Thread Kavyasree.Kotagiri
From: Kavya Sree Kotagiri Recently added support for VSC8514 in Microsemi driver (mscc.c) with more features. Features supported in Vitesse driver are also supported in the Microsemi driver. Signed-off-by: Kavya Sree Kotagiri --- drivers/net/phy/vitesse.c | 12 1 file changed, 12

[PATCH RESEND 2/5] can: flexcan: add CAN FD mode support

2019-03-06 Thread Joakim Zhang
From: Dong Aisheng This patch intends to add CAN FD mode support in driver, it means that payload size can extend up to 64 bytes. NOTE: Bit rate switch (BRS) enabled by system reset when it enables CAN FD mode (explicitly set BRS again in driver). So CAN hardware has support BRS, but now driver

[PATCH RESEND 0/5] can: flexcan: add CAN FD support on i.MX8QM

2019-03-06 Thread Joakim Zhang
Hi Marc, This patch set integrates two patch sets which have been sent before. [PATCH 0/3] can: flexcan: add imx8qm support [PATCH 0/2] can: flexcan: add CANFD BRS and ISO FD support I rebase it that will easy your patch review. Thanks a lot. Joakim Zhang. Dong Aisheng (4): can: rx-offload:

[PATCH RESEND 5/5] can: flexcan: add imx8qm support

2019-03-06 Thread Joakim Zhang
From: Dong Aisheng The Flexcan on i.MX8QM supports CAN FD protocol. Signed-off-by: Dong Aisheng Signed-off-by: Joakim Zhang --- drivers/net/can/flexcan.c | 7 +++ 1 file changed, 7 insertions(+) diff --git a/drivers/net/can/flexcan.c b/drivers/net/can/flexcan.c index fca014bc530a..49615c

[PATCH RESEND 1/5] can: rx-offload: add CANFD support based on offload

2019-03-06 Thread Joakim Zhang
From: Dong Aisheng Using struct canfd_frame instead of can_frame to add support for CAN FD mode in offload. FlexCAN controller will set the is_canfd variable when it supports CAN FD mode. Signed-off-by: Dong Aisheng Signed-off-by: Joakim Zhang --- drivers/net/can/rx-offload.c | 16 +

[PATCH RESEND 3/5] can: flexcan: add CANFD BRS support and improve bittiming setting

2019-03-06 Thread Joakim Zhang
From: Dong Aisheng This patch intends to add CANFD BitRate Switch(BRS) support. Bit timing must be set in CBT register other than CTRL1 register when CANFD supports BRS, it will extend the range of all CAN bit timing variables (PRESDIV, PROPSEG, PSEG1, PSEG2 and RJW), which will improve the bit t

[PATCH RESEND 4/5] can: flexcan: add ISO CAN FD feature support

2019-03-06 Thread Joakim Zhang
ISO CAN FD is introduced to increase the failture detection capability than non-ISO CAN FD. The non-ISO CAN FD is still supported by FlexCAN so that it can be used mainly during an intermediate phase, for evaluation and development purposes. Therefore, it is strongly recommended to configure FlexC

[PATCH v2] vsock/virtio: fix kernel panic from virtio_transport_reset_no_sock

2019-03-06 Thread Adalbert Lazăr
Previous to commit 22b5c0b63f32 ("vsock/virtio: fix kernel panic after device hot-unplug"), vsock_core_init() was called from virtio_vsock_probe(). Now, virtio_transport_reset_no_sock() can be called before vsock_core_init() has the chance to run. [Wed Feb 27 14:17:09 2019] BUG: unable to handle k

[PATCH net] iptunnel: NULL pointer deref for ip_md_tunnel_xmit

2019-03-06 Thread Alan Maguire
Naresh Kamboju noted the following oops during execution of selftest tools/testing/selftests/bpf/test_tunnel.sh on x86_64: [ 274.120445] BUG: unable to handle kernel NULL pointer dereference at [ 274.128285] #PF error: [INSTR] [ 274.131351] PGD 800414a0e067 P4D 800414a0

[PATCH net] gre: fix kernel panic when using lw tunnel

2019-03-06 Thread Nicolas Dichtel
There was several problems: - skb_dst(skb) can be NULL when the packet comes from a gretap tunnel; - skb_dst(skb)->ops may point to md_dst_ops, which doesn't set ->mtu handler, thus calling dst_mtu() leads to a panic. I also wonder if ->cow_metrics may be called if skb_dst(skb)->ops points to

Re: general protection fault in sctp_sched_rr_dequeue

2019-03-06 Thread Xin Long
On Wed, Mar 6, 2019 at 9:42 AM syzbot wrote: > > Hello, > > syzbot found the following crash on: > > HEAD commit:63bdf4284c38 Merge branch 'linus' of git://git.kernel.org/.. > git tree: upstream > console output: https://syzkaller.appspot.com/x/log.txt?x=100347cb20 > kernel config:

Re: [RFC PATCH V2 2/5] vhost: fine grain userspace memory accessors

2019-03-06 Thread Christophe de Dinechin
> On 6 Mar 2019, at 08:18, Jason Wang wrote: > > This is used to hide the metadata address from virtqueue helpers. This > will allow to implement a vmap based fast accessing to metadata. > > Signed-off-by: Jason Wang > --- > drivers/vhost/vhost.c | 94

[PATCH 1/2] appletalk: Fix compile regression

2019-03-06 Thread Arnd Bergmann
A bugfix just broke compilation of appletalk when CONFIG_SYSCTL is disabled: In file included from net/appletalk/ddp.c:65: net/appletalk/ddp.c: In function 'atalk_init': include/linux/atalk.h:164:34: error: expected expression before 'do' #define atalk_register_sysctl() do { } while(0)

[PATCH 2/2] appletalk: Add atalk.h header files to MAINTAINERS file

2019-03-06 Thread Arnd Bergmann
Add the path names here so that git-send-email can pick up the netdev@vger.kernel.org Cc line automatically for a patch that only touches the headers. Signed-off-by: Arnd Bergmann --- MAINTAINERS | 2 ++ 1 file changed, 2 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index 1e64279f338a..

Re: [RFC PATCH V2 4/5] vhost: introduce helpers to get the size of metadata area

2019-03-06 Thread Christophe de Dinechin
> On 6 Mar 2019, at 08:18, Jason Wang wrote: > > Signed-off-by: Jason Wang > --- > drivers/vhost/vhost.c | 46 -- > 1 file changed, 28 insertions(+), 18 deletions(-) > > diff --git a/drivers/vhost/vhost.c b/drivers/vhost/vhost.c > index 2025543..101

[PATCH iproute2] iprule: fix printing hint about unresolved iifname and oifname

2019-03-06 Thread Thomas Haller
# ip rule add priority 10 iif eth1 goto 1 protocol 10 was displayed as 10: from all iif eth1 [detached] goto 1unresolved proto mrt now: 10: from all iif eth1 [detached] goto 1 [unresolved] proto mrt Fixes: 0dd4ccc56c0e ("iprule: add json support") Signed-off-by

[PATCH] vhost: silence an unused-variable warning

2019-03-06 Thread Arnd Bergmann
On some architectures, the MMU can be disabled, leading to access_ok() becoming an empty macro that does not evaluate its size argument, which in turn produces an unused-variable warning: drivers/vhost/vhost.c:1191:9: error: unused variable 's' [-Werror,-Wunused-variable] size_t s = vhost

[PATCH] tcp: detecting the misuse of .sendpage for Slab objects

2019-03-06 Thread Vasily Averin
sendpage was not designed for processing of the Slab pages, in some situations it can trigger BUG_ON on receiving side. Signed-off-by: Vasily Averin --- net/ipv4/tcp.c | 4 1 file changed, 4 insertions(+) diff --git a/net/ipv4/tcp.c b/net/ipv4/tcp.c index ad07dd71063d..dbb08140cdc9 100644

Re: [PATCH v2] net: xfrm: Add '_rcu' tag for rcu protected pointer in netns_xfrm

2019-03-06 Thread Steffen Klassert
On Mon, Mar 04, 2019 at 08:19:14PM -0500, Su Yanjun wrote: > For rcu protected pointers, we'd better add '__rcu' for them. > > Once added '__rcu' tag for rcu protected pointer, the sparse tool reports > warnings. > > net/xfrm/xfrm_user.c:1198:39: sparse:expected struct sock *sk > net/xfrm/xfr

Re: [PATCH] xfrm: Reset secpath in xfrm failure

2019-03-06 Thread Steffen Klassert
On Wed, Mar 06, 2019 at 04:33:08PM +0900, Myungho Jung wrote: > In esp4_gro_receive() and esp6_gro_receive(), secpath can be allocated > without adding xfrm state to xvec. Then, sp->xvec[sp->len - 1] would > fail and result in dereferencing invalid pointer in esp4_gso_segment() > and esp6_gso_segme

Re: stmmac / meson8b-dwmac

2019-03-06 Thread Simon Huelck
Hi, i sorted out some more things: - i did not activate tcp window scaling , with this , iperf3 is reaching 930MBits now, this was related to my firewall and therefore my uplink. so the remaining topic is ( and im currently testing with next-20190306 ) TX is starving RX and the total bandwith

Re: stmmac / meson8b-dwmac

2019-03-06 Thread Simon Huelck
t; > - i did not activate tcp window scaling , with this , iperf3 is reaching > 930MBits now, this was related to my firewall and therefore my uplink. > > so the remaining topic is ( and im currently testing with next-20190306 ) > > TX is starving RX and the total bandwith

[PATCH] ray_cs: Check return value of pcmcia_register_driver

2019-03-06 Thread Yue Haibing
From: YueHaibing init_ray_cs does not check value of pcmcia_register_driver, if it fails, there maybe cause a NULL pointer dereference in exit_ray_cs. Signed-off-by: YueHaibing --- drivers/net/wireless/ray_cs.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/net/wireless/ray_cs.c

[PATCH] ray_cs: use remove_proc_subtree to simplify procfs code

2019-03-06 Thread Yue Haibing
From: YueHaibing Use remove_proc_subtree to remove the whole subtree Signed-off-by: YueHaibing --- drivers/net/wireless/ray_cs.c | 6 +- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/drivers/net/wireless/ray_cs.c b/drivers/net/wireless/ray_cs.c index d561659..ee4d810 100644

Re: [PATCH net-next v2 00/12] Refactor flower classifier to remove dependency on rtnl lock

2019-03-06 Thread Vlad Buslov
On Tue 05 Mar 2019 at 01:57, Stefano Brivio wrote: > On Wed, 27 Feb 2019 12:12:14 +0200 > Vlad Buslov wrote: > >> Currently, all netlink protocol handlers for updating rules, actions and >> qdiscs are protected with single global rtnl lock which removes any >> possibility for parallelism. This

[PATCH] ssb: Fix possible NULL pointer dereference in ssb_host_pcmcia_exit

2019-03-06 Thread Yue Haibing
From: YueHaibing Syzkaller report this: kasan: GPF could be caused by NULL-ptr deref or user memory access general protection fault: [#1] SMP KASAN PTI CPU: 0 PID: 4492 Comm: syz-executor.0 Not tainted 5.0.0-rc7+ #45 Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.10.2-1ubuntu

Re: general protection fault in sctp_sched_rr_dequeue

2019-03-06 Thread Neil Horman
On Wed, Mar 06, 2019 at 06:43:48PM +0800, Xin Long wrote: > On Wed, Mar 6, 2019 at 9:42 AM syzbot > wrote: > > > > Hello, > > > > syzbot found the following crash on: > > > > HEAD commit:63bdf4284c38 Merge branch 'linus' of git://git.kernel.org/.. > > git tree: upstream > > console outpu

Re: [RFC PATCH net-next] failover: allow name change on IFF_UP slave interfaces

2019-03-06 Thread Jiri Pirko
Tue, Mar 05, 2019 at 01:50:59AM CET, si-wei@oracle.com wrote: >When a netdev appears through hot plug then gets enslaved by a failover >master that is already up and running, the slave will be opened >right away after getting enslaved. Today there's a race that userspace >(udev) may fail to ren

Re: [PATCH net-next v2 4/7] devlink: allow subports on devlink PCI ports

2019-03-06 Thread Jiri Pirko
Tue, Mar 05, 2019 at 06:15:34PM CET, jakub.kicin...@netronome.com wrote: >On Tue, 5 Mar 2019 12:06:01 +0100, Jiri Pirko wrote: >> >> >as ports. Can we invent a new command (say "partition"?) that'd take >> >> >the bus info where the partition is to be spawned? >> >> >> >> Got it. But the ques

Re: [PATCH net] gre: fix kernel panic when using lw tunnel

2019-03-06 Thread Nicolas Dichtel
Le 06/03/2019 à 11:32, Nicolas Dichtel a écrit : > There was several problems: > - skb_dst(skb) can be NULL when the packet comes from a gretap tunnel; > - skb_dst(skb)->ops may point to md_dst_ops, which doesn't set ->mtu >handler, thus calling dst_mtu() leads to a panic. > > I also wonder

Re: [PATCH net] iptunnel: NULL pointer deref for ip_md_tunnel_xmit

2019-03-06 Thread Nicolas Dichtel
Le 06/03/2019 à 11:25, Alan Maguire a écrit : > Naresh Kamboju noted the following oops during execution of selftest > tools/testing/selftests/bpf/test_tunnel.sh on x86_64: > > [ 274.120445] BUG: unable to handle kernel NULL pointer dereference > at > [ 274.128285] #PF error: [I

[PATCH net] net: sched: flower: insert new filter to idr after setting its mask

2019-03-06 Thread Vlad Buslov
When adding new filter to flower classifier, fl_change() inserts it to handle_idr before initializing filter extensions and assigning it a mask. Normally this ordering doesn't matter because all flower classifier ops callbacks assume rtnl lock protection. However, when filter has an action that doe

[PATCH net] net: hsr: fix memory leak in hsr_dev_finalize()

2019-03-06 Thread Mao Wenan
If hsr_add_port(hsr, hsr_dev, HSR_PT_MASTER) failed to add port, it directly returns res and forgets to free the node that allocated in hsr_create_self_node(), and forgets to delete the node->mac_list linked in hsr->self_node_db. BUG: memory leak unreferenced object 0x8881cfa0c780 (size 64):

Re: [ovs-dev] openvswitch crash on i386

2019-03-06 Thread Juerg Haefliger
On Tue, 5 Mar 2019 11:58:42 -0800 Joe Stringer wrote: > On Tue, Mar 5, 2019 at 2:12 AM Christian Ehrhardt > wrote: > > > > On Tue, Mar 5, 2019 at 10:58 AM Juerg Haefliger > > wrote: > > > > > > Hi, > > > > > > Running the following commands in a loop will crash an i386 5.0 kernel > > > typica

[PATCH net-next] net: sched: fix potential use-after-free in __tcf_chain_put()

2019-03-06 Thread Vlad Buslov
When used with unlocked classifier that have filters attached to actions with goto chain, __tcf_chain_put() for last non action reference can race with calls to same function from action cleanup code that releases last action reference. In this case action cleanup handler could free the chain if it

Re: [PATCH v3 bpf-next 1/2] bpf: Fix bpf_tcp_sock and bpf_sk_fullsock issue related to bpf_sk_release

2019-03-06 Thread Lorenz Bauer
On Mon, 4 Mar 2019 at 17:43, Martin Lau wrote: > > On Mon, Mar 04, 2019 at 10:33:46AM +0100, Daniel Borkmann wrote: > > On 03/02/2019 09:21 PM, Martin Lau wrote: > > > On Sat, Mar 02, 2019 at 10:03:03AM -0800, Alexei Starovoitov wrote: > > >> On Sat, Mar 02, 2019 at 08:10:10AM -0800, Martin KaFai

Re: [PATCH] tcp: detecting the misuse of .sendpage for Slab objects

2019-03-06 Thread Eric Dumazet
On 03/06/2019 03:10 AM, Vasily Averin wrote: > sendpage was not designed for processing of the Slab pages, > in some situations it can trigger BUG_ON on receiving side. > > Signed-off-by: Vasily Averin > --- > net/ipv4/tcp.c | 4 > 1 file changed, 4 insertions(+) > > diff --git a/net/ip

Re: [RFC PATCH V2 5/5] vhost: access vq metadata through kernel virtual address

2019-03-06 Thread Michael S. Tsirkin
On Wed, Mar 06, 2019 at 02:18:12AM -0500, Jason Wang wrote: > It was noticed that the copy_user() friends that was used to access > virtqueue metdata tends to be very expensive for dataplane > implementation like vhost since it involves lots of software checks, > speculation barrier, hardware featu

Re: [PATCH] vsock/virtio: fix kernel panic from virtio_transport_reset_no_sock

2019-03-06 Thread Stefan Hajnoczi
On Wed, Mar 06, 2019 at 11:10:41AM +0200, Adalbert Lazăr wrote: > On Wed, 6 Mar 2019 08:41:04 +, Stefan Hajnoczi wrote: > > On Tue, Mar 05, 2019 at 08:01:45PM +0200, Adalbert Lazăr wrote: > > The pkt argument is the received packet that we must reply to. > > The reply packet is allocated just

[PATCH mlx5-next] net/mlx5: Fix DCT creation bad flow

2019-03-06 Thread Leon Romanovsky
From: Yishai Hadas In case the DCT creation command has succeeded a DRAIN must be issued before calling DESTROY. In addition, the original code used the wrong parameter for the DESTROY command, 'in' instead of 'din', which caused another creation try instead of destroying. Cc: # 4.15 Fixes: 57

[PATCH mlx5-next] IB/mlx5: Use mlx5 core to create/destroy a DEVX DCT

2019-03-06 Thread Leon Romanovsky
From: Yishai Hadas To prevent a hardware memory leak when a DEVX DCT object is destroyed without calling DRAIN DCT before, (e.g. under cleanup flow), need to manage its creation and destruction via mlx5 core. In that case the DRAIN DCT command will be called and only once that it will be complet

Re: [PATCH] net/rds: Accept peer connection reject messages due to incompatible version

2019-03-06 Thread Santosh Shilimkar
On 3/5/2019 11:04 PM, Gerd Rausch wrote: Prior to commit d021fabf525ff ("rds: rdma: add consumer reject") function "rds_rdma_cm_event_handler_cmn" would always honor a rejected connection attempt by issuing a "rds_conn_drop". The commit mentioned above added a "break", eliminating the "fallthro

Re: [PATCH net-next v2 4/7] devlink: allow subports on devlink PCI ports

2019-03-06 Thread Jakub Kicinski
On Wed, 6 Mar 2019 13:20:37 +0100, Jiri Pirko wrote: > Tue, Mar 05, 2019 at 06:15:34PM CET, jakub.kicin...@netronome.com wrote: > >On Tue, 5 Mar 2019 12:06:01 +0100, Jiri Pirko wrote: > >> >> >as ports. Can we invent a new command (say "partition"?) that'd take > >> >> >the bus info where the pa

[PATCH net] tcp: do not report TCP_CM_INQ of 0 for closed connections

2019-03-06 Thread Soheil Hassas Yeganeh
From: Soheil Hassas Yeganeh Returning 0 as inq to userspace indicates there is no more data to read, and the application needs to wait for EPOLLIN. For a connection that has received FIN from the remote peer, however, the application must continue reading until getting EOF (return value of 0 from

Re: [PATCH] tools: testing: selftests: Remove duplicate headers

2019-03-06 Thread Souptick Joarder
On Mon, Mar 4, 2019 at 4:19 PM Souptick Joarder wrote: > > On Tue, Feb 26, 2019 at 10:59 AM Souptick Joarder > wrote: > > > > On Tue, Feb 26, 2019 at 7:18 AM Michael Ellerman > > wrote: > > > > > > Souptick Joarder writes: > > > > Remove duplicate headers which are included twice. > > > > > >

BUG: MAX_LOCKDEP_CHAIN_HLOCKS too low!

2019-03-06 Thread syzbot
Hello, syzbot found the following crash on: HEAD commit:cf08baa29613 Add linux-next specific files for 20190306 git tree: linux-next console output: https://syzkaller.appspot.com/x/log.txt?x=15bc76c720 kernel config: https://syzkaller.appspot.com/x/.config?x=c8b6073d992e8217

Re: [PATCH] appletalk: Correctly handle return value of register_snap_client

2019-03-06 Thread David Miller
From: Yue Haibing Date: Wed, 6 Mar 2019 15:27:40 +0800 > @@ -879,15 +879,17 @@ static struct notifier_block aarp_notifier = { > > static unsigned char aarp_snap_id[] = { 0x00, 0x00, 0x00, 0x80, 0xF3 }; > > -void __init aarp_proto_init(void) > +int __init aarp_proto_init(void) > { > aa

Re: [PATCH net 1/3] sctp: sctp_sock_migrate() returns error if sctp_bind_addr_dup() fails

2019-03-06 Thread Neil Horman
On Sun, Mar 03, 2019 at 05:54:53PM +0800, Xin Long wrote: > It should fail to create the new sk if sctp_bind_addr_dup() fails > when accepting or peeloff an association. > > Signed-off-by: Xin Long > --- > net/sctp/socket.c | 34 -- > 1 file changed, 24 insertions

Re: [PATCH net 2/3] sctp: move up sctp_auth_init_hmacs() in sctp_endpoint_init()

2019-03-06 Thread Neil Horman
On Sun, Mar 03, 2019 at 05:54:54PM +0800, Xin Long wrote: > sctp_auth_init_hmacs() is called only when ep->auth_enable is set. > It better to move up sctp_auth_init_hmacs() and remove auth_enable > check in it and check auth_enable only once in sctp_endpoint_init(). > > Signed-off-by: Xin Long >

Re: [PATCH net 3/3] sctp: call sctp_auth_init_hmacs() in sctp_sock_migrate()

2019-03-06 Thread Neil Horman
On Sun, Mar 03, 2019 at 05:54:55PM +0800, Xin Long wrote: > New ep's auth_hmacs should be set if old ep's is set, in case that > net->sctp.auth_enable has been changed to 0 by users and new ep's > auth_hmacs couldn't be set in sctp_endpoint_init(). > > It can even crash kernel by doing: > > 1.

Re: [PATCH net v2] ipv4/route: fail early when inet dev is missing

2019-03-06 Thread David Miller
From: Paolo Abeni Date: Wed, 6 Mar 2019 10:42:53 +0100 > If a non local multicast packet reaches ip_route_input_rcu() while > the ingress device IPv4 private data (in_dev) is NULL, we end up > doing a NULL pointer dereference in IN_DEV_MFORWARD(). > > Since the later call to ip_route_input_mc()

Re: [PATCH net] net: hns3: Fix a logical vs bitwise typo

2019-03-06 Thread David Miller
From: Dan Carpenter Date: Wed, 6 Mar 2019 11:12:34 +0300 > There were a couple logical ORs accidentally mixed in with the bitwise > ORs. > > Fixes: e8149933b1fa ("net: hns3: remove hnae3_get_bit in data path") > Signed-off-by: Dan Carpenter > --- > Very recent bug. Applied.

Re: [RFC PATCH V2 4/5] vhost: introduce helpers to get the size of metadata area

2019-03-06 Thread Souptick Joarder
On Wed, Mar 6, 2019 at 12:48 PM Jason Wang wrote: > > Signed-off-by: Jason Wang Is the change log left with any particular reason ? > --- > drivers/vhost/vhost.c | 46 -- > 1 file changed, 28 insertions(+), 18 deletions(-) > > diff --git a/drivers/vho

[PATCH net] fou, fou6: avoid uninit-value in gue_err() and gue6_err()

2019-03-06 Thread Eric Dumazet
My prior commit missed the fact that these functions were using udp_hdr() (aka skb_transport_header()) to get access to GUE header. Since use pskb_transport_may_pull() does not exist yet, we have to add transport_offset to our pskb_may_pull() calls. BUG: KMSAN: uninit-value in gue_err+0x514/0xfa0

Re: [PATCH net] iptunnel: NULL pointer deref for ip_md_tunnel_xmit

2019-03-06 Thread David Miller
From: Alan Maguire Date: Wed, 6 Mar 2019 10:25:42 + (GMT) > Naresh Kamboju noted the following oops during execution of selftest > tools/testing/selftests/bpf/test_tunnel.sh on x86_64: ... > I'm also seeing the same failure on x86_64, and it reproduces > consistently. > > From poking around

Re: [PATCH 1/2] appletalk: Fix compile regression

2019-03-06 Thread David Miller
From: Arnd Bergmann Date: Wed, 6 Mar 2019 11:52:36 +0100 > A bugfix just broke compilation of appletalk when CONFIG_SYSCTL > is disabled: > > In file included from net/appletalk/ddp.c:65: > net/appletalk/ddp.c: In function 'atalk_init': > include/linux/atalk.h:164:34: error: expected expression

Re: [PATCH 2/2] appletalk: Add atalk.h header files to MAINTAINERS file

2019-03-06 Thread David Miller
From: Arnd Bergmann Date: Wed, 6 Mar 2019 11:52:37 +0100 > Add the path names here so that git-send-email can pick up the > netdev@vger.kernel.org Cc line automatically for a patch that > only touches the headers. > > Signed-off-by: Arnd Bergmann Applied.

Re: [PATCH] tcp: detecting the misuse of .sendpage for Slab objects

2019-03-06 Thread David Miller
From: Vasily Averin Date: Wed, 6 Mar 2019 14:10:22 +0300 > sendpage was not designed for processing of the Slab pages, > in some situations it can trigger BUG_ON on receiving side. > > Signed-off-by: Vasily Averin Applied.

Re: [PATCH mlx5-next] net/mlx5: Fix DCT creation bad flow

2019-03-06 Thread Jason Gunthorpe
On Wed, Mar 06, 2019 at 07:20:50PM +0200, Leon Romanovsky wrote: > From: Yishai Hadas > > In case the DCT creation command has succeeded a DRAIN must be issued > before calling DESTROY. > > In addition, the original code used the wrong parameter for the DESTROY > command, 'in' instead of 'din',

Re: [PATCH net] net: sched: flower: insert new filter to idr after setting its mask

2019-03-06 Thread David Miller
From: Vlad Buslov Date: Wed, 6 Mar 2019 16:22:12 +0200 > When adding new filter to flower classifier, fl_change() inserts it to > handle_idr before initializing filter extensions and assigning it a mask. > Normally this ordering doesn't matter because all flower classifier ops > callbacks assume

Re: [PATCH mlx5-next] net/mlx5: Fix DCT creation bad flow

2019-03-06 Thread Leon Romanovsky
On Wed, Mar 06, 2019 at 08:52:16PM +0200, Jason Gunthorpe wrote: > On Wed, Mar 06, 2019 at 07:20:50PM +0200, Leon Romanovsky wrote: > > From: Yishai Hadas > > > > In case the DCT creation command has succeeded a DRAIN must be issued > > before calling DESTROY. > > > > In addition, the original cod

Re: [PATCH net] net: hsr: fix memory leak in hsr_dev_finalize()

2019-03-06 Thread David Miller
From: Mao Wenan Date: Wed, 6 Mar 2019 22:45:01 +0800 > If hsr_add_port(hsr, hsr_dev, HSR_PT_MASTER) failed to > add port, it directly returns res and forgets to free the node > that allocated in hsr_create_self_node(), and forgets to delete > the node->mac_list linked in hsr->self_node_db. ... >

Re: [PATCH net] tcp: do not report TCP_CM_INQ of 0 for closed connections

2019-03-06 Thread David Miller
From: Soheil Hassas Yeganeh Date: Wed, 6 Mar 2019 13:01:36 -0500 > From: Soheil Hassas Yeganeh > > Returning 0 as inq to userspace indicates there is no more data to > read, and the application needs to wait for EPOLLIN. For a connection > that has received FIN from the remote peer, however, t

Re: [PATCH net] fou, fou6: avoid uninit-value in gue_err() and gue6_err()

2019-03-06 Thread Stefano Brivio
On Wed, 6 Mar 2019 10:41:00 -0800 Eric Dumazet wrote: > My prior commit missed the fact that these functions > were using udp_hdr() (aka skb_transport_header()) > to get access to GUE header. Ouch, I totally missed this too. :/ > Since use pskb_transport_may_pull() does not exist yet, Nit: s/

[PATCH bpf] bpf: only test gso type on gso packets

2019-03-06 Thread Willem de Bruijn
From: Willem de Bruijn BPF can adjust gso only for tcp bytestreams. Fail on other gso types. But only on gso packets. It does not touch this field if !gso_size. Fixes: b90efd225874 ("bpf: only adjust gso_size on bytestream protocols") Signed-off-by: Willem de Bruijn --- Stupid bug on my part

[PATCH net-next] 8139too : Add support for U.S. Robotics USR997901A 10/100 Cardbus NIC

2019-03-06 Thread Matthew Whitehead
Add PCI vendor and device identifier for U.S. Robotics USR997901A 10/100 Cardbus NIC. Tested on real hardware. Signed-off-by: Matthew Whitehead --- drivers/net/ethernet/realtek/8139too.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/net/ethernet/realtek/8139too.c b/drivers/net/eth

Re: [PATCH mlx5-next] net/mlx5: ODP support for XRC transport is not enabled by default in FW

2019-03-06 Thread Jason Gunthorpe
On Mon, Feb 25, 2019 at 08:54:39AM +0200, Leon Romanovsky wrote: > From: Moni Shoua > > ODP support for XRC transport is not enabled by default in FW, > so we need separate ODP checks to enable/disable it. > > While that, rewrite the set of ODP SRQ support capabilities in way > that tests each f

[PATCH bpf 2/2] libbpf: force fixdep compilation at the start of the build

2019-03-06 Thread Stanislav Fomichev
libbpf targets don't explicitly depend on fixdep target, so when we do 'make -j$(nproc)', there is a high probability, that some objects will be built before fixdep binary is available. Fix this by running sub-make; this makes sure that fixdep dependency is properly accounted for. For the same is

[PATCH bpf 1/2] selftests: bpf: fix compilation with out-of-tree $(OUTPUT)

2019-03-06 Thread Stanislav Fomichev
A bunch of related changes lumped together: * Create prog_tests and verifier output directories; these don't exist with out-of-tree $(OUTPUT) * Add missing -I (via separate TEST_{PROGS,VERIFIER}_CFLAGS) for the main tree ($(PWD) != $(OUTPUT) for out-of-tree) * Add libbpf.a dependency for test_p

[PATCH RFC v2] mac80211: debugfs option to force TX status frames

2019-03-06 Thread Julius Niedworok
At Technical University of Munich we use MAC 802.11 TX status frames to perform several measurements in MAC 802.11 setups. With ath based drivers this was possible until commit d94a461d7a7df6 ("ath9k: use ieee80211_tx_status_noskb where possible") as the driver ignored the IEEE80211_TX_CTL_REQ_TX_

[PATCH 2/2] ip6mr: Make cache queue length configurable

2019-03-06 Thread Brodie Greenfield
We want to be able to keep more spaces available in our queue for processing incoming IPv6 multicast traffic (adding (S,G) entries) - this lets us learn more groups faster, rather than dropping them at this stage. Signed-off-by: Brodie Greenfield --- Documentation/networking/ip-sysctl.txt | 8 ++

[PATCH 0/2] Make ipmr queue length configurable

2019-03-06 Thread Brodie Greenfield
We want to have some more space in our queue for processing incoming multicast packets, so we can process more of them without dropping them prematurely. It is useful to be able to increase this limit on higher-spec platforms that can handle more items. For the particular use case here at Allied T

[PATCH 1/2] ipmr: Make cache queue length configurable

2019-03-06 Thread Brodie Greenfield
We want to be able to keep more spaces available in our queue for processing incoming multicast traffic (adding (S,G) entries) - this lets us learn more groups faster, rather than dropping them at this stage. Signed-off-by: Brodie Greenfield --- Documentation/networking/ip-sysctl.txt | 8 +++

Re: [PATCH 2/2] ip6mr: Make cache queue length configurable

2019-03-06 Thread Chris Packham
On 7/03/19 9:20 AM, Brodie Greenfield wrote: > We want to be able to keep more spaces available in our queue for > processing incoming IPv6 multicast traffic (adding (S,G) entries) - this > lets us learn more groups faster, rather than dropping them at this stage. > > Signed-off-by: Brodie Greenfi

Re: [PATCH] xfrm: Reset secpath in xfrm failure

2019-03-06 Thread Myungho Jung
On Wed, Mar 06, 2019 at 12:35:43PM +0100, Steffen Klassert wrote: > On Wed, Mar 06, 2019 at 04:33:08PM +0900, Myungho Jung wrote: > > In esp4_gro_receive() and esp6_gro_receive(), secpath can be allocated > > without adding xfrm state to xvec. Then, sp->xvec[sp->len - 1] would > > fail and result i

Re: [PATCH v1 iproute2-next 1/4] rdma: add helper rd_sendrecv_msg()

2019-03-06 Thread Steve Wise
On 3/4/2019 8:13 AM, Steve Wise wrote: > Hey Leon, adding this to rd_recv_msg(): > > @@ -693,10 +693,28 @@ int rd_recv_msg(struct rd *rd, mnl_cb_t callback, void > *data, unsigned int seq) > ret = mnl_cb_run(buf, ret, seq, portid, callback, data); > } while (ret > 0); > >

Re: [PATCH] connector: fix unsafe usage of ->real_parent

2019-03-06 Thread Evgeniy Polyakov
Hi 06.03.2019, 09:46, "Li RongQing" : > proc_exit_connector() uses ->real_parent lockless. This is not > safe that its parent can go away at any moment, so use RCU to > protect it, and ensure that this task is not released. > > Fixes: b086ff87251b4a4 ("connector: add parent pid and tgid to coredu

[PATCH v2] xfrm: Reset secpath in xfrm failure

2019-03-06 Thread Myungho Jung
In esp4_gro_receive() and esp6_gro_receive(), secpath can be allocated without adding xfrm state to xvec. Then, sp->xvec[sp->len - 1] would fail and result in dereferencing invalid pointer in esp4_gso_segment() and esp6_gso_segment(). Reset secpath if xfrm function returns error. Fixes: 7785bba299

TAHI testing fails for IPv6 Fragments in Kernel 4.9

2019-03-06 Thread Captain Wiggum
We are using the TAHI Self-test tools from IPv6 Ready Logo Program: https://www.ipv6ready.org/?page=documents&tag=ipv6-core-protocols The test passed up to 4.9.133, then fails ever since. The are about 20 failing test cases regarding IPv6 fragments, where the kernel is issuing an ICMPv6 parameter

Re: TAHI testing fails for IPv6 Fragments in Kernel 4.9

2019-03-06 Thread David Miller
From: Captain Wiggum Date: Wed, 6 Mar 2019 15:26:43 -0700 > We are using the TAHI Self-test tools from IPv6 Ready Logo Program: > https://www.ipv6ready.org/?page=documents&tag=ipv6-core-protocols > > The test passed up to 4.9.133, then fails ever since. > > The are about 20 failing test cases r

Re: TAHI testing fails for IPv6 Fragments in Kernel 4.9

2019-03-06 Thread Florian Fainelli
On 3/6/19 2:26 PM, Captain Wiggum wrote: > We are using the TAHI Self-test tools from IPv6 Ready Logo Program: > https://www.ipv6ready.org/?page=documents&tag=ipv6-core-protocols > > The test passed up to 4.9.133, then fails ever since. > > The are about 20 failing test cases regarding IPv6 fragm

Re: [PATCH v2] xfrm: Reset secpath in xfrm failure

2019-03-06 Thread Eric Dumazet
On 03/06/2019 01:55 PM, Myungho Jung wrote: > In esp4_gro_receive() and esp6_gro_receive(), secpath can be allocated > without adding xfrm state to xvec. Then, sp->xvec[sp->len - 1] would > fail and result in dereferencing invalid pointer in esp4_gso_segment() > and esp6_gso_segment(). Reset sec

Re: TAHI testing fails for IPv6 Fragments in Kernel 4.9

2019-03-06 Thread Eric Dumazet
On 03/06/2019 02:28 PM, David Miller wrote: > From: Captain Wiggum > Date: Wed, 6 Mar 2019 15:26:43 -0700 > >> We are using the TAHI Self-test tools from IPv6 Ready Logo Program: >> https://www.ipv6ready.org/?page=documents&tag=ipv6-core-protocols >> >> The test passed up to 4.9.133, then fail

Re: TAHI testing fails for IPv6 Fragments in Kernel 4.9

2019-03-06 Thread David Miller
From: Eric Dumazet Date: Wed, 6 Mar 2019 14:34:25 -0800 > That was Florian patch that was later reverted, right ? > > 0ed4229b08c13c84a3c301a08defdc9e7f4467e6 ipv6: defrag: drop non-last frags > smaller than min mtu > > -> reverted in > > d4289fcc9b16b89619ee1c54f829e05e56de8b9a net: IP6 def

Re: TAHI testing fails for IPv6 Fragments in Kernel 4.9

2019-03-06 Thread Captain Wiggum
Thank you all for the reply. The problem started with 4.9.133, and persists to latest 4.9 today. I will work on the bisect approach to find the bad commit(s). It will take a few days. I will reply back when I have more info. On Wed, Mar 6, 2019 at 3:34 PM Eric Dumazet wrote: > > > > On 03/06/2019

Re: [Linuxptp-devel] strangeness

2019-03-06 Thread Paul Thomas
On Fri, Mar 1, 2019 at 1:24 AM Harini Katakam wrote: > > +netdev > > Hi Paul, > On Fri, Mar 1, 2019 at 12:29 AM Richard Cochran > wrote: > > > > On Thu, Feb 28, 2019 at 12:33:26PM -0500, Paul Thomas wrote: > > > Yes changing it to TSTAMP_ALL_PTP_FRAMES instead of TSTAMP_ALL_FRAMES > > > does seem

[PATCH bpf] selftests: bpf: test_progs: initialize duration in singal_pending test

2019-03-06 Thread Stanislav Fomichev
CHECK macro implicitly uses duration. We call CHECK() a couple of times before duration is initialized from bpf_prog_test_run(). Explicitly set duration to 0 to avoid compiler warnings. Fixes: 740f8a657221 ("selftests/bpf: make sure signal interrupts BPF_PROG_TEST_RUN") Signed-off-by: Stanislav

Re: [RFC PATCH net-next] failover: allow name change on IFF_UP slave interfaces

2019-03-06 Thread Liran Alon
> On 6 Mar 2019, at 23:42, si-wei liu wrote: > > > > On 3/6/2019 1:36 PM, Samudrala, Sridhar wrote: >> >> On 3/6/2019 1:26 PM, si-wei liu wrote: >>> >>> >>> On 3/6/2019 4:04 AM, Jiri Pirko wrote: > --- a/net/core/failover.c > +++ b/net/core/failover.c > @@ -16,6 +16,11 @@

[PATCH 7/8] deal with get_reqs_available() in aio_get_req() itself

2019-03-06 Thread Al Viro
From: Al Viro simplifies the caller Signed-off-by: Al Viro --- fs/aio.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/fs/aio.c b/fs/aio.c index 5837a29e63fe..af51b1360305 100644 --- a/fs/aio.c +++ b/fs/aio.c @@ -1029,6 +1029,11 @@ static inline struct aio_kio

[PATCH 6/8] move dropping ->ki_eventfd into iocb_put()

2019-03-06 Thread Al Viro
From: Al Viro Signed-off-by: Al Viro --- fs/aio.c | 17 - 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/fs/aio.c b/fs/aio.c index 5dd5f35d054c..5837a29e63fe 100644 --- a/fs/aio.c +++ b/fs/aio.c @@ -1066,6 +1066,8 @@ static struct kioctx *lookup_ioctx(unsigned lon

  1   2   >