[PATCH net-next] net: bridge: mcast: fix unused br var when lockdep isn't defined

2020-09-08 Thread Nikolay Aleksandrov
Stephen reported the following warning: net/bridge/br_multicast.c: In function 'br_multicast_find_port': net/bridge/br_multicast.c:1818:21: warning: unused variable 'br' [-Wunused-variable] 1818 | struct net_bridge *br = mp->br; | ^~ It happens due to bridge's mloc

Re: [PATCH net-next 0/2] net: two updates related to UDP GSO

2020-09-08 Thread Willem de Bruijn
On Tue, Sep 8, 2020 at 4:32 AM tanhuazhong wrote: > > > > On 2020/9/7 23:35, Willem de Bruijn wrote: > > On Mon, Sep 7, 2020 at 3:38 PM tanhuazhong wrote: > >> > >> > >> > >> On 2020/9/7 17:22, Willem de Bruijn wrote: > >>> On Sun, Sep 6, 2020 at 8:42 PM Jakub Kicinski wrote: > > On Sa

WARNING: refcount bug in smc_release (3)

2020-09-08 Thread syzbot
Hello, syzbot found the following issue on: HEAD commit:15bc20c6 Merge tag 'tty-5.9-rc3' of git://git.kernel.org/p.. git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=114602f290 kernel config: https://syzkaller.appspot.com/x/.config?x=978db74cb30aa994 das

BUG: spinlock bad magic in lock_sock_nested

2020-09-08 Thread syzbot
Hello, syzbot found the following issue on: HEAD commit:0f091e43 netlabel: remove unused param from audit_log_form.. git tree: net-next console output: https://syzkaller.appspot.com/x/log.txt?x=1171cbb690 kernel config: https://syzkaller.appspot.com/x/.config?x=61025c6fd3261bb1 das

Re: [PATCH net-next v2 4/6] net: mvpp2: ptp: add TAI support

2020-09-08 Thread Russell King - ARM Linux admin
On Sun, Sep 06, 2020 at 09:04:02PM +0100, Russell King - ARM Linux admin wrote: > > > +static void mvpp22_tai_set_tod(struct mvpp2_tai *tai) > > > +{ > > > + struct timespec64 now; > > > + > > > + ktime_get_real_ts64(&now); > > > + mvpp22_tai_settime64(&tai->caps, &now); > > > +} > > > + > > > +sta

[PATCH v3] net: dsa: microchip: look for phy-mode in port nodes

2020-09-08 Thread Helmut Grohne
Documentation/devicetree/bindings/net/dsa/dsa.txt says that the phy-mode property should be specified on port nodes. However, the microchip drivers read it from the switch node. Let the driver use the per-port property and fall back to the old location with a warning. Fix in-tree users. Signed-o

Re: [24/30] mwifiex: wmm: Mark 'mwifiex_1d_to_wmm_queue' as __maybe_unused

2020-09-08 Thread Lee Jones
On Tue, 01 Sep 2020, Kalle Valo wrote: > Lee Jones wrote: > > > 'mwifiex_1d_to_wmm_queue' is used in'; main.c, txrx.c and uap_txrx.c > > > > ... but not used in 14 other source files which include 'wmm.h'. > > > > Fixes the following W=1 kernel build warning(s): > > > > In file included from

Re: [PATCH net-next v7 1/6] net: marvell: prestera: Add driver for Prestera family ASIC devices

2020-09-08 Thread Vadym Kochan
On Fri, Sep 04, 2020 at 10:12:07PM +0300, Andy Shevchenko wrote: > On Fri, Sep 4, 2020 at 7:52 PM Vadym Kochan wrote: > > > > Marvell Prestera 98DX326x integrates up to 24 ports of 1GbE with 8 > > ports of 10GbE uplinks or 2 ports of 40Gbps stacking for a largely > > wireless SMB deployment. > > >

Re: Question about dev_validate_header used in af_packet.c

2020-09-08 Thread Willem de Bruijn
On Mon, Sep 7, 2020 at 11:17 PM Xie He wrote: > > On Mon, Sep 7, 2020 at 2:06 AM Willem de Bruijn > wrote: > > > > The CAP_SYS_RAWIO exception indeed was requested to be able to > > purposely test devices against bad inputs. The gmane link > > unfortunately no longer works, but this was the discu

Re: [PATCH] net/sock: don't drop udp packets if udp_mem[2] not reached

2020-09-08 Thread Paolo Abeni
Hi, On Tue, 2020-09-08 at 11:15 +0800, dust.li wrote: > Actually, with more udp sockets, I can always make it large > enough to exceed udp_mem[0], and drop packets before udp_mem[1] > and udp_mem[2]. Sure, but with enough sockets you can also exceeeds any limits ;). > diff --git a/net/core/sock.

Re: [PATCH 00/32] Set 2: Rid W=1 warnings in Wireless

2020-09-08 Thread Lee Jones
On Tue, 01 Sep 2020, Kalle Valo wrote: > Lee Jones writes: > > > This set is part of a larger effort attempting to clean-up W=1 > > kernel builds, which are currently overwhelmingly riddled with > > niggly little warnings. > > > > There are quite a few W=1 warnings in the Wireless. My plan > >

Re: [PATCH 16/28] wireless: marvell: mwifiex: init: Move 'tos_to_tid_inv' to where it's used

2020-09-08 Thread Lee Jones
On Mon, 31 Aug 2020, Kalle Valo wrote: > Lee Jones wrote: > > > 'tos_to_tid_inv' is only used in 2 of 17 files it's current being > > included into. > > > > Fixes the following W=1 kernel build warning(s): > > > > In file included from drivers/net/wireless/marvell/mwifiex/main.c:23: > > In f

Re: [PATCH net] net/packet: Fix a comment about hard_header_len and headroom allocation

2020-09-08 Thread Willem de Bruijn
On Tue, Sep 8, 2020 at 2:07 AM Xie He wrote: > > Thank you for your comment! > > On Mon, Sep 7, 2020 at 2:41 AM Willem de Bruijn > wrote: > > > > On Sun, Sep 6, 2020 at 5:18 AM Xie He wrote: > > > > > > This comment is outdated and no longer reflects the actual implementation > > > of af_packet.

Re: [net-next 06/10] net/mlx5e: Support multiple SKBs in a TX WQE

2020-09-08 Thread Maxim Mikityanskiy
On 2020-09-04 01:46, Jakub Kicinski wrote: On Thu, 3 Sep 2020 14:00:18 -0700 Saeed Mahameed wrote: +static inline void mlx5e_tx_wi_consume_fifo_skbs(struct mlx5e_txqsq *sq, +struct mlx5e_tx_wqe_info *wi, +

Re: [net-next 09/10] net/mlx5e: Move TX code into functions to be used by MPWQE

2020-09-08 Thread Maxim Mikityanskiy
On 2020-09-04 18:06, Willem de Bruijn wrote: On Thu, Sep 3, 2020 at 11:01 PM Saeed Mahameed wrote: From: Maxim Mikityanskiy mlx5e_txwqe_complete performs some actions that can be taken to separate functions: 1. Update the flags needed for hardware timestamping. 2. Stop the TX queue if it's

Re: [net-next 04/10] net/mlx5e: Unify constants for WQE_EMPTY_DS_COUNT

2020-09-08 Thread Maxim Mikityanskiy
On 2020-09-04 18:05, Willem de Bruijn wrote: On Thu, Sep 3, 2020 at 11:01 PM Saeed Mahameed wrote: From: Maxim Mikityanskiy A constant for the number of DS in an empty WQE (i.e. a WQE without data segments) is needed in multiple places (normal TX data path, MPWQE in XDP), but currently we ha

Re: [net-next 02/10] net/mlx5e: Refactor xmit functions

2020-09-08 Thread Maxim Mikityanskiy
On 2020-09-04 18:27, Willem de Bruijn wrote: On Thu, Sep 3, 2020 at 11:00 PM Saeed Mahameed wrote: From: Maxim Mikityanskiy A huge function mlx5e_sq_xmit was split into several to achieve multiple goals: 1. Reuse the code in IPoIB. 2. Better intergrate with TLS, IPSEC, GENEVE and checksum

Re: [net-next 09/10] net/mlx5e: Move TX code into functions to be used by MPWQE

2020-09-08 Thread Willem de Bruijn
On Tue, Sep 8, 2020 at 11:00 AM Maxim Mikityanskiy wrote: > > On 2020-09-04 18:06, Willem de Bruijn wrote: > > On Thu, Sep 3, 2020 at 11:01 PM Saeed Mahameed wrote: > >> > >> From: Maxim Mikityanskiy > >> > >> mlx5e_txwqe_complete performs some actions that can be taken to separate > >> function

Re: [net-next 04/10] net/mlx5e: Unify constants for WQE_EMPTY_DS_COUNT

2020-09-08 Thread Willem de Bruijn
On Tue, Sep 8, 2020 at 10:59 AM Maxim Mikityanskiy wrote: > > On 2020-09-04 18:05, Willem de Bruijn wrote: > > On Thu, Sep 3, 2020 at 11:01 PM Saeed Mahameed wrote: > >> > >> From: Maxim Mikityanskiy > >> > >> A constant for the number of DS in an empty WQE (i.e. a WQE without data > >> segments

Re: [net-next 02/10] net/mlx5e: Refactor xmit functions

2020-09-08 Thread Willem de Bruijn
On Tue, Sep 8, 2020 at 10:59 AM Maxim Mikityanskiy wrote: > > On 2020-09-04 18:27, Willem de Bruijn wrote: > > On Thu, Sep 3, 2020 at 11:00 PM Saeed Mahameed wrote: > >> > >> From: Maxim Mikityanskiy > >> > >> A huge function mlx5e_sq_xmit was split into several to achieve multiple > >> goals: >

[RFC PATCH net-next 00/22] nexthop: Add support for nexthop objects offload

2020-09-08 Thread Ido Schimmel
From: Ido Schimmel Note: I'm aware that 22 patches is a lot and I will split it for the non-RFC submission. Sending all in one piece to see if there are general comments regarding the interface. Also, most of the patches are very small. This patch set adds support for nexthop objects offload wit

[RFC PATCH net-next 01/22] nexthop: Remove unused function declaration from header file

2020-09-08 Thread Ido Schimmel
From: Ido Schimmel Not used or implemented anywhere. Signed-off-by: Ido Schimmel --- include/net/nexthop.h | 3 --- 1 file changed, 3 deletions(-) diff --git a/include/net/nexthop.h b/include/net/nexthop.h index 3a4f9e3b91a5..2e44efe5709b 100644 --- a/include/net/nexthop.h +++ b/include/net/n

[RFC PATCH net-next 02/22] nexthop: Convert to blocking notification chain

2020-09-08 Thread Ido Schimmel
From: Ido Schimmel Currently, the only listener of the nexthop notification chain is the VXLAN driver. Subsequent patches will add more listeners (e.g., device drivers such as netdevsim) that need to be able to block when processing notifications. Therefore, convert the notification chain to a b

[RFC PATCH net-next 06/22] nexthop: Pass extack to nexthop notifier

2020-09-08 Thread Ido Schimmel
From: Ido Schimmel The next patch will add extack to the notification info. This allows listeners to veto notifications and communicate the reason to user space. Signed-off-by: Ido Schimmel --- net/ipv4/nexthop.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/net/ipv4

[RFC PATCH net-next 18/22] nexthop: Remove in-kernel route notifications when nexthop changes

2020-09-08 Thread Ido Schimmel
From: Ido Schimmel Remove in-kernel route notifications when the configuration of their nexthop changes. These notifications are unnecessary because the route still uses the same nexthop ID. A separate notification for the nexthop change itself is now sent in the nexthop notification chain. Sig

[RFC PATCH net-next 03/22] nexthop: Only emit a notification when nexthop is actually deleted

2020-09-08 Thread Ido Schimmel
From: Ido Schimmel Currently, the delete notification is emitted from the error path of nexthop_add() and replace_nexthop(), which can be confusing to listeners as they are not familiar with the nexthop. Instead, only emit the notification when the nexthop is actually deleted. The following sub-

[RFC PATCH net-next 04/22] selftests: fib_nexthops: Test cleanup of FDB entries following nexthop deletion

2020-09-08 Thread Ido Schimmel
From: Ido Schimmel Commit c7cdbe2efc40 ("vxlan: support for nexthop notifiers") registered a listener in the VXLAN driver to the nexthop notification chain. Its purpose is to cleanup FDB entries that use a nexthop that is being deleted. Test that such FDB entries are removed when the nexthop gro

[RFC PATCH net-next 17/22] nexthop: Replay nexthops when registering a notifier

2020-09-08 Thread Ido Schimmel
From: Ido Schimmel When registering a new notifier to the nexthop notification chain, replay all the existing nexthops to the new notifier so that it will have a complete picture of the available nexthops. Signed-off-by: Ido Schimmel --- net/ipv4/nexthop.c | 54

[RFC PATCH net-next 15/22] nexthop: Emit a notification when a nexthop group is reduced

2020-09-08 Thread Ido Schimmel
From: Ido Schimmel When a single nexthop is deleted, the configuration of all the groups using the nexthop is effectively modified. In this case, emit a notification in the nexthop notification chain for each modified group so that listeners would not need to keep track of which nexthops are memb

[RFC PATCH net-next 16/22] nexthop: Pass extack to register_nexthop_notifier()

2020-09-08 Thread Ido Schimmel
From: Ido Schimmel This will be used by the next patch which extends the function to replay all the existing nexthops to the notifier block being registered. Device drivers will be able to pass extack to the function since it is passed to them upon reload from devlink. Signed-off-by: Ido Schimm

[RFC PATCH net-next 21/22] netdevsim: Allow programming routes with nexthop objects

2020-09-08 Thread Ido Schimmel
From: Ido Schimmel Previous patches added the ability to program nexthop objects. Therefore, no longer forbid the programming of routes that point to such objects. Signed-off-by: Ido Schimmel --- drivers/net/netdevsim/fib.c | 10 -- 1 file changed, 10 deletions(-) diff --git a/drivers

[RFC PATCH net-next 14/22] nexthop: Emit a notification when a nexthop group is modified

2020-09-08 Thread Ido Schimmel
From: Ido Schimmel When a single nexthop is replaced, the configuration of all the groups using the nexthop is effectively modified. In this case, emit a notification in the nexthop notification chain for each modified group so that listeners would not need to keep track of which nexthops are mem

[RFC PATCH net-next 09/22] rtnetlink: Add RTNH_F_TRAP flag

2020-09-08 Thread Ido Schimmel
From: Ido Schimmel The flag indicates to user space that the nexthop is not programmed to forward packets in hardware, but rather to trap them. The flag will be used in subsequent patches by netdevsim to test nexthop objects programming to device drivers and in the future by mlxsw as well. Sign

[RFC PATCH net-next 19/22] netdevsim: Add devlink resource for nexthops

2020-09-08 Thread Ido Schimmel
From: Ido Schimmel The Spectrum ASIC has a dedicated table where nexthops (i.e., adjacency entries) are populated. The size of this table can be controlled via devlink-resource. Add such a resource to netdevsim so that its occupancy will reflect the number of nexthop objects currently programmed

[RFC PATCH net-next 22/22] selftests: netdevsim: Add test for nexthop offload API

2020-09-08 Thread Ido Schimmel
From: Ido Schimmel Test various aspects of the nexthop offload API on top of the netdevsim implementation. Both good and bad flows are tested. Signed-off-by: Ido Schimmel --- .../drivers/net/netdevsim/nexthop.sh | 408 ++ 1 file changed, 408 insertions(+) create mode

[RFC PATCH net-next 07/22] nexthop: Prepare new notification info

2020-09-08 Thread Ido Schimmel
From: Ido Schimmel Prepare the new notification information so that it could be passed to listeners in the new patch. Signed-off-by: Ido Schimmel --- net/ipv4/nexthop.c | 108 + 1 file changed, 108 insertions(+) diff --git a/net/ipv4/nexthop.c b/net

[RFC PATCH net-next 13/22] nexthop: Emit a notification when a single nexthop is replaced

2020-09-08 Thread Ido Schimmel
From: Ido Schimmel The notification is emitted after all the validation checks were performed, but before the new configuration (i.e., 'struct nh_info') is pointed at by the old shell (i.e., 'struct nexthop'). This prevents the need to perform rollback in case the notification is vetoed. The nex

[RFC PATCH net-next 20/22] netdevsim: Add dummy implementation for nexthop offload

2020-09-08 Thread Ido Schimmel
From: Ido Schimmel Implement dummy nexthop "offload" in the driver by storing currently "programmed" nexthops in a hash table. Each nexthop in the hash table is marked with "trap" indication and increments the nexthops resource occupancy. This will later allow us to test the nexthop offload API

[RFC PATCH net-next 10/22] nexthop: Allow setting "offload" and "trap" indications on nexthops

2020-09-08 Thread Ido Schimmel
From: Ido Schimmel Add a function that can be called by device drivers to set "offload" or "trap" indication on nexthops following nexthop notifications. Signed-off-by: Ido Schimmel --- include/net/nexthop.h | 1 + net/ipv4/nexthop.c| 21 + 2 files changed, 22 insertio

[RFC PATCH net-next 11/22] nexthop: Emit a notification when a nexthop is added

2020-09-08 Thread Ido Schimmel
From: Ido Schimmel Emit a notification in the nexthop notification chain when a new nexthop is added (not replaced). The nexthop can either be a new group or a single nexthop. The notification is sent after the nexthop is inserted into the red-black tree, as listeners might need to callback into

[RFC PATCH net-next 12/22] nexthop: Emit a notification when a nexthop group is replaced

2020-09-08 Thread Ido Schimmel
From: Ido Schimmel Emit a notification in the nexthop notification chain when an existing nexthop group is replaced. The notification is emitted after all the validation checks were performed, but before the new configuration (i.e., 'struct nh_grp') is pointed at by the old shell (i.e., 'struct

[RFC PATCH net-next 05/22] nexthop: Add nexthop notification data structures

2020-09-08 Thread Ido Schimmel
From: Ido Schimmel Add data structures that will be used for nexthop replace and delete notifications in the previously introduced nexthop notification chain. New data structures are added instead of passing the existing nexthop code structures directly for several reasons. First, the existing

[RFC PATCH net-next 08/22] nexthop: vxlan: Convert to new notification info

2020-09-08 Thread Ido Schimmel
From: Ido Schimmel Convert the sole listener of the nexthop notification chain (the VXLAN driver) to the new notification info. Signed-off-by: Ido Schimmel --- drivers/net/vxlan.c | 9 +++-- net/ipv4/nexthop.c | 2 +- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/drivers/

Re: [PATCH net-next v7 1/6] net: marvell: prestera: Add driver for Prestera family ASIC devices

2020-09-08 Thread Andy Shevchenko
On Tue, Sep 8, 2020 at 11:35 AM Vadym Kochan wrote: > On Fri, Sep 04, 2020 at 10:12:07PM +0300, Andy Shevchenko wrote: > > On Fri, Sep 4, 2020 at 7:52 PM Vadym Kochan > > wrote: ... > > > + words[3] |= FIELD_PREP(PRESTERA_W3_HW_DEV_NUM, (dsa->hw_dev_num > > > >> 5)); > > > > Ditto. > >

Re: [PATCH bpf-next 4/4] ixgbe, xsk: use XSK_NAPI_WEIGHT as NAPI poll budget

2020-09-08 Thread Eric Dumazet
On 9/7/20 5:02 PM, Björn Töpel wrote: > From: Björn Töpel > > Start using XSK_NAPI_WEIGHT as NAPI poll budget for the AF_XDP Rx > zero-copy path. > > Signed-off-by: Björn Töpel > --- > drivers/net/ethernet/intel/ixgbe/ixgbe_xsk.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > >

Re: [PATCH nf] netfilter: ctnetlink: fix mark based dump filtering regression

2020-09-08 Thread Pablo Neira Ayuso
On Tue, Sep 01, 2020 at 08:56:19AM +0200, Martin Willi wrote: > conntrack mark based dump filtering may falsely skip entries if a mask > is given: If the mask-based check does not filter out the entry, the > else-if check is always true and compares the mark without considering > the mask. The if/e

Re: [Intel-wired-lan] [PATCH bpf-next 4/4] ixgbe, xsk: use XSK_NAPI_WEIGHT as NAPI poll budget

2020-09-08 Thread Paul Menzel
Dear Björn, Am 07.09.20 um 17:02 schrieb Björn Töpel: From: Björn Töpel Start using XSK_NAPI_WEIGHT as NAPI poll budget for the AF_XDP Rx zero-copy path. Could you please add the description from the patch series cover letter to this commit too? To my knowledge, the message in the cover le

Re: [PATCH net-next 4/4] net: dsa: set configure_vlan_while_not_filtering to true by default

2020-09-08 Thread Kurt Kanzenbach
On Mon Sep 07 2020, Vladimir Oltean wrote: > From: Vladimir Oltean > > As explained in commit 54a0ed0df496 ("net: dsa: provide an option for > drivers to always receive bridge VLANs"), DSA has historically been > skipping VLAN switchdev operations when the bridge wasn't in > vlan_filtering mode, b

Re: [PATCH net-net] netfilter: conntrack: nf_conncount_init is failing with IPv6 disabled

2020-09-08 Thread Pablo Neira Ayuso
On Tue, Sep 01, 2020 at 04:56:02PM +0200, Eelco Chaudron wrote: > The openvswitch module fails initialization when used in a kernel > without IPv6 enabled. nf_conncount_init() fails because the ct code > unconditionally tries to initialize the netns IPv6 related bit, > regardless of the build optio

Re: [PATCH net-next 4/4] net: dsa: set configure_vlan_while_not_filtering to true by default

2020-09-08 Thread Vladimir Oltean
On Tue, Sep 08, 2020 at 12:14:12PM +0200, Kurt Kanzenbach wrote: > On Mon Sep 07 2020, Vladimir Oltean wrote: > > New drivers always seem to omit setting this flag, for some reason. > > Yes, because it's not well documented, or is it? Before writing the > hellcreek DSA driver, I've read dsa.rst doc

Re: [PATCH 1/1 net-next] selftests/net: replace obsolete NFT_CHAIN configuration

2020-09-08 Thread Pablo Neira Ayuso
On Mon, Sep 07, 2020 at 06:14:28PM +0200, Fabian Frederick wrote: > Replace old parameters with global NFT_NAT from commit db8ab38880e0 > ("netfilter: nf_tables: merge ipv4 and ipv6 nat chain types") Applied. Please, Cc: netfilter-de...@vger.kernel.org next time. Thanks.

Re: [PATCH bpf-next 0/6] xsk: exit NAPI loop when AF_XDP Rx ring is full

2020-09-08 Thread Maxim Mikityanskiy
On 2020-09-04 16:59, Björn Töpel wrote: On 2020-09-04 15:53, Björn Töpel wrote: This series addresses a problem that arises when AF_XDP zero-copy is enabled, and the kernel softirq Rx processing and userland process is running on the same core. [...] @Maxim I'm not well versed in Mellanox

Re: [PATCH net-next 4/4] net: dsa: set configure_vlan_while_not_filtering to true by default

2020-09-08 Thread Vladimir Oltean
On Mon, Sep 07, 2020 at 09:07:34PM -0700, Florian Fainelli wrote: > You should be able to make b53 and bcm_sf2 also use > configure_vlan_while_not_filtering to true (or rather not specify it), give > me until tomorrow to run various tests if you don't mind. Ok, but I would prefer not doing that in

Re: [PATCH ethtool,v2] ethtool: add support show/set-time-stamping

2020-09-08 Thread Michal Kubecek
On Tue, Sep 08, 2020 at 07:35:58AM +0200, Eric Dumazet wrote: > On Mon, Sep 7, 2020 at 11:25 PM Michal Kubecek wrote: > > On Mon, Sep 07, 2020 at 06:56:20PM +0200, Eric Dumazet wrote: > > > On Mon, Sep 7, 2020 at 2:53 PM Michal Kubecek wrote: > > > > > > > > As I said in response to v1 patch, I d

Re: [PATCH v20 17/23] LSM: security_secid_to_secctx in netlink netfilter

2020-09-08 Thread Pablo Neira Ayuso
On Wed, Aug 26, 2020 at 07:52:41AM -0700, Casey Schaufler wrote: > Change netlink netfilter interfaces to use lsmcontext > pointers, and remove scaffolding. > > Reviewed-by: Kees Cook > Reviewed-by: John Johansen > Acked-by: Stephen Smalley > Signed-off-by: Casey Schaufler > cc: netdev@vger.ke

Re: [PATCH net-next] netfilter: ebt_stp: Remove unused macro BPDU_TYPE_TCN

2020-09-08 Thread Pablo Neira Ayuso
On Fri, Sep 04, 2020 at 08:56:53PM +0800, Wang Hai wrote: > BPDU_TYPE_TCN is never used after it was introduced. > So better to remove it. Applied, thanks.

Re: Question about dev_validate_header used in af_packet.c

2020-09-08 Thread Xie He
On Tue, Sep 8, 2020 at 1:41 AM Willem de Bruijn wrote: > > The intent is to bypass such validation to be able to test device > drivers. Note that removing that may cause someone's test to start > failing. > > > So there's no point in > > keeping the ability to test this, either. > > I don't disag

[PATCH v2 net] net: sch_generic: aviod concurrent reset and enqueue op for lockless qdisc

2020-09-08 Thread Yunsheng Lin
Currently there is concurrent reset and enqueue operation for the same lockless qdisc when there is no lock to synchronize the q->enqueue() in __dev_xmit_skb() with the qdisc reset operation in qdisc_deactivate() called by dev_deactivate_queue(), which may cause out-of-bounds access for priv->ring[

Re: [PATCH] brcmsmac: fix memory leak in wlc_phy_attach_lcnphy

2020-09-08 Thread Arend Van Spriel
On 9/8/2020 2:13 AM, Keita Suzuki wrote: When wlc_phy_txpwr_srom_read_lcnphy fails in wlc_phy_attach_lcnphy, the allocated pi->u.pi_lcnphy is leaked, since struct brcms_phy will be freed in the caller function. Fix this by calling wlc_phy_detach_lcnphy in the error handler of wlc_phy_txpwr_srom_

Re: [Intel-wired-lan] [PATCH bpf-next 4/4] ixgbe, xsk: use XSK_NAPI_WEIGHT as NAPI poll budget

2020-09-08 Thread Paul Menzel
Dear Björn, Am 08.09.20 um 13:12 schrieb Björn Töpel: On 2020-09-08 12:12, Paul Menzel wrote: Am 07.09.20 um 17:02 schrieb Björn Töpel: From: Björn Töpel Start using XSK_NAPI_WEIGHT as NAPI poll budget for the AF_XDP Rx zero-copy path. Could you please add the description from the patch

[PATCH] net: phy: call phy_disable_interrupts() in phy_attach_direct() instead

2020-09-08 Thread Yoshihiro Shimoda
Since the micrel phy driver calls phy_init_hw() as a workaround, the commit 9886a4dbd2aa ("net: phy: call phy_disable_interrupts() in phy_init_hw()") disables the interrupt unexpectedly. So, call phy_disable_interrupts() in phy_attach_direct() instead. Otherwise, the phy cannot link up after the et

Re: [PATCH bpf-next 0/6] xsk: exit NAPI loop when AF_XDP Rx ring is full

2020-09-08 Thread Magnus Karlsson
On Tue, Sep 8, 2020 at 12:33 PM Maxim Mikityanskiy wrote: > > On 2020-09-04 16:59, Björn Töpel wrote: > > On 2020-09-04 15:53, Björn Töpel wrote: > >> This series addresses a problem that arises when AF_XDP zero-copy is > >> enabled, and the kernel softirq Rx processing and userland process > >> i

Re: Question about dev_validate_header used in af_packet.c

2020-09-08 Thread Willem de Bruijn
On Tue, Sep 8, 2020 at 1:04 PM Xie He wrote: > > On Tue, Sep 8, 2020 at 1:41 AM Willem de Bruijn > wrote: > > > > The intent is to bypass such validation to be able to test device > > drivers. Note that removing that may cause someone's test to start > > failing. > > > > > So there's no point in

Re: [PATCH nf-next v3 3/3] netfilter: Introduce egress hook

2020-09-08 Thread Arturo Borrero Gonzalez
On 2020-09-04 23:14, Daniel Borkmann wrote: > root@x:~/x# clang -target bpf -Wall -O2 -c foo.c -o foo.o In my honest opinion (debian hat), the simplification of the stack is a key point for end users/developers. A gain in usability might justify a small performance penalty. I can think on both sy

Re: [Intel-wired-lan] [PATCH bpf-next 4/4] ixgbe, xsk: use XSK_NAPI_WEIGHT as NAPI poll budget

2020-09-08 Thread Björn Töpel
On 2020-09-08 13:20, Paul Menzel wrote: [...]>> Paul, thanks for the input! The netdev/bpf trees always include the cover letter in the merge commit. Yes, for pull/merge requests. But you posted them to the list, so I’d assume they will be applied with `git am` and not merged, or am I missing

Re: [PATCH bpf-next 4/4] ixgbe, xsk: use XSK_NAPI_WEIGHT as NAPI poll budget

2020-09-08 Thread Björn Töpel
On 2020-09-08 11:45, Eric Dumazet wrote: On 9/7/20 5:02 PM, Björn Töpel wrote: From: Björn Töpel Start using XSK_NAPI_WEIGHT as NAPI poll budget for the AF_XDP Rx zero-copy path. Signed-off-by: Björn Töpel --- drivers/net/ethernet/intel/ixgbe/ixgbe_xsk.c | 2 +- 1 file changed, 1 insert

Re: [PATCH net] net/packet: Fix a comment about hard_header_len and headroom allocation

2020-09-08 Thread Xie He
On Tue, Sep 8, 2020 at 1:56 AM Willem de Bruijn wrote: > > > > > /* > > > > Assumptions: > > > > - - if device has no dev->hard_header routine, it adds and removes ll > > > > header > > > > - inside itself. In this case ll header is invisible outside of > > > > device, > > > > - b

Re: [PATCH net-next v2 1/7] net: dsa: Add helper to convert from devlink to ds

2020-09-08 Thread Marek Behún
On Tue, 8 Sep 2020 02:51:49 +0200 Andrew Lunn wrote: > +struct dsa_switch *dsa_devlink_to_ds(struct devlink *dl) > +{ > + struct dsa_devlink_priv *dl_priv = devlink_priv(dl); > + > + return dl_priv->ds; > +} > +EXPORT_SYMBOL_GPL(dsa_devlink_to_ds); Hi Andrew, why not make this a static

[PATCH v2 0/5] SMSC: Cleanups and clock setup

2020-09-08 Thread Marco Felsch
Hi, this small series cleans the smsc-phy code a bit and adds the support to specify the phy clock source. Adding the phy clock source support is also the main purpose of this series. Each file has its own changelog. Regards, Marco Marco Felsch (5): net: phy: smsc: skip ENERGYON interrupt i

[PATCH v2 1/5] net: phy: smsc: skip ENERGYON interrupt if disabled

2020-09-08 Thread Marco Felsch
Don't enable the interrupt if the platform disable the energy detection by "smsc,disable-energy-detect". Signed-off-by: Marco Felsch Reviewed-by: Andrew Lunn --- v2: - Add Andrew's tag drivers/net/phy/smsc.c | 15 +++ 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/d

[PATCH v2 5/5] net: phy: smsc: LAN8710/20: remove PHY_RST_AFTER_CLK_EN flag

2020-09-08 Thread Marco Felsch
Don't reset the phy without respect to the phy-state-machine because this breaks the phy IRQ mode. We can archive the same behaviour if the refclk in is specified. Signed-off-by: Marco Felsch --- v2: - adapt the subject to align with previous patch drivers/net/phy/smsc.c | 1 - 1 file changed,

[PATCH v2 3/5] dt-bindings: net: phy: smsc: document reference clock

2020-09-08 Thread Marco Felsch
Add support to specify the reference clock for the phy. Signed-off-by: Marco Felsch --- v2: - no change Documentation/devicetree/bindings/net/smsc-lan87xx.txt | 4 1 file changed, 4 insertions(+) diff --git a/Documentation/devicetree/bindings/net/smsc-lan87xx.txt b/Documentation/devicetr

[PATCH v2 4/5] net: phy: smsc: LAN8710/20: add phy refclk in support

2020-09-08 Thread Marco Felsch
Add support to specify the clock provider for the phy refclk and don't rely on 'magic' host clock setup. Commit [1] tried to address this by introducing a flag and fixing the corresponding host. But this commit breaks the IRQ support since the irq setup during .config_intr() is thrown away because

[PATCH v2 2/5] net: phy: smsc: simplify config_init callback

2020-09-08 Thread Marco Felsch
Exit the driver specific config_init hook early if energy detection is disabled. We can do this because we don't need to clear the interrupt status here. Clearing the status should be removed anyway since this is handled by the phy_enable_interrupts(). Signed-off-by: Marco Felsch --- v2: - no cha

Re: [Intel-wired-lan] [PATCH bpf-next 4/4] ixgbe, xsk: use XSK_NAPI_WEIGHT as NAPI poll budget

2020-09-08 Thread Björn Töpel
On 2020-09-08 12:12, Paul Menzel wrote: Dear Björn, Am 07.09.20 um 17:02 schrieb Björn Töpel: From: Björn Töpel Start using XSK_NAPI_WEIGHT as NAPI poll budget for the AF_XDP Rx zero-copy path. Could you please add the description from the patch series cover letter to this commit too? To

Re: [PATCH RFC 5/7] bridge: cfm: Netlink Interface.

2020-09-08 Thread Nikolay Aleksandrov
On Fri, 2020-09-04 at 09:15 +, Henrik Bjoernlund wrote: > This is the implementation of CFM netlink configuration > and status information interface. > > Add new nested netlink attributes. These attributes are used by the > user space to create/delete/configure CFM instances and get status. >

Re: [PATCH] vdpa/mlx5: Setup driver only if VIRTIO_CONFIG_S_DRIVER_OK

2020-09-08 Thread Michael S. Tsirkin
On Mon, Sep 07, 2020 at 02:43:51PM +0300, Eli Cohen wrote: > On Mon, Sep 07, 2020 at 07:34:00AM -0400, Michael S. Tsirkin wrote: > > On Mon, Sep 07, 2020 at 10:51:36AM +0300, Eli Cohen wrote: > > > If the memory map changes before the driver status is > > > VIRTIO_CONFIG_S_DRIVER_OK, don't attempt

Re: [PATCH 1/2] vhost: remove mutex ops in vhost_set_backend_features

2020-09-08 Thread Michael S. Tsirkin
On Mon, Sep 07, 2020 at 06:52:19PM +0800, Zhu Lingshan wrote: > In vhost_vdpa ioctl SET_BACKEND_FEATURES path, currect code > would try to acquire vhost dev mutex twice > (first shown in vhost_vdpa_unlocked_ioctl), which can lead > to a dead lock issue. > This commit removed mutex operations in vho

INFO: rcu detected stall in security_file_free (2)

2020-09-08 Thread syzbot
Hello, syzbot found the following issue on: HEAD commit:e6135df4 Merge branch 'hashmap_iter_bucket_lock_fix' git tree: bpf console output: https://syzkaller.appspot.com/x/log.txt?x=10e3dbf590 kernel config: https://syzkaller.appspot.com/x/.config?x=a0437fdd630bee11 dashboard link:

Re: [PATCH RFC 6/7] bridge: cfm: Netlink Notifications.

2020-09-08 Thread Nikolay Aleksandrov
On Fri, 2020-09-04 at 09:15 +, Henrik Bjoernlund wrote: > This is the implementation of Netlink notifications out of CFM. > > Notifications are initiated whenever a state change happens in CFM. > [snip] > @@ -445,6 +458,7 @@ static int br_cfm_frame_rx(struct net_bridge_port *port, > struct s

Re: [PATCH net-next v2 4/6] net: mvpp2: ptp: add TAI support

2020-09-08 Thread Richard Cochran
On Tue, Sep 08, 2020 at 08:41:58AM +0100, Russell King - ARM Linux admin wrote: > > Should we always set the TAI counter to zero every time the TAI is > initialised, or just leave it as is (the counter may already be set > by a previous kernel, for example when a kexec has happened). I think if t

[PATCH net-next] bnx2x: Fix some kernel-doc warnings

2020-09-08 Thread Wang Hai
Fixes the following W=1 kernel build warning(s): drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c:4238: warning: Excess function parameter 'netdev' description in 'bnx2x_setup_tc' drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c:4238: warning: Excess function parameter 'tc' description in 'bnx2x_s

[PATCH net-next v2 4/6] devlink: Introduce external controller flag

2020-09-08 Thread Parav Pandit
From: Parav Pandit A devlink eswitch port may represent PCI PF/VF ports of a controller. A controller either located on same system or it can be an external controller located in host where such NIC is plugged in. Add the ability for driver to specify if a port is for external controller. Use

[PATCH net-next v2 6/6] devlink: Use controller while building phys_port_name

2020-09-08 Thread Parav Pandit
From: Parav Pandit Now that controller number attribute is available, use it when building phsy_port_name for external controller ports. An example devlink port and representor netdev name consist of controller annotation for external controller with controller number = 1, for a VF 1 of PF 0: $

RE: [PATCH RFC 0/7] net: bridge: cfm: Add support for Connectivity Fault Management(CFM)

2020-09-08 Thread Henrik.Bjoernlund
Hi Nik, Thanks a lot for reviewing. -Original Message- From: Nikolay Aleksandrov Sent: 7. september 2020 15:56 To: step...@networkplumber.org; Horatiu Vultur - M31836 Cc: bri...@lists.linux-foundation.org; Henrik Bjoernlund - M31679 ; da...@davemloft.net; linux-ker...@vger.kernel.or

[PATCH net-next v2 3/6] devlink: Move structure comments outside of structure

2020-09-08 Thread Parav Pandit
From: Parav Pandit To add more fields to the PCI PF and VF port attributes, follow standard structure comment format. Signed-off-by: Parav Pandit Reviewed-by: Jiri Pirko --- Changelog: v2->v3: - New patch --- include/net/devlink.h | 15 --- 1 file changed, 12 insertions(+), 3 del

[PATCH net-next v2 5/6] devlink: Introduce controller number

2020-09-08 Thread Parav Pandit
From: Parav Pandit A devlink port may be for a controller consist of PCI device. A devlink instance holds ports of two types of controllers. (1) controller discovered on same system where eswitch resides This is the case where PCI PF/VF of a controller and devlink eswitch instance both are locate

[PATCH 5/5] netfilter: nft_meta: use socket user_ns to retrieve skuid and skgid

2020-09-08 Thread Pablo Neira Ayuso
... instead of using init_user_ns. Fixes: 96518518cc41 ("netfilter: add nftables") Tested-by: Phil Sutter Signed-off-by: Pablo Neira Ayuso --- net/netfilter/nft_meta.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/net/netfilter/nft_meta.c b/net/netfilter/nft_meta.c ind

Re: [RFC PATCH net-next 02/22] nexthop: Convert to blocking notification chain

2020-09-08 Thread David Ahern
On 9/8/20 3:10 AM, Ido Schimmel wrote: > From: Ido Schimmel > > Currently, the only listener of the nexthop notification chain is the > VXLAN driver. Subsequent patches will add more listeners (e.g., device > drivers such as netdevsim) that need to be able to block when processing > notifications

Re: [RFC PATCH net-next 14/22] nexthop: Emit a notification when a nexthop group is modified

2020-09-08 Thread David Ahern
On 9/8/20 3:10 AM, Ido Schimmel wrote: > From: Ido Schimmel > > When a single nexthop is replaced, the configuration of all the groups > using the nexthop is effectively modified. In this case, emit a > notification in the nexthop notification chain for each modified group > so that listeners wou

Re: [PATCH RFC 0/7] net: bridge: cfm: Add support for Connectivity Fault Management(CFM)

2020-09-08 Thread Allan W. Nielsen
Hi, On 08.09.2020 11:04, Henrik Bjoernlund - M31679 wrote: On Sun, 2020-09-06 at 20:21 +0200, Horatiu Vultur wrote: The 09/04/2020 15:44, Stephen Hemminger wrote: > On Fri, 4 Sep 2020 09:15:20 + Henrik Bjoernlund > wrote: Hi, I also had the same initial thought - this really doesn't seem

Re: [PATCH] brcmsmac: fix memory leak in wlc_phy_attach_lcnphy

2020-09-08 Thread Keita Suzuki
Thank you for your comment. I am relatively new to the Linux kernel community, so I am more than happy to receive comments. Please let me know if I'm violating any other rules. > > Signed-off-by: Keita Suzuki > > --- > ... changelog here describing difference between previous patch and this > ver

Re: [PATCH 16/28] wireless: marvell: mwifiex: init: Move 'tos_to_tid_inv' to where it's used

2020-09-08 Thread Lee Jones
On Tue, 08 Sep 2020, Kalle Valo wrote: > Lee Jones writes: > > > On Mon, 31 Aug 2020, Kalle Valo wrote: > > > >> Lee Jones wrote: > >> > >> > 'tos_to_tid_inv' is only used in 2 of 17 files it's current being > >> > included into. > >> > > >> > Fixes the following W=1 kernel build warning(s):

[RFT net] net: ipa: fix u32_replace_bits by u32p_xxx version

2020-09-08 Thread Vadym Kochan
Looks like u32p_replace_bits() should be used instead of u32_replace_bits() which does not modifies the value but returns the modified version. Fixes: 2b9feef2b6c2 ("soc: qcom: ipa: filter and routing tables") Signed-off-by: Vadym Kochan --- Found it while grepping of u32_replace_bits() usage and

Re: [PATCH net-next] net: bridge: mcast: fix unused br var when lockdep isn't defined

2020-09-08 Thread Jakub Kicinski
On Tue, 8 Sep 2020 10:17:13 +0300 Nikolay Aleksandrov wrote: > Stephen reported the following warning: > net/bridge/br_multicast.c: In function 'br_multicast_find_port': > net/bridge/br_multicast.c:1818:21: warning: unused variable 'br' > [-Wunused-variable] > 1818 | struct net_bridge *br =

Re: [PATCH bpf] bpf: Fix clobbering of r2 in bpf_gen_ld_abs

2020-09-08 Thread Alexei Starovoitov
On Mon, Sep 7, 2020 at 3:04 PM Daniel Borkmann wrote: > > Bryce reported that he saw the following with: > > 0: r6 = r1 > 1: r1 = 12 > 2: r0 = *(u16 *)skb[r1] > > The xlated sequence was incorrectly clobbering r2 with pointer > value of r6 ... > > 0: (bf) r6 = r1 > 1: (b7) r1 = 12 >

Re: [PATCH nf-next v3 3/3] netfilter: Introduce egress hook

2020-09-08 Thread Daniel Borkmann
On 9/8/20 1:46 PM, Arturo Borrero Gonzalez wrote: On 2020-09-04 23:14, Daniel Borkmann wrote: root@x:~/x# clang -target bpf -Wall -O2 -c foo.c -o foo.o In my honest opinion (debian hat), the simplification of the stack is a key point for end users/developers. A gain in usability might justify

Re: Question about dev_validate_header used in af_packet.c

2020-09-08 Thread Xie He
On Tue, Sep 8, 2020 at 4:53 AM Willem de Bruijn wrote: > > On Tue, Sep 8, 2020 at 1:04 PM Xie He wrote: > > > > I was recently looking at some drivers, and I felt that if af_packet.c > > could help me filter out the invalid RAW frames, I didn't need to > > check the validity of the frames myself

[PATCH] e1000e: do not panic on malformed rx_desc

2020-09-08 Thread Tong Zhang
length may be corrupted in rx_desc and lead to panic, so check the sanity before passing it to skb_put [ 103.840572] skbuff: skb_over_panic: text:8f432cc1 len:61585 put:61585 head:88805642b800 data:88805642b840 tail:0xf0d1 end:0x6c0 dev:e th0 [ 103.841283] [ cut her

Re: [PATCH net-next 1/1] net: hsr/prp: add vlan support

2020-09-08 Thread Murali Karicheri
Hi Willem, Thanks for the response! On 9/4/20 11:45 AM, Willem de Bruijn wrote: On Tue, Sep 1, 2020 at 9:54 PM Murali Karicheri wrote: This patch add support for creating vlan interfaces over hsr/prp interface. Signed-off-by: Murali Karicheri --- net/hsr/hsr_device.c | 4 net/hsr/

  1   2   3   4   >