Re: [RFC net-next v2 2/3] devlink: health: add remediation type

2021-03-10 Thread Jiri Pirko
Thu, Mar 11, 2021 at 04:26:12AM CET, k...@kernel.org wrote: >Currently devlink health does not give user any clear information >of what kind of remediation ->recover callback will perform. This >makes it difficult to understand the impact of enabling auto- >-remediation, and the severity of the err

Re: [RFC net-next v2 1/3] devlink: move health state to uAPI

2021-03-10 Thread Jiri Pirko
Thu, Mar 11, 2021 at 04:26:11AM CET, k...@kernel.org wrote: >Move the health states into uAPI, so applications can use them. > >Note that we need to change the name of the enum because >user space is likely already defining the same values. >E.g. iproute2 does. > >Use this opportunity to shorten th

Re: [PATCH RESEND][next] rtl8xxxu: Fix fall-through warnings for Clang

2021-03-10 Thread Gustavo A. R. Silva
On 3/11/21 01:00, Kalle Valo wrote: > Kees Cook writes: > >> On Fri, Mar 05, 2021 at 03:40:33PM +0200, Kalle Valo wrote: >>> "Gustavo A. R. Silva" writes: >>> In preparation to enable -Wimplicit-fallthrough for Clang, fix multiple warnings by replacing /* fall through */ comments wi

module refcount issues in the liquidio driver

2021-03-10 Thread Christoph Hellwig
Hi all, I just stumbled over the odd handling of module refcounts in the liquidio driver. The big red flag is the call to module_refcount in liquidio_watchdog, which will do the wrong thing for any external module refcount, like a userspace open. But more importantly the whole concept of acquiri

Re: [PATCH V3 1/6] vDPA/ifcvf: get_vendor_id returns a device specific vendor id

2021-03-10 Thread Zhu, Lingshan
On 3/11/2021 2:13 PM, Jason Wang wrote: On 2021/3/11 12:21 下午, Zhu Lingshan wrote: On 3/11/2021 11:23 AM, Jason Wang wrote: On 2021/3/10 5:00 下午, Zhu Lingshan wrote: In this commit, ifcvf_get_vendor_id() will return a device specific vendor id of the probed pci device than a hard code.

Re: [RFC v2 5/5] clk: socfpga: allow compile testing of Stratix 10 / Agilex clocks

2021-03-10 Thread Krzysztof Kozlowski
On 10/03/2021 17:48, Arnd Bergmann wrote: > On Wed, Mar 10, 2021 at 9:38 AM Krzysztof Kozlowski > wrote: >> --- a/drivers/clk/socfpga/Kconfig >> +++ b/drivers/clk/socfpga/Kconfig >> @@ -1,6 +1,17 @@ >> # SPDX-License-Identifier: GPL-2.0 >> +config COMMON_CLK_SOCFPGA >> + bool "Intel SoCFPGA

[PATCH net] net: lapbether: Prevent racing when checking whether the netif is running

2021-03-10 Thread Xie He
There are two "netif_running" checks in this driver. One is in "lapbeth_xmit" and the other is in "lapbeth_rcv". They serve to make sure that the LAPB APIs called in these functions are called before "lapb_unregister" is called by the "ndo_stop" function. However, these "netif_running" checks are

Re: [PATCH V3 6/6] vDPA/ifcvf: verify mandatory feature bits for vDPA

2021-03-10 Thread Zhu, Lingshan
On 3/11/2021 2:20 PM, Jason Wang wrote: On 2021/3/11 12:16 下午, Zhu Lingshan wrote: On 3/11/2021 11:20 AM, Jason Wang wrote: On 2021/3/10 5:00 下午, Zhu Lingshan wrote: vDPA requres VIRTIO_F_ACCESS_PLATFORM as a must, this commit examines this when set features. Signed-off-by: Zhu Lingsha

[PATCH v2] netdevsim: fib: Remove redundant code

2021-03-10 Thread Jiapeng Chong
Fix the following coccicheck warnings: ./drivers/net/netdevsim/fib.c:874:5-8: Unneeded variable: "err". Return "0" on line 889. Reported-by: Abaci Robot Signed-off-by: Jiapeng Chong --- Changes in v2: - Modify the function type to void. drivers/net/netdevsim/fib.c | 6 +- 1 file changed

[PATCH mlx5-next 9/9] net/mlx5: Use order-0 allocations for EQs

2021-03-10 Thread Saeed Mahameed
From: Tariq Toukan Currently we are allocating high-order page for EQs. In case of fragmented system, VF hot remove/add in VMs for example, there isn't enough contiguous memory for EQs allocation, which results in crashing of the VM. Therefore, use order-0 fragments for the EQ allocations instead

[PATCH mlx5-next 7/9] net/mlx5: E-Switch, Refactor send to vport to be more generic

2021-03-10 Thread Saeed Mahameed
From: Mark Bloch Now that each representor stores a pointer to the managing E-Switch use that information when creating the send-to-vport rules. Signed-off-by: Mark Bloch Reviewed-by: Saeed Mahameed Signed-off-by: Saeed Mahameed --- drivers/infiniband/hw/mlx5/ib_rep.c | 3 +-- ...

[PATCH mlx5-next 8/9] net/mlx5: Add IFC bits needed for single FDB mode

2021-03-10 Thread Saeed Mahameed
From: Mark Bloch Currently we operate in a mode where each eswitch manager has a separate FDB. In order to combine these multiple FDBs we expose new caps to allow this: - Set root flow table which isn't native. - Set FDB a different selection mode when in LAG mode. Signed-off-by: Mark Bloch Re

[PATCH mlx5-next 6/9] RDMA/mlx5: Use represntor E-Switch when getting netdev and metadata

2021-03-10 Thread Saeed Mahameed
From: Mark Bloch Now that a pointer to the managing E-Switch is stored in the representor use it. Signed-off-by: Mark Bloch Reviewed-by: Saeed Mahameed Signed-off-by: Saeed Mahameed --- drivers/infiniband/hw/mlx5/fs.c | 2 +- drivers/infiniband/hw/mlx5/ib_rep.c | 2 +- drivers/infiniband

[PATCH mlx5-next 4/9] net/mlx5: E-Switch, Add match on vhca id to default send rules

2021-03-10 Thread Saeed Mahameed
From: Mark Bloch Match on the vhca id of the E-Switch owner when creating the send-to-vport representor rules. Signed-off-by: Mark Bloch Reviewed-by: Saeed Mahameed Signed-off-by: Saeed Mahameed --- .../ethernet/mellanox/mlx5/core/eswitch_offloads.c | 12 1 file changed, 12 in

[PATCH mlx5-next 5/9] net/mlx5: E-Switch, Add eswitch pointer to each representor

2021-03-10 Thread Saeed Mahameed
From: Mark Bloch Store the managing E-Switch of each representor. This will be used when a representor is created on eswitch manager 0 but the vport belongs to eswitch manager 1. Signed-off-by: Mark Bloch Reviewed-by: Saeed Mahameed Signed-off-by: Saeed Mahameed --- drivers/net/ethernet/mell

[PATCH mlx5-next 2/9] net/mlx5: simplify the return expression of mlx5_esw_offloads_pair()

2021-03-10 Thread Saeed Mahameed
From: Zheng Yongjun Simplify the return expression. Signed-off-by: Zheng Yongjun Signed-off-by: Saeed Mahameed --- drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c | 7 +-- 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/drivers/net/ethernet/mellanox/mlx5/core/eswit

[PATCH mlx5-next 1/9] net/mlx5: Cleanup prototype warning

2021-03-10 Thread Saeed Mahameed
From: Saeed Mahameed Cleanup W=1 warning: drivers/net/ethernet/mellanox/mlx5/core/lag_mp.c:49: warning: expecting prototype for Set lag port affinity(). Prototype was for mlx5_lag_set_port_affinity() instead Signed-off-by: Saeed Mahameed --- drivers/net/ethernet/mellanox/mlx5/core/lag_m

[PATCH mlx5-next 0/9] mlx5 next updates 2021-03-10

2021-03-10 Thread Saeed Mahameed
From: Saeed Mahameed This series is targeting mlx5-next shared tree for mlx5 netdev and rdma shared updates. >From Mark, E-Switch cleanups and refactoring, and the addition of single FDB mode needed HW bits. >From Mikhael, Remove unused struct field >From Saeed, Cleanup W=1 prototype warning

[PATCH mlx5-next 3/9] net/mlx5: Remove unused mlx5_core_health member recover_work

2021-03-10 Thread Saeed Mahameed
From: Mikhael Goikhman The code related to health->recover_work was removed in commit 63cbc552eebf ("net/mlx5: Handle SW reset of FW in error flow") Fix struct mlx5_core_health accordingly. Signed-off-by: Mikhael Goikhman Reviewed-by: Tariq Toukan Signed-off-by: Saeed Mahameed --- include/l

Re: [RFC v2 3/5] arm64: socfpga: rename ARCH_STRATIX10 to ARCH_SOCFPGA64

2021-03-10 Thread Krzysztof Kozlowski
On 10/03/2021 17:42, Arnd Bergmann wrote: > On Wed, Mar 10, 2021 at 4:54 PM Krzysztof Kozlowski > wrote: >> On 10/03/2021 16:47, Krzysztof Kozlowski wrote: >>> This edac Altera driver is very weird... it uses the same compatible >>> differently depending whether this is 32-bit or 64-bit (e.g. Stra

Re: [PATCH net-next 00/15] dpaa2-switch: CPU terminated traffic and move out of staging

2021-03-10 Thread Greg KH
On Thu, Mar 11, 2021 at 08:04:29AM +0100, Greg KH wrote: > On Thu, Mar 11, 2021 at 08:54:37AM +0200, Ioana Ciornei wrote: > > On Wed, Mar 10, 2021 at 03:13:10PM -0800, David Miller wrote: > > > From: Greg KH > > > Date: Wed, 10 Mar 2021 15:12:57 +0100 > > > > > > > Yes, either I can provide a sta

Re: [PATCH net-next 00/15] dpaa2-switch: CPU terminated traffic and move out of staging

2021-03-10 Thread Greg KH
On Thu, Mar 11, 2021 at 08:54:37AM +0200, Ioana Ciornei wrote: > On Wed, Mar 10, 2021 at 03:13:10PM -0800, David Miller wrote: > > From: Greg KH > > Date: Wed, 10 Mar 2021 15:12:57 +0100 > > > > > Yes, either I can provide a stable tag to pull from for the netdev > > > maintainers, or they can ju

Re: [PATCH RESEND][next] rtl8xxxu: Fix fall-through warnings for Clang

2021-03-10 Thread Kalle Valo
Kees Cook writes: > On Fri, Mar 05, 2021 at 03:40:33PM +0200, Kalle Valo wrote: >> "Gustavo A. R. Silva" writes: >> >> > In preparation to enable -Wimplicit-fallthrough for Clang, fix >> > multiple warnings by replacing /* fall through */ comments with >> > the new pseudo-keyword macro fallthro

Re: [PATCH bpf-next 2/2] libbpf: xsk: move barriers from libbpf_util.h to xsk.h

2021-03-10 Thread Björn Töpel
On 2021-03-11 01:06, Jonathan Lemon wrote: On Wed, Mar 10, 2021 at 09:09:29AM +0100, Björn Töpel wrote: From: Björn Töpel The only user of libbpf_util.h is xsk.h. Move the barriers to xsk.h, and remove libbpf_util.h. The barriers are used as an implementation detail, and should not be consider

[PATCH v2] perf machine: Assign boolean values to a bool variable

2021-03-10 Thread Jiapeng Chong
Fix the following coccicheck warnings: ./tools/perf/util/machine.c:2041:9-10: WARNING: return of 0/1 in function 'symbol__match_regex' with return type bool. Reported-by: Abaci Robot Signed-off-by: Jiapeng Chong --- Changes in v2: - Make code simpler. tools/perf/util/machine.c | 4 +--- 1 f

Re: [PATCH net-next 00/15] dpaa2-switch: CPU terminated traffic and move out of staging

2021-03-10 Thread Ioana Ciornei
On Wed, Mar 10, 2021 at 03:13:10PM -0800, David Miller wrote: > From: Greg KH > Date: Wed, 10 Mar 2021 15:12:57 +0100 > > > Yes, either I can provide a stable tag to pull from for the netdev > > maintainers, or they can just add the whole driver to the "proper" place > > in the network tree and I

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

2021-03-10 Thread Björn Töpel
_util.h to xsk.h") I have used the bpf tree from next-20210310 for today.

Re: [PATCH 2/3] net: ethernet: actions: Add Actions Semi Owl Ethernet MAC driver

2021-03-10 Thread Philipp Zabel
Hi Cristian, On Thu, Mar 11, 2021 at 03:20:13AM +0200, Cristian Ciocaltea wrote: > Add new driver for the Ethernet MAC used on the Actions Semi Owl > family of SoCs. > > Currently this has been tested only on the Actions Semi S500 SoC > variant. > > Signed-off-by: Cristian Ciocaltea > --- [...]

Re: [PATCH] net: add net namespace inode for all net_dev events

2021-03-10 Thread Tony Lu
On Wed, Mar 10, 2021 at 11:31:12AM -0500, Steven Rostedt wrote: > On Wed, 10 Mar 2021 17:03:40 +0800 > Tony Lu wrote: > > > I use pahole to read vmlinux.o directly with defconfig and > > CONFIG_DEBUG_INFO enabled, the result shows 22 structs prefixed with > > trace_event_raw_ that have at least o

[net-next PATCH v7 16/16] net: dpaa2-mac: Add ACPI support for DPAA2 MAC driver

2021-03-10 Thread Calvin Johnson
Modify dpaa2_mac_get_node() to get the dpmac fwnode from either DT or ACPI. Modify dpaa2_mac_get_if_mode() to get interface mode from dpmac_node which is a fwnode. Modify dpaa2_pcs_create() to create pcs from dpmac_node fwnode. Modify dpaa2_mac_connect() to support ACPI along with DT. Signed-of

[net-next PATCH v7 14/16] net: phylink: introduce phylink_fwnode_phy_connect()

2021-03-10 Thread Calvin Johnson
Define phylink_fwnode_phy_connect() to connect phy specified by a fwnode to a phylink instance. Signed-off-by: Calvin Johnson --- Changes in v7: None Changes in v6: - remove OF check for fixed-link Changes in v5: None Changes in v4: - call phy_device_free() before returning Changes in v3: None

[net-next PATCH v7 15/16] net: phylink: Refactor phylink_of_phy_connect()

2021-03-10 Thread Calvin Johnson
Refactor phylink_of_phy_connect() to use phylink_fwnode_phy_connect(). Signed-off-by: Calvin Johnson --- Changes in v7: None Changes in v6: None Changes in v5: None Changes in v4: None Changes in v3: None Changes in v2: None drivers/net/phy/phylink.c | 39 +-

[net-next PATCH v7 13/16] net/fsl: Use fwnode_mdiobus_register()

2021-03-10 Thread Calvin Johnson
fwnode_mdiobus_register() internally takes care of both DT and ACPI cases to register mdiobus. Replace existing of_mdiobus_register() with fwnode_mdiobus_register(). Note: For both ACPI and DT cases, endianness of MDIO controller need to be specified using "little-endian" property. Signed-off-by:

[net-next PATCH v7 11/16] net: mdio: Add ACPI support code for mdio

2021-03-10 Thread Calvin Johnson
Define acpi_mdiobus_register() to Register mii_bus and create PHYs for each ACPI child node. Signed-off-by: Calvin Johnson --- Changes in v7: - Include headers directly used in acpi_mdio.c Changes in v6: - use GENMASK() and ACPI_COMPANION_SET() - some cleanup - remove unwanted header inclusion

[net-next PATCH v7 12/16] net: mdiobus: Introduce fwnode_mdiobus_register()

2021-03-10 Thread Calvin Johnson
Introduce fwnode_mdiobus_register() to register PHYs on the mdiobus. If the fwnode is DT node, then call of_mdiobus_register(). If it is an ACPI node, then call acpi_mdiobus_register(). Signed-off-by: Calvin Johnson --- Changes in v7: - Move fwnode_mdiobus_register() to fwnode_mdio.c Changes i

[net-next PATCH v7 10/16] ACPI: utils: Introduce acpi_get_local_address()

2021-03-10 Thread Calvin Johnson
Introduce a wrapper around the _ADR evaluation. Signed-off-by: Calvin Johnson --- Changes in v7: None Changes in v6: None Changes in v5: - Replace fwnode_get_id() with acpi_get_local_address() Changes in v4: - Improve code structure to handle all cases Changes in v3: - Modified to retrieve reg

[net-next PATCH v7 09/16] of: mdio: Refactor of_mdiobus_register_phy()

2021-03-10 Thread Calvin Johnson
Refactor of_mdiobus_register_phy() to use fwnode_mdiobus_register_phy(). Signed-off-by: Calvin Johnson --- Changes in v7: - include fwnode_mdio.h Changes in v6: None Changes in v5: None Changes in v4: None Changes in v3: None Changes in v2: None drivers/net/mdio/of_mdio.c | 39 ++-

[net-next PATCH v7 08/16] net: mdiobus: Introduce fwnode_mdiobus_register_phy()

2021-03-10 Thread Calvin Johnson
Introduce fwnode_mdiobus_register_phy() to register PHYs on the mdiobus. From the compatible string, identify whether the PHY is c45 and based on this create a PHY device instance which is registered on the mdiobus. uninitialized symbol 'mii_ts' Reported-by: kernel test robot Reported-by: Dan Car

[net-next PATCH v7 07/16] net: mii_timestamper: check NULL in unregister_mii_timestamper()

2021-03-10 Thread Calvin Johnson
Callers of unregister_mii_timestamper() currently check for NULL value of mii_ts before calling it. Place the NULL check inside unregister_mii_timestamper() and update the callers accordingly. Signed-off-by: Calvin Johnson --- Changes in v7: - check NULL in unregister_mii_timestamper() Changes

[net-next PATCH v7 06/16] of: mdio: Refactor of_get_phy_id()

2021-03-10 Thread Calvin Johnson
With the introduction of fwnode_get_phy_id(), refactor of_get_phy_id() to use fwnode equivalent. Signed-off-by: Calvin Johnson --- Changes in v7: None Changes in v6: None Changes in v5: None Changes in v4: None Changes in v3: None Changes in v2: None drivers/net/mdio/of_mdio.c | 12 +--

Re: [PATCH] net: core: Few absolutely rudimentary typo fixes throughout the file filter.c

2021-03-10 Thread Bhaskar Chowdhury
On 22:12 Wed 10 Mar 2021, Randy Dunlap wrote: On 3/10/21 9:56 PM, Bhaskar Chowdhury wrote: Trivial spelling fixes throughout the file. Signed-off-by: Bhaskar Chowdhury Hi Bhaskar, FYI: a. we accept British or American spellings b. we accept one or two spaces after a period ('.') at the en

[net-next PATCH v7 02/16] net: phy: Introduce fwnode_mdio_find_device()

2021-03-10 Thread Calvin Johnson
Define fwnode_mdio_find_device() to get a pointer to the mdio_device from fwnode passed to the function. Refactor of_mdio_find_device() to use fwnode_mdio_find_device(). Signed-off-by: Calvin Johnson --- Changes in v7: - correct fwnode_mdio_find_device() description Changes in v6: - fix warnin

[net-next PATCH v7 03/16] net: phy: Introduce phy related fwnode functions

2021-03-10 Thread Calvin Johnson
Define fwnode_phy_find_device() to iterate an mdiobus and find the phy device of the provided phy fwnode. Additionally define device_phy_find_device() to find phy device of provided device. Define fwnode_get_phy_node() to get phy_node using named reference. Signed-off-by: Calvin Johnson --- Cha

[net-next PATCH v7 00/16] ACPI support for dpaa2 driver

2021-03-10 Thread Calvin Johnson
This patch set provides ACPI support to DPAA2 network drivers. It also introduces new fwnode based APIs to support phylink and phy layers Following functions are defined: phylink_fwnode_phy_connect() fwnode_mdiobus_register_phy() fwnode_mdiobus_register() fwnode_get_p

[net-next PATCH v7 05/16] net: phy: Introduce fwnode_get_phy_id()

2021-03-10 Thread Calvin Johnson
Extract phy_id from compatible string. This will be used by fwnode_mdiobus_register_phy() to create phy device using the phy_id. Signed-off-by: Calvin Johnson --- Changes in v7: None Changes in v6: None Changes in v5: None Changes in v4: None Changes in v3: - Use traditional comparison pattern -

[net-next PATCH v7 04/16] of: mdio: Refactor of_phy_find_device()

2021-03-10 Thread Calvin Johnson
Refactor of_phy_find_device() to use fwnode_phy_find_device(). Signed-off-by: Calvin Johnson --- Changes in v7: None Changes in v6: None Changes in v5: None Changes in v4: None Changes in v3: None Changes in v2: None drivers/net/mdio/of_mdio.c | 13 + 1 file changed, 1 insertion(+)

Re: [PATCH V3 6/6] vDPA/ifcvf: verify mandatory feature bits for vDPA

2021-03-10 Thread Jason Wang
On 2021/3/11 12:16 下午, Zhu Lingshan wrote: On 3/11/2021 11:20 AM, Jason Wang wrote: On 2021/3/10 5:00 下午, Zhu Lingshan wrote: vDPA requres VIRTIO_F_ACCESS_PLATFORM as a must, this commit examines this when set features. Signed-off-by: Zhu Lingshan ---   drivers/vdpa/ifcvf/ifcvf_base.c |

[net-next PATCH v7 01/16] Documentation: ACPI: DSD: Document MDIO PHY

2021-03-10 Thread Calvin Johnson
Introduce ACPI mechanism to get PHYs registered on a MDIO bus and provide them to be connected to MAC. Describe properties "phy-handle" and "phy-mode". Signed-off-by: Calvin Johnson --- Changes in v7: None Changes in v6: - Minor cleanup Changes in v5: - More cleanup Changes in v4: - More clea

Re: [PATCH V3 3/6] vDPA/ifcvf: rename original IFCVF dev ids to N3000 ids

2021-03-10 Thread Jason Wang
On 2021/3/11 12:23 下午, Zhu Lingshan wrote: On 3/11/2021 11:25 AM, Jason Wang wrote: On 2021/3/10 5:00 下午, Zhu Lingshan wrote: IFCVF driver probes multiple types of devices now, to distinguish the original device driven by IFCVF from others, it is renamed as "N3000". Signed-off-by: Zhu Lin

Re: [PATCH V3 1/6] vDPA/ifcvf: get_vendor_id returns a device specific vendor id

2021-03-10 Thread Jason Wang
On 2021/3/11 12:21 下午, Zhu Lingshan wrote: On 3/11/2021 11:23 AM, Jason Wang wrote: On 2021/3/10 5:00 下午, Zhu Lingshan wrote: In this commit, ifcvf_get_vendor_id() will return a device specific vendor id of the probed pci device than a hard code. Signed-off-by: Zhu Lingshan ---   drivers

RE: mlx5 sub function issue

2021-03-10 Thread Parav Pandit
Hi Ze wang, > From: ze wang > Sent: Wednesday, March 10, 2021 2:59 PM > > Hi Parav, > Thanks for your help. I did enabled VFs, and after turning off SR-IOV, > it > works. Happy to hear that. > Now the each PF can create 255 SFs, which is probably enough for us. > Is it convenient > to re

Re: [PATCH] net: core: Few absolutely rudimentary typo fixes throughout the file filter.c

2021-03-10 Thread Randy Dunlap
On 3/10/21 9:56 PM, Bhaskar Chowdhury wrote: > > Trivial spelling fixes throughout the file. > > Signed-off-by: Bhaskar Chowdhury Hi Bhaskar, FYI: a. we accept British or American spellings b. we accept one or two spaces after a period ('.') at the end of a sentence c. we accept Oxford (seria

[PATCH] net: core: Few absolutely rudimentary typo fixes throughout the file filter.c

2021-03-10 Thread Bhaskar Chowdhury
Trivial spelling fixes throughout the file. Signed-off-by: Bhaskar Chowdhury --- net/core/filter.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/net/core/filter.c b/net/core/filter.c index 255aeee72402..931ee5f39ae7 100644 --- a/net/core/filter.c +++ b/net/core/filt

[PATCH net-next] netfilter: conntrack: Remove unused variable declaration

2021-03-10 Thread YueHaibing
commit e97c3e278e95 ("tproxy: split off ipv6 defragmentation to a separate module") left behind this. Signed-off-by: YueHaibing --- include/net/netfilter/ipv6/nf_conntrack_ipv6.h | 3 --- 1 file changed, 3 deletions(-) diff --git a/include/net/netfilter/ipv6/nf_conntrack_ipv6.h b/include/net/n

[PATCH net v2] net: phy: broadcom: Add power down exit reset state delay

2021-03-10 Thread Florian Fainelli
Per the datasheet, when we clear the power down bit, the PHY remains in an internal reset state for 40us and then resume normal operation. Account for that delay to avoid any issues in the future if genphy_resume() changes. Fixes: fe26821fa614 ("net: phy: broadcom: Wire suspend/resume for BCM54810

[PATCH] net: socket.c: Fix comparison issues

2021-03-10 Thread Shubhankar Kuranagatti
The constant has been placed to the right side of the test. Signed-off-by: Shubhankar Kuranagatti --- net/socket.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/net/socket.c b/net/socket.c index 84a8049c2b09..a23dd4348793 100644 --- a/net/socket.c +++ b/net/socket.c @

[PATCH] isdn: remove extra spaces in the header file

2021-03-10 Thread Tong Zhang
fix some coding style issues in the isdn header Signed-off-by: Tong Zhang --- drivers/isdn/hardware/mISDN/iohelper.h | 14 +++--- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/drivers/isdn/hardware/mISDN/iohelper.h b/drivers/isdn/hardware/mISDN/iohelper.h index b2b2bde8e

[PATCH] mISDN: fix crash in fritzpci

2021-03-10 Thread Tong Zhang
setup_fritz() in avmfritz.c might fail with -EIO and in this case the isac.type and isac.write_reg is not initialized and remains 0(NULL). A subsequent call to isac_release() will dereference isac->write_reg and crash. [1.737444] BUG: kernel NULL pointer dereference, address:

Re: [PATCH V3 3/6] vDPA/ifcvf: rename original IFCVF dev ids to N3000 ids

2021-03-10 Thread Zhu Lingshan
On 3/11/2021 11:25 AM, Jason Wang wrote: On 2021/3/10 5:00 下午, Zhu Lingshan wrote: IFCVF driver probes multiple types of devices now, to distinguish the original device driven by IFCVF from others, it is renamed as "N3000". Signed-off-by: Zhu Lingshan ---   drivers/vdpa/ifcvf/ifcvf_base.h

Re: [PATCH V3 1/6] vDPA/ifcvf: get_vendor_id returns a device specific vendor id

2021-03-10 Thread Zhu Lingshan
On 3/11/2021 11:23 AM, Jason Wang wrote: On 2021/3/10 5:00 下午, Zhu Lingshan wrote: In this commit, ifcvf_get_vendor_id() will return a device specific vendor id of the probed pci device than a hard code. Signed-off-by: Zhu Lingshan ---   drivers/vdpa/ifcvf/ifcvf_main.c | 5 -   1 file c

Re: [PATCH V3 6/6] vDPA/ifcvf: verify mandatory feature bits for vDPA

2021-03-10 Thread Zhu Lingshan
On 3/11/2021 11:20 AM, Jason Wang wrote: On 2021/3/10 5:00 下午, Zhu Lingshan wrote: vDPA requres VIRTIO_F_ACCESS_PLATFORM as a must, this commit examines this when set features. Signed-off-by: Zhu Lingshan ---   drivers/vdpa/ifcvf/ifcvf_base.c | 8   drivers/vdpa/ifcvf/ifcvf_base.h

[PATCH] net/qlcnic: Fix a use after free in qlcnic_83xx_get_minidump_template

2021-03-10 Thread Lv Yunlong
In qlcnic_83xx_get_minidump_template, fw_dump->tmpl_hdr was freed by vfree(). But unfortunately, it is used when extended is true. Fixes: 7061b2bdd620e ("qlogic: Deletion of unnecessary checks before two function calls") Signed-off-by: Lv Yunlong --- drivers/net/ethernet/qlogic/qlcnic/qlcnic_mi

Re: [PATCH 3/3] net: dsa: mt7530: setup core clock even in TRGMII mode

2021-03-10 Thread Ilya Lipnitskiy
Hi Florian, On Wed, Mar 10, 2021 at 7:20 PM Florian Fainelli wrote: > > > > On 3/10/2021 7:17 PM, Ilya Lipnitskiy wrote: > > Hi Vladimir, > > > > On Wed, Mar 10, 2021 at 3:10 PM Vladimir Oltean wrote: > >> > >> Hello Ilya, > >> > >> On Wed, Mar 10, 2021 at 01:14:20PM -0800, Ilya Lipnitskiy wrote

[net-next 2/2] tipc: clean up warnings detected by sparse

2021-03-10 Thread Hoang Huu Le
This patch fixes the following warning from sparse: net/tipc/monitor.c:263:35: warning: incorrect type in assignment (different base types) net/tipc/monitor.c:263:35:expected unsigned int net/tipc/monitor.c:263:35:got restricted __be32 [usertype] [...] net/tipc/node.c:374:13: warning: con

[net-next 1/2] tipc: convert dest node's address to network order

2021-03-10 Thread Hoang Huu Le
From: Hoang Le (struct tipc_link_info)->dest is in network order (__be32), so we must convert the value to network order before assigning. The problem detected by sparse: net/tipc/netlink_compat.c:699:24: warning: incorrect type in assignment (different base types) net/tipc/netlink_compat.c:699

Re: [PATCH net 2/3] net: phy: broadcom: Only set BMCR.PDOWN to suspend

2021-03-10 Thread Florian Fainelli
On 3/10/21 2:56 PM, Florian Fainelli wrote: > On 3/10/21 1:43 PM, Heiner Kallweit wrote: >> On 10.03.2021 22:15, Florian Fainelli wrote: >>> On 3/10/21 1:07 PM, Heiner Kallweit wrote: On 10.03.2021 21:41, Florian Fainelli wrote: > B50212E PHYs have been observed to get into an incorrect st

Re: [PATCH bpf-next 05/10] libbpf: add BPF static linker APIs

2021-03-10 Thread Andrii Nakryiko
On Wed, Mar 10, 2021 at 6:34 PM Alexei Starovoitov wrote: > > On Tue, Mar 09, 2021 at 08:04:26PM -0800, Andrii Nakryiko wrote: > > + > > + struct btf *strtab_btf; /* we use struct btf to manage strings */ > ... > > + str_off = btf__add_str(linker->strtab_btf, sec->sec_name); > > + sec-

Re: [PATCH V3 3/6] vDPA/ifcvf: rename original IFCVF dev ids to N3000 ids

2021-03-10 Thread Jason Wang
On 2021/3/10 5:00 下午, Zhu Lingshan wrote: IFCVF driver probes multiple types of devices now, to distinguish the original device driven by IFCVF from others, it is renamed as "N3000". Signed-off-by: Zhu Lingshan --- drivers/vdpa/ifcvf/ifcvf_base.h | 8 drivers/vdpa/ifcvf/ifcvf_main

[RFC net-next v2 3/3] devlink: add more failure modes

2021-03-10 Thread Jakub Kicinski
>> Pending vendors adding the right reporters. << Extend the applicability of devlink health reporters beyond what can be locally remedied. Add failure modes which require re-flashing the NVM image or HW changes. The expectation is that driver will call devlink_health_reporter_state_update() to p

[RFC net-next v2 1/3] devlink: move health state to uAPI

2021-03-10 Thread Jakub Kicinski
Move the health states into uAPI, so applications can use them. Note that we need to change the name of the enum because user space is likely already defining the same values. E.g. iproute2 does. Use this opportunity to shorten the names. Signed-off-by: Jakub Kicinski --- .../net/ethernet/broa

[RFC net-next v2 2/3] devlink: health: add remediation type

2021-03-10 Thread Jakub Kicinski
Currently devlink health does not give user any clear information of what kind of remediation ->recover callback will perform. This makes it difficult to understand the impact of enabling auto- -remediation, and the severity of the error itself. To allow users to make more informed decision add a

Re: [PATCH V3 1/6] vDPA/ifcvf: get_vendor_id returns a device specific vendor id

2021-03-10 Thread Jason Wang
On 2021/3/10 5:00 下午, Zhu Lingshan wrote: In this commit, ifcvf_get_vendor_id() will return a device specific vendor id of the probed pci device than a hard code. Signed-off-by: Zhu Lingshan --- drivers/vdpa/ifcvf/ifcvf_main.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff

Re: [PATCH net] net: dsa: mt7530: setup core clock even in TRGMII mode

2021-03-10 Thread Florian Fainelli
On 3/10/2021 5:21 PM, Ilya Lipnitskiy wrote: > A recent change to MIPS ralink reset logic made it so mt7530 actually > resets the switch on platforms such as mt7621 (where bit 2 is the reset > line for the switch). That exposed an issue where the switch would not > function properly in TRGMII mo

Re: [PATCH 3/3] net: dsa: mt7530: setup core clock even in TRGMII mode

2021-03-10 Thread Florian Fainelli
On 3/10/2021 7:17 PM, Ilya Lipnitskiy wrote: > Hi Vladimir, > > On Wed, Mar 10, 2021 at 3:10 PM Vladimir Oltean wrote: >> >> Hello Ilya, >> >> On Wed, Mar 10, 2021 at 01:14:20PM -0800, Ilya Lipnitskiy wrote: >>> 3f9ef7785a9c ("MIPS: ralink: manage low reset lines") made it so mt7530 >>> actual

Re: [PATCH V3 6/6] vDPA/ifcvf: verify mandatory feature bits for vDPA

2021-03-10 Thread Jason Wang
On 2021/3/10 5:00 下午, Zhu Lingshan wrote: vDPA requres VIRTIO_F_ACCESS_PLATFORM as a must, this commit examines this when set features. Signed-off-by: Zhu Lingshan --- drivers/vdpa/ifcvf/ifcvf_base.c | 8 drivers/vdpa/ifcvf/ifcvf_base.h | 1 + drivers/vdpa/ifcvf/ifcvf_main.c | 5

Re: [PATCH 3/3] net: dsa: mt7530: setup core clock even in TRGMII mode

2021-03-10 Thread Ilya Lipnitskiy
Hi Vladimir, On Wed, Mar 10, 2021 at 3:10 PM Vladimir Oltean wrote: > > Hello Ilya, > > On Wed, Mar 10, 2021 at 01:14:20PM -0800, Ilya Lipnitskiy wrote: > > 3f9ef7785a9c ("MIPS: ralink: manage low reset lines") made it so mt7530 > > actually resets the switch on platforms such as mt7621 (where bi

[PATCH net-next v2] net: sock: simplify tw proto registration

2021-03-10 Thread xiangxia . m . yue
From: Tonghao Zhang Introduce the new function tw_prot_init (inspired by req_prot_init) to simplify "proto_register" function. tw_prot_cleanup will take care of a partially initialized timewait_sock_ops. Signed-off-by: Tonghao Zhang Reviewed-by: Alexander Duyck --- net/core/sock.c | 44 +

Re: [PATCH] net: sock: simplify tw proto registration

2021-03-10 Thread Tonghao Zhang
On Wed, Mar 10, 2021 at 10:42 AM Alexander Duyck wrote: > > On Tue, Mar 9, 2021 at 5:48 PM Tonghao Zhang wrote: > > > > On Wed, Mar 10, 2021 at 1:39 AM Alexander Duyck > > wrote: > > > > > > On Mon, Mar 8, 2021 at 7:15 PM wrote: > > > > > > > > From: Tonghao Zhang > > > > > > > > Introduce a n

Re: [PATCH 3/3] net: dsa: mt7530: setup core clock even in TRGMII mode

2021-03-10 Thread Ilya Lipnitskiy
Hi Vladimir, On Wed, Mar 10, 2021 at 3:10 PM Vladimir Oltean wrote: > > Hello Ilya, > > On Wed, Mar 10, 2021 at 01:14:20PM -0800, Ilya Lipnitskiy wrote: > > 3f9ef7785a9c ("MIPS: ralink: manage low reset lines") made it so mt7530 > > actually resets the switch on platforms such as mt7621 (where bi

Re: [PATCH bpf-next 05/10] libbpf: add BPF static linker APIs

2021-03-10 Thread Alexei Starovoitov
On Tue, Mar 09, 2021 at 08:04:26PM -0800, Andrii Nakryiko wrote: > + > + struct btf *strtab_btf; /* we use struct btf to manage strings */ ... > + str_off = btf__add_str(linker->strtab_btf, sec->sec_name); > + sec->shdr->sh_name = str_off; That bit took me an hour to grok. That single

RE: [PATCH net-next] net: add a helper to avoid issues with HW TX timestamping and SO_TXTIME

2021-03-10 Thread Po Liu
Hi Can it just move skb->tstamp = ktime_set(0, 0); into skb_tstamp_tx(skb, &shhwtstamps); if it always need to clear for HW tstamp setting. > -Original Message- > From: Vladimir Oltean > Sent: 2021年3月10日 22:51 > To: Jakub Kicinski ; netdev@vger.kernel.org; Po Liu > ; Claudiu Man

Re: Re: [RFC v4 07/11] vduse: Introduce VDUSE - vDPA Device in Userspace

2021-03-10 Thread Yongji Xie
On Wed, Mar 10, 2021 at 8:58 PM Jason Wang wrote: > > > On 2021/2/23 7:50 下午, Xie Yongji wrote: > > + > > + switch (cmd) { > > + case VDUSE_IOTLB_GET_FD: { > > + struct vduse_iotlb_entry entry; > > + struct vhost_iotlb_map *map; > > + struct vdpa_map_fil

Re: [PATCH net-next 2/6] ionic: implement Rx page reuse

2021-03-10 Thread Alexander Duyck
On Wed, Mar 10, 2021 at 11:28 AM Shannon Nelson wrote: > > Rework the Rx buffer allocations to use pages twice when using > normal MTU in order to cut down on buffer allocation and mapping > overhead. > > Instead of tracking individual pages, in which we may have > wasted half the space when using

[PATCH net-next 0/2] net: hns3: two updates for -next

2021-03-10 Thread Huazhong Tan
This series includes two updates for the HNS3 ethernet driver. Yufeng Mo (2): net: hns3: use FEC capability queried from firmware net: hns3: use pause capability queried from firmware drivers/net/ethernet/hisilicon/hns3/hnae3.h| 4 drivers/net/ethernet/hisilicon/hns3/hns3_debug

[PATCH net-next 2/2] net: hns3: use pause capability queried from firmware

2021-03-10 Thread Huazhong Tan
From: Yufeng Mo For maintainability and compatibility, add support to use pause capability queried from firmware, and add debugfs support to dump this capability. Signed-off-by: Yufeng Mo Signed-off-by: Huazhong Tan --- drivers/net/ethernet/hisilicon/hns3/hnae3.h | 4 driver

[PATCH net-next 1/2] net: hns3: use FEC capability queried from firmware

2021-03-10 Thread Huazhong Tan
From: Yufeng Mo For maintainability and compatibility, add support to use FEC capability queried from firmware. Signed-off-by: Yufeng Mo Signed-off-by: Huazhong Tan --- drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.c | 6 +- drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.h

[PATCH net-next,v2 1/3] net: dsa: mt7530: setup core clock even in TRGMII mode

2021-03-10 Thread Ilya Lipnitskiy
A recent change to MIPS ralink reset logic made it so mt7530 actually resets the switch on platforms such as mt7621 (where bit 2 is the reset line for the switch). That exposed an issue where the switch would not function properly in TRGMII mode after a reset. Reconfigure core clock in TRGMII mode

[PATCH net-next,v2 2/3] net: dsa: mt7530: clean up redundant clock enables

2021-03-10 Thread Ilya Lipnitskiy
Two minor changes: - In RGMII mode, the REG_GSWCK_EN bit of CORE_TRGMII_GSW_CLK_CG gets set three times in a row. In TRGMII mode, two times. Simplify the code and only set it once for both modes. - When disabling PLL, there is no need to call core_write_mmd_indirect directly, use the core_w

[PATCH net-next,v2 3/3] net: dsa: mt7530: disable TRGMII clock at reconfigure

2021-03-10 Thread Ilya Lipnitskiy
Disable both core and TRGMII Tx clocks prior to reconfiguring. Previously, only the core clock was disabled, but not TRGMII Tx clock. So disable both, then configure them, then re-enable both, for consistency. Reword the comment about core_write_mmd_indirect for clarity. Tested on Ubiquiti ER-X r

[PATCH] esp6: remove a duplicative condition

2021-03-10 Thread angkery
From: Junlin Yang Fixes coccicheck warnings: ./net/ipv6/esp6_offload.c:319:32-34: WARNING !A || A && B is equivalent to !A || B Signed-off-by: Junlin Yang --- net/ipv6/esp6_offload.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/net/ipv6/esp6_offload.c b/net/ipv6/esp6_off

Re: [RFC PATCH 01/10] ethtool: Add common function for filling out strings

2021-03-10 Thread Jakub Kicinski
On Wed, 10 Mar 2021 17:35:17 -0800 Alexander Duyck wrote: > From: Alexander Duyck > > Add a function to handle the common pattern of printing a string into the > ethtool strings interface and incrementing the string pointer by the > ETH_GSTRING_LEN. Most of the drivers end up doing this and sever

[RFC PATCH 10/10] ionic: Update driver to use ethtool_gsprintf

2021-03-10 Thread Alexander Duyck
From: Alexander Duyck Update the ionic driver to make use of ethtool_gsprintf. In addition add separate functions for Tx/Rx stats strings in order to reduce the total amount of indenting needed in the driver code. Signed-off-by: Alexander Duyck --- drivers/net/ethernet/pensando/ionic/ionic_sta

[RFC PATCH 09/10] bna: Update driver to use ethtool_gsprintf

2021-03-10 Thread Alexander Duyck
From: Alexander Duyck Update the bnad_get_strings to make use of ethtool_gsprintf and avoid unnecessary line wrapping. To do this we invert the logic for the string set test and instead exit immediately if we are not working with the stats strings. In addition the function is broken up into subfu

[RFC PATCH 05/10] ena: Update driver to use ethtool_gsprintf

2021-03-10 Thread Alexander Duyck
From: Alexander Duyck Replace instances of snprintf or memcpy with a pointer update with ethtool_gsprintf. Signed-off-by: Alexander Duyck --- drivers/net/ethernet/amazon/ena/ena_ethtool.c | 25 +++-- 1 file changed, 11 insertions(+), 14 deletions(-) diff --git a/drivers/

[RFC PATCH 06/10] netvsc: Update driver to use ethtool_gsprintf

2021-03-10 Thread Alexander Duyck
From: Alexander Duyck Replace instances of sprintf or memcpy with a pointer update with ethtool_gsprintf. Signed-off-by: Alexander Duyck --- drivers/net/hyperv/netvsc_drv.c | 33 +++-- 1 file changed, 11 insertions(+), 22 deletions(-) diff --git a/drivers/net/hyp

[RFC PATCH 07/10] virtio_net: Update driver to use ethtool_gsprintf

2021-03-10 Thread Alexander Duyck
From: Alexander Duyck Update the code to replace instances of snprintf and a pointer update with just calling ethtool_gsprintf. Also replace the char pointer with a u8 pointer to avoid having to recast the pointer type. Signed-off-by: Alexander Duyck --- drivers/net/virtio_net.c | 18 ++

[RFC PATCH 08/10] vmxnet3: Update driver to use ethtool_gsprintf

2021-03-10 Thread Alexander Duyck
From: Alexander Duyck So this patch actually does 3 things. First it removes a stray white space at the start of the variable declaration in vmxnet3_get_strings. Second it flips the logic for the string test so that we exit immediately if we are not looking for the stats strings. Doing this we

[RFC PATCH 04/10] hisilicon: Update drivers to use ethtool_gsprintf

2021-03-10 Thread Alexander Duyck
From: Alexander Duyck Update the hisilicon drivers to make use of ethtool_gsprintf. The general idea is to reduce code size and overhead by replacing the repeated pattern of string printf statements and ETH_STRING_LEN counter increments. Signed-off-by: Alexander Duyck --- drivers/net/ethernet/

[RFC PATCH 03/10] nfp: Replace nfp_pr_et with ethtool_gsprintf

2021-03-10 Thread Alexander Duyck
From: Alexander Duyck The nfp_pr_et function is nearly identical to ethtool_gsprintf except for the fact that it passes the pointer by value and as a return whereas ethtool_gsprintf passes it as a pointer. Since they are so close just update nfp to make use of ethtool_gsprintf Signed-off-by: Al

[RFC PATCH 01/10] ethtool: Add common function for filling out strings

2021-03-10 Thread Alexander Duyck
From: Alexander Duyck Add a function to handle the common pattern of printing a string into the ethtool strings interface and incrementing the string pointer by the ETH_GSTRING_LEN. Most of the drivers end up doing this and several have implemented their own versions of this function so it would

  1   2   3   4   5   >