[PATCH net-next] drivers: net: Remove unnecessary semicolon

2019-03-01 Thread Yue Haibing
From: YueHaibing drivers/net/dsa/mt7530.c:649:3-4: Unneeded semicolon drivers/net/ethernet/cisco/enic/enic_clsf.c:35:2-3: Unneeded semicolon drivers/net/ethernet/faraday/ftgmac100.c:1640:2-3: Unneeded semicolon drivers/net/ethernet/mediatek/mtk_eth_soc.c:229:2-3: Unneeded semicolon drivers/net/us

[patch net-next 1/5] net: replace ndo_get_devlink for ndo_get_devlink_port

2019-03-01 Thread Jiri Pirko
From: Jiri Pirko Follow-up patch is going to need a devlink port instance according to a netdev. Devlink port instance should be always available when devlink is used. So change the recently introduced ndo_get_devlink to ndo_get_devlink_port. With that, adjust the wrapper for the only user to get

[patch net-next 0/5] net: call for phys_port_name into devlink directly is possible

2019-03-01 Thread Jiri Pirko
From: Jiri Pirko phys_port_name may be assembled by a helper in devlink. It is currently the case only for mlxsw driver. Benefit from the get_devlink_port ndo and call into devlink directly from dev_get_phys_port_name(). That saves the trip to the driver, simplifies the code and makes it similar

[patch net-next 5/5] net: devlink: remove unused devlink_port_get_phys_port_name() function

2019-03-01 Thread Jiri Pirko
From: Jiri Pirko Now it is unused, remove it. Signed-off-by: Jiri Pirko --- include/net/devlink.h | 9 - net/core/devlink.c| 7 --- 2 files changed, 16 deletions(-) diff --git a/include/net/devlink.h b/include/net/devlink.h index ae2cd34da99e..227c453cc20e 100644 --- a/include

[patch net-next 4/5] mlxsw: Remove ndo_get_phys_port_name implementation

2019-03-01 Thread Jiri Pirko
From: Jiri Pirko Rely on the previously introduce fallback and let the core directly call devlink in order to get the physical port name. Signed-off-by: Jiri Pirko --- drivers/net/ethernet/mellanox/mlxsw/core.c | 10 -- drivers/net/ethernet/mellanox/mlxsw/core.h | 2 -- driver

[patch net-next 2/5] net: devlink: introduce devlink_compat_phys_port_name_get()

2019-03-01 Thread Jiri Pirko
From: Jiri Pirko Introduce devlink_compat_phys_port_name_get() helper that gets the physical port name for specified netdevice according to devlink port attributes. Call this helper from dev_get_phys_port_name() in case ndo_get_phys_port_name is not defined. Signed-off-by: Jiri Pirko --- inclu

[patch net-next 3/5] mlxsw: spectrum: Implement ndo_get_devlink_port

2019-03-01 Thread Jiri Pirko
From: Jiri Pirko In order for devlink compat functions to work, implement ndo_get_devlink_port. Signed-off-by: Jiri Pirko --- drivers/net/ethernet/mellanox/mlxsw/core.c | 12 drivers/net/ethernet/mellanox/mlxsw/core.h | 3 +++ drivers/net/ethernet/mellanox/mlxsw/spectrum.

[PATCH v3 3/6] ethtool: introduce new ioctl for per-queue settings

2019-03-01 Thread Jeff Kirsher
From: Nicholas Nunley Introduce a new ioctl for applying per-queue parameters. Users can apply commands to specific queues by setting SUB_COMMAND and queue_mask with the following ethtool command: ethtool -Q|--per-queue DEVNAME [queue_mask %x] SUB_COMMAND If queue_mask is not set, the SUB_COMM

[PATCH v3 1/6] ethtool: move option parsing related code into function

2019-03-01 Thread Jeff Kirsher
From: Nicholas Nunley Move option parsing code into find_option function. No behavior changes. Based on patch by Kan Liang Signed-off-by: Nicholas Nunley --- ethtool.c | 49 +++-- 1 file changed, 31 insertions(+), 18 deletions(-) diff --git a/eth

[PATCH v3 5/6] ethtool: support per-queue sub command --coalesce

2019-03-01 Thread Jeff Kirsher
From: Nicholas Nunley This patch adds the ability to configure the coalesce settings from do_scoalesce on a per-queue basis. For each masked queue the current settings are read, modified, and written back to the kernel. Example: $ sudo ./ethtool --per-queue eth5 queue_mask 0x1 --coalesce rx-

RE: [PATCH v3] net: e1000e: add MAC address kernel cmd line parameter

2019-03-01 Thread Flavio Suligoi
> >> > Hi Flavio > >> > > >> > u-boot should be able to write the MAC address in the correct part of > >> > device tree. Boards have been doing this a long time. > >> > > >> > Module parameters are considered bad. You should only do it if you > >> > have no other option. Here you do have another op

[PATCH v3 2/6] ethtool: move cmdline_coalesce out of do_scoalesce

2019-03-01 Thread Jeff Kirsher
From: Nicholas Nunley Move the definition of cmdline_coalesce out of do_scoalesce and into a macro so it can be resused across functions. No behavior change. Based on patch by Kan Liang Signed-off-by: Nicholas Nunley --- ethtool.c | 142 --

[PATCH v3 4/6] ethtool: support per-queue sub command --show-coalesce

2019-03-01 Thread Jeff Kirsher
From: Nicholas Nunley Get all masked queues' coalesce settings from kernel and dump them one by one. Example: $ sudo ./ethtool --per-queue eth5 queue_mask 0x11 --show-coalesce Queue: 0 Adaptive RX: off TX: off stats-block-usecs: 0 sample-interval: 0 pkt-rate-low: 0 pkt-rate-high: 0 rx

[PATCH v3 6/6] ethtool: fix up dump_coalesce output to match actual option names

2019-03-01 Thread Jeff Kirsher
From: Nicholas Nunley When the coalesce settings are printed with --show-coalesce a few of the option names lack the pluralization that is present in the man page and usage info, but are otherwise identical. This inconsistency could lead to some confusion if a user attempts to set the coalesce s

Re: [PATCH RFC] mac80211: Use IFF_ECHO to force delivery of tx_status frames

2019-03-01 Thread Johannes Berg
> Let us briefly describe our test setup to ensure everyone on this mailing > list is one the same page. > > Our general setup looks like this: > 1 $ iw wlp1s0 info > Interface wlp1s0 > ifindex 5 > wdev 0x1 > addr 4c:5e:0c:11:43:ac > type managed > wiphy 0 > txp

Re: [PATCH] netfilter: nf_ct_helper: Fix possible panic when nf_conntrack_helper_unregister is used in an unloadable module

2019-03-01 Thread Sergei Shtylyov
Hello! On 01.03.2019 8:56, Su Yanjun wrote: From: Su Yanjun Because nf_conntrack_helper_unregister maybe used in an unloadable module, it uses 'synchronize_rcu' which may cause kernel panic. According to the artical: Article? RCU and Unloadable Modules https://lwn.net/Articles/217484/

Re: [PATCH bpf-next v2 2/7] bpf: add program side {rd,wr}only support

2019-03-01 Thread Daniel Borkmann
On 03/01/2019 04:51 AM, Jakub Kicinski wrote: > On Fri, 1 Mar 2019 00:18:24 +0100, Daniel Borkmann wrote: >> This work adds two new map creation flags BPF_F_RDONLY_PROG >> and BPF_F_WRONLY_PROG in order to allow for read-only or >> write-only BPF maps from a BPF program side. >> >> Today we have B

Re: [PATCH bpf-next v2 3/7] bpf, obj: allow . char as part of the name

2019-03-01 Thread Daniel Borkmann
On 03/01/2019 06:52 AM, Andrii Nakryiko wrote: > On Thu, Feb 28, 2019 at 3:31 PM Daniel Borkmann wrote: >> >> Trivial addition to allow '.' aside from '_' as "special" characters >> in the object name. Used to name maps from loader side as ".bss", >> ".data", ".rodata". >> >> Signed-off-by: Daniel

Re: [PATCH] netfilter: nf_ct_helper: Fix possible panic when nf_conntrack_helper_unregister is used in an unloadable module

2019-03-01 Thread Su Yanjun
On 2019/3/1 16:43, Sergei Shtylyov wrote: Hello! On 01.03.2019 8:56, Su Yanjun wrote: From: Su Yanjun Because nf_conntrack_helper_unregister maybe used in an unloadable module, it uses 'synchronize_rcu' which may cause kernel panic. According to the artical:    Article? I got it. R

Re: stmmac / meson8b-dwmac

2019-03-01 Thread Jose Abreu
Hi Simon, On 2/27/2019 7:02 PM, Simon Huelck wrote: > Hi, > > > the thing is , that im not a stmmac developer. Yes , maybe i can bissect > it and yes you are lucky since im a C-developer since a long time for > embedded systems. > > The problem is that i dont understand the structure of stmmac

Re: [PATCH bpf-next v2 1/7] bpf: implement lookup-free direct value access

2019-03-01 Thread Daniel Borkmann
On 03/01/2019 06:46 AM, Andrii Nakryiko wrote: > On Thu, Feb 28, 2019 at 3:31 PM Daniel Borkmann wrote: >> >> This generic extension to BPF maps allows for directly loading an >> address residing inside a BPF map value as a single BPF ldimm64 >> instruction. > > This is great! I'm going to review

[PATCH net-next] cxgb4: Prefix adapter flags with CXGB4

2019-03-01 Thread Arjun Vynipadath
Some of these macros were conflicting with global namespace, hence prefixing them with CXGB4. Signed-off-by: Arjun Vynipadath Signed-off-by: Vishal Kulkarni --- drivers/net/ethernet/chelsio/cxgb4/cudbg_lib.c | 2 +- drivers/net/ethernet/chelsio/cxgb4/cxgb4.h | 24 ++--- drivers/n

[PATCH net-next] cxgb4vf: Prefix adapter flags with CXGB4VF

2019-03-01 Thread Arjun Vynipadath
Some of these macros were conflicting with global namespace, hence prefixing them with CXGB4VF. Signed-off-by: Arjun Vynipadath Signed-off-by: Vishal Kulkarni --- drivers/net/ethernet/chelsio/cxgb4vf/adapter.h | 12 ++-- .../net/ethernet/chelsio/cxgb4vf/cxgb4vf_main.c| 68 +++---

[PATCH net-next v2 1/2] cxgb4: Add VF Link state support

2019-03-01 Thread Arjun Vynipadath
Use ndo_set_vf_link_state to control the link states associated with the virtual interfaces. Signed-off-by: Arjun Vynipadath Signed-off-by: Vishal Kulkarni --- v2: - Using reverse christmas tree for variable declaration - Renamed FW_LINK* macros for vf link states to make it more clean. --- dri

[PATCH net-next v2 0/2]cxgb4/cxgb4vf: VF link state support

2019-03-01 Thread Arjun Vynipadath
This series of patches adds support for ndo_set_vf_link_state in cxgb4 driver. Patch 1 implements ndo_set_vf_link_state Patch 2 reverts the existing force_link_up behaviour for cxgb4vf driver. v2: - Using reverse christmas tree for variable declaration in Patch 1 - Patch 2 has no change Arjun Vy

[PATCH net-next v2 2/2] cxgb4vf: Revert force link up behaviour

2019-03-01 Thread Arjun Vynipadath
Reverting force link up changes since this behaviour can be achieved using VF link state feature. Reverts: commit 0913667ab3ad ("cxgb4vf: Forcefully link up virtual interfaces") Signed-off-by: Arjun Vynipadath Signed-off-by: Vishal Kulkarni --- v2: - No changes --- drivers/net/ethernet/chelsio

Re: [PATCH net-next] net: dsa: Do not configure VLAN ID 0

2019-03-01 Thread Michal Vokáč
On 01. 03. 19 0:49, Florian Fainelli wrote: Because we skip the prepare phase, we would not get a chance to have the port_vlan_prepare() callback return -EOPNOTSUPP and tell us about that. This causes problems with mv88e6xxx which specifically checks for VLAN ID = 0. Turns out we do not actually

[PATCH net-next] cxgb4vf: Call netif_carrier_off properly in pci_probe

2019-03-01 Thread Arjun Vynipadath
netif_carrier_off() should be called only after register_netdev(). Signed-off-by: Arjun Vynipadath Signed-off-by: Vishal Kulkarni --- drivers/net/ethernet/chelsio/cxgb4vf/cxgb4vf_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/chelsio/cxgb4vf/cxgb

net/strparser/strparser.c:526 strp_done+0x41/0x50

2019-03-01 Thread Naresh Kamboju
Do you see this Kernel warning while running selftests bpf tes_sock on x86_64 running Linux kernel version 5.0.0-rc8-next-20190301 ? selftests: bpf: test_sock Test case: bind4 load with invalid access: src_ip6 .. [PASS] Test case: bind4 load with invalid access: mark .. [PASS] Test case: bind6

Re: [PATCH bpf-next v2 5/7] bpf, libbpf: support global data/bss/rodata sections

2019-03-01 Thread Daniel Borkmann
On 03/01/2019 07:53 AM, Andrii Nakryiko wrote: > On Thu, Feb 28, 2019 at 3:31 PM Daniel Borkmann wrote: >> >> This work adds BPF loader support for global data sections >> to libbpf. This allows to write BPF programs in more natural >> C-like way by being able to define global variables and const

[PATCH v3 1/4] net: macb: Check MDIO state before read/write and use timeouts

2019-03-01 Thread Harini Katakam
Replace the while loop in MDIO read/write functions with a timeout. In addition, add a check for MDIO bus busy before initiating a new operation as well to make sure there is no ongoing MDIO operation. Signed-off-by: Shubhrajyoti Datta Signed-off-by: Sai Pavan Boddu Signed-off-by: Harini Katakam

[PATCH v3 2/4] net: macb: Support clock management for tsu_clk

2019-03-01 Thread Harini Katakam
TSU clock needs to be enabled/disabled as per support in devicetree and it should also be controlled during suspend/resume (WOL has no dependency on this clock). Signed-off-by: Harini Katakam --- v3 and v2: No changes drivers/net/ethernet/cadence/macb.h | 3 ++- drivers/net/ethernet/caden

[PATCH v3 4/4] net: macb: Add support for suspend/resume with full power down

2019-03-01 Thread Harini Katakam
When macb device is suspended and system is powered down, the clocks are removed and hence macb should be closed gracefully and restored upon resume. This patch does the same by switching off the net device, suspending phy and performing necessary cleanup of interrupts and BDs. Upon resume, all the

[PATCH v3 3/4] net: macb: Add pm runtime support

2019-03-01 Thread Harini Katakam
Add runtime pm functions and move clock handling there. Add runtime PM calls to mdio functions to allow for active mdio bus. Signed-off-by: Shubhrajyoti Datta Signed-off-by: Harini Katakam --- v3 changes: Fix exit path using goto v2 changes: Allow for mdio bus to be active Changes from RFC: Up

[PATCH v2 0/4] Macb power management support for ZynqMP

2019-03-01 Thread Harini Katakam
This series adds support for macb suspend/resume with system power down. In relation to the above, this series also updates mdio_read/write function for PM and adds tsu clock management. Harini Katakam (4): net: macb: Check MDIO state before read/write and use timeouts net: macb: Support clock

[PATCH net 2/2] net: phy: Use C45 Helpers in PHY_FORCING state

2019-03-01 Thread Jose Abreu
When using a C45 PHY that is in PHY_FORCING state we are currently not taking into account that this kind of PHY has different update_link functions. Use the C45 Helpers instead or the driver built-in read_status() helper, if possible. Signed-off-by: Jose Abreu Cc: Andrew Lunn Cc: Florian Faine

[PATCH net 0/2] Use C45 Helpers when possible

2019-03-01 Thread Jose Abreu
For -net. Please review! Cc: Andrew Lunn Cc: Florian Fainelli Cc: "David S. Miller" Cc: Joao Pinto Jose Abreu (2): net: phy: Use C45 Helpers in phy_read_status() net: phy: Use C45 Helpers in PHY_FORCING state drivers/net/phy/phy.c | 2 +- include/linux/phy.h | 15 +++ 2 f

[PATCH net-next v2 07/15] net: mvpp2: fix the computation of the RXQs

2019-03-01 Thread Antoine Tenart
The patch fixes the computation of RXQs being used by the PPv2 driver, which is set depending on the PPv2 engine version and the queue mode used. There are three cases: - PPv2.1: 1 RXQ per CPU. - PPV2.2 with MVPP2_QDIST_MULTI_MODE: 1 RXQ per CPU. - PPv2.2 with MVPP2_QDIST_SINGLE_MODE: 1 RXQ is sha

[PATCH net 1/2] net: phy: Use C45 Helpers in phy_read_status()

2019-03-01 Thread Jose Abreu
Currently phy_read_status() considers that either the PHY driver has the read_status() callback or uses the generic callback. For C45 PHYs we need to use the gen10g_read_status() callback. Signed-off-by: Jose Abreu Cc: Andrew Lunn Cc: Florian Fainelli Cc: "David S. Miller" Cc: Joao Pinto ---

[PATCH net-next v2 00/15] net: mvpp2: fixes and improvements

2019-03-01 Thread Antoine Tenart
Hello, This series aims to improve the Marvell PPv2 driver and to fix various issues we encountered while testing the ports in many different configurations. The series is based on top of Russell PPv2 phylink rework and improvement. I'm not sending a v2 of the previous fixes series as half the pa

[PATCH net-next v2 13/15] net: mvpp2: reset the MACs when reconfiguring a port

2019-03-01 Thread Antoine Tenart
This patch makes sure both PPv2 MACs (GMAC + XLG MAC) are set in reset while a port is reconfigured. This is done so that we make sure a MAC is in a reset state when not used, as only one of the two will be set out of reset after the port is configured properly. Signed-off-by: Antoine Tenart ---

[PATCH net-next v2 09/15] net: mvpp2: always disable both MACs when disabling a port

2019-03-01 Thread Antoine Tenart
This patch modifies the port_disable() helper to always disable both the GMAC and the XLG MAC when called. At boot time we do not know of a port was enabled in the firmware/bootloader, and if so what mode was used (hence which of the two MACs was used). This also help in implementing a logic where

[PATCH net-next v2 15/15] net: mvpp2: set the GMAC, XLG MAC, XPCS and MPCS in reset when a port is down

2019-03-01 Thread Antoine Tenart
This patch adds calls in the stop() helper to ensure both MACs and both PCS blocks are set in reset when the user manually sets a port down. This is done so that we have the exact same block reset states at boot time and when a port is set down. Signed-off-by: Antoine Tenart --- drivers/net/ethe

[PATCH net-next v2 12/15] net: mvpp2: rework the XLG MAC reset handling

2019-03-01 Thread Antoine Tenart
This patch reworks the way the XLG MAC is set in reset: the XLG MAC is set in reset at probe time and taken out of this state only when used. The idea is to move forward a situation where only the blocks used are taken out of reset. This also has the effect to handle the GMAC and the XLG MAC in a s

[PATCH net-next v2 14/15] net: mvpp2: set the XPCS and MPCS in reset when not used

2019-03-01 Thread Antoine Tenart
This patch sets both the XPCS and MPCS blocks in reset when they aren't used. This is done both at boot time and when reconfiguring a port mode. The advantage now is that only the PCS used is set out of reset when the port is configured (10GKR uses the MCPS while RXAUI uses the XPCS). Signed-off-b

[PATCH net-next v2 04/15] net: mvpp2: a port can be disabled even if we use the link IRQ

2019-03-01 Thread Antoine Tenart
We had a check in the mvpp2_mac_link_down() function (called by phylink) to avoid disabling the port when link interrupts are used. It turned out the interrupt can still be used with the port disabled. We can thus remove this check. Signed-off-by: Antoine Tenart --- drivers/net/ethernet/marvell/

[PATCH net-next v2 10/15] net: mvpp2: only update the XLG configuration when needed

2019-03-01 Thread Antoine Tenart
This patch improves the XLG configuration function, to only update the XLG configuration register when a change is needed. This helps not writing over and over the same XLG configuration each time phylink request the MAC to be configured. This mimics the GMAC configuration function. Signed-off-by:

[PATCH net-next v2 08/15] net: mvpp2: some AN fields require the link to be down when updated

2019-03-01 Thread Antoine Tenart
The GMAC configuration helper modifies values in the auto-negotiation register. Some of its values require the port to be forced down when modifying their values. This patches fixes the check made on the bit to be updated in this register, so that the port is forced down when needed. This fix cases

[PATCH net-next v2 11/15] net: mvpp2: force the XLG MAC link up or down when not using in-band

2019-03-01 Thread Antoine Tenart
This patch force the XLG MAC link state in the phylink link_up() and link_down() helpers when not using in-band auto-negotiation. This mimics what's already done for the GMAC and follows what's advised in the phylink documentation. Signed-off-by: Antoine Tenart --- drivers/net/ethernet/marvell/m

[PATCH net-next v2 06/15] net: mvpp2: fix validate for PPv2.1

2019-03-01 Thread Antoine Tenart
The Phylink validate function is the Marvell PPv2 driver makes a check on the GoP id. This is valid an has to be done when using PPv2.2 engines but makes no sense when using PPv2.1. The check done when using an RGMII interface makes sure the GoP id is not 0, but this breaks PPv2.1. Fixes it. Fixes

[PATCH net-next v2 05/15] net: mvpp2: reconfiguring the port interface is PPv2.2 specific

2019-03-01 Thread Antoine Tenart
This patch adds a check on the PPv2 version in-use not to reconfigure the port mode when an interface is updated when using PPv2.1 as the functions called are PPv2.2 specific. Signed-off-by: Antoine Tenart --- drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c | 14 ++ 1 file changed, 6

[PATCH net-next v2 02/15] net: mvpp2: update the port documentation regarding the GoP

2019-03-01 Thread Antoine Tenart
The Marvell PPv2 port structure stores the GoP id of a given port. This information is specific to PPv2.2, but cannot be used by PPv2.1. Update its comment to denote this specificity. Signed-off-by: Antoine Tenart --- drivers/net/ethernet/marvell/mvpp2/mvpp2.h | 2 +- 1 file changed, 1 insertion

[PATCH net-next v2 03/15] net: mvpp2: fix alignment of MVPP2_GMAC_CONFIG_MII_SPEED definition

2019-03-01 Thread Antoine Tenart
Cosmetic patch fix the alignment of the MVPP2_GMAC_CONFIG_MII_SPEED macro definition. Signed-off-by: Antoine Tenart --- drivers/net/ethernet/marvell/mvpp2/mvpp2.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/marvell/mvpp2/mvpp2.h b/drivers/net/etherne

[PATCH net-next v2 01/15] net: mvpp2: fix a typo in the header

2019-03-01 Thread Antoine Tenart
This cosmetic patch fixes a typo made in a comment in the Marvell PPv2 Ethernet driver header. Signed-off-by: Antoine Tenart --- drivers/net/ethernet/marvell/mvpp2/mvpp2.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/marvell/mvpp2/mvpp2.h b/drivers/ne

[PATCH net-next v2 0/3] net: phy: marvell10g: implement suspend/resume callbacks

2019-03-01 Thread Antoine Tenart
Hello, This series implements the suspend/resume callbacks in the marvell10g PHY driver: - When the PHY isn't used, it is set in low power mode. - At boot time we might now know the PHY status (as it's depending on the hardware configuration, or on what the previous stages configured), it is

[PATCH net-next v2 1/3] net: phy: marvell10g: implement suspend/resume callbacks

2019-03-01 Thread Antoine Tenart
This patch adds the suspend/resume callbacks for Marvell 10G PHYs. The three PCS (base-t, base-r and 1000base-x) are set in low power (the PCS are powered down) when the PHY isn't used. Signed-off-by: Antoine Tenart --- drivers/net/phy/marvell10g.c | 14 ++ 1 file changed, 14 inserti

[PATCH net-next v2 2/3] net: phy: marvell10g: add the suspend/resume callbacks for the 88x2210

2019-03-01 Thread Antoine Tenart
When the 88x2110 PHY support was added, the suspend and resume callbacks were forgotten. This patch adds them to the 88x2110 PHY callback definition. Signed-off-by: Antoine Tenart --- drivers/net/phy/marvell10g.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/net/phy/marvell10g.c

[PATCH net-next v2 3/3] net: phy: marvell10g: set the PHY in low power by default

2019-03-01 Thread Antoine Tenart
When the Marvell 10G PHYs are set out of reset, the LPOWER bit is set depending on an hardware configuration choice. We also do not know what is the PHY state at boot time. Hence, set the PHY in low power by default when this driver probes. Signed-off-by: Antoine Tenart --- drivers/net/phy/marve

Re: [PATCH RFC] net: marvell: mvpp2: phylink requires the link interrupt

2019-03-01 Thread Antoine Tenart
Hi Russell, I've been using this patch on my local branch for the past 3 weeks, and I saw no obvious issue so far. (I also used a similar patch before). Do you have pending questions regarding this patch? Otherwise I think you can sent it again without the RFC tag, with my Tested-by and/or Acked-

Question about setting speed and duplex failed after auto-negotiation disabled on marvell phy

2019-03-01 Thread liweihang
Hi all, We encountered a problem that if there are two devices in kernel v5.0 with marvell phy 88E1510 connect with each other directly, one with autoneg on and the other off. The one who has disabled auto-negotiation will failed on setting speed and duplex mode. Their speed and duplex mode will

Re: [RFC v2 3/6] i40e: use extack for bpf errors

2019-03-01 Thread Maciej Fijalkowski
On Thu, 28 Feb 2019 19:06:45 -0800 Jakub Kicinski wrote: > On Thu, 28 Feb 2019 13:54:38 -0800, Stephen Hemminger wrote: > > @@ -12140,12 +12144,14 @@ static int i40e_xdp(struct net_device *dev, > > struct i40e_netdev_priv *np = netdev_priv(dev); > > struct i40e_vsi *vsi = np->vsi; > > >

RE: [PATCH] dt-bindings: can: rcar_can: Add r8a774c0 support

2019-03-01 Thread Fabrizio Castro
Hello Mark, I am sorry to bother you. Do you think you can take this patch? Thanks, Fab > From: Fabrizio Castro > Sent: 13 December 2018 20:20 > Subject: [PATCH] dt-bindings: can: rcar_can: Add r8a774c0 support > > Document RZ/G2E (r8a774c0) SoC specific bindings. > > Signed-off-by: Fabrizio

RE: SOCKET_FILTER regression - eBPF can't subtract when attached from unprivileged user

2019-03-01 Thread Arthur Fabre
I can reproduce this on 4.19.0-3-amd64 both with, and without the JIT enabled. Dumping the "root" and "non-root" programs with bpftool, the subtraction instructions differ: "non-root": 0: (85) call bpf_ktime_get_ns#74944 1: (bf) r7 = r0 2: (85) call bpf_ktime_get_ns#74944 3: (bf) r6 =

RE: [PATCH 09/11] dt-bindings: can: rcar_can: Fix RZ/G2 CAN clocks

2019-03-01 Thread Fabrizio Castro
Hello Marc, I am sorry to bother you. Do you think you can take this patch? Thanks, Fab > From: Fabrizio Castro > Sent: 16 January 2019 18:38 > Subject: [PATCH 09/11] dt-bindings: can: rcar_can: Fix RZ/G2 CAN clocks > > According to the latest information, the clock options for CAN on RZ/G2 >

RE: [PATCH 11/11] dt-bindings: can: rcar_canfd: document r8a774c0 support

2019-03-01 Thread Fabrizio Castro
Hello Marc, I am sorry to bother you. Do you think you can take this patch? Thanks, Fab > From: Fabrizio Castro > Sent: 16 January 2019 18:38 > Subject: [PATCH 11/11] dt-bindings: can: rcar_canfd: document r8a774c0 support > > Document the support for rcar_canfd on R8A774C0 SoC devices. > > S

RE: [PATCH 3/3] dt-bindings: can: rcar_canfd: Document r8a774a1 support

2019-03-01 Thread Fabrizio Castro
Hello Marc, I am sorry to bother you. Do you think you can take this patch? Thanks, Fab > From: Fabrizio Castro > Sent: 17 January 2019 14:54 > Subject: [PATCH 3/3] dt-bindings: can: rcar_canfd: Document r8a774a1 support > > Document support for rcar_canfd on R8A774A1 SoC devices. > > Signed-

noqueue qdisc and non-virtual interfaces

2019-03-01 Thread Ignat Korchagin
Good day, According to this link: http://linux-tc-notes.sourceforge.net/tc/doc/sch_noqueue.txt it should not be possible to assign noqueue qdisc to physical devices or classes. Yet, I can clearly do it even on the latest 5.0-rc series kernels: $ sudo tc qdisc add dev eth0 root noqueue $ sudo tc q

Re: [PATCH net-next 1/6] net: core: dev_addr_lists: add VID to device address

2019-03-01 Thread Ivan Khoronzhuk
On Wed, Feb 27, 2019 at 08:24:00PM -0800, Florian Fainelli wrote: On 2/26/2019 10:45 AM, Ivan Khoronzhuk wrote: Despite this is supposed to be used for Ethernet VLANs, not Ethernet addresses with space for VID also can reuse this, so VID is considered as virtual ID extension, not belonging stric

Re: [PATCH net-next 2/6] net: 8021q: vlan_dev: add vid tag to addresses of uc and mc lists

2019-03-01 Thread Ivan Khoronzhuk
On Wed, Feb 27, 2019 at 08:09:44PM -0800, Florian Fainelli wrote: On 2/26/2019 10:45 AM, Ivan Khoronzhuk wrote: Update vlan mc and uc addresses with VID tag while propagating addresses to lower devices, do this only if address is not synced. It allows at end driver level to distinguish address

Re: [PATCH net-next 3/6] net: 8021q: vlan_dev: add vid tag for vlan device own address

2019-03-01 Thread Ivan Khoronzhuk
On Wed, Feb 27, 2019 at 08:13:34PM -0800, Florian Fainelli wrote: On 2/26/2019 10:45 AM, Ivan Khoronzhuk wrote: The vlan device address is held separately from uc/mc lists and handled differently. The vlan dev address is bound with real device address only if it's inherited from init, in all o

[RFC PATCH net-next] selftests: tc-testing: Add pedit tests

2019-03-01 Thread Dmytro Linkin
Add 36 pedit action tests to check pedit options described in tc-pedit(8) man page. Test cases can be specified by categories: actions, pedit, raw_op, layered_op. RAW_OP cases check offset option for u8, u16 and u32 offset size. LAYERED_OP cases check fields option for eth, ip, ip6, tcp and udp hea

Re: [patch net-next 1/5] net: replace ndo_get_devlink for ndo_get_devlink_port

2019-03-01 Thread Michal Kubecek
On Fri, Mar 01, 2019 at 09:13:58AM +0100, Jiri Pirko wrote: > From: Jiri Pirko > > Follow-up patch is going to need a devlink port instance according to > a netdev. Devlink port instance should be always available when devlink > is used. I noticed netdevsim has devlink interface but it does not

Re: SOCKET_FILTER regression - eBPF can't subtract when attached from unprivileged user

2019-03-01 Thread Daniel Borkmann
On 03/01/2019 12:39 PM, Arthur Fabre wrote: > I can reproduce this on 4.19.0-3-amd64 both with, and without the JIT enabled. > > Dumping the "root" and "non-root" programs with bpftool, > the subtraction instructions differ: > > "non-root": >0: (85) call bpf_ktime_get_ns#74944 >1: (bf) r7

Re: Question about setting speed and duplex failed after auto-negotiation disabled on marvell phy

2019-03-01 Thread Michal Vokáč
On 01. 03. 19 12:26, liweihang wrote: Hi all, We encountered a problem that if there are two devices in kernel v5.0 with marvell phy 88E1510 connect with each other directly, one with autoneg on and the other off. The one who has disabled auto-negotiation will failed on setting speed and duplex

Re: [PATCH net-next 4/6] ethernet: eth: add default vid len for all ehternet kind devices

2019-03-01 Thread Ivan Khoronzhuk
On Wed, Feb 27, 2019 at 08:29:20PM -0800, Florian Fainelli wrote: On 2/26/2019 10:45 AM, Ivan Khoronzhuk wrote: IVDF - individual virtual device filtering. Allows to set per vlan l2 address filters on end real network device (for unicast and for multicast) and drop redundant not expected packe

Re: [virtio-dev] Re: net_failover slave udev renaming (was Re: [RFC PATCH net-next v6 4/4] netvsc: refactor notifier/event handling code to use the bypass framework)

2019-03-01 Thread Michael S. Tsirkin
On Thu, Feb 28, 2019 at 05:30:56PM -0800, si-wei liu wrote: > > > On 2/28/2019 6:26 AM, Michael S. Tsirkin wrote: > > On Thu, Feb 28, 2019 at 01:32:12AM -0800, si-wei liu wrote: > > > > > Will the > > > > > change break userspace further? > > > > > > > > > > -Siwei > > > > Didn't you show usersp

Re: [PATCH net] ipvs: get sctphdr by sctphoff in sctp_csum_check

2019-03-01 Thread Pablo Neira Ayuso
On Mon, Feb 25, 2019 at 07:27:43PM +0800, Xin Long wrote: > sctp_csum_check() is called by sctp_s/dnat_handler() where it calls > skb_make_writable() to ensure sctphdr to be linearized. > > So there's no need to get sctphdr by calling skb_header_pointer() > in sctp_csum_check(). Applied, thanks.

Re: [PATCH net] netfilter: bridge: Don't sabotage nf_hook calls for an l3mdev slave

2019-03-01 Thread Pablo Neira Ayuso
On Mon, Feb 25, 2019 at 04:21:14PM -0800, David Ahern wrote: > From: David Ahern > > Followup to a173f066c7cf ("netfilter: bridge: Don't sabotage nf_hook > calls from an l3mdev"). Some packets (e.g., ndisc) do not have the skb > device flipped to the l3mdev (e.g., VRF) device. Update ip_sabotage_

Re: [PATCH] netfilter: xt_IDLETIMER: fix sysfs callback function type

2019-03-01 Thread Pablo Neira Ayuso
On Wed, Feb 27, 2019 at 10:19:10AM -0800, Sami Tolvanen wrote: > Use struct device_attribute instead of struct idletimer_tg_attr, and > the correct callback function type to avoid indirect call mismatches > with Control Flow Integrity checking. Applied, thanks.

[PATCH net-next] net: ipv4: Fix NULL pointer dereference in route lookup

2019-03-01 Thread Ido Schimmel
When calculating the multipath hash for input routes the flow info is not available and therefore should not be used. Fixes: 24ba14406c5c ("route: Add multipath_hash in flowi_common to make user-define hash") Signed-off-by: Ido Schimmel Cc: wenxu --- net/ipv4/route.c | 2 +- 1 file changed, 1

Re: [PATCH v3 1/6] ethtool: move option parsing related code into function

2019-03-01 Thread Michal Kubecek
On Fri, Mar 01, 2019 at 12:15:27AM -0800, Jeff Kirsher wrote: > From: Nicholas Nunley > > Move option parsing code into find_option function. > > No behavior changes. > > Based on patch by Kan Liang > > Signed-off-by: Nicholas Nunley Reviewed-by: Michal Kubecek

Re: [PATCH net 0/2] Use C45 Helpers when possible

2019-03-01 Thread Andrew Lunn
On Fri, Mar 01, 2019 at 11:54:22AM +0100, Jose Abreu wrote: > For -net. Please review! Hi Jose Patches for net should have fixes: tags, making it clear what they fix, and how far back the patches should be ported. Thanks Andrew

Re: [PATCH v3 2/6] ethtool: move cmdline_coalesce out of do_scoalesce

2019-03-01 Thread Michal Kubecek
On Fri, Mar 01, 2019 at 12:15:28AM -0800, Jeff Kirsher wrote: > From: Nicholas Nunley > > Move the definition of cmdline_coalesce out of do_scoalesce and into a > macro so it can be resused across functions. > > No behavior change. > > Based on patch by Kan Liang > > Signed-off-by: Nicholas N

Re: [patch net-next 1/5] net: replace ndo_get_devlink for ndo_get_devlink_port

2019-03-01 Thread Jiri Pirko
Fri, Mar 01, 2019 at 01:45:26PM CET, mkube...@suse.cz wrote: >On Fri, Mar 01, 2019 at 09:13:58AM +0100, Jiri Pirko wrote: >> From: Jiri Pirko >> >> Follow-up patch is going to need a devlink port instance according to >> a netdev. Devlink port instance should be always available when devlink >> i

Re: [PATCH net 2/2] net: phy: Use C45 Helpers in PHY_FORCING state

2019-03-01 Thread Andrew Lunn
On Fri, Mar 01, 2019 at 11:54:24AM +0100, Jose Abreu wrote: > +static inline int phy_update_link(struct phy_device *phydev) > +{ > + if (!phydev->drv) > + return -EIO; > + > + if (phydev->drv->read_status) > + return phydev->drv->read_status(phydev); > + else if

Re: SOCKET_FILTER regression - eBPF can't subtract when attached from unprivileged user

2019-03-01 Thread Daniel Borkmann
On 03/01/2019 12:39 PM, Arthur Fabre wrote: > I can reproduce this on 4.19.0-3-amd64 both with, and without the JIT enabled. > > Dumping the "root" and "non-root" programs with bpftool, > the subtraction instructions differ: > > "non-root": >0: (85) call bpf_ktime_get_ns#74944 >1: (bf) r7

Re: SOCKET_FILTER regression - eBPF can't subtract when attached from unprivileged user

2019-03-01 Thread Marek Majkowski
Great, appreciated. One more thing (since upgrading kernels takes time) do you think I can amend eBPF on my side to avoid triggering this? Naive stuff like this doesn't work sadly: uint64_t delta = b + ~a + 1; I tried couple more variants with uint32_t types, but to no avail. Ideas? Marek

[PATCH net-next v3 2/3] xdp: Always use a devmap for XDP_REDIRECT to a device

2019-03-01 Thread Toke Høiland-Jørgensen
An XDP program can redirect packets between interfaces using either the xdp_redirect() helper or the xdp_redirect_map() helper. Apart from the flexibility of updating maps from userspace, the redirect_map() helper also uses the map structure to batch packets, which results in a significant (around

[PATCH net-next v3 0/3] xdp: Use a default map for xdp_redirect helper

2019-03-01 Thread Toke Høiland-Jørgensen
This series changes the xdp_redirect helper to use a hidden default map. The redirect_map() helper also uses the map structure to batch packets, which results in a significant (around 50%) performance boost for the _map variant. However, the xdp_redirect() API is simpler if one just wants to redire

[PATCH net-next v3 3/3] xdp: Add devmap_idx map type for looking up devices by ifindex

2019-03-01 Thread Toke Høiland-Jørgensen
A common pattern when using xdp_redirect_map() is to create a device map where the lookup key is simply ifindex. Because device maps are arrays, this leaves holes in the map, and the map has to be sized to fit the largest ifindex, regardless of how many devices actually are actually needed in the m

[PATCH net-next v3 1/3] xdp: Refactor devmap code in preparation for subsequent additions

2019-03-01 Thread Toke Høiland-Jørgensen
The subsequent commits introducing default maps and a hash-based ifindex devmap require a bit of refactoring of the devmap code. Perform this first so the subsequent commits become easier to read. Signed-off-by: Toke Høiland-Jørgensen --- kernel/bpf/devmap.c | 177 ++

Re: [PATCH net-next v2 2/3] net: phy: marvell10g: add the suspend/resume callbacks for the 88x2210

2019-03-01 Thread Andrew Lunn
On Fri, Mar 01, 2019 at 12:00:46PM +0100, Antoine Tenart wrote: > When the 88x2110 PHY support was added, the suspend and resume callbacks > were forgotten. This patch adds them to the 88x2110 PHY callback > definition. > > Signed-off-by: Antoine Tenart Reviewed-by: Andrew Lunn Andrew

Re: [PATCH net-next v2 1/3] net: phy: marvell10g: implement suspend/resume callbacks

2019-03-01 Thread Andrew Lunn
On Fri, Mar 01, 2019 at 12:00:45PM +0100, Antoine Tenart wrote: > This patch adds the suspend/resume callbacks for Marvell 10G PHYs. The > three PCS (base-t, base-r and 1000base-x) are set in low power (the PCS > are powered down) when the PHY isn't used. > > Signed-off-by: Antoine Tenart Review

Re: [PATCH v3 3/6] ethtool: introduce new ioctl for per-queue settings

2019-03-01 Thread Michal Kubecek
On Fri, Mar 01, 2019 at 12:15:29AM -0800, Jeff Kirsher wrote: > From: Nicholas Nunley > > Introduce a new ioctl for applying per-queue parameters. > Users can apply commands to specific queues by setting SUB_COMMAND and > queue_mask with the following ethtool command: > > ethtool -Q|--per-queue

Re: [PATCH net-next v2 3/3] net: phy: marvell10g: set the PHY in low power by default

2019-03-01 Thread Andrew Lunn
On Fri, Mar 01, 2019 at 12:00:47PM +0100, Antoine Tenart wrote: > When the Marvell 10G PHYs are set out of reset, the LPOWER bit is set > depending on an hardware configuration choice. We also do not know what > is the PHY state at boot time. Hence, set the PHY in low power by > default when this d

Re: SOCKET_FILTER regression - eBPF can't subtract when attached from unprivileged user

2019-03-01 Thread Daniel Borkmann
On 03/01/2019 03:10 PM, Marek Majkowski wrote: > Great, appreciated. > > One more thing (since upgrading kernels takes time) do you think I can > amend eBPF on my side to avoid triggering this? Naive stuff like this > doesn't work sadly: > > uint64_t delta = b + ~a + 1; > > I tried couple mo

Re: [PATCH] net: mvpp2: avoid bouncing buffers

2019-03-01 Thread Antoine Tenart
Hi Christoph, I saw you sent this patch as part of another series back in August, but it seems it was never applied and I can't find it even in -next. We made some tests and this patch is helping a lot the PPv2 engine driver in improving its performances. Do you plan on re-sending it, or reworkin

Re: [PATCH v3 4/6] ethtool: support per-queue sub command --show-coalesce

2019-03-01 Thread Michal Kubecek
On Fri, Mar 01, 2019 at 12:15:30AM -0800, Jeff Kirsher wrote: > From: Nicholas Nunley > > Get all masked queues' coalesce settings from kernel and dump them one by > one. > > Example: > > $ sudo ./ethtool --per-queue eth5 queue_mask 0x11 --show-coalesce > Queue: 0 > Adaptive RX: off TX: off

Re: [PATCH v3 5/6] ethtool: support per-queue sub command --coalesce

2019-03-01 Thread Michal Kubecek
On Fri, Mar 01, 2019 at 12:15:31AM -0800, Jeff Kirsher wrote: > From: Nicholas Nunley > > This patch adds the ability to configure the coalesce settings from > do_scoalesce on a per-queue basis. > > For each masked queue the current settings are read, modified, and written > back to the kernel.

Re: [PATCH net-next] net: ipv4: Fix NULL pointer dereference in route lookup

2019-03-01 Thread wenxu
On 2019/3/1 下午9:38, Ido Schimmel wrote: > When calculating the multipath hash for input routes the flow info is > not available and therefore should not be used. > > Fixes: 24ba14406c5c ("route: Add multipath_hash in flowi_common to make > user-define hash") > Signed-off-by: Ido Schimmel > Cc: we

  1   2   3   4   >