[PATCH net-next 3/3] mptcp: add MP_FASTCLOSE suboption handling

2020-06-15 Thread Geliang Tang
Add handling for sending and receiving MP_FASTCLOSE suboption. Signed-off-by: Geliang Tang --- net/mptcp/options.c | 16 net/mptcp/protocol.h | 2 ++ 2 files changed, 18 insertions(+) diff --git a/net/mptcp/options.c b/net/mptcp/options.c index 82b3d7c566b4..a99b3989fec1 1006

Re: [PATCH bpf 1/2] bpf: bpf_probe_read_kernel_str() has to return amount of data read on success

2020-06-15 Thread Christoph Hellwig
On Mon, Jun 15, 2020 at 10:04:30PM -0700, Andrii Nakryiko wrote: > During recent refactorings, bpf_probe_read_kernel_str() started returning 0 on > success, instead of amount of data successfully read. This majorly breaks > applications relying on bpf_probe_read_kernel_str() and bpf_probe_read_str(

[PATCH net-next 2/3] mptcp: add MP_FAIL suboption handling

2020-06-15 Thread Geliang Tang
Add handling for sending and receiving MP_FAIL suboption. Signed-off-by: Geliang Tang --- net/mptcp/options.c | 18 ++ net/mptcp/protocol.h | 2 ++ 2 files changed, 20 insertions(+) diff --git a/net/mptcp/options.c b/net/mptcp/options.c index cc3039f0ac43..82b3d7c566b4 100644

[PATCH net-next 1/3] mptcp: add MP_PRIO suboption handling

2020-06-15 Thread Geliang Tang
Add handling for sending and receiving MP_PRIO suboption. Signed-off-by: Geliang Tang --- net/mptcp/options.c | 14 ++ net/mptcp/protocol.h | 5 + 2 files changed, 19 insertions(+) diff --git a/net/mptcp/options.c b/net/mptcp/options.c index 490b92534afc..cc3039f0ac43 100644 -

[PATCH net-next 0/3] add MP_PRIO, MP_FAIL and MP_FASTCLOSE suboptions handling

2020-06-15 Thread Geliang Tang
Add handling for sending and receiving the MP_PRIO, MP_FAIL, and MP_FASTCLOSE suboptions. Geliang Tang (3): mptcp: add MP_PRIO suboption handling mptcp: add MP_FAIL suboption handling mptcp: add MP_FASTCLOSE suboption handling net/mptcp/options.c | 48 +

Re: [PATCH 4/5] Huawei BMA: Adding Huawei BMA driver: cdev_veth_drv

2020-06-15 Thread kernel test robot
Hi, Thank you for the patch! Perhaps something to improve: [auto build test WARNING on linus/master] [also build test WARNING on v5.8-rc1 next-20200616] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system. BTW, we also suggest to use '--base' option t

Re: [PATCH 2/5] Huawei BMA: Adding Huawei BMA driver: host_cdev_drv

2020-06-15 Thread kernel test robot
Hi, Thank you for the patch! Yet something to improve: [auto build test ERROR on linus/master] [also build test ERROR on v5.8-rc1 next-20200616] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system. BTW, we also suggest to use '--base' option to specif

Re: [PATCH v4 1/3] mm/slab: Use memzero_explicit() in kzfree()

2020-06-15 Thread Michal Hocko
On Mon 15-06-20 21:57:16, Waiman Long wrote: > The kzfree() function is normally used to clear some sensitive > information, like encryption keys, in the buffer before freeing it back > to the pool. Memset() is currently used for the buffer clearing. However, > it is entirely possible that the comp

[PATCH v2] tc: qdisc: filter qdisc's by parent/handle specification

2020-06-15 Thread Anton Danilov
There wasn't a way to get a qdisc info by handle or parent, only full dump of qdisc's with following grep/sed usage. The 'qdisc get' command have been added. tc qdisc { show | get } [ dev STRING ] [ QDISC_ID ] [ invisible ] QDISC_ID := { root | ingress | handle QHANDLE | parent CLASSID } This

Re: [PATCH net v5 0/3] esp, ah: improve crypto algorithm selections

2020-06-15 Thread Steffen Klassert
On Mon, Jun 15, 2020 at 03:13:15PM -0700, Eric Biggers wrote: > This series consolidates and modernizes the lists of crypto algorithms > that are selected by the IPsec kconfig options, and adds CRYPTO_SEQIV > since it no longer gets selected automatically by other things. > > See previous discussi

Re: [PATCH v2 1/7] Bluetooth: Add definitions for advertisement monitor features

2020-06-15 Thread Miao-chen Chou
Hi Marcel, https://patchwork.kernel.org/patch/11606491/ was uploaded for review. Thanks, Miao On Fri, Jun 12, 2020 at 11:17 PM Marcel Holtmann wrote: > > Hi Miao-chen, > > > The name in the mgmt-api.txt doc is "Add Advertisement Patterns > > Monitor Command", and Luiz changed the name from > >

[PATCH net] bareudp: Fixed configuration to avoid having garbage values

2020-06-15 Thread Martin Varghese
From: Martin Code to initialize the conf structure while gathering the configuration of the device was missing. Fixes: 571912c69f0e ("net: UDP tunnel encapsulation module for tunnelling different protocols like MPLS, IP, NSH etc.") Signed-off-by: Martin --- drivers/net/bareudp.c | 2 ++ 1 fil

Re: [PATCH v4 02/11] fs: Move __scm_install_fd() to __fd_install_received()

2020-06-15 Thread Kees Cook
On Tue, Jun 16, 2020 at 05:29:41AM +, Sargun Dhillon wrote: > On Mon, Jun 15, 2020 at 08:25:15PM -0700, Kees Cook wrote: > > +/** > > + * __fd_install_received() - Install received file into file descriptor > > table > > + * > > + * @fd: fd to install into (if negative, a new fd will be alloca

Re: [PATCH v4 02/11] fs: Move __scm_install_fd() to __fd_install_received()

2020-06-15 Thread Sargun Dhillon
On Mon, Jun 15, 2020 at 08:25:15PM -0700, Kees Cook wrote: > In preparation for users of the "install a received file" logic outside > of net/ (pidfd and seccomp), relocate and rename __scm_install_fd() from > net/core/scm.c to __fd_install_received() in fs/file.c, and provide a > wrapper named fd_

[PATCH bpf 2/2] selftests/bpf: add variable-length data concatenation pattern test

2020-06-15 Thread Andrii Nakryiko
Add selftest that validates variable-length data reading and concatentation with one big shared data array. This is a common pattern in production use for monitoring and tracing applications, that potentially can read a lot of data, but usually reads much less. Such pattern allows to determine prec

[PATCH bpf 1/2] bpf: bpf_probe_read_kernel_str() has to return amount of data read on success

2020-06-15 Thread Andrii Nakryiko
During recent refactorings, bpf_probe_read_kernel_str() started returning 0 on success, instead of amount of data successfully read. This majorly breaks applications relying on bpf_probe_read_kernel_str() and bpf_probe_read_str() and their results. Fix this by returning actual number of bytes read.

Re: [PATCH 1/5] Huawei BMA: Adding Huawei BMA driver: host_edma_drv

2020-06-15 Thread kernel test robot
Hi, Thank you for the patch! Yet something to improve: [auto build test ERROR on linus/master] [also build test ERROR on v5.8-rc1 next-20200615] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system. BTW, we also suggest to use '--base'

[PATCH 1/1 v2] mvpp2: remove module bugfix

2020-06-15 Thread Sven Auhagen
The remove function does not destroy all BM Pools when per cpu pool is active. When reloading the mvpp2 as a module the BM Pools are still active in hardware and due to the bug have twice the size now old + new. This eventually leads to a kernel crash. v2: * add Fixes tag Fixes: 7d04b0b13b11 ("

Re: [PATCH 00/17] spelling.txt: /decriptors/descriptors/

2020-06-15 Thread Martin K. Petersen
On Tue, 9 Jun 2020 13:45:53 +0100, Kieran Bingham wrote: > I wouldn't normally go through spelling fixes, but I caught sight of > this typo twice, and then foolishly grepped the tree for it, and saw how > pervasive it was. > > so here I am ... fixing a typo globally... but with an addition in > s

Re: [PATCH bpf 1/2] flow_dissector: reject invalid attach_flags

2020-06-15 Thread Alexei Starovoitov
On Mon, Jun 15, 2020 at 7:43 AM Lorenz Bauer wrote: > > On Fri, 12 Jun 2020 at 23:36, Alexei Starovoitov > wrote: > > > > On Fri, Jun 12, 2020 at 9:02 AM Lorenz Bauer wrote: > > > > > > Using BPF_PROG_ATTACH on a flow dissector program supports neither flags > > > nor target_fd but accepts any v

Re: linux-next: build failures after merge of the vfs tree

2020-06-15 Thread Al Viro
On Tue, Jun 16, 2020 at 11:05:02AM +1000, Herbert Xu wrote: > On Tue, Jun 16, 2020 at 10:34:40AM +1000, Stephen Rothwell wrote: > > [Just adding Herbert to cc] > > > > On Tue, 16 Jun 2020 10:33:30 +1000 Stephen Rothwell > > wrote: > > > > > > Hi all, > > > > > > After merging the vfs tree, toda

Re: [PATCH v4 1/3] mm/slab: Use memzero_explicit() in kzfree()

2020-06-15 Thread Eric Biggers
On Mon, Jun 15, 2020 at 09:57:16PM -0400, Waiman Long wrote: > The kzfree() function is normally used to clear some sensitive > information, like encryption keys, in the buffer before freeing it back > to the pool. Memset() is currently used for the buffer clearing. However, > it is entirely possib

[PATCH net v3 1/4] flow_offload: fix incorrect cleanup for flowtable indirect flow_blocks

2020-06-15 Thread wenxu
From: wenxu The cleanup operation based on the setup callback. But in the mlx5e driver there are tc and flowtable indrict setup callback and shared the same release callbacks. So when the representor is removed, then identify the indirect flow_blocks that need to be removed by the release callb

[PATCH net v3 3/4] net/sched: cls_api: fix nooffloaddevcnt warning dmesg log

2020-06-15 Thread wenxu
From: wenxu When a indr device add in offload success. The block->nooffloaddevcnt should be 0. After the representor go away. When the dir device go away the flow_block UNBIND operation with -EOPNOTSUPP which lead the warning dmesg log. The block->nooffloaddevcnt should always count for indr bl

[PATCH v4 02/11] fs: Move __scm_install_fd() to __fd_install_received()

2020-06-15 Thread Kees Cook
In preparation for users of the "install a received file" logic outside of net/ (pidfd and seccomp), relocate and rename __scm_install_fd() from net/core/scm.c to __fd_install_received() in fs/file.c, and provide a wrapper named fd_install_received_user(), as future patches will change the interfac

[PATCH v4 05/11] fs: Expand __fd_install_received() to accept fd

2020-06-15 Thread Kees Cook
Expand __fd_install_received() with support for replace_fd() for the coming seccomp "addfd" ioctl(). Add new wrapper fd_replace_received() for the new mode and update existing wrappers to retain old mode. Signed-off-by: Kees Cook --- fs/file.c| 22 -- include/linu

[PATCH v4 03/11] fs: Add fd_install_received() wrapper for __fd_install_received()

2020-06-15 Thread Kees Cook
For both pidfd and seccomp, the __user pointer is not used. Update __fd_install_received() to make writing to ufd optional. (ufd itself cannot checked for NULL because this changes the SCM_RIGHTS interface behavior.) In these cases, the new fd needs to be returned on success. Update the existing c

[PATCH v4 09/11] selftests/seccomp: Rename user_trap_syscall() to user_notif_syscall()

2020-06-15 Thread Kees Cook
The user_trap_syscall() helper creates a filter with SECCOMP_RET_USER_NOTIF. To avoid confusion with SECCOMP_RET_TRAP, rename the helper to user_notif_syscall(). Additionally fix a redundant "return" after XFAIL. Signed-off-by: Kees Cook --- tools/testing/selftests/seccomp/seccomp_bpf.c | 60 ++

[PATCH v4 07/11] selftests/seccomp: Test SECCOMP_IOCTL_NOTIF_ADDFD

2020-06-15 Thread Kees Cook
From: Sargun Dhillon Test whether we can add file descriptors in response to notifications. This injects the file descriptors via notifications, and then uses kcmp to determine whether or not it has been successful. It also includes some basic sanity checking for arguments. Signed-off-by: Sargu

[PATCH v4 00/11] Add seccomp notifier ioctl that enables adding fds

2020-06-15 Thread Kees Cook
Hello! This is a bit of thread-merge between [1] and [2]. tl;dr: add a way for a seccomp user_notif process manager to inject files into the managed process in order to handle emulation of various fd-returning syscalls across security boundaries. Containers folks and Chrome are in need of the feat

[PATCH v4 11/11] seccomp: Fix ioctl number for SECCOMP_IOCTL_NOTIF_ID_VALID

2020-06-15 Thread Kees Cook
When SECCOMP_IOCTL_NOTIF_ID_VALID was first introduced it had the wrong direction flag set. While this isn't a big deal as nothing currently enforces these bits in the kernel, it should be defined correctly. Fix the define and provide support for the old command until it is no longer needed for bac

[PATCH v4 06/11] seccomp: Introduce addfd ioctl to seccomp user notifier

2020-06-15 Thread Kees Cook
From: Sargun Dhillon This adds a seccomp notifier ioctl which allows for the listener to "add" file descriptors to a process which originated a seccomp user notification. This allows calls like mount, and mknod to be "implemented", as the return value, and the arguments are data in memory. On the

[PATCH v4 01/11] net/scm: Regularize compat handling of scm_detach_fds()

2020-06-15 Thread Kees Cook
Duplicate the cleanups from commit 2618d530dd8b ("net/scm: cleanup scm_detach_fds") into the compat code. Move the check added in commit 1f466e1f15cf ("net: cleanly handle kernel vs user buffers for ->msg_control") to before the compat call, even though it should be impossible for an in-kernel cal

[PATCH v4 04/11] pidfd: Replace open-coded partial fd_install_received()

2020-06-15 Thread Kees Cook
The sock counting (sock_update_netprioidx() and sock_update_classid()) was missing from pidfd's implementation of received fd installation. Replace the open-coded version with a call to the new fd_install_received() helper. Fixes: 8649c322f75c ("pid: Implement pidfd_getfd syscall") Signed-off-by:

[PATCH v4 10/11] seccomp: Switch addfd to Extensible Argument ioctl

2020-06-15 Thread Kees Cook
This patch is based on discussions[1] with Sargun Dhillon, Christian Brauner, and David Laight. Instead of building size into the addfd structure, make it a function of the ioctl command (which is how sizes are normally passed to ioctls). To support forward and backward compatibility, just mask out

[PATCH v4 08/11] selftests/seccomp: Make kcmp() less required

2020-06-15 Thread Kees Cook
The seccomp tests are a bit noisy without CONFIG_CHECKPOINT_RESTORE (due to missing the kcmp() syscall). The seccomp tests are more accurate with kcmp(), but it's not strictly required. Refactor the tests to use alternatives (comparing fd numbers), and provide a central test for kcmp() so there is

[PATCH net v3 4/4] flow_offload: fix the list_del corruption in the driver list

2020-06-15 Thread wenxu
From: wenxu When a indr device add in offload success. After the representor go away. All the flow_block_cb cleanup but miss del form driver list. Fixes: 0fdcf78d5973 ("net: use flow_indr_dev_setup_offload()") Signed-off-by: wenxu --- net/netfilter/nf_flow_table_offload.c | 1 + net/netfilter/

[PATCH net v3 2/4] flow_offload: fix incorrect cb_priv check for flow_block_cb

2020-06-15 Thread wenxu
From: wenxu In the function __flow_block_indr_cleanup, The match stataments this->cb_priv == cb_priv is always false, the flow_block_cb->cb_priv is totally different data with the flow_indr_dev->cb_priv. Store the representor cb_priv to the flow_block_cb->indr.cb_priv in the driver. Fixes: 1fac

[PATCH net v3 0/4] several fixes for indirect flow_blocks offload

2020-06-15 Thread wenxu
From: wenxu v2: patch2: store the cb_priv of representor to the flow_block_cb->indr.cb_priv in the driver. And make the correct check with the statments this->indr.cb_priv == cb_priv patch4: del the driver list only in the indriect cleanup callbacks v3: add the cover letter and changlogs. This

Re: [PATCH v3 03/13] RDMA/rds: Remove FMR support for memory registration

2020-06-15 Thread santosh . shilimkar
On 5/29/20 12:12 PM, Jason Gunthorpe wrote: On Thu, May 28, 2020 at 01:21:33PM -0700, santosh.shilim...@oracle.com wrote: On 5/28/20 12:45 PM, Jason Gunthorpe wrote: From: Max Gurtovoy Use FRWR method for memory registration by default and remove the ancient and unsafe FMR method. Signed-off

[PATCH 1/1] openvswitch: fix infoleak in conntrack

2020-06-15 Thread Xidong Wang
From: xidongwang The stack object “zone_limit” has 3 members. In function ovs_ct_limit_get_default_limit(), the member "count" is not initialized and sent out via “nla_put_nohdr”. Signed-off-by: xidongwang --- net/openvswitch/conntrack.c | 1 + 1 file changed, 1 insertion(+) diff --git a/net/

[PATCH 5/5] Huawei BMA: Adding Huawei BMA driver: host_kbox_drv

2020-06-15 Thread yunaixin03610
From: yunaixin The BMA software is a system management software offered by Huawei. It supports the status monitoring, performance monitoring, and event monitoring of various components, including server CPUs, memory, hard disks, NICs, IB cards, PCIe cards, RAID controller cards, and optical mo

[PATCH 4/5] Huawei BMA: Adding Huawei BMA driver: cdev_veth_drv

2020-06-15 Thread yunaixin03610
From: yunaixin The BMA software is a system management software offered by Huawei. It supports the status monitoring, performance monitoring, and event monitoring of various components, including server CPUs, memory, hard disks, NICs, IB cards, PCIe cards, RAID controller cards, and optical mo

[PATCH 3/5] Huawei BMA: Adding Huawei BMA driver: host_veth_drv

2020-06-15 Thread yunaixin03610
From: yunaixin The BMA software is a system management software offered by Huawei. It supports the status monitoring, performance monitoring, and event monitoring of various components, including server CPUs, memory, hard disks, NICs, IB cards, PCIe cards, RAID controller cards, and optical mo

RE: [EXT] Re: [PATCH] net: fec: fix ref count leaking when pm_runtime_get_sync fails

2020-06-15 Thread Andy Duan
From: David Miller Sent: Tuesday, June 16, 2020 4:42 AM > From: Navid Emamdoost > Date: Sun, 14 Jun 2020 00:38:01 -0500 > > > in fec_enet_mdio_read, fec_enet_mdio_write, fec_enet_get_regs, > > fec_enet_open and fec_drv_remove, pm_runtime_get_sync is called which > > increments the counter even i

[PATCH v4 2/3] mm, treewide: Rename kzfree() to kfree_sensitive()

2020-06-15 Thread Waiman Long
As said by Linus: A symmetric naming is only helpful if it implies symmetries in use. Otherwise it's actively misleading. In "kzalloc()", the z is meaningful and an important part of what the caller wants. In "kzfree()", the z is actively detrimental, because maybe in the future we r

[PATCH v4 3/3] btrfs: Use kfree() in btrfs_ioctl_get_subvol_info()

2020-06-15 Thread Waiman Long
In btrfs_ioctl_get_subvol_info(), there is a classic case where kzalloc() was incorrectly paired with kzfree(). According to David Sterba, there isn't any sensitive information in the subvol_info that needs to be cleared before freeing. So kfree_sensitive() isn't really needed, use kfree() instead.

[PATCH v4 0/3] mm, treewide: Rename kzfree() to kfree_sensitive()

2020-06-15 Thread Waiman Long
v4: - Break out the memzero_explicit() change as suggested by Dan Carpenter so that it can be backported to stable. - Drop the "crypto: Remove unnecessary memzero_explicit()" patch for now as there can be a bit more discussion on what is best. It will be introduced as a separate pa

[PATCH v4 1/3] mm/slab: Use memzero_explicit() in kzfree()

2020-06-15 Thread Waiman Long
The kzfree() function is normally used to clear some sensitive information, like encryption keys, in the buffer before freeing it back to the pool. Memset() is currently used for the buffer clearing. However, it is entirely possible that the compiler may choose to optimize away the memory clearing

[PATCH net] net: fix memleak in register_netdevice()

2020-06-15 Thread Yang Yingliang
I got a memleak report when doing some fuzz test: unreferenced object 0x888112584000 (size 13599): comm "ip", pid 3048, jiffies 4294911734 (age 343.491s) hex dump (first 32 bytes): 74 61 70 30 00 00 00 00 00 00 00 00 00 00 00 00 tap0 00 ee d9 19 81 88 ff ff 00 00 00 00

Re: [PATCH] tg3: driver sleeps indefinitely when EEH errors exceed eeh_max_freezes

2020-06-15 Thread Michael Chan
On Mon, Jun 15, 2020 at 3:21 PM David Christensen wrote: > > On 6/15/20 1:45 PM, Michael Chan wrote: > > On Mon, Jun 15, 2020 at 12:01 PM David Christensen > > wrote: > >> > >> The driver function tg3_io_error_detected() calls napi_disable twice, > >> without an intervening napi_enable, when the

Re: [PATCH] macsec: Support 32bit PN netlink attribute for XPN links

2020-06-15 Thread David Miller
From: Era Mayflower Date: Tue, 16 Jun 2020 00:41:14 +0900 > + if (tb_sa[MACSEC_SA_ATTR_PN]) { validate_add_rxsa() requires that MACSET_SA_ATTR_PN be non-NULL, so you don't need to add this check here.

Re: [PATCH net] ip6_gre: fix use-after-free in ip6gre_tunnel_lookup()

2020-06-15 Thread David Miller
From: Taehee Yoo Date: Mon, 15 Jun 2020 15:07:51 + > In the datapath, the ip6gre_tunnel_lookup() is used and it internally uses > fallback tunnel device pointer, which is fb_tunnel_dev. > This pointer is protected by RTNL. It's not enough to be used > in the datapath. > So, this pointer would

[PATCH net] ionic: no link check while resetting queues

2020-06-15 Thread Shannon Nelson
If the driver is busy resetting queues after a change in MTU or queue parameters, don't bother checking the link, wait until the next watchdog cycle. Fixes: 987c0871e8ae ("ionic: check for linkup in watchdog") Signed-off-by: Shannon Nelson --- drivers/net/ethernet/pensando/ionic/ionic_lif.c | 3

Re: [PATCH] net: Fix the arp error in some cases

2020-06-15 Thread David Miller
From: guodeqing Date: Tue, 16 Jun 2020 09:00:50 +0800 > ie., > $ ifconfig eth0 6.6.6.6 netmask 255.255.255.0 > > $ ip rule add from 6.6.6.6 table > > $ ip route add 9.9.9.9 via 6.6.6.6 > > $ ping -I 6.6.6.6 9.9.9.9 > PING 9.9.9.9 (9.9.9.9) from 6.6.6.6 : 56(84) bytes of data. > > 3 packe

Re: [PATCH v3 1/3] net: phy: mscc: move shared probe code into a helper

2020-06-15 Thread David Miller
From: David Miller Date: Mon, 15 Jun 2020 18:11:29 -0700 (PDT) > Because you removed this devm_kzalloc() code, vsc8531 is never initialized. You also need to provide a proper header posting when you repost this series after fixing this bug.

Re: [PATCH v3 1/3] net: phy: mscc: move shared probe code into a helper

2020-06-15 Thread David Miller
From: Heiko Stuebner Date: Mon, 15 Jun 2020 16:44:59 +0200 > static int vsc8584_probe(struct phy_device *phydev) > { > struct vsc8531_private *vsc8531; > + int rc; > u32 default_mode[4] = {VSC8531_LINK_1000_ACTIVITY, > VSC8531_LINK_100_ACTIVITY, VSC8531_LINK_ACTIVITY, >

RE: [PATCH] net: usb: ax88179_178a: fix packet alignment padding

2020-06-15 Thread ASIX_Allan [Office]
Added ASIX S/W, Louis in the CC loop. --- Best regards, Allan Chou ASIX Electronics Corporation TEL: 886-3-5799500 ext.228 FAX: 886-3-5799558 E-mail: al...@asix.com.tw https://www.asix.com.tw/ -Original Message- From: David Miller Sent: Tuesday, June 16, 2020 3:52 AM To: j...@ozl

Re: [PATCH net v2] mptcp: fix memory leak in mptcp_subflow_create_socket()

2020-06-15 Thread David Miller
From: Wei Yongjun Date: Mon, 15 Jun 2020 09:35:22 +0800 > socket malloced by sock_create_kern() should be release before return > in the error handling, otherwise it cause memory leak. > > unreferenced object 0x88810910c000 (size 1216): > comm "0003_test_m", pid 12238, jiffies 4295050

Re: [PATCH net 0/2] remove dependency between mlx5, act_ct, nf_flow_table

2020-06-15 Thread David Miller
From: Roi Dayan Date: Sun, 14 Jun 2020 14:12:47 +0300 > Some exported functions from act_ct and nf_flow_table being used in mlx5_core. > This leads that mlx5 module always require act_ct and nf_flow_table modules. > Those small exported functions can be moved to the header files to > avoid this m

Re: linux-next: build failures after merge of the vfs tree

2020-06-15 Thread Herbert Xu
On Tue, Jun 16, 2020 at 10:34:40AM +1000, Stephen Rothwell wrote: > [Just adding Herbert to cc] > > On Tue, 16 Jun 2020 10:33:30 +1000 Stephen Rothwell > wrote: > > > > Hi all, > > > > After merging the vfs tree, today's linux-next build (x86_64 allmodconfig) > > failed like this: Thanks Steph

[PATCH] net: Fix the arp error in some cases

2020-06-15 Thread guodeqing
ie., $ ifconfig eth0 6.6.6.6 netmask 255.255.255.0 $ ip rule add from 6.6.6.6 table $ ip route add 9.9.9.9 via 6.6.6.6 $ ping -I 6.6.6.6 9.9.9.9 PING 9.9.9.9 (9.9.9.9) from 6.6.6.6 : 56(84) bytes of data. 3 packets transmitted, 0 received, 100% packet loss, time 2079ms $ arp Address H

Re: [PATCH net v2 2/2] net/sched: act_gate: fix configuration of the periodic timer

2020-06-15 Thread David Miller
From: Vladimir Oltean Date: Tue, 16 Jun 2020 00:55:50 +0300 > On Mon, 15 Jun 2020 at 22:33, Davide Caratti wrote: >> >> assigning a dummy value of 'clock_id' to avoid cancellation of the cycle >> timer before its initialization was a temporary solution, and we still >> need to handle the case wh

答复: 答复: [vger.kernel.org代发]Re: 答复: [PATCH] can current ECMP implementation support consistent hashing for next hop?

2020-06-15 Thread 杨燚
Got it, thanks David, so it is only one way to do it by ourselves :-), yes performance has to been hurt by consistent hashing, but I also found consistent hashing can't make sure the flows are always dispatched to the server which is handling them, it can just ensure most of cases are so. For o

[PATCH v5 4/7] Bluetooth: Add handler of MGMT_OP_REMOVE_ADV_MONITOR

2020-06-15 Thread Miao-chen Chou
This adds the request handler of MGMT_OP_REMOVE_ADV_MONITOR command. Note that the controller-based monitoring is not yet in place. This removes the internal monitor(s) without sending HCI traffic, so the request returns immediately. The following test was performed. - Issue btmgmt advmon-remove w

[PATCH v5 5/7] Bluetooth: Notify adv monitor added event

2020-06-15 Thread Miao-chen Chou
This notifies management sockets on MGMT_EV_ADV_MONITOR_ADDED event. The following test was performed. - Start two btmgmt consoles, issue a btmgmt advmon-add command on one console and observe a MGMT_EV_ADV_MONITOR_ADDED event on the other Signed-off-by: Miao-chen Chou --- Changes in v5: None C

[PATCH v5 2/7] Bluetooth: Add handler of MGMT_OP_READ_ADV_MONITOR_FEATURES

2020-06-15 Thread Miao-chen Chou
This adds the request handler of MGMT_OP_READ_ADV_MONITOR_FEATURES command. Since the controller-based monitoring is not yet in place, this report only the supported features but not the enabled features. The following test was performed. - Issuing btmgmt advmon-features. Signed-off-by: Miao-chen

[PATCH v5 7/7] Bluetooth: Update background scan and report device based on advertisement monitors

2020-06-15 Thread Miao-chen Chou
This calls hci_update_background_scan() when there is any update on the advertisement monitors. If there is at least one advertisement monitor, the filtering policy of scan parameters should be 0x00. This also reports device found mgmt events if there is at least one monitor. The following cases w

[PATCH v5 3/7] Bluetooth: Add handler of MGMT_OP_ADD_ADV_PATTERNS_MONITOR

2020-06-15 Thread Miao-chen Chou
This adds the request handler of MGMT_OP_ADD_ADV_PATTERNS_MONITOR command. Note that the controller-based monitoring is not yet in place. This tracks the content of the monitor without sending HCI traffic, so the request returns immediately. The following manual test was performed. - Issue btmgmt

[PATCH v5 1/7] Bluetooth: Add definitions for advertisement monitor features

2020-06-15 Thread Miao-chen Chou
This adds support for Advertisement Monitor API. Here are the commands and events added. - Read Advertisement Monitor Feature command - Add Advertisement Pattern Monitor command - Remove Advertisement Monitor command - Advertisement Monitor Added event - Advertisement Monitor Removed event Signed-

[PATCH v5 6/7] Bluetooth: Notify adv monitor removed event

2020-06-15 Thread Miao-chen Chou
This notifies management sockets on MGMT_EV_ADV_MONITOR_REMOVED event. The following test was performed. - Start two btmgmt consoles, issue a btmgmt advmon-remove command on one console and observe a MGMT_EV_ADV_MONITOR_REMOVED event on the other. Signed-off-by: Miao-chen Chou --- Changes in v5

Re: [PATCH bpf] tools/bpftool: add ringbuf map to a list of known map types

2020-06-15 Thread Daniel Borkmann
On 6/16/20 12:53 AM, Andrii Nakryiko wrote: Add symbolic name "ringbuf" to map to BPF_MAP_TYPE_RINGBUF. Without this, users will see "type 27" instead of "ringbuf" in `map show` output. Signed-off-by: Andrii Nakryiko Applied, thanks!

Re: [PATCH bpf] bpf: fix definition of bpf_ringbuf_output() helper in UAPI comments

2020-06-15 Thread Daniel Borkmann
On 6/15/20 11:49 PM, Andrii Nakryiko wrote: Fix definition of bpf_ringbuf_output() in UAPI header comments, which is used to generate libbpf's bpf_helper_defs.h header. Return value is a number (erro code), not a pointer. Fixes: 457f44363a88 ("bpf: Implement BPF ring buffer and verifier support

Re: [PATCH 00/17] spelling.txt: /decriptors/descriptors/

2020-06-15 Thread Mark Brown
On Tue, 9 Jun 2020 13:45:53 +0100, Kieran Bingham wrote: > I wouldn't normally go through spelling fixes, but I caught sight of > this typo twice, and then foolishly grepped the tree for it, and saw how > pervasive it was. > > so here I am ... fixing a typo globally... but with an addition in > sc

Re: [PATCH iproute2] tc: qdisc: filter qdisc's by parent/handle specification

2020-06-15 Thread Stephen Hemminger
On Mon, 15 Jun 2020 22:29:28 +0300 Anton Danilov wrote: > There wasn't a way to get a qdisc info by handle or parent, only full > dump of qdisc's with following grep/sed usage. > > The 'qdisc get' command have been added. > > tc qdisc { show | get } [ dev STRING ] [ QDISC_ID ] [ invisible ] >

[PATCH][next] ethtool: ioctl: Use array_size() in copy_to_user()

2020-06-15 Thread Gustavo A. R. Silva
Use array_size() helper instead of the open-coded version in copy_to_user(). These sorts of multiplication factors need to be wrapped in array_size(). This issue was found with the help of Coccinelle and, audited and fixed manually. Addresses-KSPP-ID: https://github.com/KSPP/linux/issues/83 Signe

[PATCH bpf] tools/bpftool: add ringbuf map to a list of known map types

2020-06-15 Thread Andrii Nakryiko
Add symbolic name "ringbuf" to map to BPF_MAP_TYPE_RINGBUF. Without this, users will see "type 27" instead of "ringbuf" in `map show` output. Signed-off-by: Andrii Nakryiko --- tools/bpf/bpftool/map.c | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/bpf/bpftool/map.c b/tools/bpf/bpftool

Re: 答复: [vger.kernel.org代发]Re: 答复: [PATCH] can current ECMP implementation support consistent hashing for next hop?

2020-06-15 Thread David Ahern
On 6/15/20 12:56 AM, Yi Yang (杨燚)-云服务集团 wrote: > My next hops are final real servers but not load balancers, say we sets > maximum number of servers to 64, but next hop entry is added or removed > dynamically, we are unlikely to know them beforehand. I can't understand how > user space can attai

Re: [PATCH] tg3: driver sleeps indefinitely when EEH errors exceed eeh_max_freezes

2020-06-15 Thread David Christensen
On 6/15/20 1:45 PM, Michael Chan wrote: On Mon, Jun 15, 2020 at 12:01 PM David Christensen wrote: The driver function tg3_io_error_detected() calls napi_disable twice, without an intervening napi_enable, when the number of EEH errors exceeds eeh_max_freezes, resulting in an indefinite sleep wh

[PATCH net v5 3/3] esp, ah: modernize the crypto algorithm selections

2020-06-15 Thread Eric Biggers
From: Eric Biggers The crypto algorithms selected by the ESP and AH kconfig options are out-of-date with the guidance of RFC 8221, which lists the legacy algorithms MD5 and DES as "MUST NOT" be implemented, and some more modern algorithms like AES-GCM and HMAC-SHA256 as "MUST" be implemented. But

[PATCH net v5 0/3] esp, ah: improve crypto algorithm selections

2020-06-15 Thread Eric Biggers
This series consolidates and modernizes the lists of crypto algorithms that are selected by the IPsec kconfig options, and adds CRYPTO_SEQIV since it no longer gets selected automatically by other things. See previous discussion at https://lkml.kernel.org/netdev/20200604192322.22142-1-ebigg...@ker

[PATCH net v5 1/3] esp, ah: consolidate the crypto algorithm selections

2020-06-15 Thread Eric Biggers
From: Eric Biggers Instead of duplicating the algorithm selections between INET_AH and INET6_AH and between INET_ESP and INET6_ESP, create new tristates XFRM_AH and XFRM_ESP that do the algorithm selections, and make these be selected by the corresponding INET* options. Suggested-by: Herbert Xu

[PATCH net v5 2/3] esp: select CRYPTO_SEQIV

2020-06-15 Thread Eric Biggers
From: Eric Biggers Commit f23efcbcc523 ("crypto: ctr - no longer needs CRYPTO_SEQIV") made CRYPTO_CTR stop selecting CRYPTO_SEQIV. This breaks IPsec for most users since GCM and several other encryption algorithms require "seqiv" -- and RFC 8221 lists AES-GCM as "MUST" be implemented. Just make

Re: [PATCH net v2 2/2] net/sched: act_gate: fix configuration of the periodic timer

2020-06-15 Thread Vladimir Oltean
On Mon, 15 Jun 2020 at 22:33, Davide Caratti wrote: > > assigning a dummy value of 'clock_id' to avoid cancellation of the cycle > timer before its initialization was a temporary solution, and we still > need to handle the case where act_gate timer parameters are changed by > commands like the fol

[PATCH bpf] bpf: fix definition of bpf_ringbuf_output() helper in UAPI comments

2020-06-15 Thread Andrii Nakryiko
Fix definition of bpf_ringbuf_output() in UAPI header comments, which is used to generate libbpf's bpf_helper_defs.h header. Return value is a number (erro code), not a pointer. Fixes: 457f44363a88 ("bpf: Implement BPF ring buffer and verifier support for it") Signed-off-by: Andrii Nakryiko ---

Re: BUG: kernel NULL pointer dereference in __cgroup_bpf_run_filter_skb

2020-06-15 Thread Cong Wang
On Mon, Jun 15, 2020 at 6:06 AM Daniël Sonck wrote: > > Op zo 14 jun. 2020 om 22:43 schreef Daniël Sonck : > > > > Hello, > > > > Op zo 14 jun. 2020 om 20:29 schreef Cong Wang : > > > > > > Hello, > > > > > > On Sun, Jun 14, 2020 at 5:39 AM Daniël Sonck wrote: > > > > > > > > Hello, > > > > > > >

Re: [Patch net] net: change addr_list_lock back to static key

2020-06-15 Thread Cong Wang
On Sat, Jun 13, 2020 at 9:03 AM Taehee Yoo wrote: > > On Thu, 11 Jun 2020 at 08:21, Cong Wang wrote: > > > > Hi Cong :) > > > On Wed, Jun 10, 2020 at 7:48 AM Taehee Yoo wrote: > > > > > > On Tue, 9 Jun 2020 at 06:53, Cong Wang wrote: > > > > > > > > + lockdep_set_class_and_subclass(&dev->

[PATCH] liquidio: Replace vmalloc_node + memset with vzalloc_node and use array_size

2020-06-15 Thread Gustavo A. R. Silva
Use vzalloc/vzalloc_node instead of the vmalloc/vzalloc_node and memset. Also, notice that vzalloc_node() function has no 2-factor argument form to calculate the size for the allocation, so multiplication factors need to be wrapped in array_size(). This issue was found with the help of Coccinelle

[PATCH v2] bluetooth: Adding a configurable autoconnect timeout

2020-06-15 Thread Alain Michaud
This patch adds a configurable LE autoconnect timeout. Signed-off-by: Alain Michaud --- Changes in v1: Fixing longer than 80 char line. include/net/bluetooth/hci_core.h | 1 + net/bluetooth/hci_core.c | 1 + net/bluetooth/hci_event.c| 2 +- net/bluetooth/hci_request.c |

Re: [PATCH v3 1/3] net: phy: mscc: move shared probe code into a helper

2020-06-15 Thread kernel test robot
Hi Heiko, I love your patch! Perhaps something to improve: [auto build test WARNING on net-next/master] [also build test WARNING on sparc-next/master net/master linus/master v5.8-rc1 next-20200615] [cannot apply to robh/for-next] [if your patch is applied to the wrong git tree, please drop us a

Re: [PATCH net v2 1/2] net/sched: act_gate: fix NULL dereference in tcf_gate_init()

2020-06-15 Thread Vladimir Oltean
Hi Davide, On Mon, 15 Jun 2020 at 22:31, Davide Caratti wrote: > > it is possible to see a KASAN use-after-free, immediately followed by a > NULL dereference crash, with the following command: > > # tc action add action gate index 3 cycle-time 1ns \ > > cycle-time-ext 1ns clocki

Re: [PATCH net] net: dsa: sja1105: fix PTP timestamping with large tc-taprio cycles

2020-06-15 Thread David Miller
From: Vladimir Oltean Date: Sun, 14 Jun 2020 23:54:09 +0300 > From: Vladimir Oltean > > It isn't actually described clearly at all in UM10944.pdf, but on TX of > a management frame (such as PTP), this needs to happen: > > - The destination MAC address (i.e. 01-80-c2-00-00-0e), along with the >

Re: [PATCH] tg3: driver sleeps indefinitely when EEH errors exceed eeh_max_freezes

2020-06-15 Thread Michael Chan
On Mon, Jun 15, 2020 at 12:01 PM David Christensen wrote: > > The driver function tg3_io_error_detected() calls napi_disable twice, > without an intervening napi_enable, when the number of EEH errors exceeds > eeh_max_freezes, resulting in an indefinite sleep while holding rtnl_lock. > > The funct

Re: [PATCH 1/1] mvpp2: ethtool rxtx stats fix

2020-06-15 Thread David Miller
From: Sven Auhagen Date: Sun, 14 Jun 2020 09:19:17 +0200 > The ethtool rx and tx queue statistics are reporting wrong values. > Fix reading out the correct ones. > > Signed-off-by: Sven Auhagen Applied and queued up for -stable, thank you.

[ANNOUNCE] nftables 0.9.6 release

2020-06-15 Thread Pablo Neira Ayuso
Hi! The Netfilter project proudly presents: nftables 0.9.6 This release fixes vmap support which broke in 0.9.5. You can download this new release from: https://www.netfilter.org/projects/nftables/downloads.html#nftables-0.9.6 https://www.netfilter.org/pub/nftables/ To build the code,

Re: [PATCH] net: macb: fix ref count leaking via pm_runtime_get_sync

2020-06-15 Thread David Miller
From: Navid Emamdoost Date: Sun, 14 Jun 2020 00:48:03 -0500 > in macb_mdio_write, macb_mdio_read, and at91ether_open, > pm_runtime_get_sync is called which increments the counter even in case of > failure, leading to incorrect ref count. > In case of failure, decrement the ref count before return

Re: [PATCH] net: fec: fix ref count leaking when pm_runtime_get_sync fails

2020-06-15 Thread David Miller
From: Navid Emamdoost Date: Sun, 14 Jun 2020 00:38:01 -0500 > in fec_enet_mdio_read, fec_enet_mdio_write, fec_enet_get_regs, > fec_enet_open and fec_drv_remove, pm_runtime_get_sync is called which > increments the counter even in case of failure, leading to incorrect > ref count. In case of failu

Re: [PATCH] MAINTAINERS: switch to my private email for Renesas Ethernet drivers

2020-06-15 Thread David Miller
From: Sergei Shtylyov Date: Sat, 13 Jun 2020 23:59:30 +0300 > Subject: MAINTAINERS: switch to my private email for Renesas Ethernet drivers > > I no longer work for Cogent Embedded (but my old email still works :-)), > and still would like to continue looking after the Renesas Ethernet drivers >

Re: [PATCH] rocker: fix incorrect error handling in dma_rings_init

2020-06-15 Thread David Miller
From: Aditya Pakki Date: Fri, 12 Jun 2020 15:27:55 -0500 > In rocker_dma_rings_init, the goto blocks in case of errors > caused by the functions rocker_dma_cmd_ring_waits_alloc() and > rocker_dma_ring_create() are incorrect. The patch fixes the > order consistent with cleanup in rocker_dma_rings_

Re: [PATCH] test_objagg: Fix potential memory leak in error handling

2020-06-15 Thread David Miller
From: Aditya Pakki Date: Fri, 12 Jun 2020 15:01:54 -0500 > In case of failure of check_expect_hints_stats(), the resources > allocated by objagg_hints_get should be freed. The patch fixes > this issue. > > Signed-off-by: Aditya Pakki Applied.

  1   2   3   >