[PATCH] fix for potential NULL pointer dereference with bare lan743x

2020-10-28 Thread Sergej Bauer
This is just a minor fix which prevents a kernel NULL pointer dereference when using phy-less lan743x. Signed-off-by: Sergej Bauer --- drivers/net/ethernet/microchip/lan743x_ethtool.c | 7 ++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/drivers/net/ethernet/microchip/lan74

[RFC PATCH 2/3] mwifiex: pcie: add reset_d3cold quirk for Surface gen4+ devices

2020-10-28 Thread Tsuchiya Yuto
To reset mwifiex on Surface gen4+ (Pro 4 or later gen) devices, it seems that putting the wifi device into D3cold is required according to errata.inf file on Windows installation (Windows/INF/errata.inf). This patch adds a function that performs power-cycle (put into D3cold then D0) and call the f

Re: [PATCH] bpf: don't rely on GCC __attribute__((optimize)) to disable GCSE

2020-10-28 Thread Geert Uytterhoeven
Hi Ard, On Tue, Oct 27, 2020 at 9:57 PM Ard Biesheuvel wrote: > Commit 3193c0836f203 ("bpf: Disable GCC -fgcse optimization for > ___bpf_prog_run()") introduced a __no_fgcse macro that expands to a > function scope __attribute__((optimize("-fno-gcse"))), to disable a > GCC specific optimization t

[PATCH v8,net-next,02/12] octeontx2-af: add mailbox interface for CPT

2020-10-28 Thread Srujana Challa
On OcteonTX2 SoC, the admin function (AF) is the only one with all priviliges to configure HW and alloc resources, PFs and it's VFs have to request AF via mailbox for all their needs. This patch adds a mailbox interface for CPT PFs and VFs to allocate resources for cryptography. Signed-off-by: Suh

Re: [PATCH net-next 5/5] net: mscc: ocelot: support L2 multicast entries

2020-10-28 Thread Florian Fainelli
On 10/28/2020 7:27 PM, Vladimir Oltean wrote: > There is one main difference in mscc_ocelot between IP multicast and L2 > multicast. With IP multicast, destination ports are encoded into the > upper bytes of the multicast MAC address. Example: to deliver the > address 01:00:5E:11:22:33 to ports

Re: [PATCH net-next v7 2/8] net: dsa: Give drivers the chance to veto certain upper devices

2020-10-28 Thread Florian Fainelli
On 10/28/2020 12:42 AM, Kurt Kanzenbach wrote: > From: Vladimir Oltean > > Some switches rely on unique pvids to ensure port separation in > standalone mode, because they don't have a port forwarding matrix > configurable in hardware. So, setups like a group of 2 uppers with the > same VLAN, s

Re: [PATCHv2 iproute2-next 0/5] iproute2: add libbpf support

2020-10-28 Thread Stephen Hemminger
On Wed, 28 Oct 2020 19:27:20 -0700 Andrii Nakryiko wrote: > On Wed, Oct 28, 2020 at 7:06 PM Hangbin Liu wrote: > > > > On Wed, Oct 28, 2020 at 05:02:34PM -0600, David Ahern wrote: > > > fails to compile on Ubuntu 20.10: > > > > > > root@u2010-sfo3:~/iproute2.git# ./configure > > > TC scheduler

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

2020-10-28 Thread Yunsheng Lin
On 2020/10/29 4:04, Vishwanath Pai wrote: > On 10/28/20 1:47 PM, Cong Wang wrote: >> On Wed, Oct 28, 2020 at 8:37 AM Pai, Vishwanath wrote: >>> Hi, >>> >>> We noticed some problems when testing the latest 5.4 LTS kernel and traced >>> it >>> back to this commit using git bisect. When running our

[resend] Solution for the problem conntrack in tc subsystem

2020-10-28 Thread wenxu
Hi, Currently kernel tc subsystem can do conntrack things in cat_ct. But there is a problem need to fix.  For several fragment packets handle in act_ct.  The tcf_ct_handle_fragments will defrag the packets to a big one. But the after action will redirect mirror to a device which maybe lead

[PATCH -next] net: stmmac: platform: remove useless if/else

2020-10-28 Thread Zou Wei
Fix the following coccinelle report: ./drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c:233:6-8: WARNING: possible condition with no effect (if == else) Both branches are the same, so remove the else if/else altogether. Reported-by: Hulk Robot Signed-off-by: Zou Wei --- drivers/net/ether

Re: [PATCH net-next 4/5] net: mscc: ocelot: make entry_type a member of struct ocelot_multicast

2020-10-28 Thread Florian Fainelli
On 10/28/2020 7:27 PM, Vladimir Oltean wrote: > This saves a re-classification of the MDB address on deletion. > > Signed-off-by: Vladimir Oltean > --- [snip] > mc = ocelot_multicast_get(ocelot, mdb->addr, vid); > if (!mc) { > /* New entry */ > - int pgi

Re: [PATCH bpf-next v4] bpf: Lift hashtab key_size limit

2020-10-28 Thread Andrii Nakryiko
On Wed, Oct 28, 2020 at 3:21 PM Florian Lehner wrote: > > Currently key_size of hashtab is limited to MAX_BPF_STACK. > As the key of hashtab can also be a value from a per cpu map it can be > larger than MAX_BPF_STACK. > > The use-case for this patch originates to implement allow/disallow > lists

Re: [PATCHv2 iproute2-next 0/5] iproute2: add libbpf support

2020-10-28 Thread David Ahern
On 10/28/20 8:27 PM, Andrii Nakryiko wrote: > On Wed, Oct 28, 2020 at 7:06 PM Hangbin Liu wrote: >> >> On Wed, Oct 28, 2020 at 05:02:34PM -0600, David Ahern wrote: >>> fails to compile on Ubuntu 20.10: >>> >>> root@u2010-sfo3:~/iproute2.git# ./configure >>> TC schedulers >>> ATM yes >>> IPT us

Re: [PATCHv2 iproute2-next 0/5] iproute2: add libbpf support

2020-10-28 Thread Stephen Hemminger
On Thu, 29 Oct 2020 10:06:37 +0800 Hangbin Liu wrote: > On Wed, Oct 28, 2020 at 05:02:34PM -0600, David Ahern wrote: > > fails to compile on Ubuntu 20.10: > > > > root@u2010-sfo3:~/iproute2.git# ./configure > > TC schedulers > > ATMyes > > IPTusing xtables > > IPSET yes > >

Re: [PATCH net-next 2/5] net: mscc: ocelot: use ether_addr_copy

2020-10-28 Thread Florian Fainelli
On 10/28/2020 7:27 PM, Vladimir Oltean wrote: > Since a helper is available for copying Ethernet addresses, let's use it. > > Signed-off-by: Vladimir Oltean Reviewed-by: Florian Fainelli -- Florian

Re: [PATCH net] ip_tunnel: fix over-mtu packet send fail without TUNNEL_DONT_FRAGMENT flags

2020-10-28 Thread wenxu
On 10/27/2020 11:55 PM, Jakub Kicinski wrote: > On Tue, 27 Oct 2020 08:51:07 -0600 David Ahern wrote: >>> Is this another incarnation of 4cb47a8644cc ("tunnels: PMTU discovery >>> support for directly bridged IP packets")? Sounds like non-UDP tunnels >>> need the same treatment to make PMTUD work

Re: [PATCH net-next v7 3/8] net: dsa: Add DSA driver for Hirschmann Hellcreek switches

2020-10-28 Thread Florian Fainelli
On 10/28/2020 12:42 AM, Kurt Kanzenbach wrote: > Add a basic DSA driver for Hirschmann Hellcreek switches. Those switches are > implementing features needed for Time Sensitive Networking (TSN) such as > support > for the Time Precision Protocol and various shapers like the Time Aware > Shaper.

Re: [PATCH net-next 3/5] net: mscc: ocelot: remove the "new" variable in ocelot_port_mdb_add

2020-10-28 Thread Florian Fainelli
On 10/28/2020 7:27 PM, Vladimir Oltean wrote: > It is Not Needed, a comment will suffice. > > Signed-off-by: Vladimir Oltean Reviewed-by: Florian Fainelli -- Florian

Re: [PATCH net-next 1/5] net: mscc: ocelot: classify L2 mdb entries as LOCKED

2020-10-28 Thread Florian Fainelli
On 10/28/2020 7:27 PM, Vladimir Oltean wrote: > ocelot.h says: > > /* MAC table entry types. > * ENTRYTYPE_NORMAL is subject to aging. > * ENTRYTYPE_LOCKED is not subject to aging. > * ENTRYTYPE_MACv4 is not subject to aging. For IPv4 multicast. > * ENTRYTYPE_MACv6 is not subject to aging.

Re: [PATCHv2 iproute2-next 0/5] iproute2: add libbpf support

2020-10-28 Thread David Ahern
On 10/28/20 8:06 PM, Hangbin Liu wrote: > On Wed, Oct 28, 2020 at 05:02:34PM -0600, David Ahern wrote: >> fails to compile on Ubuntu 20.10: >> >> root@u2010-sfo3:~/iproute2.git# ./configure >> TC schedulers >> ATM yes >> IPT using xtables >> IPSET yes >> >> iptables modules directory: /usr/lib/

[PATCH net-next 5/5] net: mscc: ocelot: support L2 multicast entries

2020-10-28 Thread Vladimir Oltean
There is one main difference in mscc_ocelot between IP multicast and L2 multicast. With IP multicast, destination ports are encoded into the upper bytes of the multicast MAC address. Example: to deliver the address 01:00:5E:11:22:33 to ports 3, 8, and 9, one would need to program the address of 00:

[PATCH net-next 4/5] net: mscc: ocelot: make entry_type a member of struct ocelot_multicast

2020-10-28 Thread Vladimir Oltean
This saves a re-classification of the MDB address on deletion. Signed-off-by: Vladimir Oltean --- drivers/net/ethernet/mscc/ocelot.c | 51 +++--- drivers/net/ethernet/mscc/ocelot.h | 17 +- 2 files changed, 34 insertions(+), 34 deletions(-) diff --git a/drivers/n

[PATCH net-next 0/5] L2 multicast forwarding for Ocelot switch

2020-10-28 Thread Vladimir Oltean
This series enables the mscc_ocelot switch to forward raw L2 (non-IP) mdb entries as configured by the bridge driver after this patch: https://patchwork.ozlabs.org/project/netdev/patch/20201028233831.610076-1-vladimir.olt...@nxp.com/ Vladimir Oltean (5): net: mscc: ocelot: classify L2 mdb entri

Re: [PATCHv2 iproute2-next 0/5] iproute2: add libbpf support

2020-10-28 Thread Andrii Nakryiko
On Wed, Oct 28, 2020 at 7:06 PM Hangbin Liu wrote: > > On Wed, Oct 28, 2020 at 05:02:34PM -0600, David Ahern wrote: > > fails to compile on Ubuntu 20.10: > > > > root@u2010-sfo3:~/iproute2.git# ./configure > > TC schedulers > > ATM yes > > IPT using xtables > > IPSET yes > > > > iptables mod

[PATCH net-next 3/5] net: mscc: ocelot: remove the "new" variable in ocelot_port_mdb_add

2020-10-28 Thread Vladimir Oltean
It is Not Needed, a comment will suffice. Signed-off-by: Vladimir Oltean --- drivers/net/ethernet/mscc/ocelot.c | 7 ++- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/drivers/net/ethernet/mscc/ocelot.c b/drivers/net/ethernet/mscc/ocelot.c index 763d0277eeae..ea49d715c9d0 100

[PATCH net-next 1/5] net: mscc: ocelot: classify L2 mdb entries as LOCKED

2020-10-28 Thread Vladimir Oltean
ocelot.h says: /* MAC table entry types. * ENTRYTYPE_NORMAL is subject to aging. * ENTRYTYPE_LOCKED is not subject to aging. * ENTRYTYPE_MACv4 is not subject to aging. For IPv4 multicast. * ENTRYTYPE_MACv6 is not subject to aging. For IPv6 multicast. */ We don't want the permanent entries ad

[PATCH net-next 2/5] net: mscc: ocelot: use ether_addr_copy

2020-10-28 Thread Vladimir Oltean
Since a helper is available for copying Ethernet addresses, let's use it. Signed-off-by: Vladimir Oltean --- drivers/net/ethernet/mscc/ocelot.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/net/ethernet/mscc/ocelot.c b/drivers/net/ethernet/mscc/ocelot.c index 2

[PATCH -next] net: nvidia: forcedeth: remove useless if/else

2020-10-28 Thread Zou Wei
Fix the following coccinelle report: ./drivers/net/ethernet/nvidia/forcedeth.c:3479:8-10: WARNING: possible condition with no effect (if == else) Both branches are the same, so remove the else if/else altogether. Reported-by: Hulk Robot Signed-off-by: Zou Wei --- drivers/net/ethernet/nvidia/f

[PATCH net-next] net/smc: improve return codes for SMC-Dv2

2020-10-28 Thread Karsten Graul
To allow better problem diagnosis the return codes for SMC-Dv2 are improved by this patch. A few more CLC DECLINE codes are defined and sent to the peer when an SMC connection cannot be established. There are now multiple SMC variations that are offered by the client and the server may encounter pr

[PATCH net 0/2] ibmvnic: fixes in reset path

2020-10-28 Thread Lijun Pan
Patch 1/2 notifies peers in failover and migration reset. Patch 2/2 skips timeout reset if it is already resetting. Lijun Pan (2): ibmvnic: notify peers when failover and migration happen ibmvnic: skip tx timeout reset while in resetting drivers/net/ethernet/ibm/ibmvnic.c | 14 +-

[PATCH 0/3] mwifiex: disable ps_mode by default for stability

2020-10-28 Thread Tsuchiya Yuto
Hello all, On Microsoft Surface devices (PCIe-88W8897), we are observing stability issues when ps_mode (IEEE power_save) is enabled, then eventually causes firmware crash. Especially on 5GHz APs, the connection is completely unstable and almost unusable. I think the most desirable change is to fi

Re: [PATCH v2 net 5/5] net: ipa: avoid going past end of resource group array

2020-10-28 Thread Willem de Bruijn
On Wed, Oct 28, 2020 at 3:42 PM Alex Elder wrote: > > The minimum and maximum limits for resources assigned to a given > resource group are programmed in pairs, with the limits for two > groups set in a single register. > > If the number of supported resource groups is odd, only half of the > regi

Re: [PATCH net] selftests: add test script for bareudp tunnels

2020-10-28 Thread Guillaume Nault
On Wed, Oct 28, 2020 at 07:05:19PM +0100, Guillaume Nault wrote: > Test different encapsulation modes of the bareudp module: BTW, I was assuming that kselftests were like documentation updates, and therefore always suitable for the net tree. If not, the patch applies cleanly to net-next (and I can

[PATCH v2 net 4/5] net: ipa: distinguish between resource group types

2020-10-28 Thread Alex Elder
The number of resource groups supported by the hardware can be different for source and destination resources. Determine the number supported for each using separate functions. Make the functions inline end move their definitions into "ipa_reg.h", because they determine whether certain register d

Re: [PATCH net-next 1/4] net: xdp: introduce bulking for xdp tx return path

2020-10-28 Thread Jesper Dangaard Brouer
On Tue, 27 Oct 2020 20:04:07 +0100 Lorenzo Bianconi wrote: > Introduce bulking capability in xdp tx return path (XDP_REDIRECT). > xdp_return_frame is usually run inside the driver NAPI tx completion > loop so it is possible batch it. > Current implementation considers only page_pool memory model.

Re: [PATCHv2 iproute2-next 0/5] iproute2: add libbpf support

2020-10-28 Thread Hangbin Liu
On Wed, Oct 28, 2020 at 05:02:34PM -0600, David Ahern wrote: > fails to compile on Ubuntu 20.10: > > root@u2010-sfo3:~/iproute2.git# ./configure > TC schedulers > ATM yes > IPT using xtables > IPSET yes > > iptables modules directory: /usr/lib/x86_64-linux-gnu/xtables > libc has setns: yes

Re: [RFC bpf-next 07/16] kallsyms: Use rb tree for kallsyms name search

2020-10-28 Thread Alexei Starovoitov
On Wed, Oct 28, 2020 at 07:25:34PM +0100, Jiri Olsa wrote: > On Thu, Oct 22, 2020 at 10:21:29AM +0200, Jiri Olsa wrote: > > The kallsyms_expand_symbol function showed in several bpf related > > profiles, because it's doing linear search. > > > > Before: > > > > Performance counter stats for './s

[PATCH v8,net-next,10/12] crypto: octeontx2: add virtual function driver support

2020-10-28 Thread Srujana Challa
Add support for the Marvell OcteonTX2 CPT virtual function driver. This patch includes probe, PCI specific initialization and interrupt handling. Signed-off-by: Suheil Chandran Signed-off-by: Srujana Challa --- drivers/crypto/marvell/octeontx2/Makefile | 4 +- .../marvell/octeontx2/otx2_c

[PATCH v8,net-next,03/12] octeontx2-af: add debugfs entries for CPT block

2020-10-28 Thread Srujana Challa
Add entries to debugfs at /sys/kernel/debug/octeontx2/cpt. cpt_pc: dump cpt performance HW registers. Usage: cat /sys/kernel/debug/octeontx2/cpt/cpt_pc cpt_ae_sts: show cpt asymmetric engines current state Usage: cat /sys/kernel/debug/octeontx2/cpt/cpt_ae_sts cpt_se_sts: show cpt symmetric engin

[PATCH v4 4/5] ARM: dts: exynos: Add Ethernet to Artik 5 board

2020-10-28 Thread Łukasz Stelmach
Add node for ax88796c ethernet chip. Signed-off-by: Łukasz Stelmach --- arch/arm/boot/dts/exynos3250-artik5-eval.dts | 29 1 file changed, 29 insertions(+) diff --git a/arch/arm/boot/dts/exynos3250-artik5-eval.dts b/arch/arm/boot/dts/exynos3250-artik5-eval.dts index 20446a

[PATCH v4 0/5] AX88796C SPI Ethernet Adapter

2020-10-28 Thread Łukasz Stelmach
This is a driver for AX88796C Ethernet Adapter connected in SPI mode as found on ARTIK5 evaluation board. The driver has been ported from a v3.10.9 vendor kernel for ARTIK5 board. Changes in v4: - fixed compilation problems in asix,ax88796c.yaml and in ax88796c_main.c introduced in v3 Changes

[PATCH v4 5/5] ARM: defconfig: Enable ax88796c driver

2020-10-28 Thread Łukasz Stelmach
Enable ax88796c driver for the ethernet chip on Exynos3250-based ARTIK5 boards. Signed-off-by: Łukasz Stelmach --- arch/arm/configs/exynos_defconfig | 2 ++ arch/arm/configs/multi_v7_defconfig | 2 ++ 2 files changed, 4 insertions(+) diff --git a/arch/arm/configs/exynos_defconfig b/arch/arm/

[PATCH 1/3] mwifiex: disable ps_mode explicitly by default instead

2020-10-28 Thread Tsuchiya Yuto
On Microsoft Surface devices (PCIe-88W8897), the ps_mode causes connection unstable, especially with 5GHz APs. Then, it eventually causes fw crash. This commit disables ps_mode by default instead of enabling it. Required code is extracted from mwifiex_drv_set_power(). Signed-off-by: Tsuchiya Yut

Re: [RFC PATCH] lsm,selinux: pass the family information along with xfrm flow

2020-10-28 Thread James Morris
On Tue, 27 Oct 2020, Paul Moore wrote: > On Wed, Sep 30, 2020 at 9:44 AM Paul Moore wrote: > > On Tue, Sep 29, 2020 at 7:09 PM James Morris wrote: > > > I'm not keen on adding a parameter which nobody is using. Perhaps a note > > > in the header instead? > > > > On Wed, Sep 30, 2020 at 6:14 AM H

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

2020-10-28 Thread Cong Wang
On Wed, Oct 28, 2020 at 8:37 AM Pai, Vishwanath wrote: > Hi, > > We noticed some problems when testing the latest 5.4 LTS kernel and traced it > back to this commit using git bisect. When running our tests the machine stops > responding to all traffic and the only way to recover is a reboot. I do

[PATCH 0/2] mwifiex: fixes for shutdown_sw() and reinit_sw()

2020-10-28 Thread Tsuchiya Yuto
Hello all, This series fixes a software level reset feature. We, Microsoft Surface devices users observed this issue, where firmware reset requires another quirk. The other device users might not notice this issue because if the reset is performed for the firmware level, this issue can't be observ

Re: [PATCH v4 2/3] net: add kcov handle to skb extensions

2020-10-28 Thread Willem de Bruijn
On Wed, Oct 28, 2020 at 2:21 PM Aleksandr Nogikh wrote: > > From: Aleksandr Nogikh > > Remote KCOV coverage collection enables coverage-guided fuzzing of the > code that is not reachable during normal system call execution. It is > especially helpful for fuzzing networking subsystems, where it is

[PATCH v2] brcmfmac: Fix memory leak for unpaired brcmf_{alloc/free}

2020-10-28 Thread Seung-Woo Kim
There are missig brcmf_free() for brcmf_alloc(). Fix memory leak by adding missed brcmf_free(). Reported-by: Jaehoon Chung Fixes: commit 450914c39f88 ("brcmfmac: split brcmf_attach() and brcmf_detach() functions") Signed-off-by: Seung-Woo Kim Reviewed-by: Arend van Spriel --- Change from v1 [1

[PATCH net-next 3/3] self-tests: introduce self-tests for RPS default mask

2020-10-28 Thread Paolo Abeni
Ensure that RPS default mask changes take place on all newly created netns/devices and don't affect existing ones. Signed-off-by: Paolo Abeni --- tools/testing/selftests/net/Makefile | 1 + tools/testing/selftests/net/config| 3 + .../testing/selftests/net/rps_default_mask

[PATCH v8,net-next,05/12] crypto: octeontx2: add mailbox communication with AF

2020-10-28 Thread Srujana Challa
In the resource virtualization unit (RVU) each of the PF and AF (admin function) share a 64KB of reserved memory region for communication. This patch initializes PF <=> AF mailbox IRQs, registers handlers for processing these communication messages. Signed-off-by: Suheil Chandran Signed-off-by: S

[PATCH net-next v7 2/8] net: dsa: Give drivers the chance to veto certain upper devices

2020-10-28 Thread Kurt Kanzenbach
From: Vladimir Oltean Some switches rely on unique pvids to ensure port separation in standalone mode, because they don't have a port forwarding matrix configurable in hardware. So, setups like a group of 2 uppers with the same VLAN, swp0.100 and swp1.100, will cause traffic tagged with VLAN 100

[PATCH v8,net-next,08/12] crypto: octeontx2: add LF framework

2020-10-28 Thread Srujana Challa
CPT RVU Local Functions(LFs) needs to be attached to the PF/VF to submit the instructions to CPT. This patch adds the interface to initialize and attach the LFs. It also adds interface to register the LF's interrupts. Signed-off-by: Suheil Chandran Signed-off-by: Srujana Challa --- drivers/cryp

[PATCH net-next v7 7/8] dt-bindings: Add vendor prefix for Hirschmann

2020-10-28 Thread Kurt Kanzenbach
Hirschmann is building devices for automation and networking. Add them to the vendor prefixes. Signed-off-by: Kurt Kanzenbach Reviewed-by: Florian Fainelli Acked-by: Rob Herring --- Documentation/devicetree/bindings/vendor-prefixes.yaml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Doc

[PATCH net-next v7 0/8] Hirschmann Hellcreek DSA driver

2020-10-28 Thread Kurt Kanzenbach
Hi, this series adds a DSA driver for the Hirschmann Hellcreek TSN switch IP. Characteristics of that IP: * Full duplex Ethernet interface at 100/1000 Mbps on three ports * IEEE 802.1Q-compliant Ethernet Switch * IEEE 802.1Qbv Time-Aware scheduling support * IEEE 1588 and IEEE 802.1AS support

[PATCH net-next v7 1/8] net: dsa: Add tag handling for Hirschmann Hellcreek switches

2020-10-28 Thread Kurt Kanzenbach
The Hirschmann Hellcreek TSN switches have a special tagging protocol for frames exchanged between the CPU port and the master interface. The format is a one byte trailer indicating the destination or origin port. It's quite similar to the Micrel KSZ tagging. That's why the implementation is based

[PATCH net-next v7 3/8] net: dsa: Add DSA driver for Hirschmann Hellcreek switches

2020-10-28 Thread Kurt Kanzenbach
Add a basic DSA driver for Hirschmann Hellcreek switches. Those switches are implementing features needed for Time Sensitive Networking (TSN) such as support for the Time Precision Protocol and various shapers like the Time Aware Shaper. This driver includes basic support for networking: * VLAN

[PATCH net-next v7 6/8] net: dsa: hellcreek: Add PTP status LEDs

2020-10-28 Thread Kurt Kanzenbach
The switch has two controllable I/Os which are usually connected to LEDs. This is useful to immediately visually see the PTP status. These provide two signals: * is_gm This LED can be activated if the current device is the grand master in that PTP domain. * sync_good This LED can be

[PATCH net-next v7 4/8] net: dsa: hellcreek: Add PTP clock support

2020-10-28 Thread Kurt Kanzenbach
From: Kamil Alkhouri The switch has internal PTP hardware clocks. Add support for it. There are three clocks: * Synchronized * Syntonized * Free running Currently the synchronized clock is exported to user space which is a good default for the beginning. The free running clock might be expor

[PATCH v8,net-next,01/12] octeontx2-pf: move lmt flush to include/linux/soc

2020-10-28 Thread Srujana Challa
On OcteonTX2 platform CPT instruction enqueue and NIX packet send are only possible via LMTST operations which uses LDEOR instruction. This patch moves lmt flush function from OcteonTX2 nic driver to include/linux/soc since it will be used by OcteonTX2 CPT and NIC driver for LMTST. Signed-off-by:

Re: [linux-sunxi] Re: [PATCH] net: phy: realtek: omit setting PHY-side delay when "rgmii" specified

2020-10-28 Thread Samuel Holland
Icenowy, On 10/26/20 7:12 AM, Andrew Lunn wrote: >> By referring to linux/phy.h, NA means not applicable. This surely >> do not apply when RGMII is really in use. > > It means the PHY driver should not touch the mode, something else has > set it up. That could be strapping, the bootloader, ACPI f

Re: [PATCH net v2 2/2] dpaa_eth: fix the RX headroom size alignment

2020-10-28 Thread Willem de Bruijn
On Wed, Oct 28, 2020 at 12:41 PM Camelia Groza wrote: > > The headroom reserved for received frames needs to be aligned to an > RX specific value. There is currently a discrepancy between the values > used in the Ethernet driver and the values passed to the FMan. > Coincidentally, the resulting al

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

2020-10-28 Thread Vishwanath Pai
On 10/28/20 1:47 PM, Cong Wang wrote: > On Wed, Oct 28, 2020 at 8:37 AM Pai, Vishwanath wrote: >> Hi, >> >> We noticed some problems when testing the latest 5.4 LTS kernel and traced it >> back to this commit using git bisect. When running our tests the machine stops >> responding to all traffi

Re: [PATCH] rtl8192ce: avoid accessing the data mapped to streaming DMA

2020-10-28 Thread Pkshih
On Mon, 2020-10-19 at 11:09 +0800, Jia-Ju Bai wrote: > In rtl92ce_tx_fill_cmddesc(), skb->data is mapped to streaming DMA on > line 530: >   dma_addr_t mapping = dma_map_single(..., skb->data, ...); > > On line 533, skb->data is assigned to hdr after cast: >   struct ieee80211_hdr *hdr = (struct i

Re: [PATCH] RFC: net: phy: of phys probe/reset issue

2020-10-28 Thread Florian Fainelli
On 10/28/2020 12:32 PM, Grygorii Strashko wrote: > hi Andrew, > > On 23/10/2020 23:10, Andrew Lunn wrote: >>> Yes there is: have your Ethernet PHY compatible string be of the form >>> "ethernet." and then there is no need for such hacking. >>> of_get_phy_id() will parse that compatible

Re: [bpf-next PATCH 2/4] selftests/bpf: Drop python client/server in favor of threads

2020-10-28 Thread Martin KaFai Lau
On Tue, Oct 27, 2020 at 06:47:13PM -0700, Alexander Duyck wrote: > From: Alexander Duyck > > Drop the tcp_client/server.py files in favor of using a client and server > thread within the test case. Specifically we spawn a new thread to play the > role of the server, and the main testing thread pl

Re: [PATCH] net: bonding: alb disable balance for IPv6 multicast related mac

2020-10-28 Thread Jay Vosburgh
LIU Yulong wrote: >According to the RFC 2464 [1] the prefix "33:33:xx:xx:xx:xx" is defined to >construct the multicast destination MAC address for IPv6 multicast traffic. >The NDP (Neighbor Discovery Protocol for IPv6)[2] will comply with such >rule. The work steps [6] are: > *) Let's assume a d

Re: [PATCH] net: bonding: alb disable balance for IPv6 multicast related mac

2020-10-28 Thread Jay Vosburgh
LIU Yulong wrote: >Hi Jay, > > > >Thank you for your response and review. Please see my inline comments. I'm still reviewing your commentary, but to answer your final question regarding updating the patch, you'll need to repost the entire patch (with the new changes). This repost shoul

[PATCH net-next 2/4] sfc: implement encap TSO on EF100

2020-10-28 Thread Edward Cree
The NIC only needs to know where the headers it has to edit (TCP and inner and outer IPv4) are, which fits GSO_PARTIAL nicely. It also supports non-PARTIAL offload of UDP tunnels, again just needing to be told the outer transport offset so that it can edit the UDP length field. (It's not clear t

[PATCH net-next 3/4] sfc: only use fixed-id if the skb asks for it

2020-10-28 Thread Edward Cree
AIUI, the NETIF_F_TSO_MANGLEID flag is a signal to the stack that a driver may _need_ to mangle IDs in order to do TSO, and conversely a signal from the stack that the driver is permitted to do so. Since we support both fixed and incrementing IPIDs, we should rely on the SKB_GSO_FIXEDID flag on

[PATCH net-next 4/4] sfc: advertise our vlan features

2020-10-28 Thread Edward Cree
Signed-off-by: Edward Cree --- drivers/net/ethernet/sfc/ef100_nic.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/net/ethernet/sfc/ef100_nic.c b/drivers/net/ethernet/sfc/ef100_nic.c index 8a187a16ac89..cd93c5ffd45c 100644 --- a/drivers/net/ethernet/sfc/ef100_nic.c +++ b/drivers/n

[PATCH net-next 1/4] sfc: extend bitfield macros to 17 fields

2020-10-28 Thread Edward Cree
We need EFX_POPULATE_OWORD_17 for an encap TSO descriptor on EF100. Signed-off-by: Edward Cree --- drivers/net/ethernet/sfc/bitfield.h | 42 + 1 file changed, 37 insertions(+), 5 deletions(-) diff --git a/drivers/net/ethernet/sfc/bitfield.h b/drivers/net/ethernet/sf

RE: [EXT] [PATCH v2] net: fec: fix MDIO probing for some FEC hardware blocks

2020-10-28 Thread Andy Duan
From: Greg Ungerer Sent: Wednesday, October 28, 2020 1:23 PM > Some (apparently older) versions of the FEC hardware block do not like the > MMFR register being cleared to avoid generation of MII events at > initialization > time. The action of clearing this register results in no future MII even

Re: [PATCH] net: cls_api: remove unneeded local variable in tc_dump_chain()

2020-10-28 Thread Tom Rix
ting binary is identical before and after this change. > > No functional change. No change in object code. > > Signed-off-by: Lukas Bulwahn > --- > applies cleanly on current master and next-20201028 > > Jamal, Cong, Jiri, please ack. > David, Jakub, please pick thi

WARNING: suspicious RCU usage in ovs_flow_tbl_masks_cache_resize

2020-10-28 Thread syzbot
Hello, syzbot found the following issue on: HEAD commit:6daa1da4 chelsio/chtls: fix memory leaks in CPL handlers git tree: net console output: https://syzkaller.appspot.com/x/log.txt?x=10defae450 kernel config: https://syzkaller.appspot.com/x/.config?x=46c6fea3eb827ae1 dashboard li

[PATCH net-next 0/4] sfc: EF100 TSO enhancements

2020-10-28 Thread Edward Cree
Support TSO over encapsulation (with GSO_PARTIAL), and over VLANs (which the code already handled but we didn't advertise). Also correct our handling of IPID mangling. I couldn't find documentation of exactly what shaped SKBs we can get given, so patch #2 is slightly guesswork, but when I test

RE: [tipc-discussion] [net v3 1/1] tipc: fix memory leak caused by tipc_buf_append()

2020-10-28 Thread Tung Quang Nguyen
Hi Cong, No, I have never ignored any comment from reviewers. I sent v2 on Oct 26 after discussing with Xin Long, and v3 on Oct 27 after receiving comment from Jakub. I received your 3 emails nearly at the same time on Oct 28. It's weird. Your emails did not appear in this email archive either:

[PATCH v2 0/2] get rid of GCC __attribute__((optimize)) for BPF

2020-10-28 Thread Ard Biesheuvel
This is a followup to [0]: [PATCH] bpf: don't rely on GCC __attribute__((optimize)) to disable GCSE[0] Changes since v1: - only use -fno-gcse when CONFIG_BPF_JIT_ALWAYS_ON=y and CONFIG_CC_IS_GCC=y (but ignore CONFIG_RETPOLINE since we want to avoid GCSE in all cases) - to avoid potential impact

Re: [PATCH 2/3] mwifiex: add allow_ps_mode module parameter

2020-10-28 Thread Brian Norris
On Wed, Oct 28, 2020 at 2:56 PM Tsuchiya Yuto wrote: > > To make the ps_mode (power_save) control easier, this commit adds a new > module parameter allow_ps_mode and set it false (disallowed) by default. This sounds like a bad idea, as it breaks all the existing users who expect this feature to b

[PATCH net] selftests: add test script for bareudp tunnels

2020-10-28 Thread Guillaume Nault
Test different encapsulation modes of the bareudp module: * Unicast MPLS, * IPv4 only, * IPv4 in multiproto mode (that is, IPv4 and IPv6), * IPv6. Each mode is tested with both an IPv4 and an IPv6 underlay. Signed-off-by: Guillaume Nault --- tools/testing/selftests/net/Makefile | 1

[PATCH 1/2] mwifiex: fix mwifiex_shutdown_sw() causing sw reset failure

2020-10-28 Thread Tsuchiya Yuto
When FLR is performed but without fw reset for some reasons (e.g. on Surface devices, fw reset requires another quirk), it fails to reset properly. You can trigger the issue on such devices via debugfs entry for reset: $ echo 1 | sudo tee /sys/kernel/debug/mwifiex/mlan0/reset and the resultin

Re: [tipc-discussion] [net v3 1/1] tipc: fix memory leak caused by tipc_buf_append()

2020-10-28 Thread Cong Wang
On Tue, Oct 27, 2020 at 10:23 PM Tung Quang Nguyen wrote: > > Hi Cong, > > No, I have never ignored any comment from reviewers. I sent v2 on Oct 26 > after discussing with Xin Long, and v3 on Oct 27 after receiving comment from > Jakub. > I received your 3 emails nearly at the same time on Oct 2

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

2020-10-28 Thread Pai, Vishwanath
On 10/28/20, 10:51 AM, "Vishwanath Pai" wrote: On Thu, Sep 17, 2020 at 4:26 PM Cong Wang wrote: > > On Fri, Sep 11, 2020 at 1:13 AM Yunsheng Lin wrote: > > > > On 2020/9/11 4:07, Cong Wang wrote: > > > On Tue, Sep 8, 2020 at 4:06 AM Yunsheng Lin > > > wrote: > > >> > > >> Currently there is c

Re: [PATCH v2] netem: fix zero division in tabledist

2020-10-28 Thread Stephen Hemminger
On Wed, 28 Oct 2020 17:07:31 + Aleksandr Nogikh wrote: > From: Aleksandr Nogikh > > Currently it is possible to craft a special netlink RTM_NEWQDISC > command that can result in jitter being equal to 0x8000. It is > enough to set the 32 bit jitter to 0x0200 (it will later be > multi

Re: [tipc-discussion] [net v3 1/1] tipc: fix memory leak caused by tipc_buf_append()

2020-10-28 Thread Xin Long
On Tue, Oct 27, 2020 at 11:25 AM Tung Nguyen wrote: > > Commit ed42989eab57 ("tipc: fix the skb_unshare() in tipc_buf_append()") > replaced skb_unshare() with skb_copy() to not reduce the data reference > counter of the original skb intentionally. This is not the correct > way to handle the cloned

Re: [PATCH net-next] net: phylink: disable BMCR_ISOLATE in phylink_mii_c22_pcs_config

2020-10-28 Thread Jakub Kicinski
On Mon, 26 Oct 2020 11:58:02 -0600 Robert Hancock wrote: > The Xilinx PCS/PMA PHY requires that BMCR_ISOLATE be disabled for proper > operation in 1000BaseX mode. It should be safe to ensure this bit is > disabled in phylink_mii_c22_pcs_config in all cases. > > Signed-off-by: Robert Hancock > Rev

Re: [PATCH net-next] net: ceph: Fix most of the kerneldoc warings

2020-10-28 Thread Jakub Kicinski
On Wed, 28 Oct 2020 01:59:07 +0100 Andrew Lunn wrote: > net/ceph/cls_lock_client.c:143: warning: Function parameter or member 'oid' > not described in 'ceph_cls_break_lock' > net/ceph/cls_lock_client.c:143: warning: Function parameter or member 'oloc' > not described in 'ceph_cls_break_lock' > ..

Re: [PATCH net-next 1/4] net: xdp: introduce bulking for xdp tx return path

2020-10-28 Thread Lorenzo Bianconi
> Hi Lorenzo, Hi Ilias, thx for the review. > > On Tue, Oct 27, 2020 at 08:04:07PM +0100, Lorenzo Bianconi wrote: [...] > > +void xdp_return_frame_bulk(struct xdp_frame *xdpf, > > + struct xdp_frame_bulk *bq) > > +{ > > + struct xdp_mem_info *mem = &xdpf->mem; > > + s

Re: [PATCH] bpf: don't rely on GCC __attribute__((optimize)) to disable GCSE

2020-10-28 Thread Ard Biesheuvel
On Wed, 28 Oct 2020 at 00:04, Daniel Borkmann wrote: > > On 10/27/20 9:57 PM, Ard Biesheuvel wrote: > > Commit 3193c0836f203 ("bpf: Disable GCC -fgcse optimization for > > ___bpf_prog_run()") introduced a __no_fgcse macro that expands to a > > function scope __attribute__((optimize("-fno-gcse"))),

[PATCH bpf-next 11/11] tools/bpftool: add bpftool support for split BTF

2020-10-28 Thread Andrii Nakryiko
Add ability to work with split BTF by providing extra -B flag, which allows to specify the path to the base BTF file. Signed-off-by: Andrii Nakryiko --- tools/bpf/bpftool/btf.c | 9 ++--- tools/bpf/bpftool/main.c | 15 ++- tools/bpf/bpftool/main.h | 1 + 3 files changed, 21 in

Re: WARNING in dma_map_page_attrs

2020-10-28 Thread h...@lst.de
On Tue, Oct 27, 2020 at 12:52:30PM +, Parav Pandit wrote: > > > From: h...@lst.de > > Sent: Tuesday, October 27, 2020 1:41 PM > > > > On Mon, Oct 26, 2020 at 05:23:48AM +, Parav Pandit wrote: > > > Hi Christoph, > > > > > > > From: Jakub Kicinski > > > > Sent: Saturday, October 24, 2020

[PATCH bpf-next 03/11] libbpf: unify and speed up BTF string deduplication

2020-10-28 Thread Andrii Nakryiko
From: Andrii Nakryiko Revamp BTF dedup's string deduplication to match the approach of writable BTF string management. This allows to transfer deduplicated strings index back to BTF object after deduplication without expensive extra memory copying and hash map re-construction. It also simplifies

[PATCH bpf-next 08/11] libbpf: support BTF dedup of split BTFs

2020-10-28 Thread Andrii Nakryiko
Add support for deduplication split BTFs. When deduplicating split BTF, base BTF is considered to be immutable and can't be modified or adjusted. 99% of BTF deduplication logic is left intact (module some type numbering adjustments). There are only two differences. First, each type in base BTF get

Re: [PATCH] net/atm: use list_is_singular() in br2684_setfilt()

2020-10-28 Thread Jakub Kicinski
On Tue, 27 Oct 2020 00:57:00 +0800 Hui Su wrote: > list_is_singular() can tell whether a list has just one entry. > So we use list_is_singular() here. > > Signed-off-by: Hui Su > --- > net/atm/br2684.c | 3 +-- > 1 file changed, 1 insertion(+), 2 deletions(-) > > diff --git a/net/atm/br2684.c b

[PATCH bpf-next 10/11] selftests/bpf: add split BTF dedup selftests

2020-10-28 Thread Andrii Nakryiko
Add selftests validating BTF deduplication for split BTF case. Add a helper macro that allows to validate entire BTF with raw BTF dump, not just type-by-type. This saves tons of code and complexity. Signed-off-by: Andrii Nakryiko --- tools/testing/selftests/bpf/btf_helpers.c | 59 tool

[PATCH bpf-next 04/11] libbpf: implement basic split BTF support

2020-10-28 Thread Andrii Nakryiko
Support split BTF operation, in which one BTF (base BTF) provides basic set of types and strings, while another one (split BTF) builds on top of base's types and strings and adds its own new types and strings. From API standpoint, the fact that the split BTF is built on top of the base BTF is trans

[PATCH bpf-next 09/11] libbpf: accomodate DWARF/compiler bug with duplicated identical arrays

2020-10-28 Thread Andrii Nakryiko
In some cases compiler seems to generate distinct DWARF types for identical arrays within the same CU. That seems like a bug, but it's already out there and breaks type graph equivalence checks, so accommodate it anyway by checking for identical arrays, regardless of their type ID. Signed-off-by:

[PATCH bpf-next 06/11] selftests/bpf: add checking of raw type dump in BTF writer APIs selftests

2020-10-28 Thread Andrii Nakryiko
From: Andrii Nakryiko Add re-usable btf_helpers.{c,h} to provide BTF-related testing routines. Start with adding a raw BTF dumping helpers. Raw BTF dump is the most succinct and at the same time a very human-friendly way to validate exact contents of BTF types. Cross-validate raw BTF dump and wr

[PATCH bpf-next 07/11] libbpf: fix BTF data layout checks and allow empty BTF

2020-10-28 Thread Andrii Nakryiko
Make data section layout checks stricter, disallowing overlap of types and strings data. Additionally, allow BTFs with no type data. There is nothing inherently wrong with having BTF with no types (put potentially with some strings). This could be a situation with kernel module BTFs, if module doe

[PATCH bpf-next 05/11] selftests/bpf: add split BTF basic test

2020-10-28 Thread Andrii Nakryiko
Add selftest validating ability to programmatically generate and then dump split BTF. Signed-off-by: Andrii Nakryiko --- .../selftests/bpf/prog_tests/btf_split.c | 99 +++ tools/testing/selftests/bpf/test_progs.h | 11 +++ 2 files changed, 110 insertions(+) create mode

[PATCH bpf-next 01/11] libbpf: factor out common operations in BTF writing APIs

2020-10-28 Thread Andrii Nakryiko
Factor out commiting of appended type data. Also extract fetching the very last type in the BTF (to append members to). These two operations are common across many APIs and will be easier to refactor with split BTF, if they are extracted into a single place. Signed-off-by: Andrii Nakryiko --- to

  1   2   3   4   >