Re: WARNING in hci_conn_timeout

2020-08-01 Thread Greg KH
On Sat, Aug 01, 2020 at 03:56:09PM -0700, syzbot wrote: > syzbot has bisected this issue to: > > commit 3d30311c0e4d834c94e6a27d6242a942d6a76b85 > Author: Varsha Rao > Date: Sun Oct 9 11:13:56 2016 + > > staging: vt6655: Removes unnecessary blank lines. I doubt this is the real issue

Re: [PATCH bpf-next] selftests/bpf: fix spurious test failures in core_retro selftest

2020-08-01 Thread Alexei Starovoitov
On Fri, Jul 31, 2020 at 2:55 PM John Fastabend wrote: > > Andrii Nakryiko wrote: > > core_retro selftest uses BPF program that's triggered on sys_enter > > system-wide, but has no protection from some unrelated process doing syscall > > while selftest is running. This leads to occasional test fail

Re: [PATCH V2 bpf-next] bpf: make __htab_lookup_and_delete_batch faster when map is almost empty

2020-08-01 Thread Yonghong Song
On 8/1/20 11:09 AM, Brian Vazquez wrote: While running some experiments it was observed that map_lookup_batch was 2x slower than get_next_key + lookup when the syscall overhead is minimal. This was because the map_lookup_batch implementation was more expensive traversing empty buckets, this ca

[PATCH] appletalk: Fix atalk_proc_init() return path

2020-08-01 Thread Lukas Wunner
From: Vincent Duvert Add a missing return statement to atalk_proc_init so it doesn't return -ENOMEM when successful. This allows the appletalk module to load properly. Fixes: e2bcd8b0ce6e ("appletalk: use remove_proc_subtree to simplify procfs code") Link: https://www.downtowndougbrown.com/20

Re: [PATCH -next] virtio_net: Avoid loop in virtnet_poll

2020-08-01 Thread Michael S. Tsirkin
On Sun, Aug 02, 2020 at 11:41:23AM +0800, Mao Wenan wrote: > The loop may exist if vq->broken is true, > virtqueue_get_buf_ctx_packed or virtqueue_get_buf_ctx_split > will return NULL, so virtnet_poll will reschedule napi to > receive packet, it will lead cpu usage(si) to 100%. > > call trace as b

Re: [PATCH 1/2 v2 net-next] 8390: Miscellaneous cleanups

2020-08-01 Thread Jakub Kicinski
On Sat, 1 Aug 2020 22:52:42 +0200 Armin Wolf wrote: > Replace version string with MODULE_* macros. > > Include necessary libraries. > > Fix two minor coding-style issues. > > Signed-off-by: Armin Wolf This doesn't build but also ../drivers/net/ethernet/8390/lib8390.c:973:17: error: undefined

[PATCH bpf-next 1/2] bpf: change uapi for bpf iterator map elements

2020-08-01 Thread Yonghong Song
Commit a5cbe05a6673 ("bpf: Implement bpf iterator for map elements") added bpf iterator support for map elements. The map element bpf iterator requires info to identify a particular map. In the above commit, the attr->link_create.target_fd is used to carry map_fd and an enum bpf_iter_link_info is a

Re: [PATCH net-next] cxgb4: Add support to flash firmware config image

2020-08-01 Thread Jakub Kicinski
On Sat, 1 Aug 2020 02:47:38 +0530 Rahul Lakkireddy wrote: > I thought /lib/firmware is where firmware related files need to be > placed and ethtool --flash needs to be used to program them to > their respective locations on adapter's flash. Our goal is to provide solid, common interfaces for Linux

[PATCH bpf-next 2/2] libbpf: support new uapi for map element bpf iterator

2020-08-01 Thread Yonghong Song
Previous commit adjusted kernel uapi for map element bpf iterator. This patch adjusted libbpf API due to uapi change. Signed-off-by: Yonghong Song --- tools/lib/bpf/bpf.c| 4 +++- tools/lib/bpf/bpf.h| 5 +++-- tools/lib/bpf/libbpf.c | 7 +-- 3 files changed, 11 insertions(+), 5 delet

[PATCH bpf-next 0/2] bpf: change uapi for bpf iterator map elements

2020-08-01 Thread Yonghong Song
Andrii raised a concern that current uapi for bpf iterator map element is a little restrictive and not suitable for future potential complex customization. This is a valid suggestion, considering people may indeed add more complex custimization to the iterator, e.g., cgroup_id + user_id, etc. for t

Re: [PATCH v2 bpf-next 0/5] BPF link force-detach support

2020-08-01 Thread Alexei Starovoitov
On Fri, Jul 31, 2020 at 11:29 AM Andrii Nakryiko wrote: > > This patch set adds new BPF link operation, LINK_DETACH, allowing processes > with BPF link FD to force-detach it from respective BPF hook, similarly how > BPF link is auto-detached when such BPF hook (e.g., cgroup, net_device, netns, > e

[PATCH -next] virtio_net: Avoid loop in virtnet_poll

2020-08-01 Thread Mao Wenan
The loop may exist if vq->broken is true, virtqueue_get_buf_ctx_packed or virtqueue_get_buf_ctx_split will return NULL, so virtnet_poll will reschedule napi to receive packet, it will lead cpu usage(si) to 100%. call trace as below: virtnet_poll virtnet_receive virtqueue_ge

Re: [PATCH bpf-next] tools build: propagate build failures from tools/build/Makefile.build

2020-08-01 Thread Alexei Starovoitov
On Thu, Jul 30, 2020 at 7:44 PM Andrii Nakryiko wrote: > > The '&&' command seems to have a bad effect when $(cmd_$(1)) exits with > non-zero effect: the command failure is masked (despite `set -e`) and all but > the first command of $(dep-cmd) is executed (successfully, as they are mostly > print

Re: [PATCH v9 bpf-next 10/14] bpf: Add d_path helper

2020-08-01 Thread Alexei Starovoitov
On Sat, Aug 01, 2020 at 07:03:18PM +0200, Jiri Olsa wrote: > Adding d_path helper function that returns full path for > given 'struct path' object, which needs to be the kernel > BTF 'path' object. The path is returned in buffer provided > 'buf' of size 'sz' and is zero terminated. > > bpf_d_pat

Re: [PATCH v6 bpf-next 0/6] bpf: tailcalls in BPF subprograms

2020-08-01 Thread Alexei Starovoitov
On Sat, Aug 01, 2020 at 09:13:57AM +0200, Maciej Fijalkowski wrote: > On Sat, Aug 01, 2020 at 03:03:19AM +0200, Daniel Borkmann wrote: > > On 7/31/20 2:03 AM, Maciej Fijalkowski wrote: > > > v5->v6: > > > - propagate only those poke descriptors that individual subprogram is > > >actually using

Re: [GIT] Networking

2020-08-01 Thread David Miller
From: Linus Torvalds Date: Sat, 1 Aug 2020 16:45:49 -0700 > On Sat, Aug 1, 2020 at 2:36 PM David Miller wrote: >> >> git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net.git > > How is this wrt an rc8 or a final? Nothing scary in there, I think you can safely do a -final with those netwo

[PATCH bpf-next 3/3] tools/resolve_btfids: use libbpf's btf__parse() API

2020-08-01 Thread Andrii Nakryiko
Instead of re-implementing generic BTF parsing logic, use libbpf's API. Also add .gitignore for resolve_btfids's build artifacts. Signed-off-by: Andrii Nakryiko --- tools/bpf/resolve_btfids/.gitignore | 4 ++ tools/bpf/resolve_btfids/main.c | 58 + 2 files change

[PATCH bpf-next 2/3] tools/bpftool: use libbpf's btf__parse() API for parsing BTF from file

2020-08-01 Thread Andrii Nakryiko
Use generic libbpf API to parse BTF data from file, instead of re-implementing it in bpftool. Signed-off-by: Andrii Nakryiko --- tools/bpf/bpftool/btf.c | 54 + 1 file changed, 1 insertion(+), 53 deletions(-) diff --git a/tools/bpf/bpftool/btf.c b/tools/b

[PATCH bpf-next 0/3] Add generic and raw BTF parsing APIs to libbpf

2020-08-01 Thread Andrii Nakryiko
It's pretty common for applications to want to parse raw (binary) BTF data from file, as opposed to parsing it from ELF sections. It's also pretty common for tools to not care whether given file is ELF or raw BTF format. This patch series exposes internal raw BTF parsing API and adds generic varian

[PATCH bpf-next 1/3] libbpf: add btf__parse_raw() and generic btf__parse() APIs

2020-08-01 Thread Andrii Nakryiko
Add public APIs to parse BTF from raw data file (e.g., /sys/kernel/btf/vmlinux), as well as generic btf__parse(), which will try to determine correct format, currently either raw or ELF. Signed-off-by: Andrii Nakryiko --- tools/lib/bpf/btf.c | 114 ++- to

Re: [PATCH v2] drivers/net/wan/lapbether: Use needed_headroom instead of hard_header_len

2020-08-01 Thread Xie He
On Sat, Aug 1, 2020 at 6:31 AM Willem de Bruijn wrote: > > The kernel interface cannot be changed. If packet sockets used to pass > the first byte up to userspace, they have to continue to do so. > > So I think you can limit the header_ops to only dev_hard_header. Actually if we want to keep the

Re: [GIT] Networking

2020-08-01 Thread pr-tracker-bot
The pull request you sent on Sat, 01 Aug 2020 14:36:31 -0700 (PDT): > git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net.git refs/heads/master has been merged into torvalds/linux.git: https://git.kernel.org/torvalds/c/ac3a0c8472969a03c0496ae774b3a29eb26c8d5a Thank you! -- Deet-doot-dot,

Re: [GIT] Networking

2020-08-01 Thread Linus Torvalds
On Sat, Aug 1, 2020 at 2:36 PM David Miller wrote: > > git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net.git How is this wrt an rc8 or a final? I have another possible small reason to do an rc8 right now. And this roughly doubles my current diff. On a very much related note, I really w

Re: WARNING in hci_conn_timeout

2020-08-01 Thread syzbot
syzbot has bisected this issue to: commit 3d30311c0e4d834c94e6a27d6242a942d6a76b85 Author: Varsha Rao Date: Sun Oct 9 11:13:56 2016 + staging: vt6655: Removes unnecessary blank lines. bisection log: https://syzkaller.appspot.com/x/bisect.txt?x=17023a1490 start commit: 7dc6fd0f

[GIT] Networking

2020-08-01 Thread David Miller
1) Encap offset calculation is incorrect in esp6, from Sabrina Dubroca. 2) Better parameter validation in pfkey_dump(), from Mark Salyzyn. 3) Fix several clang issues on powerpc in selftests, from Tanner Love. 4) cmsghdr_from_user_compat_to_kern() uses the wrong length, from Al Viro. 5) Ou

Re: [PATCH net-next RFC 01/13] devlink: Add reload level option to devlink reload command

2020-08-01 Thread Moshe Shemesh
On 7/31/2020 2:11 AM, Jakub Kicinski wrote: On Thu, 30 Jul 2020 15:30:45 +0300 Moshe Shemesh wrote: My expectations would be that the driver must perform the lowest reset level possible that satisfies the requested functional change. IOW driver may do more, in fact it should be acceptable for

Re: [PATCH v3 2/6] dt-bindings: net: can: binding for CTU CAN FD open-source IP core.

2020-08-01 Thread Pavel Pisa
Hello Rob ad others, On Wednesday 29 of July 2020 01:12:31 Pavel Pisa wrote: > On Saturday 04 of January 2020 00:53:59 Rob Herring wrote: > > On Sat, Dec 21, 2019 at 03:07:31PM +0100, p...@cmp.felk.cvut.cz wrote: > > > From: Pavel Pisa > > > > > > Signed-off-by: Pavel Pisa > > > --- > > > .../d

[net-next:master 152/153] net/core/fib_rules.c:26:7: warning: "CONFIG_IP_MULTIPLE_TABLES" is not defined, evaluates to 0

2020-08-01 Thread kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next.git master head: 7126bd5c8bcbc015cf89864cf71d750e8f33f924 commit: 8b66a6fd34f519f4ad42c4ab0152c3c0782a7dbd [152/153] fib: fix another fib_rules_ops indirect call wrapper problem config: openrisc-randconfig-r026-20200802 (att

[PATCH 2/2 v2 net-next] lib8390: Fix coding-style issues and remove verion printing

2020-08-01 Thread Armin Wolf
Fix various checkpatch warnings. Remove version printing so modules including lib8390 do not have to provide a global version string for successful compilation. Replace pr_cont() with SMP-safe construct. Signed-off-by: Armin Wolf --- drivers/net/ethernet/8390/lib8390.c | 606 ++

[PATCH 1/2 v2 net-next] 8390: Miscellaneous cleanups

2020-08-01 Thread Armin Wolf
Replace version string with MODULE_* macros. Include necessary libraries. Fix two minor coding-style issues. Signed-off-by: Armin Wolf --- drivers/net/ethernet/8390/8390.c | 25 - 1 file changed, 20 insertions(+), 5 deletions(-) diff --git a/drivers/net/ethernet/8390/8

[PATCH 0/2 v2 net-next] 8390: core cleanups

2020-08-01 Thread Armin Wolf
The purpose of this patchset is to do some cleanups in lib8390.c and 8390.c. While most cleanups are coding-style related, pt_cont() usage was replaced by a more SMP-safe construct. Other functional changes include the removal of version-printing in lib8390.c so modules using lib8390.c do not nee

Re: [PATCH net-next v3 2/2] net: dsa: qca8k: Add 802.1q VLAN support

2020-08-01 Thread Florian Fainelli
On 8/1/2020 10:06 AM, Jonathan McDowell wrote: > This adds full 802.1q VLAN support to the qca8k, allowing the use of > vlan_filtering and more complicated bridging setups than allowed by > basic port VLAN support. > > Tested with a number of untagged ports with separate VLANs and then a > trun

Re: [PATCH net-next v3 1/2] net: dsa: qca8k: Add define for port VID

2020-08-01 Thread Florian Fainelli
On 8/1/2020 10:05 AM, Jonathan McDowell wrote: > Rather than using a magic value of 1 when configuring the port VIDs add > a QCA8K_PORT_VID_DEF define and use that instead. Also fix up the > bitmask in the process; the top 4 bits are reserved so this wasn't a > problem, but only masking 12 bits

Re: [PATCH net] net/bpfilter: initialize pos in __bpfilter_process_sockopt

2020-08-01 Thread Alexei Starovoitov
On Fri, Jul 31, 2020 at 02:07:42AM +0200, Daniel Borkmann wrote: > On 7/30/20 6:13 PM, Christian Brauner wrote: > > On Thu, Jul 30, 2020 at 06:09:00PM +0200, Christoph Hellwig wrote: > > > __bpfilter_process_sockopt never initialized the pos variable passed to > > > the pipe write. This has been m

[Linux-kernel-mentees] [PATCH net] net/smc: Prevent kernel-infoleak in __smc_diag_dump()

2020-08-01 Thread Peilin Ye
__smc_diag_dump() is potentially copying uninitialized kernel stack memory into socket buffers, since the compiler may leave a 4-byte hole near the beginning of `struct smcd_diag_dmbinfo`. Fix it by initializing `dinfo` with memset(). Cc: sta...@vger.kernel.org Fixes: 4b1b7d3b30a6 ("net/smc: add S

WARNING in hci_conn_timeout

2020-08-01 Thread syzbot
Hello, syzbot found the following issue on: HEAD commit:7dc6fd0f Merge branch 'i2c/for-current' of git://git.kerne.. git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=12a7083290 kernel config: https://syzkaller.appspot.com/x/.config?x=e59ee776d5aa8d55 das

Re: [PATCH net-next] mptcp: fix syncookie build error on UP

2020-08-01 Thread David Miller
From: Florian Westphal Date: Sat, 1 Aug 2020 16:39:59 +0200 > kernel test robot says: > net/mptcp/syncookies.c: In function 'mptcp_join_cookie_init': > include/linux/kernel.h:47:38: warning: division by zero [-Wdiv-by-zero] > #define ARRAY_SIZE(arr) (sizeof(arr) / sizeof((arr)[0]) + > __must_b

Re: [PATCH net] vxlan: fix memleak of fdb

2020-08-01 Thread David Miller
From: Taehee Yoo Date: Sat, 1 Aug 2020 07:07:50 + > When vxlan interface is deleted, all fdbs are deleted by vxlan_flush(). > vxlan_flush() flushes fdbs but it doesn't delete fdb, which contains > all-zeros-mac because it is deleted by vxlan_uninit(). > But vxlan_uninit() deletes only the fd

Re: [PATCH net-next] fib: fix another fib_rules_ops indirect call wrapper problem

2020-08-01 Thread David Miller
From: Brian Vazquez Date: Fri, 31 Jul 2020 20:01:10 -0700 > It turns out that on commit 41d707b7332f ("fib: fix fib_rules_ops > indirect calls wrappers") I forgot to include the case when > CONFIG_IP_MULTIPLE_TABLES is not set. > > Fixes: 41d707b7332f ("fib: fix fib_rules_ops indirect calls wrap

Re: [PATCH net-next] tcp: fix build fong CONFIG_MPTCP=n

2020-08-01 Thread David Miller
From: Eric Dumazet Date: Fri, 31 Jul 2020 19:09:29 -0700 > Fixes these errors: > > net/ipv4/syncookies.c: In function 'tcp_get_cookie_sock': > net/ipv4/syncookies.c:216:19: error: 'struct tcp_request_sock' has no > member named 'drop_req' > 216 | if (tcp_rsk(req)->drop_req) { > |

[RFC] replace SNAPSHOT with auto-generated version

2020-08-01 Thread Stephen Hemminger
Replace the iproute2 snapshot with a version string which is autogenerated as part of the build process using git describe. This will also allow seeing if the version of the command is built from the same sources is as upstream. Signed-off-by: Stephen Hemminger --- One additional tweak needed wi

Re: [PATCH net] vxlan: fix memleak of fdb

2020-08-01 Thread Roopa Prabhu
On 8/1/20 12:07 AM, Taehee Yoo wrote: External email: Use caution opening links or attachments When vxlan interface is deleted, all fdbs are deleted by vxlan_flush(). vxlan_flush() flushes fdbs but it doesn't delete fdb, which contains all-zeros-mac because it is deleted by vxlan_uninit(). Bu

[PATCH net-next v3 2/2] net: dsa: qca8k: Add 802.1q VLAN support

2020-08-01 Thread Jonathan McDowell
This adds full 802.1q VLAN support to the qca8k, allowing the use of vlan_filtering and more complicated bridging setups than allowed by basic port VLAN support. Tested with a number of untagged ports with separate VLANs and then a trunk port with all the VLANs tagged on it. v3: - Pull QCA8K_PORT

[PATCH net-next v3 1/2] net: dsa: qca8k: Add define for port VID

2020-08-01 Thread Jonathan McDowell
Rather than using a magic value of 1 when configuring the port VIDs add a QCA8K_PORT_VID_DEF define and use that instead. Also fix up the bitmask in the process; the top 4 bits are reserved so this wasn't a problem, but only masking 12 bits is the correct approach. Signed-off-by: Jonathan McDowell

[PATCH v9 bpf-next 14/14] selftests/bpf: Add set test to resolve_btfids

2020-08-01 Thread Jiri Olsa
Adding test to for sets resolve_btfids. We're checking that testing set gets properly resolved and sorted. Signed-off-by: Jiri Olsa --- .../selftests/bpf/prog_tests/resolve_btfids.c | 39 ++- 1 file changed, 38 insertions(+), 1 deletion(-) diff --git a/tools/testing/selftests/bp

[PATCH v9 bpf-next 08/14] bpf: Add btf_struct_ids_match function

2020-08-01 Thread Jiri Olsa
Adding btf_struct_ids_match function to check if given address provided by BTF object + offset is also address of another nested BTF object. This allows to pass an argument to helper, which is defined via parent BTF object + offset, like for bpf_d_path (added in following changes): SEC("fentry/

[PATCH v9 bpf-next 12/14] selftests/bpf: Add verifier test for d_path helper

2020-08-01 Thread Jiri Olsa
Adding verifier test for attaching tracing program and calling d_path helper from within and testing that it's allowed for dentry_open function and denied for 'd_path' function with appropriate error. Acked-by: Andrii Nakryiko Signed-off-by: Jiri Olsa --- tools/testing/selftests/bpf/test_verifi

[PATCH v9 bpf-next 13/14] selftests/bpf: Add test for d_path helper

2020-08-01 Thread Jiri Olsa
Adding test for d_path helper which is pretty much copied from Wenbo Zhang's test for bpf_get_fd_path, which never made it in. The test is doing fstat/close on several fd types, and verifies we got the d_path helper working on kernel probes for vfs_getattr/filp_close functions. Original-patch-by:

[PATCH v9 bpf-next 10/14] bpf: Add d_path helper

2020-08-01 Thread Jiri Olsa
Adding d_path helper function that returns full path for given 'struct path' object, which needs to be the kernel BTF 'path' object. The path is returned in buffer provided 'buf' of size 'sz' and is zero terminated. bpf_d_path(&file->f_path, buf, size); The helper calls directly d_path function

[PATCH v9 bpf-next 01/14] tools resolve_btfids: Add size check to get_id function

2020-08-01 Thread Jiri Olsa
To make sure we don't crash on malformed symbols. Signed-off-by: Jiri Olsa --- tools/bpf/resolve_btfids/main.c | 9 - 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/tools/bpf/resolve_btfids/main.c b/tools/bpf/resolve_btfids/main.c index 6956b6350cad..e0929620abc6 100644 ---

[PATCH v9 bpf-next 07/14] bpf: Factor btf_struct_access function

2020-08-01 Thread Jiri Olsa
Adding btf_struct_walk function that walks through the struct type + given offset and returns following values: enum bpf_struct_walk_result { /* < 0 error */ WALK_SCALAR = 0, WALK_PTR, WALK_STRUCT, }; WALK_SCALAR - when SCALAR_VALUE is found WALK_PTR- when poin

[PATCH v9 bpf-next 05/14] bpf: Add type_id pointer as argument to __btf_resolve_size

2020-08-01 Thread Jiri Olsa
Adding type_id pointer as argument to __btf_resolve_size to return also BTF ID of the resolved type. It will be used in following changes. Signed-off-by: Jiri Olsa --- kernel/bpf/btf.c | 13 + 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/kernel/bpf/btf.c b/kernel/bpf

[PATCH v9 bpf-next 09/14] bpf: Add BTF_SET_START/END macros

2020-08-01 Thread Jiri Olsa
Adding support to define sorted set of BTF ID values. Following defines sorted set of BTF ID values: BTF_SET_START(btf_allowlist_d_path) BTF_ID(func, vfs_truncate) BTF_ID(func, vfs_fallocate) BTF_ID(func, dentry_open) BTF_ID(func, vfs_getattr) BTF_ID(func, filp_close) BTF_SET_END(bt

[PATCH v9 bpf-next 02/14] tools resolve_btfids: Add support for set symbols

2020-08-01 Thread Jiri Olsa
The set symbol does not have the unique number suffix, so we need to give it a special parsing function. This was omitted in the first batch, because there was no set support yet, so it slipped in the testing. Signed-off-by: Jiri Olsa --- tools/bpf/resolve_btfids/main.c | 20 +++

[PATCH v9 bpf-next 11/14] bpf: Update .BTF_ids section in btf.rst with sets info

2020-08-01 Thread Jiri Olsa
Updating btf.rst doc with info about BTF_SET_START/END macros. Signed-off-by: Jiri Olsa --- Documentation/bpf/btf.rst | 25 + 1 file changed, 25 insertions(+) diff --git a/Documentation/bpf/btf.rst b/Documentation/bpf/btf.rst index b5361b8621c9..44dc789de2b4 100644 --- a

[PATCH v9 bpf-next 03/14] bpf: Move btf_resolve_size into __btf_resolve_size

2020-08-01 Thread Jiri Olsa
Moving btf_resolve_size into __btf_resolve_size and keeping btf_resolve_size public with just first 3 arguments, because the rest of the arguments are not used by outside callers. Following changes are adding more arguments, which are not useful to outside callers. They will be added to the __btf_

[PATCH v9 bpf-next 04/14] bpf: Add elem_id pointer as argument to __btf_resolve_size

2020-08-01 Thread Jiri Olsa
If the resolved type is array, make btf_resolve_size return also ID of the elem type. It will be needed in following changes. Acked-by: Andrii Nakryiko Signed-off-by: Jiri Olsa --- kernel/bpf/btf.c | 10 +++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/kernel/bpf/btf.c b

[PATCH v9 bpf-next 00/14] bpf: Add d_path helper

2020-08-01 Thread Jiri Olsa
hi, adding d_path helper function that returns full path for given 'struct path' object, which needs to be the kernel BTF 'path' object. The path is returned in buffer provided 'buf' of size 'sz' and is zero terminated. int bpf_d_path(struct path *path, char *buf, u32 sz); The helper calls dire

[PATCH v9 bpf-next 06/14] bpf: Remove recursion call in btf_struct_access

2020-08-01 Thread Jiri Olsa
Andrii suggested we can simply jump to again label instead of making recursion call. Suggested-by: Andrii Nakryiko Signed-off-by: Jiri Olsa --- kernel/bpf/btf.c | 11 +-- 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/kernel/bpf/btf.c b/kernel/bpf/btf.c index bc05a24f7361

Re: [PATCH bpf-next] bpf: make __htab_lookup_and_delete_batch faster when map is almost empty

2020-08-01 Thread Yonghong Song
On 7/31/20 9:57 PM, Brian Vazquez wrote: While running some experiments it was observed that map_lookup_batch was much slower than get_next_key + lookup when the syscall overhead is minimal. This was because the map_lookup_batch implementation was more expensive traversing empty buckets, this

Re: WARNING: ODEBUG bug in cancel_delayed_work

2020-08-01 Thread syzbot
syzbot has bisected this issue to: commit 43ff7f53de2294a83dcf84b35de6ffa1ffafae9d Author: Bhumika Goyal Date: Thu Oct 6 18:10:01 2016 + Staging: vc04_services: vchiq_arm: Remove unused function remote_event_destroy bisection log: https://syzkaller.appspot.com/x/bisect.txt?x=107c810

[net-next 13/14] ice: adjust profile ID map locks

2020-08-01 Thread Tony Nguyen
From: Victor Raj The profile ID map lock should be held till the caller completes all references of that profile entries. The current code releases the lock right after the match search. This caused a driver issue when the profile map entries were referenced after it was freed in other thread af

[net-next 09/14] ice: port fix for chk_linearlize

2020-08-01 Thread Tony Nguyen
From: Kiran Patil This is a port of commit 248de22e638f ("i40e/i40evf: Account for frags split over multiple descriptors in check linearize") As part of testing workloads (read/write) using larger IO size (128K) tx_timeout is observed and whenever it happens, it was due to tx_linearize. Signed-

[net-next 05/14] ice: remove page_reuse statistic

2020-08-01 Thread Tony Nguyen
From: Jesse Brandeburg The page reuse statistic wasn't even being displayed to the user, even though the driver counted it. Don't waste the struct space and hot-path cycles since the driver doesn't display it. Signed-off-by: Jesse Brandeburg Tested-by: Andrew Bowers Signed-off-by: Tony Nguyen

[net-next 08/14] ice: Allow 2 queue pairs per VF on SR-IOV initialization

2020-08-01 Thread Tony Nguyen
From: Brett Creeley Currently VFs are only allowed to get 16, 4, and 1 queue pair by default, which require 17, 5, and 2 MSI-X vectors respectively. This is because each VF needs a MSI-X per data queue and a MSI-X for its other interrupt. The calculation is based on the number of VFs created, MSI

[net-next 06/14] ice: add useful statistics

2020-08-01 Thread Tony Nguyen
From: Jesse Brandeburg Display and count some useful hot-path statistics. The usefulness is as follows: - tx_restart: use to determine if the transmit ring size is too small or if the transmit interrupt rate is too low. - rx_gro_dropped: use to count drops from GRO layer, which previously were

[net-next 03/14] ice: fix the vsi_id mask to be 10 bit for set_rss_lut

2020-08-01 Thread Tony Nguyen
From: Kiran Patil set_rss_lut can fail due to incorrect vsi_id mask. vsi_id is 10 bit but mask was 0x1FF whereas it should be 0x3FF. For vsi_num >= 512, FW set_rss_lut can fail with return code EACCESS (VSI ownership issue) because software was providing incorrect vsi_num (dropping 10th bit due

[net-next 12/14] ice: update PTYPE lookup table

2020-08-01 Thread Tony Nguyen
Update the PTYPE lookup table to reflect values that can be set by the hardware. Signed-off-by: Tony Nguyen Tested-by: Andrew Bowers --- .../net/ethernet/intel/ice/ice_lan_tx_rx.h| 314 ++ 1 file changed, 314 insertions(+) diff --git a/drivers/net/ethernet/intel/ice/ice_lan

[net-next 01/14] ice: mark PM functions as __maybe_unused

2020-08-01 Thread Tony Nguyen
From: Wei Yongjun In certain configurations without power management support, the following warnings happen: drivers/net/ethernet/intel/ice/ice_main.c:4214:12: warning: 'ice_resume' defined but not used [-Wunused-function] 4214 | static int ice_resume(struct device *dev) |^~~

[net-next 04/14] ice: Fix RSS profile locks

2020-08-01 Thread Tony Nguyen
From: Vignesh Sridhar Replacing flow profile locks with RSS profile locks in the function to remove all RSS rules for a given VSI. This is to align the locks used for RSS rule addition to VSI and removal during VSI teardown to avoid a race condition owing to several iterations of the above operat

[net-next 14/14] ice: Misc minor fixes

2020-08-01 Thread Tony Nguyen
This is a collection of minor fixes including typos, white space, and style. No functional changes. Signed-off-by: Tony Nguyen Tested-by: Andrew Bowers --- drivers/net/ethernet/intel/ice/ice_common.c | 5 ++--- drivers/net/ethernet/intel/ice/ice_devlink.c | 2 +- drivers/net/ethernet/i

[net-next 11/14] ice: Disable VLAN pruning in promiscuous mode

2020-08-01 Thread Tony Nguyen
From: Nick Nunley Disable VLAN pruning when entering promiscuous mode, and re-enable it when exiting. Without this VLAN-over-bridge topologies created on the device won't be functional unless rx-vlan-filter is explicitly disabled with ethtool. Signed-off-by: Nick Nunley Tested-by: Andrew Bower

[net-next 02/14] ice: rename misleading grst_delay variable

2020-08-01 Thread Tony Nguyen
From: Nick Nunley The grst_delay variable in ice_check_reset contains the maximum time (in 100 msec units) that the driver will wait for a reset event to transition to the Device Active state. The value is the sum of three separate components: 1) The maximum time it may take for the firmware to p

[net-next 00/14][pull request] 100GbE Intel Wired LAN Driver Updates 2020-08-01

2020-08-01 Thread Tony Nguyen
This series contains updates to the ice driver only. Wei Yongjun marks power management functions with __maybe_unused. Nick disables VLAN pruning in promiscuous mode and renames grst_delay to grst_timeout. Kiran modifies the check for linearization and corrects the vsi_id mask value. Vignesh re

[net-next 07/14] ice: Clear and free XLT entries on reset

2020-08-01 Thread Tony Nguyen
From: Vignesh Sridhar This fix has been added to address memory leak issues resulting from triggering a sudden driver reset which does not allow us to follow our normal removal flows for SW XLT entries for advanced features. - Adding call to destroy flow profile locks when clearing SW XLT tables

[net-next 10/14] ice: Graceful error handling in HW table calloc failure

2020-08-01 Thread Tony Nguyen
From: Surabhi Boob In the ice_init_hw_tbls, if the devm_kcalloc for es->written fails, catch that error and bail out gracefully, instead of continuing with a NULL pointer. Fixes: 32d63fa1e9f3 ("ice: Initialize DDP package structures") Signed-off-by: Surabhi Boob Tested-by: Andrew Bowers Signed

[PATCH] via-velocity: Add missing KERN_ where needed

2020-08-01 Thread Joe Perches
Link status is emitted on multiple lines as it does not use KERN_CONT. Coalesce the multi-part logging into a single line output and add missing KERN_ to a couple logging calls. This also reduces object size. Signed-off-by: Joe Perches --- drivers/net/ethernet/via/via-velocity.c | 46 +

Re: [PATCH bpf-next 1/5] bpf: introduce BPF_PROG_TYPE_USER

2020-08-01 Thread kernel test robot
Hi Song, I love your patch! Yet something to improve: [auto build test ERROR on bpf-next/master] url: https://github.com/0day-ci/linux/commits/Song-Liu/introduce-BPF_PROG_TYPE_USER/20200801-165208 base: https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next.git master config: i386

Re: [PATCH 2/2] net: phy: Associate device node with fixed PHY

2020-08-01 Thread Andrew Lunn
On Sat, Aug 01, 2020 at 10:41:32AM +0100, Russell King - ARM Linux admin wrote: > On Sat, Aug 01, 2020 at 09:52:52AM +0530, Vikas Singh wrote: > > Hi Andrew, > > > > Please refer to the "fman" node under > > linux/arch/arm64/boot/dts/freescale/fsl-ls1046a-rdb.dts > > I have two 10G ethernet interf

Re: [Linux-kernel-mentees] [PATCH net] rds: Prevent kernel-infoleak in rds_notify_queue_get()

2020-08-01 Thread Jason Gunthorpe
On Sat, Aug 01, 2020 at 11:00:26AM +0300, Dan Carpenter wrote: > > Without an actual example where this doesn't work right it is hard to > > say anything more.. > > Here is the example that set off the recent patches: > > https://lkml.org/lkml/2020/7/27/199 Oh, that is something completely diffe

[PATCH net-next] mptcp: fix syncookie build error on UP

2020-08-01 Thread Florian Westphal
kernel test robot says: net/mptcp/syncookies.c: In function 'mptcp_join_cookie_init': include/linux/kernel.h:47:38: warning: division by zero [-Wdiv-by-zero] #define ARRAY_SIZE(arr) (sizeof(arr) / sizeof((arr)[0]) + __must_be_array(arr)) I forgot that spinock_t size is 0 on UP, so ARRAY_SIZE cann

[no subject]

2020-08-01 Thread Tayeb Souami
Ahoj!Jmenuji se Tayeb Souami, křesťanský a americký občan. Žádám vás o svolení svěřit společenskou a humanitární misi ve vaší zemi provedením malého vyhledávání ve vyhledávání Google, které jsem překročil vaši e-mailovou adresu.Čekám na vaši odpověď, abych vám dal další podrobnosti.Děkuji mn

[PATCH V1 net-next 3/3] net: ena: xdp: add queue counters for xdp actions

2020-08-01 Thread sameehj
From: Sameeh Jubran When using XDP every ingress packet is passed to an eBPF (xdp) program which returns an action for this packet. This patch adds counters for the number of times each such action was received. It also counts all the invalid actions received from the eBPF program. Signed-off-b

[PATCH V1 net-next 2/3] net: ena: ethtool: add stats printing to XDP queues

2020-08-01 Thread sameehj
From: Sameeh Jubran Added statistics for TX queues that are used for XDP TX. The statistics are the same as the ones printed for regular non-XDP TX queues. The XDP queue statistics can be queried using `ethtool -S ` Signed-off-by: Shay Agroskin Signed-off-by: Sameeh Jubran --- drivers/net/et

[PATCH V1 net-next 0/3] Enhance current features in ena driver

2020-08-01 Thread sameehj
From: Sameeh Jubran This series adds the following: * Exposes new device stats using ethtool. * Adds and exposes the stats of xdp TX queues through ethtool. Sameeh Jubran (3): net: ena: ethtool: Add new device statistics net: ena: ethtool: add stats printing to XDP queues net: ena: xdp: ad

[PATCH V1 net-next 1/3] net: ena: ethtool: Add new device statistics

2020-08-01 Thread sameehj
From: Sameeh Jubran The new metrics provide granular visibility along multiple network dimensions and enable troubleshooting and remediation of issues caused by instances exceeding network performance allowances. The new statistics can be queried using ethtool command. Signed-off-by: Guy Tzalik

Re: [PATCH bpf-next 1/5] bpf: introduce BPF_PROG_TYPE_USER

2020-08-01 Thread kernel test robot
Hi Song, I love your patch! Yet something to improve: [auto build test ERROR on bpf-next/master] url: https://github.com/0day-ci/linux/commits/Song-Liu/introduce-BPF_PROG_TYPE_USER/20200801-165208 base: https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next.git master config: riscv

Re: [PATCH v2] drivers/net/wan/lapbether: Use needed_headroom instead of hard_header_len

2020-08-01 Thread Willem de Bruijn
On Sat, Aug 1, 2020 at 8:46 AM Xie He wrote: > > On Fri, Jul 31, 2020 at 7:33 PM Willem de Bruijn > wrote: > > > > I quickly scanned the main x.25 datapath code. Specifically > > x25_establish_link, x25_terminate_link and x25_send_frame. These all > > write this 1 byte header. It appears to be an

Re: [RFC PATCH 00/17] Drop uses of pci_read_config_*() return value

2020-08-01 Thread Borislav Petkov
On Sat, Aug 01, 2020 at 01:24:29PM +0200, Saheed O. Bolarinwa wrote: > The return value of pci_read_config_*() may not indicate a device error. > However, the value read by these functions is more likely to indicate > this kind of error. This presents two overlapping ways of reporting > errors and

Re: [PATCH v2] drivers/net/wan/lapbether: Use needed_headroom instead of hard_header_len

2020-08-01 Thread Xie He
On Fri, Jul 31, 2020 at 7:33 PM Willem de Bruijn wrote: > > I quickly scanned the main x.25 datapath code. Specifically > x25_establish_link, x25_terminate_link and x25_send_frame. These all > write this 1 byte header. It appears to be an in-band communication > means between the network and data

[RFC PATCH 17/17] net: Drop uses of pci_read_config_*() return value

2020-08-01 Thread Saheed O. Bolarinwa
The return value of pci_read_config_*() may not indicate a device error. However, the value read by these functions is more likely to indicate this kind of error. This presents two overlapping ways of reporting errors and complicates error checking. It is possible to move to one single way of chec

[RFC PATCH 00/17] Drop uses of pci_read_config_*() return value

2020-08-01 Thread Saheed O. Bolarinwa
The return value of pci_read_config_*() may not indicate a device error. However, the value read by these functions is more likely to indicate this kind of error. This presents two overlapping ways of reporting errors and complicates error checking. It is possible to move to one single way of chec

[RFC PATCH 02/17] atm: Drop uses of pci_read_config_*() return value

2020-08-01 Thread Saheed O. Bolarinwa
The return value of pci_read_config_*() may not indicate a device error. However, the value read by these functions is more likely to indicate this kind of error. This presents two overlapping ways of reporting errors and complicates error checking. It is possible to move to one single way of chec

Re: [PATCH v1] qed: Use %pM format specifier for MAC addresses

2020-08-01 Thread Andy Shevchenko
On Thu, Jul 30, 2020 at 04:26:17PM +, Alexander Lobakin wrote: > From: Andy Shevchenko > Date: Thu, 30 Jul 2020 18:59:20 +0300 > > > Convert to %pM instead of using custom code. > Thanks! > > Acked-by: Alexander Lobakin Thanks, but no-one sees this properly (seems broken message-id -> in-

linux-next: Fixes tag needs some work in the bpf-next tree

2020-08-01 Thread Stephen Rothwell
Hi all, In commit 1acf8f90ea7e ("libbpf: Fix register in PT_REGS MIPS macros") Fixes tag Fixes: c1932cd ("bpf: Add MIPS support to samples/bpf.") has these problem(s): - SHA1 should be at least 12 digits long Can be fixed by setting core.abbrev to 12 (or more) or (for git v2.11

Re: [PATCH 2/2] net: phy: Associate device node with fixed PHY

2020-08-01 Thread Russell King - ARM Linux admin
On Sat, Aug 01, 2020 at 09:52:52AM +0530, Vikas Singh wrote: > Hi Andrew, > > Please refer to the "fman" node under > linux/arch/arm64/boot/dts/freescale/fsl-ls1046a-rdb.dts > I have two 10G ethernet interfaces out of which one is of fixed-link. Please do not top post. How does XGMII (which is a

Re: [PATCH] net: Phy: Add PHY lookup support on MDIO bus in case of ACPI probe

2020-08-01 Thread Russell King - ARM Linux admin
On Sat, Aug 01, 2020 at 10:23:38AM +0530, Vikas Singh wrote: > Hi Andrew, > > As i have already mentioned that this patch is based on > https://www.spinics.net/lists/netdev/msg662173.html, > > > When MDIO bus gets registered itself along with

[PATCH] net: Pass NULL to skb_network_protocol() when we don't care about vlan depth

2020-08-01 Thread linmiaohe
From: Miaohe Lin When we don't care about vlan depth, we could pass NULL instead of the address of a unused local variable to skb_network_protocol() as a param. Signed-off-by: Miaohe Lin --- net/core/skbuff.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/net/core/skbuff

Re: [PATCH net-next] tcp: fix build fong CONFIG_MPTCP=n

2020-08-01 Thread Florian Westphal
Florian Westphal wrote: > Eric Dumazet wrote: > > Fixes these errors: > > > > net/ipv4/syncookies.c: In function 'tcp_get_cookie_sock': > > net/ipv4/syncookies.c:216:19: error: 'struct tcp_request_sock' has no > > member named 'drop_req' > > 216 | if (tcp_rsk(req)->drop_req) { > > |

[PATCH] net: Use __skb_pagelen() directly in skb_cow_data()

2020-08-01 Thread linmiaohe
From: Miaohe Lin In fact, skb_pagelen() - skb_headlen() is equal to __skb_pagelen(), use it directly to avoid unnecessary skb_headlen() call. Also fix the CHECK note of checkpatch.pl: Comparison to NULL could be written "!__pskb_pull_tail" Signed-off-by: Miaohe Lin --- net/core/skbuff.c |

  1   2   >