[PATCH net-next 2/3] bpf, perf: split bpf_perf_event_output

2016-07-12 Thread Daniel Borkmann
Split the bpf_perf_event_output() helper as a preparation into two parts. The newly bpf_perf_event_output() will prepare the raw record itself and test for unknown flags from BPF trace context, where the __bpf_perf_event_output() does the core work and will be reused later as well. Signed-off-by:

[PATCH net v3 1/2] net: ethoc: Fix early error paths

2016-07-12 Thread Florian Fainelli
In case any operation fails before we can successfully go the point where we would register a MDIO bus, we would be going to an error label which involves unregistering then freeing this yet to be created MDIO bus. Update all error paths to go to label free which is the only one valid until either

[PATCH net v3 0/2] net: ethoc: Error path and transmit fixes

2016-07-12 Thread Florian Fainelli
Hi all, This patch series contains two patches for the ethoc driver while testing on a TS-7300 board where ethoc is provided by an on-board FPGA. First patch was cooked after chasing crashes with invalid resources passed to the driver. Second patch was cooked after seeing that an interface

[PATCH net v3 2/2] net: ethoc: Correctly pad short packets

2016-07-12 Thread Florian Fainelli
Even though the hardware can be doing zero padding, we want the SKB to be going out on the wire with the appropriate size. This fixes packet truncations observed with e.g: ARP packets. Signed-off-by: Florian Fainelli --- drivers/net/ethernet/ethoc.c | 6 ++ 1 file

[PATCH net-next] net: vrf: Documentation update

2016-07-12 Thread David Ahern
Update vrf documentation for changes made to 4.4 - 4.8 kernels and iproute2 support for vrf keyword. Signed-off-by: David Ahern --- Documentation/networking/vrf.txt | 201 --- 1 file changed, 103 insertions(+), 98 deletions(-) diff

[PATCH net-next 1/3] perf, events: add non-linear data support for raw records

2016-07-12 Thread Daniel Borkmann
This patch adds support for non-linear data on raw records. It means that for such data, the newly introduced __output_custom() helper will be used instead of __output_copy(). __output_custom() will invoke whatever custom callback is passed in via struct perf_raw_record_frag to extract the data

Re: [patch net-next v2 2/2] mlxsw: core: Trace EMAD messages

2016-07-12 Thread David Miller
From: Jiri Pirko Date: Tue, 12 Jul 2016 18:05:04 +0200 > From: Jiri Pirko > > Trace EMAD messages going down to HW and up from HW. Devlink needs to be > registered before EMAD init so the trace function can be called > with valid devlink handle. > >

Re: [patch net-next v2 1/2] devlink: add hardware messages tracing facility

2016-07-12 Thread David Miller
From: Jiri Pirko Date: Tue, 12 Jul 2016 18:05:03 +0200 > From: Jiri Pirko > > Define a tracepoint and allow user to trace messages going to and from > hardware associated with devlink instance. > > Signed-off-by: Jiri Pirko Applied.

[PATCH net 2/2] dccp: limit sk_filter trim to payload

2016-07-12 Thread Willem de Bruijn
From: Willem de Bruijn Dccp verifies packet integrity, including length, at initial rcv in dccp_invalid_packet, later pulls headers in dccp_enqueue_skb. A call to sk_filter in-between can cause __skb_pull to wrap skb->len. skb_copy_datagram_msg interprets this as a negative

[PATCH net 2/2] net/mlx5e: start/stop all tx queues upon open/close netdev

2016-07-12 Thread Saeed Mahameed
From: Mohamad Haj Yahia Start all tx queues (including inactive ones) when opening the netdev. Stop all tx queues (including inactive ones) when closing the netdev. This is a workaround for the tx timeout watchdog false alarm issue in which the netdev watchdog is polling

[PATCH net 1/2] net/mlx5e: Fix TX Timeout to detect queues stuck on BQL

2016-07-12 Thread Saeed Mahameed
From: Daniel Jurgens Change netif_tx_queue_stopped to netif_xmit_stopped. This will show when queues are stopped due to byte queue limits. Fixes: 3947ca185999 ('net/mlx5e: Implement ndo_tx_timeout callback') Signed-off-by: Daniel Jurgens

[PATCH net 0/2] mlx5 tx timeout watchdog fixes

2016-07-12 Thread Saeed Mahameed
Hi Dave, This patch set provides two trivial fixes for the tx timeout series lately applied into net 4.7. >From Daniel, detect stuck queues due to BQL >From Mohamad, fix tx timeout watchdog false alarm Hopefully those two fixes will make it to -stable, assuming 3947ca185999 ('net/mlx5e:

[PATCH net 0/2] limit sk_filter trim to payload

2016-07-12 Thread Willem de Bruijn
From: Willem de Bruijn Sockets can apply a filter to incoming packets to drop or trim them. Fix two codepaths that call skb_pull/__skb_pull after sk_filter without checking for packet length. Reading beyond skb->tail after trimming happens in more codepaths, but safety of

Re: [PATCH v2 0/8] thunderbolt: Introducing Thunderbolt(TM) networking

2016-07-12 Thread Andreas Noever
On Tue, Jul 12, 2016 at 12:50 PM, Levy, Amir (Jer) wrote: > On Wed, Jun 29 2016, 11:35 AM, Levy, Amir (Jer) wrote: >> This is version 2 of Thunderbolt(TM) driver for non-Apple hardware. >> >> Changes since v1: >> - Separation to 2 modules. >> - Moved ICM specific

[PATCH net-next 0/3] BPF event output helper improvements

2016-07-12 Thread Daniel Borkmann
This set adds improvements to the BPF event output helper to support non-linear data sampling, here specifically, for skb context. For details please see individual patches. The set is based against net-next tree. Thanks a lot! Daniel Borkmann (3): perf, events: add non-linear data support for

[PATCH net-next 3/3] bpf: avoid stack copy and use skb ctx for event output

2016-07-12 Thread Daniel Borkmann
This work improves bpf_skb_event_output() helper in two ways, i) it avoids that users need to unnecessary extract sampled skb data to stack first via bpf_skb_load_bytes() and then copy once again into the ring buffer slot, and ii) it avoids that only portions can be sampled with

[PATCH net 1/2] rose: limit sk_filter trim to payload

2016-07-12 Thread Willem de Bruijn
From: Willem de Bruijn Sockets can have a filter program attached that drops or trims incoming packets based on the filter program return value. Rose requires data packets to have at least ROSE_MIN_LEN bytes. It verifies this on arrival in rose_route_frame and

Re: [PATCH net 2/2] dccp: limit sk_filter trim to payload

2016-07-12 Thread Daniel Borkmann
On 07/13/2016 12:18 AM, Willem de Bruijn wrote: From: Willem de Bruijn Dccp verifies packet integrity, including length, at initial rcv in dccp_invalid_packet, later pulls headers in dccp_enqueue_skb. A call to sk_filter in-between can cause __skb_pull to wrap skb->len.

Re: [PATCH net 1/2] rose: limit sk_filter trim to payload

2016-07-12 Thread Daniel Borkmann
On 07/13/2016 12:18 AM, Willem de Bruijn wrote: From: Willem de Bruijn Sockets can have a filter program attached that drops or trims incoming packets based on the filter program return value. Rose requires data packets to have at least ROSE_MIN_LEN bytes. It verifies this

Re: XDP seeking input from NIC hardware vendors

2016-07-12 Thread Jesper Dangaard Brouer
On Tue, 12 Jul 2016 12:13:01 -0700 John Fastabend wrote: > On 16-07-11 07:24 PM, Alexei Starovoitov wrote: > > On Sat, Jul 09, 2016 at 01:27:26PM +0200, Jesper Dangaard Brouer wrote: > >> On Fri, 8 Jul 2016 18:51:07 +0100 > >> Jakub Kicinski

[PATCH net 1/2] rose: limit sk_filter trim to payload

2016-07-12 Thread Willem de Bruijn
From: Willem de Bruijn Sockets can have a filter program attached that drops or trims incoming packets based on the filter program return value. Rose requires data packets to have at least ROSE_MIN_LEN bytes. It verifies this on arrival in rose_route_frame and

[PATCH net-next 06/10] net/mlx5e: Adjustments in the TC offload code towards reuse for SRIOV

2016-07-12 Thread Saeed Mahameed
From: Or Gerlitz Towards reusing the TC offloads code for an SRIOV use-case, change some of the helper functions to have _nic in their names so it's clear what's NIC unique and what's general. Also group together the NIC related helpers so we can easily branch per the

[PATCH net-next 04/10] net/mlx5: E-Switch, Use two priorities for SRIOV offloads mode

2016-07-12 Thread Saeed Mahameed
From: Or Gerlitz In the offloads mode, some slow path rules are added by the driver (e.g send-to-vport), while offloaded rules are to be added from upper layers. The slow path rules have lower priority and we don't want matching on offloaded rules to suffer from extra

[PATCH net-next 02/10] net/mlx5: Introduce bulk reading of flow counters

2016-07-12 Thread Saeed Mahameed
From: Amir Vadai This commit utilize the ability of ConnectX-4 to bulk read flow counters. Few bulk counter queries could be done instead of issuing thousands of firmware commands per second to get statistics of all flows set to HW, such as those programmed when we offload tc

[PATCH net-next 05/10] net/mlx5: E-Switch, Add API to configure rules for the offloaded mode

2016-07-12 Thread Saeed Mahameed
From: Or Gerlitz This allows for upper levels in the driver, e.g the TC offload code to add e-switch offloaded steering rules. The caller provides the rule spec for matching, action, source and destination vports. Signed-off-by: Or Gerlitz

[PATCH net-next 08/10] net/mlx5e: Add TC drop and mirred/redirect action parsing for SRIOV offloads

2016-07-12 Thread Saeed Mahameed
From: Or Gerlitz Add the setup code that parses the TC actions needed to support offloading drop and mirred/redirect for SRIOV e-switch. We can redirect between two devices if they belong to the same HW switch, compare the switchdev HW ID attribute to enforce that.

[PATCH net-next 10/10] net/mlx5e: Add TC offload support for the VF representors netdevice

2016-07-12 Thread Saeed Mahameed
From: Or Gerlitz The VF representors support only TC filter/action offloads (not mqprio) and this is enabled for them by default. Signed-off-by: Or Gerlitz Signed-off-by: Saeed Mahameed ---

[PATCH net-next 01/10] net/mlx5: Store counters in rbtree instead of list

2016-07-12 Thread Saeed Mahameed
From: Amir Vadai In order to use bulk counters, we need to have counters sorted by id. Signed-off-by: Amir Vadai Reviewed-by: Or Gerlitz Signed-off-by: Saeed Mahameed ---

[PATCH net-next 03/10] net/mlx5e: Offload TC flow counters only when supported

2016-07-12 Thread Saeed Mahameed
From: Or Gerlitz Currenly, the code that programs the flow actions into the firmware doesn't check if was actually asked to offload the statistics, fix that. Fixes: aad7e08d39bd ('net/mlx5e: Hardware offloaded flower filter statistics support') Signed-off-by: Or Gerlitz

[PATCH net-next 09/10] net/mlx5e: Add TC HW support for FDB (SRIOV e-switch) offloads

2016-07-12 Thread Saeed Mahameed
From: Or Gerlitz Enhance the TC offload code such that when the eswitch exists and it's mode being SRIOV offloads, we do TC actions parsing and setup targeted for eswitch. Next, we add the offloaded flow to the HW e-switch (fdb). Signed-off-by: Or Gerlitz

Re: [PATCH v8 06/11] net/mlx4_en: add page recycle to prepare rx ring for tx support

2016-07-12 Thread David Miller
From: Brenden Blanco Date: Tue, 12 Jul 2016 00:51:29 -0700 > + mlx4_en_free_resources(priv); > + > old_prog = xchg(>prog, prog); > if (old_prog) > bpf_prog_put(old_prog); > > - return 0; > + err = mlx4_en_alloc_resources(priv); > +

Re: [PATCH 1/1] net: nps_enet: Fix PCS reset

2016-07-12 Thread David Miller
From: Elad Kanfi Date: Tue, 12 Jul 2016 16:01:11 +0300 > From: Noam Camus > > During commit b54b8c2d6e3c > ("net: ezchip: adapt driver to little endian architecture") > adapting to little endian architecture, > zeroing of controller was left out. >

[PATCH net-next 07/10] net/switchdev: Export the same parent ID service function

2016-07-12 Thread Saeed Mahameed
From: Or Gerlitz This helper serves to know if two switchdev port netdevices belong to the same HW ASIC, e.g to figure out if forwarding offload is possible between them. Signed-off-by: Or Gerlitz Signed-off-by: Saeed Mahameed

[PATCH net-next 00/10] Mellanox 100G mlx5 Bulk flow statistics and SRIOV TC offloads

2016-07-12 Thread Saeed Mahameed
Hi Dave, This series from Amir and Or deals with two enhancements for the mlx5 TC offloads. The 1st two patches add bulk reading of flow counters. Few bulk counter queries are used instead of issuing thousands firmware commands per second to get statistics of all flows set to HW. The next

Re: [patch net-next 1/2] devlink: add hardware messages tracing facility

2016-07-12 Thread Jiri Pirko
Mon, Jul 11, 2016 at 10:54:12PM CEST, rost...@goodmis.org wrote: >On Mon, 11 Jul 2016 15:18:47 +0200 >Jiri Pirko wrote: > >> diff --git a/include/net/devlink.h b/include/net/devlink.h >> index c99ffe8..865ade6 100644 >> --- a/include/net/devlink.h >> +++ b/include/net/devlink.h

[iproute PATCH v2] ip-address.8: Document autojoin flag

2016-07-12 Thread Phil Sutter
Description copied from related kernel support commit message with a little tailoring to fit. While at it, fix font of non-terminal CONFFLAG-LIST in synopsis. Signed-off-by: Phil Sutter --- Changes since v1: - Set commands/flags in bold font instead of quotes. - Make capitalization

Re: [PATCH] iwlwifi: add missing type declaration

2016-07-12 Thread Luca Coelho
On Mon, 2016-07-11 at 22:49 +0200, Arnd Bergmann wrote: > The iwl-debug.h header relies in implicit inclusion of linux/device.h > and > we get a lot of warnings without that: > > drivers/net/wireless/intel/iwlwifi/iwl-debug.h:44:23: error: 'struct > device' declared inside parameter list will not

[PATCH v8 03/11] rtnl: add option for setting link xdp prog

2016-07-12 Thread Brenden Blanco
Sets the bpf program represented by fd as an early filter in the rx path of the netdev. The fd must have been created as BPF_PROG_TYPE_XDP. Providing a negative value as fd clears the program. Getting the fd back via rtnl is not possible, therefore reading of this value merely provides a bool

[PATCH v8 10/11] bpf: enable direct packet data write for xdp progs

2016-07-12 Thread Brenden Blanco
For forwarding to be effective, XDP programs should be allowed to rewrite packet data. This requires that the drivers supporting XDP must all map the packet memory as TODEVICE or BIDIRECTIONAL before invoking the program. Signed-off-by: Brenden Blanco ---

[PATCH v8 04/11] net/mlx4_en: add support for fast rx drop bpf program

2016-07-12 Thread Brenden Blanco
Add support for the BPF_PROG_TYPE_XDP hook in mlx4 driver. In tc/socket bpf programs, helpers linearize skb fragments as needed when the program touches the packet data. However, in the pursuit of speed, XDP programs will not be allowed to use these slower functions, especially if it involves

[PATCH v8 01/11] bpf: add XDP prog type for early driver filter

2016-07-12 Thread Brenden Blanco
Add a new bpf prog type that is intended to run in early stages of the packet rx path. Only minimal packet metadata will be available, hence a new context type, struct xdp_md, is exposed to userspace. So far only expose the packet start and end pointers, and only in read mode. An XDP program must

[PATCH v8 09/11] net/mlx4_en: add xdp forwarding and data write support

2016-07-12 Thread Brenden Blanco
A user will now be able to loop packets back out of the same port using a bpf program attached to xdp hook. Updates to the packet contents from the bpf program is also supported. For the packet write feature to work, the rx buffers are now mapped as bidirectional when the page is allocated. This

[PATCH v8 11/11] bpf: add sample for xdp forwarding and rewrite

2016-07-12 Thread Brenden Blanco
Add a sample that rewrites and forwards packets out on the same interface. Observed single core forwarding performance of ~10Mpps. Since the mlx4 driver under test recycles every single packet page, the perf output shows almost exclusively just the ring management and bpf program work. Slowdowns

[PATCH v8 07/11] bpf: add XDP_TX xdp_action for direct forwarding

2016-07-12 Thread Brenden Blanco
XDP enabled drivers must transmit received packets back out on the same port they were received on when a program returns this action. Signed-off-by: Brenden Blanco --- include/uapi/linux/bpf.h | 1 + 1 file changed, 1 insertion(+) diff --git a/include/uapi/linux/bpf.h

[PATCH v8 08/11] net/mlx4_en: break out tx_desc write into separate function

2016-07-12 Thread Brenden Blanco
In preparation for writing the tx descriptor from multiple functions, create a helper for both normal and blueflame access. Signed-off-by: Brenden Blanco --- drivers/infiniband/hw/mlx4/qp.c| 11 +-- drivers/net/ethernet/mellanox/mlx4/en_tx.c | 127

Re: WARNING: CPU: 0 PID: 0 at net/ipv4/af_inet.c:155 inet_sock_destruct+0x1c4/0x1dc

2016-07-12 Thread Mason
On 05/07/2016 17:28, Florian Fainelli wrote: > Le 05/07/2016 07:50, Mason wrote: > >> On 05/07/2016 15:33, Mason wrote: >> >>> I was testing suspend/resume sequences where the suspend operation >>> fails and returns without having suspended the platform. Please forget I ever mentioned suspend,

Re: [PATCH v6 RESEND] r8152: Add support for setting pass through MAC address on RTL8153-AD

2016-07-12 Thread Michał Pecio
> From: Mario Limonciello > Date: Mon, 11 Jul 2016 19:58:04 -0500 > > > The RTL8153-AD supports a persistent system specific MAC address. > > This means a device plugged into two different systems with host > > side support will show different (but persistent) MAC

Re: [PATCH v7 02/11] net: add ndo to setup/query xdp prog in adapter rx

2016-07-12 Thread Brenden Blanco
On Mon, Jul 11, 2016 at 11:12:24PM -0700, David Miller wrote: > From: Brenden Blanco > Date: Mon, 11 Jul 2016 14:29:49 -0700 > > > + if (fd >= 0) { > > + prog = bpf_prog_get_type(fd, BPF_PROG_TYPE_XDP); > > + if (IS_ERR(prog)) > > +

[PATCH 1/1] bonding: restrict the data protected by rcu_read_lock

2016-07-12 Thread Zhu Yanjun
In this function, origin is a pointer to struct aggregator. No matter what agg is changed to, it has nothing to do with origin. CC: Jay Vosburgh Signed-off-by: Zhu Yanjun --- drivers/net/bonding/bond_3ad.c |2 +- 1 file changed, 1

Re: [PATCH 2/3] chcr: Support for Chelsio's Crypto Hardware

2016-07-12 Thread Herbert Xu
On Mon, Jul 11, 2016 at 11:28:07AM -0700, Yeshaswi M R Gowda wrote: > > + u_ctx = ULD_CTX(ctx); > + if (cxgb4_is_crypto_q_full(u_ctx->lldi.ports[0], ctx->tx_channel_id)) > + return -EBUSY; You cannot just return -EBUSY. If the request has the MAY_BACKLOG bit set, it must be

Re: [PATCH v7 01/11] bpf: add XDP prog type for early driver filter

2016-07-12 Thread David Miller
From: Brenden Blanco Date: Mon, 11 Jul 2016 14:29:48 -0700 > + WARN_ONCE(1, "\n" > + "*\n" > + "** NOTICE NOTICE NOTICE NOTICE NOTICE NOTICE **\n" > + "**

Re: [PATCH v7 02/11] net: add ndo to setup/query xdp prog in adapter rx

2016-07-12 Thread David Miller
From: Brenden Blanco Date: Mon, 11 Jul 2016 14:29:49 -0700 > + if (fd >= 0) { > + prog = bpf_prog_get_type(fd, BPF_PROG_TYPE_XDP); > + if (IS_ERR(prog)) > + return PTR_ERR(prog); > + } > + > + xdp.command =

Re: [PATCH v7 04/11] net/mlx4_en: add support for fast rx drop bpf program

2016-07-12 Thread David Miller
From: Brenden Blanco Date: Mon, 11 Jul 2016 14:29:51 -0700 > + if (priv->num_frags > 1) > + return -EOPNOTSUPP; I hate to be the user who has to debug why his XDP program won't load just because he set a jumbo MTU beforehand.

Re: [patch net-next 1/2] devlink: add hardware messages tracing facility

2016-07-12 Thread Jiri Pirko
Mon, Jul 11, 2016 at 10:45:16PM CEST, da...@davemloft.net wrote: >From: Jiri Pirko >Date: Mon, 11 Jul 2016 15:18:47 +0200 > >> From: Jiri Pirko >> >> Define a tracepoint and allow user to trace messages going to and from >> hardware associated with devlink

Re: [patch net-next 1/2] devlink: add hardware messages tracing facility

2016-07-12 Thread Jiri Pirko
Mon, Jul 11, 2016 at 06:08:14PM CEST, rost...@goodmis.org wrote: >On Mon, 11 Jul 2016 15:18:47 +0200 >Jiri Pirko wrote: > >> From: Jiri Pirko >> >> Define a tracepoint and allow user to trace messages going to and from >> hardware associated with devlink

Re: [PATCH v7 01/11] bpf: add XDP prog type for early driver filter

2016-07-12 Thread Brenden Blanco
On Mon, Jul 11, 2016 at 11:02:54PM -0700, David Miller wrote: > From: Brenden Blanco > Date: Mon, 11 Jul 2016 14:29:48 -0700 > > > + WARN_ONCE(1, "\n" > > +"*\n" > > +"** NOTICE NOTICE

Re: [PATCH v7 02/11] net: add ndo to setup/query xdp prog in adapter rx

2016-07-12 Thread David Miller
From: Brenden Blanco Date: Mon, 11 Jul 2016 23:35:00 -0700 > On Mon, Jul 11, 2016 at 11:12:24PM -0700, David Miller wrote: >> From: Brenden Blanco >> Date: Mon, 11 Jul 2016 14:29:49 -0700 >> >> > + if (fd >= 0) { >> > + prog =

Re: [PATCH 3/3] crypto: Added Chelsio Menu to the Kconfig file

2016-07-12 Thread Herbert Xu
On Tue, Jul 12, 2016 at 03:30:41AM +0800, kbuild test robot wrote: > Hi, > > [auto build test WARNING on net-next/master] > [also build test WARNING on v4.7-rc7 next-20160711] > [if your patch is applied to the wrong git tree, please drop us a note to > help improve the system] Yeshaswi, please

[PATCH v8 05/11] Add sample for adding simple drop program to link

2016-07-12 Thread Brenden Blanco
Add a sample program that only drops packets at the BPF_PROG_TYPE_XDP_RX hook of a link. With the drop-only program, observed single core rate is ~20Mpps. Other tests were run, for instance without the dropcnt increment or without reading from the packet header, the packet rate was mostly

[PATCH v8 06/11] net/mlx4_en: add page recycle to prepare rx ring for tx support

2016-07-12 Thread Brenden Blanco
The mlx4 driver by default allocates order-3 pages for the ring to consume in multiple fragments. When the device has an xdp program, this behavior will prevent tx actions since the page must be re-mapped in TODEVICE mode, which cannot be done if the page is still shared. Start by making the

[PATCH v8 02/11] net: add ndo to setup/query xdp prog in adapter rx

2016-07-12 Thread Brenden Blanco
Add one new netdev op for drivers implementing the BPF_PROG_TYPE_XDP filter. The single op is used for both setup/query of the xdp program, modelled after ndo_setup_tc. Signed-off-by: Brenden Blanco --- include/linux/netdevice.h | 34 ++

[PATCH v8 00/11] Add driver bpf hook for early packet drop and forwarding

2016-07-12 Thread Brenden Blanco
This patch set introduces new infrastructure for programmatically processing packets in the earliest stages of rx, as part of an effort others are calling eXpress Data Path (XDP) [1]. Start this effort by introducing a new bpf program type for early packet filtering, before even an skb has been

[iproute PATCH] ip-macsec.8: fix typo in 'examples' section

2016-07-12 Thread Davide Caratti
fix wrong 'device' keyword in 'ip link add device eth0' Signed-off-by: Davide Caratti --- man/man8/ip-macsec.8 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/man/man8/ip-macsec.8 b/man/man8/ip-macsec.8 index e8455d7..03ed700 100644 ---

RE: [PATCH v8 06/11] net/mlx4_en: add page recycle to prepare rx ring for tx support

2016-07-12 Thread Tariq Toukan
>The mlx4 driver by default allocates order-3 pages for the ring to consume in >multiple fragments. When the device has an xdp program, this behavior will >prevent tx actions since the page must be re-mapped in TODEVICE mode, which >cannot be done if the page is still shared. > >Start by making

Re: [net-next PATCH RFC] mlx4: RX prefetch loop

2016-07-12 Thread Alexei Starovoitov
On Tue, Jul 12, 2016 at 09:52:52PM +0200, Jesper Dangaard Brouer wrote: > > > > >> Also unconditionally doing batch of 8 may also hurt depending on what > > >> is happening either with the stack, bpf afterwards or even cpu version. > > > > > > See this as software DDIO, if the unlikely case

Re: [PATCH net-next 3/3] bpf: avoid stack copy and use skb ctx for event output

2016-07-12 Thread kbuild test robot
Hi, [auto build test WARNING on net-next/master] url: https://github.com/0day-ci/linux/commits/Daniel-Borkmann/BPF-event-output-helper-improvements/20160713-065944 config: s390-allyesconfig (attached as .config) compiler: s390x-linux-gnu-gcc (Debian 5.3.1-8) 5.3.1 20160205 reproduce:

Re: [PATCH net-next 3/3] bpf: avoid stack copy and use skb ctx for event output

2016-07-12 Thread Fengguang Wu
Hi Daniel, On Wed, Jul 13, 2016 at 01:45:47AM +0200, Daniel Borkmann wrote: On 07/13/2016 01:25 AM, kbuild test robot wrote: Hi, [auto build test WARNING on net-next/master] url: https://github.com/0day-ci/linux/commits/Daniel-Borkmann/BPF-event-output-helper-improvements/20160713-065944

Re: [PATCH v8 01/11] bpf: add XDP prog type for early driver filter

2016-07-12 Thread Alexei Starovoitov
On Tue, Jul 12, 2016 at 07:52:53AM -0700, Tom Herbert wrote: > On Tue, Jul 12, 2016 at 6:14 AM, Jesper Dangaard Brouer > wrote: > > > > On Tue, 12 Jul 2016 00:51:24 -0700 Brenden Blanco > > wrote: > > > >> Add a new bpf prog type that is intended to run

Re: iwlwifi: add missing type declaration

2016-07-12 Thread Kalle Valo
Arnd Bergmann wrote: > The iwl-debug.h header relies in implicit inclusion of linux/device.h and > we get a lot of warnings without that: > > drivers/net/wireless/intel/iwlwifi/iwl-debug.h:44:23: error: 'struct device' > declared inside parameter list will not be visible outside

[PATCH iproute2] ip route: restore route entries in correct order

2016-07-12 Thread Xin Long
Sometimes we cannot restore route entries, because in kernel [1] fib_check_nh() [2] fib_valid_prefsrc() cause some routes to depend on existence of others while adding. For example, we saved all the routes, and flushed all tables [a] default via 192.168.122.1 dev eth0 [b] 192.168.122.0/24

RE: [PATCH v2 0/8] thunderbolt: Introducing Thunderbolt(TM) networking

2016-07-12 Thread Levy, Amir (Jer)
On Wed, Jun 29 2016, 11:35 AM, Levy, Amir (Jer) wrote: > This is version 2 of Thunderbolt(TM) driver for non-Apple hardware. > > Changes since v1: > - Separation to 2 modules. > - Moved ICM specific registers definition to ICM header file. > - Added new Thunderbolt device IDs. > - Renamed the

RE: [PATCH v8 08/11] net/mlx4_en: break out tx_desc write into separate function

2016-07-12 Thread Tariq Toukan
>In preparation for writing the tx descriptor from multiple functions, create a >helper for both normal and blueflame access. > >Signed-off-by: Brenden Blanco Reviewed-by: Tariq Toukan

Re: [net-next PATCH RFC] mlx4: RX prefetch loop

2016-07-12 Thread Jesper Dangaard Brouer
On Mon, 11 Jul 2016 16:05:11 -0700 Alexei Starovoitov wrote: > On Mon, Jul 11, 2016 at 01:09:22PM +0200, Jesper Dangaard Brouer wrote: > > > - /* Process all completed CQEs */ > > > + /* Extract and prefetch completed CQEs */ > > > while (XNOR(cqe->owner_sr_opcode

Re: WARNING: CPU: 0 PID: 0 at net/ipv4/af_inet.c:155 inet_sock_destruct+0x1c4/0x1dc

2016-07-12 Thread Mason
On 12/07/2016 11:53, Mason wrote: > However, the 310 seconds time span still seems to be relevant. > > Steps to reproduce: I booted the system, logged in as root, > mounted an NFS file system, then left the system idling at > the prompt. > > (I don't remember seeing this warning in v4.1 and

Re: [patch net-next 1/2] devlink: add hardware messages tracing facility

2016-07-12 Thread Steven Rostedt
On Tue, 12 Jul 2016 10:38:37 +0200 Jiri Pirko wrote: > Hmm, I'm trying to make it work this was but it seems to be a bit more > complicated. I did not find any code doing this (having the tracepoint > compiled in or not) so I cannot copy the solution. > > The problem is that

[PATCH -next] rxrpc: Fix error handling in af_rxrpc_init()

2016-07-12 Thread weiyj_lk
From: Wei Yongjun security initialized after alloc workqueue, so we should exit security before destroy workqueue in the error handing. Fixes: 648af7fca159 ("rxrpc: Absorb the rxkad security module") Signed-off-by: Wei Yongjun ---

[PATCH -next] net: mediatek: fix non static symbol warnings

2016-07-12 Thread weiyj_lk
From: Wei Yongjun Fixes the following sparse warnings: drivers/net/ethernet/mediatek/mtk_eth_soc.c:79:5: warning: symbol '_mtk_mdio_write' was not declared. Should it be static? drivers/net/ethernet/mediatek/mtk_eth_soc.c:98:5: warning: symbol '_mtk_mdio_read'

Re: [patch net-next 1/2] devlink: add hardware messages tracing facility

2016-07-12 Thread Jiri Pirko
Tue, Jul 12, 2016 at 02:44:17PM CEST, rost...@goodmis.org wrote: >On Tue, 12 Jul 2016 10:38:37 +0200 >Jiri Pirko wrote: > > >> Hmm, I'm trying to make it work this was but it seems to be a bit more >> complicated. I did not find any code doing this (having the tracepoint >>

[PATCH -next] stmmac: dwmac-socfpga: fix wrong pointer passed to PTR_ERR()

2016-07-12 Thread weiyj_lk
From: Wei Yongjun PTR_ERR should access the value just tested by IS_ERR, otherwise the wrong error code will be returned. Signed-off-by: Wei Yongjun --- drivers/net/ethernet/stmicro/stmmac/dwmac-socfpga.c | 2 +- 1 file changed, 1

[PATCH -next] dwc_eth_qos: fix missing clk_disable_unprepare() on error in dwceqos_probe()

2016-07-12 Thread weiyj_lk
From: Wei Yongjun Fix missing clk_disable_unprepare() call before return from dwceqos_probe() in the error handling case of invalid fixed-link. Signed-off-by: Wei Yongjun --- drivers/net/ethernet/synopsys/dwc_eth_qos.c | 2 +- 1

RE: [PATCH] net: Fragment large datagrams even when IP_HDRINCL is set.

2016-07-12 Thread Alan Davey
>> On Wed, 15 Jun 2016, Alan Davey wrote: >> >>> The only case that would break is that where an application relies on >>> the existing (documented as a bug) feature of getting an EMSGSIZE >>> return code in the case of an over-sized packet. Applications that >>> perform their own

RE: [PATCH v8 04/11] net/mlx4_en: add support for fast rx drop bpf program

2016-07-12 Thread Tariq Toukan
>Add support for the BPF_PROG_TYPE_XDP hook in mlx4 driver. > >In tc/socket bpf programs, helpers linearize skb fragments as needed when the >program touches the packet data. However, in the pursuit of speed, XDP >programs will not be allowed to use these slower functions, especially if it

Re: [PATCH net-next 3/3] bpf: avoid stack copy and use skb ctx for event output

2016-07-12 Thread Daniel Borkmann
On 07/13/2016 01:25 AM, kbuild test robot wrote: Hi, [auto build test WARNING on net-next/master] url: https://github.com/0day-ci/linux/commits/Daniel-Borkmann/BPF-event-output-helper-improvements/20160713-065944 config: s390-allyesconfig (attached as .config) compiler: s390x-linux-gnu-gcc

Re: [PATCH v8 06/11] net/mlx4_en: add page recycle to prepare rx ring for tx support

2016-07-12 Thread Brenden Blanco
On Tue, Jul 12, 2016 at 02:18:32PM -0700, David Miller wrote: > From: Brenden Blanco > Date: Tue, 12 Jul 2016 00:51:29 -0700 > > > + mlx4_en_free_resources(priv); > > + > > old_prog = xchg(>prog, prog); > > if (old_prog) > > bpf_prog_put(old_prog); > >

Re: [PATCH net v2 0/2] net: ethoc: Error path and transmit fixes

2016-07-12 Thread Max Filippov
Hello, On Mon, Jul 11, 2016 at 04:35:53PM -0700, Florian Fainelli wrote: > This patch series contains two patches for the ethoc driver while testing on a > TS-7300 board where ethoc is provided by an on-board FPGA. > > First patch was cooked after chasing crashes with invalid resources passed to

Re: [PATCH v2 net] ipv6: addrconf: fix Juniper SSL VPN client regression

2016-07-12 Thread Bjørn Mork
Hannes, I just realized that I missed you on the CC list of the v2 patch. Sorry. It was definitely not my intention. I really appreciate the feedback you have kindly provided before. I guess you might have seen it in netdev anyway, but in case not, here is a direct patchwork link:

Re: [PATCH v8 01/11] bpf: add XDP prog type for early driver filter

2016-07-12 Thread Tom Herbert
On Tue, Jul 12, 2016 at 6:14 AM, Jesper Dangaard Brouer wrote: > > On Tue, 12 Jul 2016 00:51:24 -0700 Brenden Blanco > wrote: > >> Add a new bpf prog type that is intended to run in early stages of the >> packet rx path. Only minimal packet metadata will

Re: Multi-thread udp 4.7 regression, bisected to 71d8c47fc653

2016-07-12 Thread Pablo Neira Ayuso
On Mon, Jul 11, 2016 at 06:17:39PM -0300, Marc Dionne wrote: > Hi Pablo, > > Testing out your patch: > > 1) With no NAT in place, the clash resolution happens, with no side > effects. No EPERM errors are seen. > > 2) With ip(6)table_nat loaded, the clash resolution fails and I get > some EPERM

Re: WARNING: CPU: 0 PID: 0 at net/ipv4/af_inet.c:155 inet_sock_destruct+0x1c4/0x1dc

2016-07-12 Thread Eric Dumazet
On Tue, 2016-07-12 at 11:53 +0200, Mason wrote: > On 05/07/2016 17:28, Florian Fainelli wrote: > > > Le 05/07/2016 07:50, Mason wrote: > > > >> On 05/07/2016 15:33, Mason wrote: > >> > >>> I was testing suspend/resume sequences where the suspend operation > >>> fails and returns without having

[PATCH 1/1] Fix PCS reset

2016-07-12 Thread Elad Kanfi
From: Noam Camus During commit b54b8c2d6e3c ("net: ezchip: adapt driver to little endian architecture") adapting to little endian architecture, zeroing of controller was left out. Signed-off-by: Elad Kanfi ---

Re: WARNING: CPU: 0 PID: 0 at net/ipv4/af_inet.c:155 inet_sock_destruct+0x1c4/0x1dc

2016-07-12 Thread Mason
On 12/07/2016 16:25, Eric Dumazet wrote: > Could you try this debug patch ? Note: I've been unable to trigger the warning again. Dunno what has changed... With your patch applied, I get a warning at boot: [4.668309] nb8800 26000.ethernet eth0: Link is Up - 1Gbps/Full - flow control rx/tx

Re: [PATCH v8 00/11] Add driver bpf hook for early packet drop and forwarding

2016-07-12 Thread Tariq Toukan
Regression tests for mlx4_en are currently running, results will be ready by tomorrow morning. Regards, Tariq

Re: [PATCH iproute2] ip route: restore route entries in correct order

2016-07-12 Thread Phil Sutter
On Tue, Jul 12, 2016 at 09:37:58PM +0800, Xin Long wrote: > Sometimes we cannot restore route entries, because in kernel > [1] fib_check_nh() > [2] fib_valid_prefsrc() > cause some routes to depend on existence of others while adding. > > For example, we saved all the routes, and flushed all

Re: [PATCH v2 net] ipv6: addrconf: fix Juniper SSL VPN client regression

2016-07-12 Thread Hannes Frederic Sowa
On 11.07.2016 16:48, David Miller wrote: > From: Bjørn Mork > Date: Mon, 11 Jul 2016 16:43:50 +0200 > >> The Juniper SSL VPN client use a "tun" interface and seems to >> be picky about visible changes.to it. Commit cc9da6cc4f56 >> ("ipv6: addrconf: use stable address generator for

Re: [PATCH v2 net] ipv6: addrconf: fix Juniper SSL VPN client regression

2016-07-12 Thread Bjørn Mork
David Miller writes: > What really irks me is that we "fixing" something without knowing what > actually is the problem. Agreed > Someone needs to figure out exactly what is making the Juniper thing > unhappy. It really shouldn't care if a link local address is assigned >

Re: [PATCH net v2 2/2] net: ethoc: Correctly pad short packets

2016-07-12 Thread Max Filippov
Hi Florian, On Mon, Jul 11, 2016 at 04:35:55PM -0700, Florian Fainelli wrote: > Even though the hardware can be doing zero padding, we want the SKB to > be going out on the wire with the appropriate size. This fixes packet > truncations observed with e.g: ARP packets. > > Signed-off-by: Florian

Re: ethtool TODO list - additional info

2016-07-12 Thread Jiri Pirko
Tue, Jul 05, 2016 at 05:37:42PM CEST, jorge.garcia.gonza...@gmail.com wrote: >Hi ! > >Some days ago, Jiri Pirko was talking about some next steps to >implement for ethtool. > > I haven't seen any follow up since ethtool's maintainer change. Can we have >additional details about these ? > >-

Re: [PATCH 1/1] bonding: restrict the data protected by rcu_read_lock

2016-07-12 Thread David Miller
From: Zhu Yanjun Date: Tue, 12 Jul 2016 15:28:17 +0800 > In this function, origin is a pointer to struct aggregator. > No matter what agg is changed to, it has nothing to do with origin. > > CC: Jay Vosburgh > Signed-off-by: Zhu Yanjun

Re: 4.6.3, pppoe + shaper workload, skb_panic / skb_push / ppp_start_xmit

2016-07-12 Thread nuclearcat
On 2016-07-12 20:31, Cong Wang wrote: On Mon, Jul 11, 2016 at 12:45 PM, wrote: Hi On latest kernel i noticed kernel panic happening 1-2 times per day. It is also happening on older kernel (at least 4.5.3). ... [42916.426463] Call Trace: [42916.426658]

Re: 4.6.3, pppoe + shaper workload, skb_panic / skb_push / ppp_start_xmit

2016-07-12 Thread Cong Wang
On Tue, Jul 12, 2016 at 11:03 AM, wrote: > On 2016-07-12 20:31, Cong Wang wrote: >> >> On Mon, Jul 11, 2016 at 12:45 PM, wrote: >>> >>> Hi >>> >>> On latest kernel i noticed kernel panic happening 1-2 times per day. It >>> is >>> also

  1   2   >