[PATCHv2 net] sctp: not disable bh in the whole sctp_get_port_local()

2020-08-20 Thread Xin Long
With disabling bh in the whole sctp_get_port_local(), when snum == 0 and too many ports have been used, the do-while loop will take the cpu for a long time and cause cpu stuck: [ ] watchdog: BUG: soft lockup - CPU#11 stuck for 22s! [ ] RIP: 0010:native_queued_spin_lock_slowpath+0x4de/0x940 [

Re: [PATCH net] sctp: not disable bh in the whole sctp_get_port_local()

2020-08-20 Thread Xin Long
On Thu, Aug 20, 2020 at 9:13 PM Eric Dumazet wrote: > > > > On 8/19/20 11:48 PM, Xin Long wrote: > > With disabling bh in the whole sctp_get_port_local(), when > > snum == 0 and too many ports have been used, the do-while > > loop will take the cpu for a long time and cause cpu stuck: > > > > [

[PATCH][next] atmel: Use fallthrough pseudo-keyword

2020-08-20 Thread Gustavo A. R. Silva
Replace the existing /* fall through */ comments and its variants with the new pseudo-keyword macro fallthrough[1]. [1] https://www.kernel.org/doc/html/v5.7/process/deprecated.html?highlight=fallthrough#implicit-switch-case-fall-through Signed-off-by: Gustavo A. R. Silva --- drivers/net/wirele

[PATCH][next] carl9170: Use fallthrough pseudo-keyword

2020-08-20 Thread Gustavo A. R. Silva
Replace the existing /* fall through */ comments and its variants with the new pseudo-keyword macro fallthrough[1]. [1] https://www.kernel.org/doc/html/v5.7/process/deprecated.html?highlight=fallthrough#implicit-switch-case-fall-through Signed-off-by: Gustavo A. R. Silva --- drivers/net/wirele

Re: [PATCH bpf-next v2 2/3] bpf: implement link_query callbacks in map element iterators

2020-08-20 Thread Yonghong Song
On 8/20/20 11:33 PM, Andrii Nakryiko wrote: On Thu, Aug 20, 2020 at 3:50 PM Yonghong Song wrote: For bpf_map_elem and bpf_sk_local_storage bpf iterators, additional map_id should be shown for fdinfo and userspace query. For example, the following is for a bpf_map_elem iterator. $ cat /pr

[PATCH][next] rtw88: Use fallthrough pseudo-keyword

2020-08-20 Thread Gustavo A. R. Silva
Replace the existing /* fall through */ comments and its variants with the new pseudo-keyword macro fallthrough[1]. [1] https://www.kernel.org/doc/html/v5.7/process/deprecated.html?highlight=fallthrough#implicit-switch-case-fall-through Signed-off-by: Gustavo A. R. Silva --- drivers/net/wirele

Re: [PATCH bpf-next v2 1/3] bpf: implement link_query for bpf iterators

2020-08-20 Thread Yonghong Song
On 8/20/20 11:31 PM, Andrii Nakryiko wrote: On Thu, Aug 20, 2020 at 3:50 PM Yonghong Song wrote: This patch implemented bpf_link callback functions show_fdinfo and fill_link_info to support link_query interface. The general interface for show_fdinfo and fill_link_info will print/fill the t

[PATCH][next] mwifiex: Use fallthrough pseudo-keyword

2020-08-20 Thread Gustavo A. R. Silva
Replace the existing /* fall through */ comments and its variants with the new pseudo-keyword macro fallthrough[1]. [1] https://www.kernel.org/doc/html/v5.7/process/deprecated.html?highlight=fallthrough#implicit-switch-case-fall-through Signed-off-by: Gustavo A. R. Silva --- drivers/net/wirele

[PATCH][next] b43legacy: Use fallthrough pseudo-keyword

2020-08-20 Thread Gustavo A. R. Silva
Replace the existing /* fall through */ comments and its variants with the new pseudo-keyword macro fallthrough[1]. [1] https://www.kernel.org/doc/html/v5.7/process/deprecated.html?highlight=fallthrough#implicit-switch-case-fall-through Signed-off-by: Gustavo A. R. Silva --- drivers/net/wirele

[PATCH][next] b43: Use fallthrough pseudo-keyword

2020-08-20 Thread Gustavo A. R. Silva
Replace the existing /* fall through */ comments and its variants with the new pseudo-keyword macro fallthrough[1]. [1] https://www.kernel.org/doc/html/v5.7/process/deprecated.html?highlight=fallthrough#implicit-switch-case-fall-through Signed-off-by: Gustavo A. R. Silva --- drivers/net/wirele

Re: [PATCH bpf-next v2 3/3] bpftool: implement link_query for bpf iterators

2020-08-20 Thread Andrii Nakryiko
On Thu, Aug 20, 2020 at 3:50 PM Yonghong Song wrote: > > The link query for bpf iterators is implemented. > Besides being shown to the user what bpf iterator > the link represents, the target_name is also used > to filter out what additional information should be > printed out, e.g., whether map_i

Re: [PATCH bpf-next v2 2/3] bpf: implement link_query callbacks in map element iterators

2020-08-20 Thread Andrii Nakryiko
On Thu, Aug 20, 2020 at 3:50 PM Yonghong Song wrote: > > For bpf_map_elem and bpf_sk_local_storage bpf iterators, > additional map_id should be shown for fdinfo and > userspace query. For example, the following is for > a bpf_map_elem iterator. > $ cat /proc/1753/fdinfo/9 > pos:0 > flags

[PATCH][next] iwlegacy: Use fallthrough pseudo-keyword

2020-08-20 Thread Gustavo A. R. Silva
Replace the existing /* fall through */ comments and its variants with the new pseudo-keyword macro fallthrough[1]. [1] https://www.kernel.org/doc/html/v5.7/process/deprecated.html?highlight=fallthrough#implicit-switch-case-fall-through Signed-off-by: Gustavo A. R. Silva --- drivers/net/wirele

Re: [PATCH bpf-next v2 1/3] bpf: implement link_query for bpf iterators

2020-08-20 Thread Andrii Nakryiko
On Thu, Aug 20, 2020 at 3:50 PM Yonghong Song wrote: > > This patch implemented bpf_link callback functions > show_fdinfo and fill_link_info to support link_query > interface. > > The general interface for show_fdinfo and fill_link_info > will print/fill the target_name. Each targets can > registe

[PATCH][next] brcmfmac: Use fallthrough pseudo-keyword

2020-08-20 Thread Gustavo A. R. Silva
Replace the existing /* fall through */ comments and its variants with the new pseudo-keyword macro fallthrough[1]. Also, remove unnecessary fall-through markings when it is the case. [1] https://www.kernel.org/doc/html/v5.7/process/deprecated.html?highlight=fallthrough#implicit-switch-case-fall-

[PATCH][next] orinoco: Use fallthrough pseudo-keyword

2020-08-20 Thread Gustavo A. R. Silva
Replace the existing /* fall through */ comments and its variants with the new pseudo-keyword macro fallthrough[1]. [1] https://www.kernel.org/doc/html/v5.7/process/deprecated.html?highlight=fallthrough#implicit-switch-case-fall-through Signed-off-by: Gustavo A. R. Silva --- drivers/net/wirele

[PATCH][next] prism54: Use fallthrough pseudo-keyword

2020-08-20 Thread Gustavo A. R. Silva
Replace the existing /* fall through */ comments and its variants with the new pseudo-keyword macro fallthrough[1]. [1] https://www.kernel.org/doc/html/v5.7/process/deprecated.html?highlight=fallthrough#implicit-switch-case-fall-through Signed-off-by: Gustavo A. R. Silva --- drivers/net/wirele

Re: [PATCH bpf-next] docs: correct subject prefix and update LLVM info

2020-08-20 Thread Yonghong Song
On 8/20/20 10:28 PM, Jianlin Lv wrote: bpf_devel_QA.rst:152 The subject prefix information is not accurate, it should be 'PATCH bpf-next v2' Also update LLVM version info and add information about ‘-DLLVM_TARGETS_TO_BUILD’ to prompt the developer to build the desired target. Signed-off-by: J

Re: [PATCH v7 bpf-next] bpf/selftests: fold test_current_pid_tgid_new_ns into test_progs.

2020-08-20 Thread Andrii Nakryiko
On Thu, Aug 20, 2020 at 6:29 PM Carlos Neira wrote: > > Currently tests for bpf_get_ns_current_pid_tgid() are outside test_progs. > This change folds test cases into test_progs. > > Changes from V6: > - Rebased changes. > > Signed-off-by: Carlos Neira > --- Acked-by: Andrii Nakryiko > tools/

Re: [PATCH v2 bpf 2/2] selftests/bpf: add test for freplace program with write access

2020-08-20 Thread Yonghong Song
On 8/20/20 5:28 PM, Udip Pant wrote: This adds a selftest that tests the behavior when a freplace target program attempts to make a write access on a packet. The expectation is that the read or write access is granted based on the program type of the linked program and not itself (which is of

Re: [PATCH v2 bpf 1/2] bpf: verifier: check for packet data access based on target prog

2020-08-20 Thread Yonghong Song
On 8/20/20 11:13 PM, Yonghong Song wrote: On 8/20/20 5:28 PM, Udip Pant wrote: While using dynamic program extension (of type BPF_PROG_TYPE_EXT), we need to check the program type of the target program to grant the read / write access to the packet data. The BPF_PROG_TYPE_EXT type can be u

[PATCH][next] rt2x00: Use fallthrough pseudo-keyword

2020-08-20 Thread Gustavo A. R. Silva
Replace the existing /* fall through */ comments and its variants with the new pseudo-keyword macro fallthrough[1]. Also, remove unnecessary fall-through markings when it is the case. [1] https://www.kernel.org/doc/html/v5.7/process/deprecated.html?highlight=fallthrough#implicit-switch-case-fall-

Re: [PATCH v2 bpf 1/2] bpf: verifier: check for packet data access based on target prog

2020-08-20 Thread Yonghong Song
On 8/20/20 5:28 PM, Udip Pant wrote: While using dynamic program extension (of type BPF_PROG_TYPE_EXT), we need to check the program type of the target program to grant the read / write access to the packet data. The BPF_PROG_TYPE_EXT type can be used to extend types such as XDP, SKB and othe

[PATCH][next] rtlwifi: Use fallthrough pseudo-keyword

2020-08-20 Thread Gustavo A. R. Silva
Replace the existing /* fall through */ comments and its variants with the new pseudo-keyword macro fallthrough[1]. [1] https://www.kernel.org/doc/html/v5.7/process/deprecated.html?highlight=fallthrough#implicit-switch-case-fall-through Signed-off-by: Gustavo A. R. Silva --- drivers/net/wirele

general protection fault in fib_check_nexthop

2020-08-20 Thread syzbot
Hello, syzbot found the following issue on: HEAD commit:18445bf4 Merge tag 'spi-fix-v5.9-rc1' of git://git.kernel... git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=162cbd7a90 kernel config: https://syzkaller.appspot.com/x/.config?x=a0437fdd630bee11 das

[PATCH][next] iwlwifi: Use fallthrough pseudo-keyword

2020-08-20 Thread Gustavo A. R. Silva
Replace the existing /* fall through */ comments and its variants with the new pseudo-keyword macro fallthrough[1]. [1] https://www.kernel.org/doc/html/v5.7/process/deprecated.html?highlight=fallthrough#implicit-switch-case-fall-through Signed-off-by: Gustavo A. R. Silva --- drivers/net/wirele

[PATCH][next] mediatek: Use fallthrough pseudo-keyword

2020-08-20 Thread Gustavo A. R. Silva
Replace the existing /* fall through */ comments and its variants with the new pseudo-keyword macro fallthrough[1]. Also, remove unnecessary fall-through markings when it is the case. [1] https://www.kernel.org/doc/html/v5.7/process/deprecated.html?highlight=fallthrough#implicit-switch-case-fall-

[PATCH net-next] net: remove redundant variable in vxlan_xmit_one

2020-08-20 Thread Jianlin Lv
dst/src is used multiple times in vxlan_xmit_one function as the variable name, although its scope is different, but it reduces the readability and it is unnecessary to use intermediate variables here; This patch reduces unnecessary assignments and removes redundant variables Signed-off-by: Jianli

[PATCH bpf-next] docs: correct subject prefix and update LLVM info

2020-08-20 Thread Jianlin Lv
bpf_devel_QA.rst:152 The subject prefix information is not accurate, it should be 'PATCH bpf-next v2' Also update LLVM version info and add information about ‘-DLLVM_TARGETS_TO_BUILD’ to prompt the developer to build the desired target. Signed-off-by: Jianlin Lv --- Documentation/bpf/bpf_devel_

Re: [RFC 1/3] Initialize devlink health dump framework for the dlge driver

2020-08-20 Thread Benjamin Poirier
On 2020-08-21 11:08 +0800, Coiby Xu wrote: [...] > > > diff --git a/drivers/staging/qlge/qlge_health.h > > > b/drivers/staging/qlge/qlge_health.h > > > new file mode 100644 > > > index ..07d3bafab845 > > > --- /dev/null > > > +++ b/drivers/staging/qlge/qlge_health.h > > > @@ -0,0 +1,2

Re: [PATCH iproute2 net-next] iplink: add support for protodown reason

2020-08-20 Thread Roopa Prabhu
On 8/20/20 9:36 PM, Stephen Hemminger wrote: On Thu, 20 Aug 2020 20:52:02 -0700 Roopa Prabhu wrote: + if (tb[IFLA_PROTO_DOWN]) { + if (rta_getattr_u8(tb[IFLA_PROTO_DOWN])) + print_bool(PRINT_ANY, +"proto_down", " protodown

Re: [PATCH] rtlwifi: switch from 'pci_' to 'dma_' API

2020-08-20 Thread Larry Finger
On 8/20/20 9:46 AM, Christophe JAILLET wrote: The wrappers in include/linux/pci-dma-compat.h should go away. The patch has been generated with the coccinelle script below and has been hand modified to replace GFP_ with a correct flag. It has been compile tested. The only file where some GFP_ fl

Re: [PATCH iproute2 net-next] iplink: add support for protodown reason

2020-08-20 Thread Stephen Hemminger
On Thu, 20 Aug 2020 20:52:02 -0700 Roopa Prabhu wrote: > + if (tb[IFLA_PROTO_DOWN]) { > + if (rta_getattr_u8(tb[IFLA_PROTO_DOWN])) > + print_bool(PRINT_ANY, > +"proto_down", " protodown on ", true); In general my preference is t

[PATCH iproute2 net-next] iplink: add support for protodown reason

2020-08-20 Thread Roopa Prabhu
From: Roopa Prabhu This patch adds support for recently added link IFLA_PROTO_DOWN_REASON attribute. IFLA_PROTO_DOWN_REASON enumerates reasons for the already existing IFLA_PROTO_DOWN link attribute. $ cat /etc/iproute2/protodown_reasons.d/r.conf 0 mlag 1 evpn 2 vrrp 3 psecurity $ ip link set d

Re: [RFC 3/3] staging: qlge: clean up code that dump info to dmesg

2020-08-20 Thread Coiby Xu
On Sun, Aug 16, 2020 at 11:57:17AM +0900, Benjamin Poirier wrote: On 2020-08-15 00:06 +0800, Coiby Xu wrote: The related code are not necessary because, - Device status and general registers can be obtained by ethtool. - Coredump can be done via devlink health reporter. - Structure related to th

Re: [RFC 1/3] Initialize devlink health dump framework for the dlge driver

2020-08-20 Thread Coiby Xu
On Sun, Aug 16, 2020 at 11:56:40AM +0900, Benjamin Poirier wrote: On 2020-08-15 00:05 +0800, Coiby Xu wrote: Initialize devlink health dump framework for the dlge driver so the coredump could be done via devlink. Signed-off-by: Coiby Xu --- drivers/staging/qlge/Makefile | 2 +- drivers/

Re: [PATCH net-next] hinic: add debugfs support

2020-08-20 Thread luobin (L)
On 2020/8/21 0:02, Jakub Kicinski wrote: > On Thu, 20 Aug 2020 20:14:32 +0800 Luo bin wrote: >> +static int hinic_dbg_help(struct hinic_dev *nic_dev, const char *cmd_buf) >> +{ >> +netif_info(nic_dev, drv, nic_dev->netdev, "Available commands:\n"); >> +netif_info(nic_dev, drv, nic_dev->netd

[PATCH bpf-next] libbpf: add perf_buffer APIs for better integration with outside epoll loop

2020-08-20 Thread Andrii Nakryiko
Add a set of APIs to perf_buffer manage to allow applications to integrate perf buffer polling into existing epoll-based infrastructure. One example is applications using libevent already and wanting to plug perf_buffer polling, instead of relying on perf_buffer__poll() and waste an extra thread to

[net-next PATCH] netlabel: fix problems with mapping removal

2020-08-20 Thread Paul Moore
This patch fixes two main problems seen when removing NetLabel mappings: memory leaks and potentially extra audit noise. The memory leaks are caused by not properly free'ing the mapping's address selector struct when free'ing the entire entry as well as not properly cleaning up a temporary mapping

[PATCH v7 bpf-next] bpf/selftests: fold test_current_pid_tgid_new_ns into test_progs.

2020-08-20 Thread Carlos Neira
Currently tests for bpf_get_ns_current_pid_tgid() are outside test_progs. This change folds test cases into test_progs. Changes from V6: - Rebased changes. Signed-off-by: Carlos Neira --- tools/testing/selftests/bpf/.gitignore| 1 - tools/testing/selftests/bpf/Makefile | 3

[RFC PATCH net-next 1/2] net: Implement granular VF trust flags

2020-08-20 Thread Carolyn Wyborny
Add generic VF privilege defines as trust flags, ifla_vf_trust_flags struct and validation by the kernel of flags configured by drivers. These are all for use with granular VF Trust flags feature. See known limitations and gaps in the cover message. Signed-off-by: Carolyn Wyborny --- include/l

[RFC PATCH net-next 2/2] igb: Implement granular VF trust flags

2020-08-20 Thread Carolyn Wyborny
Implement granular VF trust flags feature in the igb driver. See known limitations and gaps in cover message. Signed-off-by: Carolyn Wyborny --- drivers/net/ethernet/intel/igb/igb.h |2 +- drivers/net/ethernet/intel/igb/igb_main.c | 21 +++-- 2 files changed, 12 inse

[RFC PATCH net-next 0/2] Granular VF Trust Flags for SR-IOV

2020-08-20 Thread Carolyn Wyborny
Proposal for Granular VF Trust Flags for SR-IOV I would like to propose extending the concept of VF trust in a more granular way by creating VF trust flags. VF Trust Flags would allow more flexibility in assigning privileges to VF's administratively in SR-IOV. Users are asking for more configurati

linux-next: build failure after merge of the bpf-next tree

2020-08-20 Thread Stephen Rothwell
Hi all, After merging the bpf-next tree, today's linux-next build (x86_64 allmodconfig) failed like this: Auto-detecting system features: ...libelf: [ OFF ] ... zlib: [ OFF ] ... bpf: [ on ] No li

[PATCH v2 bpf 2/2] selftests/bpf: add test for freplace program with write access

2020-08-20 Thread Udip Pant
This adds a selftest that tests the behavior when a freplace target program attempts to make a write access on a packet. The expectation is that the read or write access is granted based on the program type of the linked program and not itself (which is of type, for e.g., BPF_PROG_TYPE_EXT). This

[PATCH v2 bpf 1/2] bpf: verifier: check for packet data access based on target prog

2020-08-20 Thread Udip Pant
While using dynamic program extension (of type BPF_PROG_TYPE_EXT), we need to check the program type of the target program to grant the read / write access to the packet data. The BPF_PROG_TYPE_EXT type can be used to extend types such as XDP, SKB and others. Since the BPF_PROG_TYPE_EXT program ty

Re: [PATCH net-next v2] Add Mellanox BlueField Gigabit Ethernet driver

2020-08-20 Thread Jakub Kicinski
On Fri, 21 Aug 2020 02:04:39 +0300 Vladimir Oltean wrote: > On Thu, Jul 30, 2020 at 05:30:59PM -0700, Jakub Kicinski wrote: > > On Thu, 30 Jul 2020 18:53:58 -0400 David Thompson wrote: > > > + > > > + /* Tell networking subsystem to poll GigE driver */ > > > + napi_schedule(&priv->napi); > > >

INFO: task hung in process_one_work (4)

2020-08-20 Thread syzbot
Hello, syzbot found the following issue on: HEAD commit:9123e3a7 Linux 5.9-rc1 git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=144c0c8990 kernel config: https://syzkaller.appspot.com/x/.config?x=3d400a47d1416652 dashboard link: https://syzkaller.appspot

Re: [PATCH v3] ravb: Fixed to be able to unload modules

2020-08-20 Thread David Miller
From: Yuusuke Ashizuka Date: Thu, 20 Aug 2020 18:43:07 +0900 > When this driver is built as a module, I cannot rmmod it after insmoding > it. > This is because that this driver calls ravb_mdio_init() at the time of > probe, and module->refcnt is incremented by alloc_mdio_bitbang() called > after

[PATCH net-next 1/2] io_uring: allow tcp ancillary data for __sys_recvmsg_sock()

2020-08-20 Thread Luke Hsiao
From: Luke Hsiao For TCP tx zero-copy, the kernel notifies the process of completions by queuing completion notifications on the socket error queue. This patch allows reading these notifications via recvmsg to support TCP tx zero-copy. Ancillary data was originally disallowed due to privilege es

[PATCH net-next 2/2] io_uring: ignore POLLIN for recvmsg on MSG_ERRQUEUE

2020-08-20 Thread Luke Hsiao
From: Luke Hsiao Currently, io_uring's recvmsg subscribes to both POLLERR and POLLIN. In the context of TCP tx zero-copy, this is inefficient since we are only reading the error queue and not using recvmsg to read POLLIN responses. This patch was tested by using a simple sending program to call

[PATCH net-next 0/2] Support reading msg errq from io_uring

2020-08-20 Thread Luke Hsiao
From: Luke Hsiao This patch series adds support for reading MSG_ERRQUEUE using the io_uring interface. Support for this operation allows io_uring to serve as an alternative to epoll + recvmsg for reading notification completions for TCP tx zerocopy. The first patch allows ancillary data to be r

Re: [PATCH net] tipc: call rcu_read_lock() in tipc_aead_encrypt_done()

2020-08-20 Thread David Miller
From: Xin Long Date: Thu, 20 Aug 2020 15:34:47 +0800 > b->media->send_msg() requires rcu_read_lock(), as we can see > elsewhere in tipc, tipc_bearer_xmit, tipc_bearer_xmit_skb > and tipc_bearer_bc_xmit(). > > Syzbot has reported this issue as: > > net/tipc/bearer.c:466 suspicious rcu_derefer

Re: [PATCH net] net/sched: act_ct: Fix skb double-free in tcf_ct_handle_fragments() error flow

2020-08-20 Thread David Miller
From: Alaa Hleihel Date: Wed, 19 Aug 2020 18:24:10 +0300 > tcf_ct_handle_fragments() shouldn't free the skb when ip_defrag() call > fails. Otherwise, we will cause a double-free bug. > In such cases, just return the error to the caller. > > Fixes: b57dc7c13ea9 ("net/sched: Introduce action ct")

Re: [PATCH v2] net: sctp: Fix negotiation of the number of data streams.

2020-08-20 Thread David Miller
From: David Laight Date: Wed, 19 Aug 2020 14:40:52 + > > The number of output and input streams was never being reduced, eg when > processing received INIT or INIT_ACK chunks. > The effect is that DATA chunks can be sent with invalid stream ids > and then discarded by the remote system. > >

Re: [PATCH net-next v2 0/4] refactoring of ibmvnic code

2020-08-20 Thread David Miller
From: Lijun Pan Date: Wed, 19 Aug 2020 17:52:22 -0500 > This patch series refactor reset_init and init functions, > and make some other cosmetic changes to make the code > easier to read and debug. v2 removes __func__ and v1's 1/5. Series applied, thank you.

Re: [PATCH bpf-next 10/16] libbpf: implement generalized .BTF.ext func/line info adjustment

2020-08-20 Thread Andrii Nakryiko
On Thu, Aug 20, 2020 at 4:13 PM Andrii Nakryiko wrote: > > Complete multi-prog sections and multi sub-prog support in libbpf by properly > adjusting .BTF.ext's line and function information. Mark exposed > btf_ext__reloc_func_info() and btf_ext__reloc_func_info() APIs as deprecated. > These APIs h

Re: [PATCH v2] dt-bindings: net: renesas,ether: Improve schema validation

2020-08-20 Thread David Miller
From: Geert Uytterhoeven Date: Wed, 19 Aug 2020 14:45:39 +0200 > - Remove pinctrl consumer properties, as they are handled by core > dt-schema, > - Document missing properties, > - Document missing PHY child node, > - Add "additionalProperties: false". > > Signed-off-by: Geert Uytter

Re: [PATCH net-next] net: ipa: remove duplicate include

2020-08-20 Thread David Miller
From: Wang Hai Date: Wed, 19 Aug 2020 10:46:45 +0800 > Remove linux/notifier.h which is included more than once > > Reported-by: Hulk Robot > Signed-off-by: Wang Hai Applied to net-next, thank you.

Re: [PATCH] gre6: Fix reception with IP6_TNL_F_RCV_DSCP_COPY

2020-08-20 Thread David Miller
From: Mark Tomlinson Date: Wed, 19 Aug 2020 13:53:58 +1200 > When receiving an IPv4 packet inside an IPv6 GRE packet, and the > IP6_TNL_F_RCV_DSCP_COPY flag is set on the tunnel, the IPv4 header would > get corrupted. This is due to the common ip6_tnl_rcv() function assuming > that the inner head

Re: [PATCH bpf-next 12/16] selftests/bpf: add selftest for multi-prog sections and bpf-to-bpf calls

2020-08-20 Thread Andrii Nakryiko
On Thu, Aug 20, 2020 at 4:13 PM Andrii Nakryiko wrote: > > Add a selftest excercising bpf-to-bpf subprogram calls, as well as multiple > entry-point BPF programs per section. Also make sure that BPF CO-RE works for > such set ups both for sub-programs and for multi-entry sections. > > Signed-off-b

Re: [PATCH net-next] ethtool: allow flow-type ether without IP protocol field

2020-08-20 Thread David Miller
From: Vishal Kulkarni Date: Wed, 19 Aug 2020 00:25:03 +0530 > Set IP protocol mask only when IP protocol field is set. > This will allow flow-type ether with vlan rule which don't have > protocol field to apply. > > ethtool -N ens5f4 flow-type ether proto 0x8100 vlan 0x600\ > m 0x1FFF action 3 l

Re: [PATCH net, 0/2] hv_netvsc: Some fixes for the select_queue

2020-08-20 Thread David Miller
From: Haiyang Zhang Date: Thu, 20 Aug 2020 14:53:13 -0700 > This patch set includes two fixes for the select_queue process. Series applied, thank you.

Re: [PATCH] nfc: st-nci: Remove unnecessary cast

2020-08-20 Thread David Miller
From: Alex Dewar Date: Thu, 20 Aug 2020 19:32:58 +0100 > In st_nci_hci_connectivity_event_received(), the return value of > devm_kzalloc() is unnecessarily cast from void*. Remove cast. > > Issue identified with Coccinelle. > > Signed-off-by: Alex Dewar Applied.

Re: [PATCH] nfc: st21nfca: Remove unnecessary cast

2020-08-20 Thread David Miller
From: Alex Dewar Date: Thu, 20 Aug 2020 19:38:36 +0100 > In st21nfca_connectivity_event_received(), the return value of > devm_kzalloc() is unnecessarily cast from void*. Remove cast. > > Issue identified with Coccinelle. > > Signed-off-by: Alex Dewar Applied.

Re: [PATCH v5 bpf-next 07/12] bpf: tcp: Add bpf_skops_hdr_opt_len() and bpf_skops_write_hdr_opt()

2020-08-20 Thread Martin KaFai Lau
On Thu, Aug 20, 2020 at 03:39:21PM -0700, Mat Martineau wrote: > > On Thu, 20 Aug 2020, Martin KaFai Lau wrote: > > > The bpf prog needs to parse the SYN header to learn what options have > > been sent by the peer's bpf-prog before writing its options into SYNACK. > > This patch adds a "syn_skb"

Re: [PATCH] net: qed: Remove unnecessary cast

2020-08-20 Thread David Miller
From: Alex Dewar Date: Thu, 20 Aug 2020 18:47:25 +0100 > In qed_rdma_destroy_cq() the result of dma_alloc_coherent() is cast from > void* unnecessarily. Remove cast. > > Issue identified with Coccinelle. > > Signed-off-by: Alex Dewar Applied to net-next, thanks.

Re: [PATCH net-next 0/3] tcp_mmap: optmizations

2020-08-20 Thread David Miller
From: Eric Dumazet Date: Thu, 20 Aug 2020 10:11:15 -0700 > This series updates tcp_mmap reference tool to use best pratices. > > First patch is using madvise(MADV_DONTNEED) to decrease pressure > on the socket lock. > > Last patches try to use huge pages when available. Series applied, thanks

[PATCH bpf-next 09/16] libbpf: make RELO_CALL work for multi-prog sections and sub-program calls

2020-08-20 Thread Andrii Nakryiko
This patch implements general and correct logic for bpf-to-bpf sub-program calls. Only sub-programs used (called into) from entry-point (main) BPF program are going to be appended at the end of main BPF program. This ensures that BPF verifier won't encounter any dead code due to copying unreference

[PATCH bpf-next 11/16] libbpf: add multi-prog section support for struct_ops

2020-08-20 Thread Andrii Nakryiko
Adjust struct_ops handling code to work with multi-program ELF sections properly. Signed-off-by: Andrii Nakryiko --- tools/lib/bpf/libbpf.c | 26 -- 1 file changed, 8 insertions(+), 18 deletions(-) diff --git a/tools/lib/bpf/libbpf.c b/tools/lib/bpf/libbpf.c index 2151bb

[PATCH bpf-next 13/16] tools/bpftool: replace bpf_program__title() with bpf_program__section_name()

2020-08-20 Thread Andrii Nakryiko
bpf_program__title() is deprecated, switch to bpf_program__section_name() and avoid compilation warnings. Signed-off-by: Andrii Nakryiko --- tools/bpf/bpftool/prog.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/bpf/bpftool/prog.c b/tools/bpf/bpftool/prog.c index

[PATCH bpf-next 12/16] selftests/bpf: add selftest for multi-prog sections and bpf-to-bpf calls

2020-08-20 Thread Andrii Nakryiko
Add a selftest excercising bpf-to-bpf subprogram calls, as well as multiple entry-point BPF programs per section. Also make sure that BPF CO-RE works for such set ups both for sub-programs and for multi-entry sections. Signed-off-by: Andrii Nakryiko --- .../selftests/bpf/prog_tests/subprogs.c

[PATCH bpf-next 14/16] selftests/bpf: don't use deprecated libbpf APIs

2020-08-20 Thread Andrii Nakryiko
Remove all uses of bpf_program__title() and bpf_program__find_program_by_title(). Signed-off-by: Andrii Nakryiko --- tools/testing/selftests/bpf/flow_dissector_load.h | 8 +++- .../testing/selftests/bpf/prog_tests/reference_tracking.c | 2 +- tools/testing/selftests/bpf/test_socket_c

[PATCH bpf-next 08/16] libbpf: support CO-RE relocations for multi-prog sections

2020-08-20 Thread Andrii Nakryiko
Fix up CO-RE relocation code to handle relocations against ELF sections containing multiple BPF programs. This requires lookup of a BPF program by its section name and instruction index it contains. While it could have been done as a simple loop, it could run into performance issues pretty quickly,

[PATCH bpf-next 16/16] selftests/bpf: turn fexit_bpf2bpf into test with subtests

2020-08-20 Thread Andrii Nakryiko
There are clearly 4 subtests, so make it official. Signed-off-by: Andrii Nakryiko --- .../testing/selftests/bpf/prog_tests/fexit_bpf2bpf.c | 12 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/tools/testing/selftests/bpf/prog_tests/fexit_bpf2bpf.c b/tools/testing/self

[PATCH bpf-next 10/16] libbpf: implement generalized .BTF.ext func/line info adjustment

2020-08-20 Thread Andrii Nakryiko
Complete multi-prog sections and multi sub-prog support in libbpf by properly adjusting .BTF.ext's line and function information. Mark exposed btf_ext__reloc_func_info() and btf_ext__reloc_func_info() APIs as deprecated. These APIs have simplistic assumption that all sub-programs are going to be ap

[PATCH bpf-next 15/16] libbpf: deprecate notion of BPF program "title" in favor of "section name"

2020-08-20 Thread Andrii Nakryiko
BPF program title is ambigious and misleading term. It is ELF section name, so let's just call it that and deprecate bpf_program__title() API in favor of bpf_program__section_name(). Additionally, using bpf_object__find_program_by_title() is now inherently dangerous and ambiguous, as multiple BPF

[PATCH bpf-next 05/16] libbpf: normalize and improve logging across few functions

2020-08-20 Thread Andrii Nakryiko
Make libbpf logs follow similar pattern and provide more context like section name or program name, where appropriate. Also, add BPF_INSN_SZ constant and use it throughout to clean up code a little bit. This commit doesn't have any functional changes and just removes some code changes out of the wa

Re: [PATCH net-next] net: zerocopy: combine pages in zerocopy_sg_from_iter()

2020-08-20 Thread David Miller
From: Eric Dumazet Date: Thu, 20 Aug 2020 08:43:59 -0700 > Currently, tcp sendmsg(MSG_ZEROCOPY) is building skbs with order-0 fragments. > Compared to standard sendmsg(), these skbs usually contain up to 16 fragments > on arches with 4KB page sizes, instead of two. > > This adds considerable cos

[PATCH bpf-next 06/16] libbpf: ensure ELF symbols table is found before further ELF processing

2020-08-20 Thread Andrii Nakryiko
libbpf ELF parsing logic might need symbols available before ELF parsing is completed, so we need to make sure that symbols table section is found in a separate pass before all the subsequent sections are processed. Signed-off-by: Andrii Nakryiko --- tools/lib/bpf/libbpf.c | 40 +

[PATCH bpf-next 07/16] libbpf: parse multi-function sections into multiple BPF programs

2020-08-20 Thread Andrii Nakryiko
Teach libbpf how to parse code sections into potentially multiple bpf_program instances, based on ELF FUNC symbols. Each BPF program will keep track of its position within containing ELF section for translating section instruction offsets into program instruction offsets: regardless of BPF program'

[PATCH bpf-next 04/16] libbpf: skip well-known ELF sections when iterating ELF

2020-08-20 Thread Andrii Nakryiko
Skip and don't log ELF sections that libbpf knows about and ignores during ELF processing. This allows to not unnecessarily log details about those ELF sections and cleans up libbpf debug log. Ignored sections include DWARF data, string table, empty .text section and few special (e.g., .llvm_addrsi

[PATCH bpf-next 00/16] Add libbpf full support for BPF-to-BPF calls

2020-08-20 Thread Andrii Nakryiko
Currently, libbpf supports a limited form of BPF-to-BPF subprogram calls. The restriction is that entry-point BPF program should use *all* of defined sub-programs in BPF .o file. If any of the subprograms is not used, such entry-point BPF program will be rejected by verifier as containing unreachab

[PATCH bpf-next 02/16] libbpf: factor out common ELF operations and improve logging

2020-08-20 Thread Andrii Nakryiko
Factor out common ELF operations done throughout the libbpf. This simplifies usage across multiple places in libbpf, as well as hide error reporting from higher-level functions and make error logging more consistent. Signed-off-by: Andrii Nakryiko --- tools/lib/bpf/libbpf.c | 367 +++

[PATCH bpf-next 01/16] selftests/bpf: BPF object files should depend only on libbpf headers

2020-08-20 Thread Andrii Nakryiko
There is no need to re-build BPF object files if any of the sources of libbpf change. So record more precise dependency only on libbpf/bpf_*.h headers. This eliminates unnecessary re-builds. Signed-off-by: Andrii Nakryiko --- tools/testing/selftests/bpf/Makefile | 2 +- 1 file changed, 1 inserti

[PATCH bpf-next 03/16] libbpf: add __noinline macro to bpf_helpers.h

2020-08-20 Thread Andrii Nakryiko
__noinline is pretty frequently used, especially with BPF subprograms, so add them along the __always_inline, for user convenience and completeness. Signed-off-by: Andrii Nakryiko --- tools/lib/bpf/bpf_helpers.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tools/lib/bpf/bpf_helpers.h b

Re: [PATCH net-next v2] Add Mellanox BlueField Gigabit Ethernet driver

2020-08-20 Thread Vladimir Oltean
On Thu, Jul 30, 2020 at 05:30:59PM -0700, Jakub Kicinski wrote: > On Thu, 30 Jul 2020 18:53:58 -0400 David Thompson wrote: > > + > > + /* Tell networking subsystem to poll GigE driver */ > > + napi_schedule(&priv->napi); > > _irqoff Hmm, I wouldn't be so sure about this particular advice. Wit

Re: [PATCH net-next 0/2] nfp: flower: add support for QinQ matching

2020-08-20 Thread David Miller
From: Simon Horman Date: Thu, 20 Aug 2020 16:39:36 +0200 > Louis says: > > Add new feature to the Netronome flower driver to enable QinQ offload. > This needed a bit of gymnastics in order to not break compatibility with > older firmware as the flow key sent to the firmware had to be updated > i

[PATCH bpf-next v2 1/3] bpf: implement link_query for bpf iterators

2020-08-20 Thread Yonghong Song
This patch implemented bpf_link callback functions show_fdinfo and fill_link_info to support link_query interface. The general interface for show_fdinfo and fill_link_info will print/fill the target_name. Each targets can register show_fdinfo and fill_link_info callbacks to print/fill more target

[PATCH bpf-next v2 3/3] bpftool: implement link_query for bpf iterators

2020-08-20 Thread Yonghong Song
The link query for bpf iterators is implemented. Besides being shown to the user what bpf iterator the link represents, the target_name is also used to filter out what additional information should be printed out, e.g., whether map_id should be shown or not. The following is an example of bpf_iter

[PATCH bpf-next v2 0/3] bpf: implement link_query for bpf iterators

2020-08-20 Thread Yonghong Song
"link" has been an important concept for bpf ecosystem to connect bpf program with other properties. Currently, the information related information can be queried from userspace through bpf command BPF_LINK_GET_NEXT_ID, BPF_LINK_GET_FD_BY_ID and BPF_OBJ_GET_INFO_BY_FD. The information is also avail

[PATCH bpf-next v2 2/3] bpf: implement link_query callbacks in map element iterators

2020-08-20 Thread Yonghong Song
For bpf_map_elem and bpf_sk_local_storage bpf iterators, additional map_id should be shown for fdinfo and userspace query. For example, the following is for a bpf_map_elem iterator. $ cat /proc/1753/fdinfo/9 pos:0 flags: 0200 mnt_id: 14 link_type: iter link_id:34

Re: [PATCH net-next v2] Add Mellanox BlueField Gigabit Ethernet driver

2020-08-20 Thread David Miller
From: David Thompson Date: Thu, 20 Aug 2020 18:51:39 + > When I wrote the Kconfig definition I was thinking that "INET" is an > obvious functional dependency for an Ethernet driver. People can and should be able to use your driver even if ipv4/ipv6 is disabled, don't you think? > Yes, the m

Re: [PATCH ipsec-next v3] xfrm: add /proc/sys/core/net/xfrm_redact_secret

2020-08-20 Thread David Miller
From: Antony Antony Date: Thu, 20 Aug 2020 20:35:49 +0200 > Redacting secret is a FIPS 140-2 requirement. Why not control this via the kernel lockdown mode rather than making an ad-hoc API for this?

Re: [PATCH v5 bpf-next 07/12] bpf: tcp: Add bpf_skops_hdr_opt_len() and bpf_skops_write_hdr_opt()

2020-08-20 Thread Mat Martineau
On Thu, 20 Aug 2020, Martin KaFai Lau wrote: The bpf prog needs to parse the SYN header to learn what options have been sent by the peer's bpf-prog before writing its options into SYNACK. This patch adds a "syn_skb" arg to tcp_make_synack() and send_synack(). This syn_skb will eventually be ma

Re: [PATCH bpf-next 1/3] bpf: implement link_query for bpf iterators

2020-08-20 Thread Alexei Starovoitov
On Thu, Aug 20, 2020 at 09:15:30AM -0700, Yonghong Song wrote: > > > On 8/20/20 8:07 AM, Jakub Kicinski wrote: > > On Wed, 19 Aug 2020 17:13:23 -0700 Yonghong Song wrote: > > > + fill_link_info = iter_link->tinfo->reg_info->fill_link_info; > > > + if (fill_link_info) > > > + return fill_l

Re: BPF sk_lookup v5 - TCP SYN and UDP 0-len flood benchmarks

2020-08-20 Thread Alexei Starovoitov
On Thu, Aug 20, 2020 at 3:29 AM Jakub Sitnicki wrote: > > On Tue, Aug 18, 2020 at 08:19 PM CEST, Alexei Starovoitov wrote: > > On Tue, Aug 18, 2020 at 8:49 AM Jakub Sitnicki wrote: > >> : rcu_read_lock(); > >> : run_array = > >> rcu_der

Re: [RFC PATCH bpf-next 2/4] bpf: make BTF show support generic, apply to seq files/bpf_trace_printk

2020-08-20 Thread Alexei Starovoitov
On Tue, Aug 18, 2020 at 10:12:05AM +0100, Alan Maguire wrote: > > Fair enough. I'm thinking a helper like > > long bpf_btf_snprintf(char *str, u32 str_size, struct btf_ptr *ptr, > u32 ptr_size, u64 flags); > > Then the user can choose perf event or ringbuf interfaces > to sha

Re: [PATCH v6 bpf-next] bpf/selftests: fold test_current_pid_tgid_new_ns into test_progs.

2020-08-20 Thread Alexei Starovoitov
On Thu, Aug 20, 2020 at 7:27 AM Carlos Neira wrote: > > Currently tests for bpf_get_ns_current_pid_tgid() are outside test_progs. > This change folds both tests into test_progs. > > Changes from V5: > - Fold both tests into test_progs. > > Signed-off-by: Carlos Neira It doesn't apply. Pls rebas

[PATCH net, 2/2] hv_netvsc: Fix the queue_mapping in netvsc_vf_xmit()

2020-08-20 Thread Haiyang Zhang
netvsc_vf_xmit() / dev_queue_xmit() will call VF NIC’s ndo_select_queue or netdev_pick_tx() again. They will use skb_get_rx_queue() to get the queue number, so the “skb->queue_mapping - 1” will be used. This may cause the last queue of VF not been used. Use skb_record_rx_queue() here, so that the

  1   2   3   4   >