Re: [PATCH bpf-next 0/4] i40e AF_XDP zero-copy buffer leak fixes

2018-09-05 Thread Alexei Starovoitov
On Wed, Sep 05, 2018 at 09:15:14PM +0200, Björn Töpel wrote: > Den ons 5 sep. 2018 kl 19:14 skrev Jakub Kicinski > : > > > > On Tue, 4 Sep 2018 20:11:01 +0200, Björn Töpel wrote: > > > From: Björn Töpel > > > > > > This series addresses an AF_XDP zero-copy issue that buffers passed > > > from

Re: [PATCH net 0/3] net/iucv: fixes 2018-09-05

2018-09-05 Thread David Miller
From: Julian Wiedmann Date: Wed, 5 Sep 2018 16:55:09 +0200 > please apply three straight-forward fixes for iucv. One that prevents > leaking the skb on malformed inbound packets, one to fix the error > handling on transmit error, and one to get rid of a compile warning. Series applied, thank

Re: [PATCH bpf-next] bpf/verifier: properly clear union members after a ctx read

2018-09-05 Thread Alexei Starovoitov
On Wed, Sep 05, 2018 at 02:47:22PM +0100, Edward Cree wrote: > On 05/09/18 03:23, Alexei Starovoitov wrote: > > So would you agree it's fair to add > > Fixes: f1174f77b50c ("bpf/verifier: rework value tracking") > > ? > Sure.  Though I don't think it needs backporting, as it's a conservative >  

Re: [PATCH RFC] net/mlx5_en: switch to Toeplitz RSS hash by default

2018-09-05 Thread Saeed Mahameed
On Sun, Sep 2, 2018 at 2:55 AM, Konstantin Khlebnikov wrote: > On 02.09.2018 12:29, Tariq Toukan wrote: >> >> >> >> On 31/08/2018 2:29 PM, Konstantin Khlebnikov wrote: >>> >>> XOR (MLX5_RX_HASH_FN_INVERTED_XOR8) gives only 8 bits. >>> It seems not enough for RFS. All other drivers use toeplitz.

Re: [PATCH net] net/sched: fix memory leak in act_tunnel_key_init()

2018-09-05 Thread David Miller
From: Davide Caratti Date: Tue, 4 Sep 2018 19:00:19 +0200 > If users try to install act_tunnel_key 'set' rules with duplicate values > of 'index', the tunnel metadata are allocated, but never released. Then, > kmemleak complains as follows: ... > This problem theoretically happens also in case

Re: [PATCH net-next] nfp: separate VXLAN and GRE feature handling

2018-09-05 Thread David Miller
From: Jakub Kicinski Date: Tue, 4 Sep 2018 08:28:33 -0700 > VXLAN and GRE FW features have to currently be both advertised > for the driver to enable them. Separate the handling. > > Signed-off-by: Jakub Kicinski > Reviewed-by: Dirk van der Merwe Applied.

Re: [PATCH net-next 0/3] nfp: improve the new rtsym helpers

2018-09-05 Thread David Miller
From: Jakub Kicinski Date: Tue, 4 Sep 2018 07:37:30 -0700 > This set fixes a bug in ABS rtsym handling I added in net-next, > it expands the error checking and reporting on the rtsym accesses. Series applied.

Re: [PATCH v2 net-next] failover: Add missing check to validate 'slave_dev' in net_failover_slave_unregister

2018-09-05 Thread David Miller
From: YueHaibing Date: Tue, 4 Sep 2018 02:56:26 + > Fixes gcc '-Wunused-but-set-variable' warning: > > drivers/net/net_failover.c: In function 'net_failover_slave_unregister': > drivers/net/net_failover.c:598:35: warning: > variable 'primary_dev' set but not used

Re: [PATCH v2 net-next] packet: add sockopt to ignore outgoing packets

2018-09-05 Thread David Miller
From: Vincent Whitchurch Date: Mon, 3 Sep 2018 16:23:36 +0200 > Currently, the only way to ignore outgoing packets on a packet socket is > via the BPF filter. With MSG_ZEROCOPY, packets that are looped into > AF_PACKET are copied in dev_queue_xmit_nit(), and this copy happens even > if the

[net-next 2/9] net/mlx5: Add new list to store deleted flow counters

2018-09-05 Thread Saeed Mahameed
From: Vlad Buslov In order to prevent flow counters stats work function from traversing whole flow counters tree while searching for deleted flow counters, new list to store deleted flow counters is added to struct mlx5_fc_stats. Lockless NULL-terminated single linked list data type is used due

[net-next 9/9] net/mlx5e: don't set CHECKSUM_COMPLETE on SCTP packets

2018-09-05 Thread Saeed Mahameed
From: Alaa Hleihel CHECKSUM_COMPLETE is not applicable to SCTP protocol. Setting it for SCTP packets leads to CRC32c validation failure. Fixes: bbceefce9adf ("net/mlx5e: Support RX CHECKSUM_COMPLETE") Signed-off-by: Alaa Hleihel Reviewed-by: Or Gerlitz Signed-off-by: Saeed Mahameed ---

[net-next 4/9] net/mlx5: Add flow counters idr

2018-09-05 Thread Saeed Mahameed
From: Vlad Buslov Previous patch in series changed flow counter storage structure from rb_tree to linked list in order to improve flow counter traversal performance. The drawback of such solution is that flow counter lookup by id becomes linear in complexity. Store pointers to flow counters in

[net-next 8/9] net/mlx5e: Set ECN for received packets using CQE indication

2018-09-05 Thread Saeed Mahameed
From: Natali Shechtman In multi-host (MH) NIC scheme, a single HW port serves multiple hosts or sockets on the same host. The HW uses a mechanism in the PCIe buffer which monitors the amount of consumed PCIe buffers per host. On a certain configuration, under congestion, the HW emulates a switch

[net-next 7/9] net/mlx5e: Replace PTP clock lock from RW lock to seq lock

2018-09-05 Thread Saeed Mahameed
From: Shay Agroskin Changed "priv.clock.lock" lock from 'rw_lock' to 'seq_lock' in order to improve packet rate performance. Tested on Intel(R) Xeon(R) CPU E5-2660 v2 @ 2.20GHz. Sent 64b packets between two peers connected by ConnectX-5, and measured packet rate for the receiver in three modes:

[net-next 5/9] net/mlx5e: Move mlx5e_priv_flags into en_ethtool.c

2018-09-05 Thread Saeed Mahameed
From: Kamal Heib Move the definition of mlx5e_priv_flags into en_ethtool.c because it's only used there. Fixes: 4e59e2888139 ("net/mlx5e: Introduce net device priv flags infrastructure") Signed-off-by: Kamal Heib Signed-off-by: Saeed Mahameed --- drivers/net/ethernet/mellanox/mlx5/core/en.h

[pull request][net-next 0/9] Mellanox, mlx5 ethernet updates 2018-09-05

2018-09-05 Thread Saeed Mahameed
Hi Dave, This pull request provides some updates to mlx5 ethernet driver. For more information please see tag log below. Please pull and let me know if there's any problem. Thanks, Saeed. --- The following changes since commit 05dcc71298643256948a2e17db7dbecc748719d2: net: lan743x_ptp:

[net-next 3/9] net/mlx5: Store flow counters in a list

2018-09-05 Thread Saeed Mahameed
From: Vlad Buslov In order to improve performance of flow counter stats query loop that traverses all configured flow counters, replace rb_tree with double-linked list. This change improves performance of traversing flow counters by removing the tree traversal. (profiling data showed that call

[net-next 6/9] net/mlx5e: Move Q counters allocation and drop RQ to init_rx

2018-09-05 Thread Saeed Mahameed
From: Roi Dayan Not all profiles query the HW Q counters in update_stats() callback. HW Q couners are limited per device and in case of representors all their Q counters are allocated on the parent PF device. Avoid reundant allocation of HW Q counters by moving the allocation to init_rx profile

[net-next 1/9] net/mlx5: Change flow counters addlist type to single linked list

2018-09-05 Thread Saeed Mahameed
From: Vlad Buslov In order to prevent flow counters stats work function from traversing whole flow counters tree while searching for deleted flow counters, new list to store deleted flow counters will be added to struct mlx5_fc_stats. However, the flow counter structure itself has no space left

[net 08/10] net/mlx5: Check for error in mlx5_attach_interface

2018-09-05 Thread Saeed Mahameed
From: Huy Nguyen Currently, mlx5_attach_interface does not check for error after calling intf->attach or intf->add. When these two calls fails, the client is not initialized and will cause issues such as kernel panic on invalid address in the teardown path (mlx5_detach_interface) Fixes:

[net 09/10] net/mlx5e: Ethtool steering, fix udp source port value

2018-09-05 Thread Saeed Mahameed
Copy and paste bug was introduced in the offending patch. We need to write udp source port value into the headers value and not headers criteria "mask". Fixes: 142644f8a1f8 ("net/mlx5e: Ethtool steering flow parsing refactoring") Signed-off-by: Saeed Mahameed ---

[net 05/10] net/mlx5: E-Switch, Fix memory leak when creating switchdev mode FDB tables

2018-09-05 Thread Saeed Mahameed
From: Raed Salem The memory allocated for the slow path table flow group input structure was not freed upon successful return, fix that. Fixes: 1967ce6ea5c8 ("net/mlx5: E-Switch, Refactor fast path FDB table creation in switchdev mode") Signed-off-by: Raed Salem Reviewed-by: Or Gerlitz

[net 10/10] net/mlx5: Fix possible deadlock from lockdep when adding fte to fg

2018-09-05 Thread Saeed Mahameed
From: Roi Dayan This is a false positive report due to incorrect nested lock annotations as we lock multiple fgs with the same subclass. Instead of locking all fgs only lock the one being used as was done before. Fixes: bd71b08ec2ee ("net/mlx5: Support multiple updates of steering rules in

[net 06/10] net/mlx5: Fix not releasing read lock when adding flow rules

2018-09-05 Thread Saeed Mahameed
From: Roi Dayan If building match list fg fails and we never jumped to search_again_locked label then the function returned without unlocking the read lock. Fixes: bd71b08ec2ee ("net/mlx5: Support multiple updates of steering rules in parallel") Signed-off-by: Roi Dayan Reviewed-by: Maor

Re: [PATCH mlx5-next v1 05/15] net/mlx5: Break encap/decap into two separated flow table creation flags

2018-09-05 Thread Leon Romanovsky
On Thu, Sep 06, 2018 at 12:37:17AM +0300, Or Gerlitz wrote: > On Wed, Sep 5, 2018 at 9:11 PM, Leon Romanovsky wrote: > > On Wed, Sep 05, 2018 at 10:38:00AM -0600, Jason Gunthorpe wrote: > >> On Wed, Sep 05, 2018 at 08:10:25AM +0300, Leon Romanovsky wrote: > >> > > > - int en_encap_decap =

[net 04/10] net/mlx5: Use u16 for Work Queue buffer strides offset

2018-09-05 Thread Saeed Mahameed
From: Tariq Toukan Minimal stride size is 16. Hence, the number of strides in a fragment (of PAGE_SIZE) is <= PAGE_SIZE / 16 <= 4K. u16 is sufficient to represent this. Fixes: d7037ad73daa ("net/mlx5: Fix QP fragmented buffer allocation") Signed-off-by: Tariq Toukan Reviewed-by: Eran Ben

[pull request][net 00/10] Mellanox, mlx5 fixes 2018-09-05

2018-09-05 Thread Saeed Mahameed
Hi Dave, This pull request contains some fixes for mlx5 etherent netdevice and core driver. Please pull and let me know if there's any problem. For -stable v4.9: ('net/mlx5: Fix debugfs cleanup in the device init/remove flow') For -stable v4.12: ("net/mlx5: E-Switch, Fix memory leak when

[net 07/10] net/mlx5: Consider PCI domain in search for next dev

2018-09-05 Thread Saeed Mahameed
From: Daniel Jurgens The PCI BDF is not unique. PCI domain must also be considered when searching for the next physical device during lag setup. Example below: mlx5_core :01:00.0: MLX5E: StrdRq(1) RqSz(8) StrdSz(128) RxCqeCmprss(0) mlx5_core :01:00.1: MLX5E: StrdRq(1) RqSz(8)

[net 01/10] net/mlx5: Fix use-after-free in self-healing flow

2018-09-05 Thread Saeed Mahameed
From: Jack Morgenstein When the mlx5 health mechanism detects a problem while the driver is in the middle of init_one or remove_one, the driver needs to prevent the health mechanism from scheduling future work; if future work is scheduled, there is a problem with use-after-free: the system WQ

[net 02/10] net/mlx5: Fix debugfs cleanup in the device init/remove flow

2018-09-05 Thread Saeed Mahameed
From: Jack Morgenstein When initializing the device (procedure init_one), the driver calls mlx5_pci_init to perform pci initialization. As part of this initialization, mlx5_pci_init creates a debugfs directory. If this creation fails, init_one aborts, returning failure to the caller (which is

[net 03/10] net/mlx5: Use u16 for Work Queue buffer fragment size

2018-09-05 Thread Saeed Mahameed
From: Tariq Toukan Minimal stride size is 16. Hence, the number of strides in a fragment (of PAGE_SIZE) is <= PAGE_SIZE / 16 <= 4K. u16 is sufficient to represent this. Fixes: 388ca8be0037 ("IB/mlx5: Implement fragmented completion queue (CQ)") Signed-off-by: Tariq Toukan Reviewed-by: Eran

Re: [PATCH net-next v3 5/5] net: dsa: b53: Add SerDes support

2018-09-05 Thread Andrew Lunn
On Wed, Sep 05, 2018 at 12:42:15PM -0700, Florian Fainelli wrote: > Add support for the Northstar Plus SerDes which is accessed through a > special page of the switch. Since this is something that most people > probably will not want to use, make it a configurable option with a > default on

[PATCH net-next] liquidio: Add spoof checking on a VF MAC address

2018-09-05 Thread Felix Manlunas
From: Weilin Chang 1. Provide the API to set/unset the spoof checking feature. 2. Add a function to periodically provide the count of found packets with spoof VF MAC address. 3. Prevent VF MAC address changing while the spoofchk of the VF is on unless the changing MAC address is issued

[PATCH bpf-next 1/4] tools/bpf: sync kernel uapi header if_link.h to tools

2018-09-05 Thread Yonghong Song
Among others, this header will be used later for bpftool net support. Signed-off-by: Yonghong Song --- tools/include/uapi/linux/if_link.h | 17 + 1 file changed, 17 insertions(+) diff --git a/tools/include/uapi/linux/if_link.h b/tools/include/uapi/linux/if_link.h index

[PATCH bpf-next 3/4] tools/bpf: add more netlink functionalities in lib/bpf

2018-09-05 Thread Yonghong Song
This patch added a few netlink attribute parsing functions and the netlink API functions to query networking links, tc classes, tc qdiscs and tc filters. For example, the following API is to get networking links: int nl_get_link(int sock, unsigned int nl_pid, dump_nlmsg_t

[PATCH bpf-next 2/4] tools/bpf: move bpf/lib netlink related functions into a new file

2018-09-05 Thread Yonghong Song
There are no functionality change for this patch. In the subsequent patches, more netlink related library functions will be added and a separate file is better than cluttering bpf.c. Signed-off-by: Yonghong Song --- tools/lib/bpf/Build | 2 +- tools/lib/bpf/bpf.c | 129

[PATCH bpf-next 0/4] tools/bpf: add bpftool net support

2018-09-05 Thread Yonghong Song
As bpf usage becomes more pervasive, people starts to worry about their cpu and memory cost. On a particular host, people often wanted to know all running bpf programs and their attachment context. So they can relate a performance/memory anormly quickly to a particular bpf program or an

[PATCH bpf-next 4/4] tools/bpf: bpftool: add net support

2018-09-05 Thread Yonghong Song
Add "bpftool net" support. Networking devices are enumerated to dump device index/name associated with xdp progs. For each networking device, tc classes and qdiscs are enumerated in order to check their bpf filters. In addition, root handle and clsact ingress/egress are also checked for bpf

Re: [PATCH] cxgb4: fix abort_req_rss6 struct

2018-09-05 Thread Jason Gunthorpe
On Fri, Aug 31, 2018 at 11:52:00AM -0700, Steve Wise wrote: > Remove the incorrect WR_HDR field which can cause a misinterpretation > of this CPL by ULDs. What does that mean? Is this an -rc patch? Jason

Re: [PATCH net-next v3 4/5] net: dsa: b53: Add PHYLINK support

2018-09-05 Thread Andrew Lunn
On Wed, Sep 05, 2018 at 12:42:14PM -0700, Florian Fainelli wrote: > Add support for PHYLINK, things are reasonably straight forward since we > do not yet support SerDes interfaces, that leaves us with just > MLO_AN_PHY and MLO_AN_FIXED to deal with. > > Signed-off-by: Florian Fainelli

Re: [PATCH net-next v3 3/5] net: dsa: b53: Add helper to set link parameters

2018-09-05 Thread Andrew Lunn
On Wed, Sep 05, 2018 at 12:42:13PM -0700, Florian Fainelli wrote: > Extract the logic from b53_adjust_link() responsible for overriding a > given port's link, speed, duplex and pause settings and make two helper > functions to set the port's configuration and the port's link settings. > We will

Re: [PATCH net-next v3 2/5] net: dsa: b53: Make SRAB driver manage port interrupts

2018-09-05 Thread Andrew Lunn
On Wed, Sep 05, 2018 at 12:42:12PM -0700, Florian Fainelli wrote: > Update the SRAB driver to manage per-port interrupts. Since we cannot > sleep during b53_io_ops, schedule a workqueue whenever we get a port > specific interrupt. We will later make use of this to call back into > PHYLINK when

Re: [PATCH net-next v3 1/5] net: dsa: b53: Add ability to enable/disable port interrupts

2018-09-05 Thread Andrew Lunn
On Wed, Sep 05, 2018 at 12:42:11PM -0700, Florian Fainelli wrote: > Some switches expose individual interrupt line(s) for port specific > event(s), allow configuring these interrupts at an appropriate time > during port_enable/disable callbacks where all port specific resources > are known to be

Re: Poptrie in Linux kernel

2018-09-05 Thread Md. Islam
Hi Yasuhiro I would like to point out that the lookup process, Trie construction and even the Trie itself is not same as the patent [1]. The idea of splitting prefix into multiple level is not new. SAIL [2] does it as well. In fact, I started by implementing SAIL in Linux kernel. Then came

Re: [PATCH mlx5-next v1 05/15] net/mlx5: Break encap/decap into two separated flow table creation flags

2018-09-05 Thread Or Gerlitz
On Wed, Sep 5, 2018 at 9:11 PM, Leon Romanovsky wrote: > On Wed, Sep 05, 2018 at 10:38:00AM -0600, Jason Gunthorpe wrote: >> On Wed, Sep 05, 2018 at 08:10:25AM +0300, Leon Romanovsky wrote: >> > > > - int en_encap_decap = !!(flags & MLX5_FLOW_TABLE_TUNNEL_EN); >> > > > + int en_encap

Re: [PATCH rdma-next v1 00/15] Flow actions to mutate packets

2018-09-05 Thread Jason Gunthorpe
On Wed, Sep 05, 2018 at 08:14:58AM +0300, Leon Romanovsky wrote: > > This looks OK to me, can you make the shared commit please? > > Thanks, I pushed to mlx5-next > > 50acec06f392 net/mlx5: Export packet reformat alloc/dealloc functions > 31ca3648f01b net/mlx5: Pass a namespace for packet

Re: [PATCH net-next] net: sched: change tcf_del_walker() to use concurrent-safe delete

2018-09-05 Thread Cong Wang
On Wed, Sep 5, 2018 at 12:05 AM Vlad Buslov wrote: > > > On Tue 04 Sep 2018 at 22:41, Cong Wang wrote: > > On Mon, Sep 3, 2018 at 1:33 PM Vlad Buslov wrote: > >> > >> > >> On Mon 03 Sep 2018 at 18:50, Cong Wang wrote: > >> > On Mon, Sep 3, 2018 at 12:06 AM Vlad Buslov wrote: > >> >> > >> >>

[PATCH iproute2] tc/mqprio: Print extra info on invalid args.

2018-09-05 Thread Caleb Raitto
From: Caleb Raitto Print the name of the argument that wasn't understood, and also print the usage string. Signed-off-by: Caleb Raitto --- tc/q_mqprio.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tc/q_mqprio.c b/tc/q_mqprio.c index 89b46002..cf2eceb4 100644 ---

[PATCH iproute2] man: Change numtc to num_tc

2018-09-05 Thread Caleb Raitto
From: Caleb Raitto The argument parser only accepts num_tc: https://git.kernel.org/pub/scm/network/iproute2/iproute2.git/tree/tc/q_mqprio.c#n55 Signed-off-by: Caleb Raitto --- man/man8/tc-mqprio.8 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/man/man8/tc-mqprio.8

[PATCH net-next v3 3/5] net: dsa: b53: Add helper to set link parameters

2018-09-05 Thread Florian Fainelli
Extract the logic from b53_adjust_link() responsible for overriding a given port's link, speed, duplex and pause settings and make two helper functions to set the port's configuration and the port's link settings. We will make use of both, as separate functions while adding PHYLINK support next.

[PATCH net-next v3 4/5] net: dsa: b53: Add PHYLINK support

2018-09-05 Thread Florian Fainelli
Add support for PHYLINK, things are reasonably straight forward since we do not yet support SerDes interfaces, that leaves us with just MLO_AN_PHY and MLO_AN_FIXED to deal with. Signed-off-by: Florian Fainelli --- drivers/net/dsa/b53/b53_common.c | 122 +++

[PATCH net-next v3 5/5] net: dsa: b53: Add SerDes support

2018-09-05 Thread Florian Fainelli
Add support for the Northstar Plus SerDes which is accessed through a special page of the switch. Since this is something that most people probably will not want to use, make it a configurable option with a default on ARCH_BCM_NSP where it is the most useful currently. The SerDes supports both

[PATCH net-next v3 2/5] net: dsa: b53: Make SRAB driver manage port interrupts

2018-09-05 Thread Florian Fainelli
Update the SRAB driver to manage per-port interrupts. Since we cannot sleep during b53_io_ops, schedule a workqueue whenever we get a port specific interrupt. We will later make use of this to call back into PHYLINK when there is e.g: a link state change. Signed-off-by: Florian Fainelli ---

[PATCH net-next v3 1/5] net: dsa: b53: Add ability to enable/disable port interrupts

2018-09-05 Thread Florian Fainelli
Some switches expose individual interrupt line(s) for port specific event(s), allow configuring these interrupts at an appropriate time during port_enable/disable callbacks where all port specific resources are known to be set-up and ready for use. Signed-off-by: Florian Fainelli ---

[PATCH net-next v3 0/5] net: dsa: b53: SerDes support

2018-09-05 Thread Florian Fainelli
Hi all, This patch series adds support for the SerDes found on NorthStar Plus (NSP) which allows us to use the SFP port on the BCM958625HR board (and other similar designs). Changes in v3: - properly hunk the request_threaded_irq() bits into patch #2 Changes in v2: - migrate to threaded

Re: [PATCH net-next v2 0/5] net: dsa: b53: SerDes support

2018-09-05 Thread Florian Fainelli
On 09/05/2018 12:23 PM, Florian Fainelli wrote: > Hi all, > > This patch series adds support for the SerDes found on NorthStar Plus > (NSP) which allows us to use the SFP port on the BCM958625HR board (and > other similar designs). David, please disregard this version, for some reason I managed

[PATCH net-next v2 0/5] net: dsa: b53: SerDes support

2018-09-05 Thread Florian Fainelli
Hi all, This patch series adds support for the SerDes found on NorthStar Plus (NSP) which allows us to use the SFP port on the BCM958625HR board (and other similar designs). Changes in v2: - migrate to threaded interrupt (Andrew) - fixed a case where MLO_AN_FIXED's mac_config would still call

[PATCH net-next v2 2/5] net: dsa: b53: Make SRAB driver manage port interrupts

2018-09-05 Thread Florian Fainelli
Update the SRAB driver to manage per-port interrupts. Since we cannot sleep during b53_io_ops, schedule a workqueue whenever we get a port specific interrupt. We will later make use of this to call back into PHYLINK when there is e.g: a link state change. Signed-off-by: Florian Fainelli ---

[PATCH net-next v2 4/5] net: dsa: b53: Add PHYLINK support

2018-09-05 Thread Florian Fainelli
Add support for PHYLINK, things are reasonably straight forward since we do not yet support SerDes interfaces, that leaves us with just MLO_AN_PHY and MLO_AN_FIXED to deal with. Signed-off-by: Florian Fainelli --- drivers/net/dsa/b53/b53_common.c | 122 +++

[PATCH net-next v2 5/5] net: dsa: b53: Add SerDes support

2018-09-05 Thread Florian Fainelli
Add support for the Northstar Plus SerDes which is accessed through a special page of the switch. Since this is something that most people probably will not want to use, make it a configurable option with a default on ARCH_BCM_NSP where it is the most useful currently. The SerDes supports both

[PATCH net-next v2 1/5] net: dsa: b53: Add ability to enable/disable port interrupts

2018-09-05 Thread Florian Fainelli
Some switches expose individual interrupt line(s) for port specific event(s), allow configuring these interrupts at an appropriate time during port_enable/disable callbacks where all port specific resources are known to be set-up and ready for use. Signed-off-by: Florian Fainelli ---

[PATCH net-next v2 3/5] net: dsa: b53: Add helper to set link parameters

2018-09-05 Thread Florian Fainelli
Extract the logic from b53_adjust_link() responsible for overriding a given port's link, speed, duplex and pause settings and make two helper functions to set the port's configuration and the port's link settings. We will make use of both, as separate functions while adding PHYLINK support next.

Re: [RFC PATCH bpf-next 0/4] tools/bpf: bpftool: add net support

2018-09-05 Thread Yonghong Song
On 9/5/18 10:51 AM, Jakub Kicinski wrote: On Mon, 3 Sep 2018 11:26:43 -0700, Yonghong Song wrote: The functionality to dump network driver and tc related bpf programs are added. Currently, users can already use "ip link show " and "tc filter show dev ..." to dump bpf program attachment

Re: [PATCH bpf-next 0/4] i40e AF_XDP zero-copy buffer leak fixes

2018-09-05 Thread Björn Töpel
Den ons 5 sep. 2018 kl 19:14 skrev Jakub Kicinski : > > On Tue, 4 Sep 2018 20:11:01 +0200, Björn Töpel wrote: > > From: Björn Töpel > > > > This series addresses an AF_XDP zero-copy issue that buffers passed > > from userspace to the kernel was leaked when the hardware descriptor > > ring was

[PATCH 1/7] fix hnode refcounting

2018-09-05 Thread Al Viro
From: Al Viro cls_u32.c misuses refcounts for struct tc_u_hnode - it counts references via ->hlist and via ->tp_root together. u32_destroy() drops the former and, in case when there had been links, leaves the sucker on the list. As the result, there's nothing to protect it from getting freed

[PATCH 4/7] get rid of unused argument of u32_destroy_key()

2018-09-05 Thread Al Viro
From: Al Viro Signed-off-by: Al Viro --- net/sched/cls_u32.c | 13 ++--- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/net/sched/cls_u32.c b/net/sched/cls_u32.c index 5816288810cc..3311aacad6c3 100644 --- a/net/sched/cls_u32.c +++ b/net/sched/cls_u32.c @@ -406,8 +406,7

[PATCH 3/7] make sure that divisor is a power of 2

2018-09-05 Thread Al Viro
From: Al Viro Signed-off-by: Al Viro --- net/sched/cls_u32.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/net/sched/cls_u32.c b/net/sched/cls_u32.c index 9ea5f2be907b..5816288810cc 100644 --- a/net/sched/cls_u32.c +++ b/net/sched/cls_u32.c @@ -995,7 +995,11 @@

[PATCHES] cls_u32 cleanups and fixes

2018-09-05 Thread Al Viro
Several cls_u32 patches: fixing refcounting, preventing links to and deletion of root hnodes, validating divisor. Plus cleanups - removal of some useless fields and saner handling of tc_u_common hashtable. The first 3 in series are fixes (and -stable fodder), the rest - cleanups. Branch

[PATCH 5/7] get rid of tc_u_knode ->tp

2018-09-05 Thread Al Viro
From: Al Viro not used anymore Signed-off-by: Al Viro --- net/sched/cls_u32.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/net/sched/cls_u32.c b/net/sched/cls_u32.c index 3311aacad6c3..8a1a573487bd 100644 --- a/net/sched/cls_u32.c +++ b/net/sched/cls_u32.c @@ -68,7 +68,6 @@ struct

[PATCH 2/7] mark root hnode explicitly

2018-09-05 Thread Al Viro
From: Al Viro ... and disallow deleting or linking to such Signed-off-by: Al Viro --- net/sched/cls_u32.c | 14 +++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/net/sched/cls_u32.c b/net/sched/cls_u32.c index 3f985f29ef30..9ea5f2be907b 100644 ---

[PATCH 7/7] clean tc_u_common hashtable

2018-09-05 Thread Al Viro
From: Al Viro * calculate key *once*, not for each hash chain element * let tc_u_hash() return the pointer to chain head rather than index - callers are cleaner that way. Signed-off-by: Al Viro --- net/sched/cls_u32.c | 22 -- 1 file changed, 8 insertions(+), 14

[PATCH 6/7] get rid of tc_u_common ->rcu

2018-09-05 Thread Al Viro
From: Al Viro unused Signed-off-by: Al Viro --- net/sched/cls_u32.c | 1 - 1 file changed, 1 deletion(-) diff --git a/net/sched/cls_u32.c b/net/sched/cls_u32.c index 8a1a573487bd..be9240ae1417 100644 --- a/net/sched/cls_u32.c +++ b/net/sched/cls_u32.c @@ -98,7 +98,6 @@ struct tc_u_common {

Re: 4.18.6 dl_seq_start [xt_hashlimit] unable to handle kernel NULL pointer dereference at 0000000000000050

2018-09-05 Thread Cong Wang
On Wed, Sep 5, 2018 at 4:06 AM Sami Farin wrote: > > 4.17 worked ok, this with 32 GB Ryzen system. > > BUG: unable to handle kernel NULL pointer dereference at 0050 > PGD 0 P4D 0 > Oops: [#1] PREEMPT SMP NOPTI > CPU: 0 PID: 6303 Comm: grep Tainted: GT 4.18.6+ #16

Re: [**EXTERNAL**] Re: VRF with enslaved L3 enabled bridge

2018-09-05 Thread D'Souza, Nelson
Hi David, Just following up would you be able to confirm that this is a Linux VRF issue? Also, how do I log a VRF related defect to ensure this gets resolved in a subsequent release. Thanks, Nelson On 8/2/18, 4:12 PM, "D'Souza, Nelson" wrote: Hi David, Turns out the VRF

Re: BUG: unable to handle kernel paging request in fib6_node_lookup_1

2018-09-05 Thread Song Liu
> On Sep 5, 2018, at 10:32 AM, David Ahern wrote: > > On 9/5/18 12:11 AM, Song Liu wrote: >> We are debugging an issue with fib6_node_lookup_1(). >> >> We use a 4.16 based kernel, and we have back ported most upstream >> patches in ip6_fib.{c.h}. The only major differences I can spot are >>

Re: [PATCH mlx5-next v1 05/15] net/mlx5: Break encap/decap into two separated flow table creation flags

2018-09-05 Thread Leon Romanovsky
On Wed, Sep 05, 2018 at 10:38:00AM -0600, Jason Gunthorpe wrote: > On Wed, Sep 05, 2018 at 08:10:25AM +0300, Leon Romanovsky wrote: > > > > - int en_encap_decap = !!(flags & MLX5_FLOW_TABLE_TUNNEL_EN); > > > > + int en_encap = !!(flags & MLX5_FLOW_TABLE_TUNNEL_EN_ENCAP); > > > > +

Re: BUG: unable to handle kernel paging request in fib6_node_lookup_1

2018-09-05 Thread Song Liu
> On Sep 5, 2018, at 10:09 AM, Wei Wang wrote: > > On Tue, Sep 4, 2018 at 11:11 PM Song Liu wrote: >> >> We are debugging an issue with fib6_node_lookup_1(). >> >> We use a 4.16 based kernel, and we have back ported most upstream >> patches in ip6_fib.{c.h}. The only major differences I

Re: [PATCH rdma-next v1 12/15] RDMA/mlx5: Add a new flow action verb - modify header

2018-09-05 Thread Leon Romanovsky
On Wed, Sep 05, 2018 at 10:38:42AM -0600, Jason Gunthorpe wrote: > On Wed, Sep 05, 2018 at 08:20:44AM +0300, Leon Romanovsky wrote: > > On Tue, Sep 04, 2018 at 03:58:23PM -0600, Jason Gunthorpe wrote: > > > On Tue, Aug 28, 2018 at 02:18:51PM +0300, Leon Romanovsky wrote: > > > > > > > +static int

[PATCH ethtool] ethtool: support combinations of FEC modes

2018-09-05 Thread Edward Cree
Of the three drivers that currently support FEC configuration, two (sfc and cxgb4[vf]) accept configurations with more than one bit set in the feccmd.fec bitmask. (The precise semantics of these combinations vary.) Thus, this patch adds the ability to specify such combinations through a

Re: [RFC PATCH bpf-next 0/4] tools/bpf: bpftool: add net support

2018-09-05 Thread Jakub Kicinski
On Mon, 3 Sep 2018 11:26:43 -0700, Yonghong Song wrote: > The functionality to dump network driver and tc related bpf programs > are added. Currently, users can already use "ip link show " > and "tc filter show dev ..." to dump bpf program attachment > information for xdp programs and tc bpf

smsc95xx: Invalid max MTU

2018-09-05 Thread Stefan Wahren
Hi, recently there was a user who reports that his Raspberry Pi 3B didn't work as expected [1]. The problem is that the smsc95xx driver accepts to high MTU values ( > 9000) from userspace like dhcp-client, but according to the LAN9500 databook the chip seems only capable to handle MTU sizes

Re: BUG: unable to handle kernel paging request in fib6_node_lookup_1

2018-09-05 Thread David Ahern
On 9/5/18 12:11 AM, Song Liu wrote: > We are debugging an issue with fib6_node_lookup_1(). > > We use a 4.16 based kernel, and we have back ported most upstream > patches in ip6_fib.{c.h}. The only major differences I can spot are > Did you backport all patches in each set that included a

Re: [PATCH bpf-next 0/4] i40e AF_XDP zero-copy buffer leak fixes

2018-09-05 Thread Jakub Kicinski
On Tue, 4 Sep 2018 20:11:01 +0200, Björn Töpel wrote: > From: Björn Töpel > > This series addresses an AF_XDP zero-copy issue that buffers passed > from userspace to the kernel was leaked when the hardware descriptor > ring was torn down. > > The patches fixes the i40e AF_XDP zero-copy

Re: BUG: unable to handle kernel paging request in fib6_node_lookup_1

2018-09-05 Thread Wei Wang
On Tue, Sep 4, 2018 at 11:11 PM Song Liu wrote: > > We are debugging an issue with fib6_node_lookup_1(). > > We use a 4.16 based kernel, and we have back ported most upstream > patches in ip6_fib.{c.h}. The only major differences I can spot are > > 8b7f2731bd68d83940714ce92381d1a72596407c >

Re: bpfilter causes a leftover kernel process

2018-09-05 Thread Olivier Brunel
Hi, Quick follow-up on this: - first off, Arch devs have updated their kernel config so the next kernel will not have bpfilter enabled anymore, thus avoiding any issue. - having said that, I've found a neasy way to reproduce it in an Arch VM, in case you're interested : Boot the latest

Re: phys_port_id in switchdev mode?

2018-09-05 Thread Jakub Kicinski
On Wed, 5 Sep 2018 09:20:43 -0700, Samudrala, Sridhar wrote: > > With this libvirt on Host0 should easily find the actual PF0 netdev to > > run the NDO on, if it wants to use VFs: > > - libvrit finds act VF0/0 to plug into the VF; > > - reads its phys_port_id -> "PF0 SN"; > > - finds netdev

Re: phys_port_id in switchdev mode?

2018-09-05 Thread Jakub Kicinski
On Tue, 4 Sep 2018 23:37:29 +0300, Or Gerlitz wrote: > On Tue, Sep 4, 2018 at 1:20 PM, Jakub Kicinski wrote: > > On Mon, 3 Sep 2018 12:40:22 +0300, Or Gerlitz wrote: > >> On Tue, Aug 28, 2018 at 9:05 PM, Jakub Kicinski wrote: > >> > Hi! > >> > >> Hi Jakub and sorry for the late reply, this

Re: [PATCH rdma-next v1 12/15] RDMA/mlx5: Add a new flow action verb - modify header

2018-09-05 Thread Jason Gunthorpe
On Wed, Sep 05, 2018 at 08:20:44AM +0300, Leon Romanovsky wrote: > On Tue, Sep 04, 2018 at 03:58:23PM -0600, Jason Gunthorpe wrote: > > On Tue, Aug 28, 2018 at 02:18:51PM +0300, Leon Romanovsky wrote: > > > > > +static int > > > UVERBS_HANDLER(MLX5_IB_METHOD_FLOW_ACTION_CREATE_MODIFY_HEADER)( > >

Re: [PATCH mlx5-next v1 05/15] net/mlx5: Break encap/decap into two separated flow table creation flags

2018-09-05 Thread Jason Gunthorpe
On Wed, Sep 05, 2018 at 08:10:25AM +0300, Leon Romanovsky wrote: > > > - int en_encap_decap = !!(flags & MLX5_FLOW_TABLE_TUNNEL_EN); > > > + int en_encap = !!(flags & MLX5_FLOW_TABLE_TUNNEL_EN_ENCAP); > > > + int en_decap = !!(flags & MLX5_FLOW_TABLE_TUNNEL_EN_DECAP); > > > > Yuk, please don't use

Re: phys_port_id in switchdev mode?

2018-09-05 Thread Samudrala, Sridhar
On 9/4/2018 3:20 AM, Jakub Kicinski wrote: On Mon, 3 Sep 2018 12:40:22 +0300, Or Gerlitz wrote: On Tue, Aug 28, 2018 at 9:05 PM, Jakub Kicinski wrote: Hi! Hi Jakub and sorry for the late reply, this crazigly hot summer refuses to die, Note I replied couple of minutes ago but it didn't get to

Re: [PATCH v3 3/3] IB/ipoib: Log sysfs 'dev_id' accesses from userspace

2018-09-05 Thread Stephen Hemminger
On Mon, 3 Sep 2018 19:13:16 +0300 Arseny Maslennikov wrote: > + if (ndev->dev_id == ndev->dev_port) { > + netdev_info_once(ndev, > + "\"%s\" wants to know my dev_id. " > + "Should it look at dev_port instead?\n", > +

[PATCH net-next] qed*: Utilize FW 8.37.7.0

2018-09-05 Thread Denis Bolotin
This patch adds a new qed firmware with fixes and support for new features. Fixes: - Fix a rare case of device crash with iWARP, iSCSI or FCoE offload. - Fix GRE tunneled traffic when iWARP offload is enabled. - Fix RoCE failure in ib_send_bw when using inline data. - Fix latency optimization

Re: [PATCH net-next] net/mlx5e: Make function mlx5i_grp_sw_update_stats() static

2018-09-05 Thread David Miller
From: Wei Yongjun Date: Wed, 5 Sep 2018 11:16:02 + > Fixes the following sparse warning: > > drivers/net/ethernet/mellanox/mlx5/core/ipoib/ipoib.c:119:6: warning: > symbol 'mlx5i_grp_sw_update_stats' was not declared. Should it be static? > > Signed-off-by: Wei Yongjun Applied.

Re: [PATCH net] mlxsw: spectrum_buffers: Set up a dedicated pool for BUM traffic

2018-09-05 Thread David Miller
From: Petr Machata Date: Wed, 05 Sep 2018 12:16:00 +0200 > MC-aware mode was recently enabled by mlxsw on Spectrum switches in > commit 7b8195306694 ("mlxsw: spectrum: Configure MC-aware mode on mlxsw > ports"). Unfortunately, testing has shown that the fix is incomplete and > in the presented

[PATCH net 3/3] net/iucv: declare iucv_path_table_empty() as static

2018-09-05 Thread Julian Wiedmann
Fixes a compile warning. Signed-off-by: Julian Wiedmann --- net/iucv/iucv.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/net/iucv/iucv.c b/net/iucv/iucv.c index 8f7ef167c45a..eb502c6290c2 100644 --- a/net/iucv/iucv.c +++ b/net/iucv/iucv.c @@ -1874,7 +1874,7 @@ static void

[PATCH net 2/3] net/af_iucv: fix skb handling on HiperTransport xmit error

2018-09-05 Thread Julian Wiedmann
When sending an skb, afiucv_hs_send() bails out on various error conditions. But currently the caller has no way of telling whether the skb was freed or not - resulting in potentially either a) leaked skbs from iucv_send_ctrl(), or b) double-free's from iucv_sock_sendmsg(). As dev_queue_xmit()

[PATCH net 1/3] net/af_iucv: drop inbound packets with invalid flags

2018-09-05 Thread Julian Wiedmann
Inbound packets may have any combination of flag bits set in their iucv header. If we don't know how to handle a specific combination, drop the skb instead of leaking it. To clarify what error is returned in this case, replace the hard-coded 0 with the corresponding macro. Signed-off-by: Julian

[PATCH net 0/3] net/iucv: fixes 2018-09-05

2018-09-05 Thread Julian Wiedmann
Hi Dave, please apply three straight-forward fixes for iucv. One that prevents leaking the skb on malformed inbound packets, one to fix the error handling on transmit error, and one to get rid of a compile warning. Thanks, Julian Julian Wiedmann (3): net/af_iucv: drop inbound packets with

Re: [PATCH net 2/3] tls: clear key material from kernel memory when do_tls_setsockopt_conf fails

2018-09-05 Thread Boris Pismenny
Hi Sabrina, On 9/5/2018 4:21 PM, Sabrina Dubroca wrote: Fixes: 3c4d7559159b ("tls: kernel TLS support") Signed-off-by: Sabrina Dubroca --- net/tls/tls_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/net/tls/tls_main.c b/net/tls/tls_main.c index

Re: [PATCH v3 3/3] IB/ipoib: Log sysfs 'dev_id' accesses from userspace

2018-09-05 Thread Leon Romanovsky
On Mon, Sep 03, 2018 at 07:13:16PM +0300, Arseny Maslennikov wrote: > Signed-off-by: Arseny Maslennikov > --- > drivers/infiniband/ulp/ipoib/ipoib_main.c | 38 +++ > 1 file changed, 38 insertions(+) > > diff --git a/drivers/infiniband/ulp/ipoib/ipoib_main.c >

  1   2   >