Re: [bpf PATCH] bpf: sockmap, decrement copied count correctly in redirect error case

2018-08-28 Thread Daniel Borkmann
On 08/25/2018 02:37 AM, John Fastabend wrote: > Currently, when a redirect occurs in sockmap and an error occurs in > the redirect call we unwind the scatterlist once in the error path > of bpf_tcp_sendmsg_do_redirect() and then again in sendmsg(). Then > in the error path of sendmsg we decrement t

bpf-next is OPEN

2018-08-28 Thread Daniel Borkmann
Merge window is over so new bpf-next development round begins. Thanks, Daniel

[PATCH bpf-next] bpf: remove duplicated include from syscall.c

2018-08-28 Thread YueHaibing
Remove duplicated include. Signed-off-by: YueHaibing --- kernel/bpf/syscall.c | 1 - 1 file changed, 1 deletion(-) diff --git a/kernel/bpf/syscall.c b/kernel/bpf/syscall.c index 8339d81..3c9636f 100644 --- a/kernel/bpf/syscall.c +++ b/kernel/bpf/syscall.c @@ -30,7 +30,6 @@ #include #include

[PATCH] specifically mention zero TX queues in error msg

2018-08-28 Thread Robert P. J. Day
To be consistent with subsequent error message specifically mentioning zero RX queues, add a reference to TX queues to the error message. Signed-off-by: Robert P. J. Day --- diff --git a/net/core/dev.c b/net/core/dev.c index 325fc5088370..a5d0c2244fb5 100644 --- a/net/core/dev.c +++ b/net/core/

Re: [RFC/PATCH] Add a socketoption IPV6_MULTICAST_ALL analogue to the IPV4 version

2018-08-28 Thread Andre Naujoks
On 5/8/18 1:48 PM, 吉藤英明 wrote: > Hi, > > 2018-05-08 15:41 GMT+09:00 Andre Naujoks : >> On 08.05.2018 08:31, 吉藤英明 wrote: >>> Hi, >>> >>> 2018-05-08 15:03 GMT+09:00 Andre Naujoks : On 11.04.2018 13:02, Andre Naujoks wrote: > Hi. Hi again. Since it has been a month now, I

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

2018-08-28 Thread Leon Romanovsky
From: Leon Romanovsky >From Mark, This series exposes the ability to create flow actions which can mutate packet headers. We do that by exposing two new verbs: * modify header - can change existing packet headers. packet * reformat - can encapsulate or decapsulate a packet. Once

[PATCH mlx5-next v1 03/15] net/mlx5: Export modify header alloc/dealloc functions

2018-08-28 Thread Leon Romanovsky
From: Mark Bloch Those functions will be used by the RDMA side to create modify header actions to be attached to flow steering rules via verbs. Signed-off-by: Mark Bloch Reviewed-by: Saeed Mahameed Signed-off-by: Leon Romanovsky --- drivers/net/ethernet/mellanox/mlx5/core/fs_cmd.c| 2 ++

[PATCH mlx5-next v1 02/15] net/mlx5: Add proper NIC TX steering flow tables support

2018-08-28 Thread Leon Romanovsky
From: Mark Bloch Extend the ability to add steering rules to NIC TX flow tables. For now, we are only adding TX bypass (egress) which is used by the RDMA side. This will allow to shape outgoing traffic and tweak it if needed, for example performing encapsulation or rewriting headers. Signed-off-

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

2018-08-28 Thread Leon Romanovsky
From: Mark Bloch Today we are able to attach encap and decap actions only to the FDB. In preparation to enable those actions on the NIC flow tables, break the single flag into two. Those flags control whatever a decap or encap operations can be attached to the flow table created. For FDB, if enca

[PATCH mlx5-next v1 01/15] net/mlx5: Cleanup flow namespace getter switch logic

2018-08-28 Thread Leon Romanovsky
From: Mark Bloch Refactor the switch logic so it's simpler to follow and understand. Signed-off-by: Mark Bloch Reviewed-by: Saeed Mahameed Signed-off-by: Leon Romanovsky --- drivers/net/ethernet/mellanox/mlx5/core/fs_core.c | 24 ++- 1 file changed, 6 insertions(+), 18 de

[PATCH mlx5-next v1 07/15] {net, RDMA}/mlx5: Rename encap to reformat packet

2018-08-28 Thread Leon Romanovsky
From: Mark Bloch Renames all encap mlx5_{core,ib} code to use the new naming of packet reformat. This change doesn't introduce any function change and is needed to properly reflect the operation being done by this action. For example not only can we encapsulate a packet, but also decapsulate it.

[PATCH mlx5-next v1 06/15] net/mlx5: Move header encap type to IFC header file

2018-08-28 Thread Leon Romanovsky
From: Mark Bloch Those bits are hardware specification and should be defined in the IFC header file. Signed-off-by: Mark Bloch Reviewed-by: Or Gerlitz Reviewed-by: Saeed Mahameed Signed-off-by: Leon Romanovsky --- drivers/net/ethernet/mellanox/mlx5/core/en_tc.c | 5 - include/linux/mlx5

[PATCH rdma-next v1 11/15] RDMA/uverbs: Add UVERBS_ATTR_CONST_IN to the specs language

2018-08-28 Thread Leon Romanovsky
From: Mark Bloch This makes it clear and safe to access constants passed in from user space. We define a consistent ABI of u64 for all constants, and verify that the data passed in can be represented by the type the user supplies. The expectation is this will always be used with an enum declarin

[PATCH rdma-next v1 15/15] RDMA/mlx5: Extend packet reformat verbs

2018-08-28 Thread Leon Romanovsky
From: Mark Bloch We expose new actions: L2_TO_L2_TUNNEL - A generic encap from L2 to L2, the data passed should be the encapsulating headers. L3_TUNNEL_TO_L2 - Will do decap where the inner packet starts from L3, the data should be mac or mac + vlan (14 or 18

[PATCH mlx5-next v1 08/15] net/mlx5: Expose new packet reformat capabilities

2018-08-28 Thread Leon Romanovsky
From: Mark Bloch Expose new abilities when creating a packet reformat context. The new types which can be created are: MLX5_REFORMAT_TYPE_L2_TO_L2_TUNNEL: Ability to create generic encap operation to be done by the HW. MLX5_REFORMAT_TYPE_L3_TUNNEL_TO_L2: Ability to create generic decap operatio

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

2018-08-28 Thread Leon Romanovsky
From: Mark Bloch Expose the ability to create a flow action which changes packet headers. The data passed from userspace should be modify header actions as defined by HW specification. Signed-off-by: Mark Bloch Signed-off-by: Leon Romanovsky --- drivers/infiniband/hw/mlx5/flow.c | 134

[PATCH rdma-next v1 13/15] RDMA/uverbs: Add generic function to fill in flow action object

2018-08-28 Thread Leon Romanovsky
From: Mark Bloch Refactor the initialization of a flow action object to a common function. Signed-off-by: Mark Bloch Signed-off-by: Leon Romanovsky --- drivers/infiniband/core/uverbs_std_types_flow_action.c | 7 ++- drivers/infiniband/hw/mlx5/flow.c | 8 +++- in

[PATCH mlx5-next v1 09/15] net/mlx5: Pass a namespace for packet reformat ID allocation

2018-08-28 Thread Leon Romanovsky
From: Mark Bloch Currently we attach packet reformat actions only to the FDB namespace. In preparation to be able to use that for NIC steering, pass the actual namespace as a parameter. Signed-off-by: Mark Bloch Reviewed-by: Or Gerlitz Reviewed-by: Saeed Mahameed Signed-off-by: Leon Romanovsk

[PATCH mlx5-next v1 10/15] net/mlx5: Export packet reformat alloc/dealloc functions

2018-08-28 Thread Leon Romanovsky
From: Mark Bloch This will allow for the RDMA side to allocate packet reformat context. Signed-off-by: Mark Bloch Reviewed-by: Saeed Mahameed Signed-off-by: Leon Romanovsky --- drivers/net/ethernet/mellanox/mlx5/core/fs_cmd.c| 2 ++ drivers/net/ethernet/mellanox/mlx5/core/mlx5_core.h | 8

Re: [PATCH] net: wireless: ath: Convert to using %pOFn instead of device_node.name

2018-08-28 Thread Kalle Valo
Rob Herring writes: > In preparation to remove the node name pointer from struct device_node, > convert printf users to use the %pOFn format specifier. > > Cc: Kalle Valo > Cc: "David S. Miller" > Cc: linux-wirel...@vger.kernel.org > Cc: netdev@vger.kernel.org > Signed-off-by: Rob Herring > --

[PATCH rdma-next v1 14/15] RDMA/mlx5: Add new flow action verb - packet reformat

2018-08-28 Thread Leon Romanovsky
From: Mark Bloch For now, only add L2_TUNNEL_TO_L2 option. This will allow to perform generic decap operation if the encapsulating protocol is L2 based, and the inner packet is also L2 based. For example this can be used to decap VXLAN packets. Signed-off-by: Mark Bloch Signed-off-by: Leon Roma

[PATCH mlx5-next v1 04/15] net/mlx5: Add support for more namespaces when allocating modify header

2018-08-28 Thread Leon Romanovsky
From: Mark Bloch There are RX and TX flow steering namespaces with different number of actions. Initialize them accordingly. Signed-off-by: Mark Bloch Reviewed-by: Saeed Mahameed Reviewed-by: Or Gerlitz Signed-off-by: Leon Romanovsky --- drivers/net/ethernet/mellanox/mlx5/core/fs_cmd.c | 5

Re: bpfilter causes a leftover kernel process

2018-08-28 Thread Olivier Brunel
On Mon, 27 Aug 2018 20:35:02 -0700 Alexei Starovoitov wrote: > I'm also running Arch Linux in my VM, but I'm not able to reproduce > umount issue. I'm guessing it's somehow related to non-static build > and libc.so being busy with old systemd. Oh, I mentioned it in a previous draft of my origina

[PATCH net 0/3] ipv6: fix error path of inet6_init()

2018-08-28 Thread Sabrina Dubroca
The error path of inet6_init() can trigger multiple kernel panics, mostly due to wrong ordering of cleanups. This series fixes those issues. Sabrina Dubroca (3): ipv6: fix cleanup ordering for ip6_mr failure ipv6: fix cleanup ordering for pingv6 registration net: rtnl: return early from rtnl

[PATCH net 3/3] net: rtnl: return early from rtnl_unregister_all when protocol isn't registered

2018-08-28 Thread Sabrina Dubroca
rtnl_unregister_all(PF_INET6) gets called from inet6_init in cases when no handler has been registered for PF_INET6 yet, for example if ip6_mr_init() fails. Abort and avoid a NULL pointer deref in that case. Example of panic (triggered by faking a failure of register_pernet_subsys): general

[PATCH net 1/3] ipv6: fix cleanup ordering for ip6_mr failure

2018-08-28 Thread Sabrina Dubroca
Commit 15e668070a64 ("ipv6: reorder icmpv6_init() and ip6_mr_init()") moved the cleanup label for ipmr_fail, but should have changed the contents of the cleanup labels as well. Now we can end up cleaning up icmpv6 even though it hasn't been initialized (jump to icmp_fail or ipmr_fail). Simply undo

[PATCH net 2/3] ipv6: fix cleanup ordering for pingv6 registration

2018-08-28 Thread Sabrina Dubroca
Commit 6d0bfe226116 ("net: ipv6: Add IPv6 support to the ping socket.") contains an error in the cleanup path of inet6_init(): when proto_register(&pingv6_prot, 1) fails, we try to unregister &pingv6_prot. When rawv6_init() fails, we skip unregistering &pingv6_prot. Example of panic (triggered by

RV: 20183516 document set

2018-08-28 Thread Docs
DEAR ALL TAKE NOTE 20183516 document set.xlsx Description: Binary data

[PATCH bpf-next 00/11] AF_XDP zero-copy support for i40e

2018-08-28 Thread Björn Töpel
From: Björn Töpel This patch set introduces zero-copy AF_XDP support for Intel's i40e driver. In the first preparatory patch we also add support for XDP_REDIRECT for zero-copy allocated frames so that XDP programs can redirect them. This was a ToDo from the first AF_XDP zero-copy patch set from e

[PATCH bpf-next 06/11] i40e: refactor Rx path for re-use

2018-08-28 Thread Björn Töpel
From: Björn Töpel In this commit, the Rx path is refactored some, as a step torwards the introduction AF_XDP Rx zero-copy. The page re-use counter is moved into the i40e_reuse_rx_page, instead of bumping the counter in many places. The Rx buffer page clearing is moved for better readability. Las

[PATCH bpf-next 09/11] i40e: move common Tx functions to i40e_txrx_common.h

2018-08-28 Thread Björn Töpel
From: Magnus Karlsson This patch prepares for the upcoming zero-copy Tx functionality, by moving common functions and refactor chunks of code into re-usable functions, used both by the regular path and zero-copy path. Signed-off-by: Magnus Karlsson --- drivers/net/ethernet/intel/i40e/i40e_txrx

[PATCH bpf-next 11/11] samples/bpf: add -c/--copy -z/--zero-copy flags to xdpsock

2018-08-28 Thread Björn Töpel
From: Björn Töpel The -c/--copy -z/--zero-copy flags enforces either copy or zero-copy mode. Signed-off-by: Björn Töpel --- samples/bpf/xdpsock_user.c | 12 +++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/samples/bpf/xdpsock_user.c b/samples/bpf/xdpsock_user.c index

[PATCH bpf-next 08/11] i40e: add AF_XDP zero-copy Rx support

2018-08-28 Thread Björn Töpel
From: Björn Töpel This patch adds zero-copy Rx support for AF_XDP sockets. Instead of allocating buffers of type MEM_TYPE_PAGE_SHARED, the Rx frames are allocated as MEM_TYPE_ZERO_COPY when AF_XDP is enabled for a certain queue. All AF_XDP specific functions are added to a new file, i40e_xsk.c.

[PATCH bpf-next 10/11] i40e: add AF_XDP zero-copy Tx support

2018-08-28 Thread Björn Töpel
From: Magnus Karlsson This patch adds zero-copy Tx support for AF_XDP sockets. It implements the ndo_xsk_async_xmit netdev ndo and performs all the Tx logic from a NAPI context. This means pulling egress packets from the Tx ring, placing the frames on the NIC HW descriptor ring and completing sen

[PATCH bpf-next 05/11] i40e: added queue pair disable/enable functions

2018-08-28 Thread Björn Töpel
From: Björn Töpel Add functions for queue pair enable/disable. Instead of resetting the whole device, only the affected queue pair is disabled or enabled. This plumbing is used in a later commit, when zero-copy AF_XDP support is introduced. Signed-off-by: Björn Töpel --- drivers/net/ethernet/

[PATCH bpf-next 03/11] xsk: expose xdp_umem_get_{data,dma} to drivers

2018-08-28 Thread Björn Töpel
From: Björn Töpel Move the xdp_umem_get_{data,dma} functions to include/net/xdp_sock.h, so that the upcoming zero-copy implementation in the Ethernet drivers can utilize them. Also, supply some dummy function implementations for CONFIG_XDP_SOCKETS=n configs. Signed-off-by: Björn Töpel --- inc

[PATCH bpf-next 07/11] i40e: move common Rx functions to i40e_txrx_common.h

2018-08-28 Thread Björn Töpel
From: Björn Töpel This patch prepares for the upcoming zero-copy Rx functionality, by moving/changing linkage of common functions, used both by the regular path and zero-copy path. Signed-off-by: Björn Töpel --- drivers/net/ethernet/intel/i40e/i40e_txrx.c | 33 --- .../ethern

[PATCH bpf-next 04/11] net: add napi_if_scheduled_mark_missed

2018-08-28 Thread Björn Töpel
From: Magnus Karlsson The function napi_if_scheduled_mark_missed is used to check if the NAPI context is scheduled, if so set NAPIF_STATE_MISSED and return true. Used by the AF_XDP zero-copy i40e Tx code implementation in order to make sure that irq affinity is honored by the napi context. Signe

[PATCH bpf-next 01/11] xdp: implement convert_to_xdp_frame for MEM_TYPE_ZERO_COPY

2018-08-28 Thread Björn Töpel
From: Björn Töpel This commit adds proper MEM_TYPE_ZERO_COPY support for convert_to_xdp_frame. Converting a MEM_TYPE_ZERO_COPY xdp_buff to an xdp_frame is done by transforming the MEM_TYPE_ZERO_COPY buffer into a MEM_TYPE_PAGE_ORDER0 frame. This is costly, and in the future it might make sense to

[PATCH bpf-next 02/11] xdp: export xdp_rxq_info_unreg_mem_model

2018-08-28 Thread Björn Töpel
From: Björn Töpel Export __xdp_rxq_info_unreg_mem_model as xdp_rxq_info_unreg_mem_model, so it can be used from netdev drivers. Also, add additional checks for the memory type. Signed-off-by: Björn Töpel --- include/net/xdp.h | 1 + net/core/xdp.c| 15 +-- 2 files changed, 14

Re: [PATCH bpf-next 00/11] AF_XDP zero-copy support for i40e

2018-08-28 Thread Björn Töpel
Den tis 28 aug. 2018 kl 14:47 skrev Björn Töpel : > > From: Björn Töpel > > This patch set introduces zero-copy AF_XDP support for Intel's i40e > driver. In the first preparatory patch we also add support for > XDP_REDIRECT for zero-copy allocated frames so that XDP programs can > redirect them. T

Hello dear.

2018-08-28 Thread Mrs Aisha Gaddafi
Hello dear. It is wonderful to contact you, I want us to have correspondence. I wish you will have the desire so that we can get acquainted to each other. Life itself is a mystery, you never know where it might lead you. I'm Aisha.gaddafi, the only biological douther of Qi,muamar gaddafi of li

Re: Oops running iptables -F OUTPUT

2018-08-28 Thread Ard Biesheuvel
Hello Andreas, Nick, On 28 August 2018 at 06:06, Nicholas Piggin wrote: > On Mon, 27 Aug 2018 19:11:01 +0200 > Andreas Schwab wrote: > >> I'm getting this Oops when running iptables -F OUTPUT: >> >> [ 91.139409] Unable to handle kernel paging request for data at address >> 0xd001fff12f34

Re: [PATCH bpf-next 01/11] xdp: implement convert_to_xdp_frame for MEM_TYPE_ZERO_COPY

2018-08-28 Thread Jesper Dangaard Brouer
On Tue, 28 Aug 2018 14:44:25 +0200 Björn Töpel wrote: > From: Björn Töpel > > This commit adds proper MEM_TYPE_ZERO_COPY support for > convert_to_xdp_frame. Converting a MEM_TYPE_ZERO_COPY xdp_buff to an > xdp_frame is done by transforming the MEM_TYPE_ZERO_COPY buffer into a > MEM_TYPE_PAGE_OR

WARNING from tcp.c

2018-08-28 Thread Adam Mitchell
Can anyone help me understand why a busy database server gets these kernel warnings? It comes from this WARN_ON macro, apparently because the socket is still owned by the user process. Why would that happen? WARN_ON(sock_owned_by_user(sk)); [726780.788201] WARNING: CPU: 15 PID: 52245 at n

[PATCH bpf] bpf: fix several offset tests in bpf_msg_pull_data

2018-08-28 Thread Daniel Borkmann
While recently going over bpf_msg_pull_data(), I noticed three issues which are fixed in here: 1) When we attempt to find the first scatterlist element (sge) for the start offset, we add len to the offset before we check for start < offset + len, whereas it should come after when we itera

[PATCH net 1/2] net_sched: reject unknown tcfa_action values

2018-08-28 Thread Paolo Abeni
After the commit 802bfb19152c ("net/sched: user-space can't set unknown tcfa_action values"), unknown tcfa_action values are converted to TC_ACT_UNSPEC, but the common agreement is instead rejecting such configurations. This change also introduce an helper to simplify the destruction of a single a

[PATCH net 0/2] net_sched: reject unknown tcfa_action values

2018-08-28 Thread Paolo Abeni
As agreed some time ago, this changeset reject unknown tcfa_action values, instead of changing such values under the hood. A tdc test is included to verify the new behavior. Paolo Abeni (2): net_sched: reject unknown tcfa_action values tc-testing: add test-cases for numeric and invalid contro

[PATCH net 2/2] tc-testing: add test-cases for numeric and invalid control action

2018-08-28 Thread Paolo Abeni
Only the police action allows us to specify an arbitrary numeric value for the control action. This change introduces an explicit test case for the above feature and then leverage it for testing the kernel behavior for invalid control actions (reject). Signed-off-by: Paolo Abeni --- .../tc-testi

[PATCH] iprule: Fix destination prefix output

2018-08-28 Thread Stefan Bader
When adding support for JSON output the new code for printing the destination prefix adds a stray blank character before the bitmask. This causes some user-space parsing to fail. Current output: ...: from x.x.x.x/l to y.y.y.y /l Previous output: ...: from x.x.x.x/l to y.y.y.y/l Fixes: 0dd4ccc

Re: [PATCH net 0/3] ipv6: fix error path of inet6_init()

2018-08-28 Thread Xin Long
- Original Message - > The error path of inet6_init() can trigger multiple kernel panics, > mostly due to wrong ordering of cleanups. This series fixes those > issues. > > Sabrina Dubroca (3): > ipv6: fix cleanup ordering for ip6_mr failure > ipv6: fix cleanup ordering for pingv6 re

Re: [PATCH] iprule: Fix destination prefix output

2018-08-28 Thread Luca Boccassi
On Tue, 2018-08-28 at 16:27 +0200, Stefan Bader wrote: > When adding support for JSON output the new code for printing > the destination prefix adds a stray blank character before > the bitmask. This causes some user-space parsing to fail. > > Current output: >   ...: from x.x.x.x/l to y.y.y.y /l

net-next is OPEN...

2018-08-28 Thread David Miller
You know the drill... http://vger.kernel.org/~davem/net-next.html

Re: [PATCH net] sctp: hold transport before accessing its asoc in sctp_transport_get_next

2018-08-28 Thread Xin Long
On Mon, Aug 27, 2018 at 9:08 PM Neil Horman wrote: > > On Mon, Aug 27, 2018 at 06:38:31PM +0800, Xin Long wrote: > > As Marcelo noticed, in sctp_transport_get_next, it is iterating over > > transports but then also accessing the association directly, without > > checking any refcnts before that, w

Re: Oops running iptables -F OUTPUT

2018-08-28 Thread Ard Biesheuvel
On 28 August 2018 at 15:56, Ard Biesheuvel wrote: > Hello Andreas, Nick, > > On 28 August 2018 at 06:06, Nicholas Piggin wrote: >> On Mon, 27 Aug 2018 19:11:01 +0200 >> Andreas Schwab wrote: >> >>> I'm getting this Oops when running iptables -F OUTPUT: >>> >>> [ 91.139409] Unable to handle ker

[bpf-next PATCH 1/2] bpf: sockmap test remove shutdown() calls

2018-08-28 Thread John Fastabend
Currently, we do a shutdown(sk, SHUT_RDWR) on both peer sockets and a shutdown on the sender as well. However, this is incorrect and can occasionally cause issues if you happen to have bad timing. First peer1 or peer2 may still be in use depending on the test and timing. Second we really should onl

[bpf-next PATCH 0/2] bpf: test_sockmap updates

2018-08-28 Thread John Fastabend
Two small test sockmap updates for bpf-next. These help me run some additional tests with test_sockmap. --- John Fastabend (2): bpf: sockmap test remove shutdown() calls bpf: use --cgroup in test_suite if supplied tools/testing/selftests/bpf/test_sockmap.c | 56 --

[bpf-next PATCH 2/2] bpf: use --cgroup in test_suite if supplied

2018-08-28 Thread John Fastabend
If the user supplies a --cgroup value in the arguments when running the test_suite go ahaead and run the self tests there. I use this to test with multiple cgroup users. Signed-off-by: John Fastabend --- tools/testing/selftests/bpf/test_sockmap.c | 53 1 file chang

Re: [PATCH net] net/sched: act_pedit: fix dump of extended layered op

2018-08-28 Thread Cong Wang
On Mon, Aug 27, 2018 at 1:56 PM Davide Caratti wrote: > > in the (rare) case of failure in nla_nest_start(), missing NULL checks in > tcf_pedit_key_ex_dump() can make the following command > > # tc action add action pedit ex munge ip ttl set 64 > > dereference a NULL pointer: > > BUG: unable to

[PATCH net-next] net: thunderbolt: Convert to use SPDX identifier

2018-08-28 Thread Mika Westerberg
This gets rid of the licence boilerblate in favor of SPDX identifier which only takes a single line comment. Signed-off-by: Mika Westerberg --- drivers/net/thunderbolt.c | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/drivers/net/thunderbolt.c b/drivers/net/thunderbolt.c

Re: [PATCH net 1/2] net_sched: reject unknown tcfa_action values

2018-08-28 Thread Cong Wang
On Tue, Aug 28, 2018 at 7:25 AM Paolo Abeni wrote: > > +int tcf_action_destroy_one(struct tc_action *a, int bind) > +{ > + struct tc_action *actions[] = { a, NULL }; > + > + return tcf_action_destroy(actions, bind); > +} Make it static. > + > static int tcf_action_put(struct tc_act

Re: [Intel-wired-lan] [PATCH] i40e: report correct statistics when XDP is enabled

2018-08-28 Thread Paul Menzel
Dear Björn, On 08/24/18 16:00, Jesper Dangaard Brouer wrote: > On Fri, 24 Aug 2018 13:21:59 +0200 > Björn Töpel wrote: > >> When XDP is enabled, the driver will report incorrect >> statistics. Received frames will reported as transmitted frames. >> >> This commits fixes the i40e implementation

Re: [Intel-wired-lan] [PATCH] i40e: report correct statistics when XDP is enabled

2018-08-28 Thread Björn Töpel
On 2018-08-28 19:00, Paul Menzel wrote: Dear Björn, On 08/24/18 16:00, Jesper Dangaard Brouer wrote: On Fri, 24 Aug 2018 13:21:59 +0200 Björn Töpel wrote: When XDP is enabled, the driver will report incorrect statistics. Received frames will reported as transmitted frames. This commits fix

Re: Oops running iptables -F OUTPUT

2018-08-28 Thread Andreas Schwab
On Aug 28 2018, Ard Biesheuvel wrote: > diff --git a/arch/powerpc/kernel/setup_64.c b/arch/powerpc/kernel/setup_64.c > index 6a501b25dd85..57d09d5ceb1a 100644 > --- a/arch/powerpc/kernel/setup_64.c > +++ b/arch/powerpc/kernel/setup_64.c > @@ -779,7 +779,6 @@ EXPORT_SYMBOL(__per_cpu_offset); > >

Re: [PATCH bpf-next 01/11] xdp: implement convert_to_xdp_frame for MEM_TYPE_ZERO_COPY

2018-08-28 Thread Björn Töpel
Den tis 28 aug. 2018 kl 16:11 skrev Jesper Dangaard Brouer : > > On Tue, 28 Aug 2018 14:44:25 +0200 > Björn Töpel wrote: > > > From: Björn Töpel > > > > This commit adds proper MEM_TYPE_ZERO_COPY support for > > convert_to_xdp_frame. Converting a MEM_TYPE_ZERO_COPY xdp_buff to an > > xdp_frame is

[PATCH net-next] liquidio: remove unnecessary delay when processing IQ responses

2018-08-28 Thread Felix Manlunas
From: Rick Farrington Signed-off-by: Rick Farrington Signed-off-by: Felix Manlunas --- drivers/net/ethernet/cavium/liquidio/request_manager.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/cavium/liquidio/request_manager.c b/drivers/net/ethernet/caviu

[PATCH net-next] liquidio: fix race condition in instruction completion processing

2018-08-28 Thread Felix Manlunas
From: Rick Farrington In lio_enable_irq, the pkt_in_done count register was being cleared to zero. However, there could be some completed instructions which were not yet processed due to budget and limit constraints. So, only write this register with the number of actual completions that were pr

[PATCH net-next 2/2] selftests/net: add ip_defrag selftest

2018-08-28 Thread Peter Oskolkov
This test creates a raw IPv4 socket, fragments a largish UDP datagram and sends the fragments out of order. Then repeats in a loop with different message and fragment lengths. Then does the same with overlapping fragments (with overlapping fragments the expectation is that the recv times out). T

[PATCH net-next 1/2] ip: fail fast on IP defrag errors

2018-08-28 Thread Peter Oskolkov
The current behavior of IP defragmentation is inconsistent: - some overlapping/wrong length fragments are dropped without affecting the queue; - most overlapping fragments cause the whole frag queue to be dropped. This patch brings consistency: if a bad fragment is detected, the whole frag queue

Re: phys_port_id in switchdev mode?

2018-08-28 Thread Jakub Kicinski
Ugh, CC: netdev.. On Tue, 28 Aug 2018 20:05:39 +0200, Jakub Kicinski wrote: > Hi! > > I wonder if we can use phys_port_id in switchdev to group together > interfaces of a single PCI PF? Here is the problem: > > With a mix of PF and VF interfaces it gets increasingly difficult to > figure out wh

[net-next 01/15] ice: Rework flex descriptor programming

2018-08-28 Thread Jeff Kirsher
From: Anirudh Venkataramanan The driver can support two flex descriptor profiles, ICE_RXDID_FLEX_NIC and ICE_RXDID_FLEX_NIC_2. This patch reworks the current flex programming logic to add support for the latter profile. Signed-off-by: Anirudh Venkataramanan Tested-by: Tony Brelinski Signed-off

[net-next 00/15][pull request] 100GbE Intel Wired LAN Driver Updates 2018-08-28

2018-08-28 Thread Jeff Kirsher
This series contains new features and implementation updates for the ice driver. Anirudh reworks the current flex programming logic to add support for a second flex descriptor profile. Updated the transmit scheduler code to handle changes to the spec, specifically the firmware expects a 4KB buffe

[net-next 13/15] ice: Enable VSI Rx/Tx pruning only when VLAN 0 is active

2018-08-28 Thread Jeff Kirsher
From: Brett Creeley VLAN pruning is not valid when VLAN 0 is not active. If VLAN pruning is enabled and VLAN 0 is not active (8021q driver not loaded) then normal, non-VLAN, traffic will not pass. TX/RX VLAN pruning is enabled when the VLAN 0 is added to the active_vlan bitmap and it is disabled

[net-next 03/15] ice: Update request resource command to latest specification

2018-08-28 Thread Jeff Kirsher
From: Dan Nowlin Align Request Resource Ownership AQ command (0x0008) to the latest specification. This includes: - Correcting the resource IDs for the Global Cfg and Change locks. - new enum ICE_CHANGE_LOCK_RES_ID - new enum ICE_GLOBAL_CFG_LOCK_RES_ID - Altering the flow for Global Config Lock

[net-next 06/15] ice: Refactor switch rule management structures and functions

2018-08-28 Thread Jeff Kirsher
From: Anirudh Venkataramanan This patch is an adaptation of the work originally done by Grishma Kotecha that in summary refactors the switch filtering logic in the driver. More specifically, - Update the recipe structure to also store list of rules - Update the existing code for recipes like M

[net-next 12/15] ice: Enable firmware logging during device initialization.

2018-08-28 Thread Jeff Kirsher
From: Hieu Tran To enable FW logging, the "cq_en" and "uart_en" enable bits of the "fw_log" element in struct ice_hw need to set accordingly based on some user-provided parameters during driver loading. To select which FW log events to be emitted, the "cfg" elements of corresponding FW modules in

[net-next 10/15] ice: Add support for Tx hang, Tx timeout and malicious driver detection

2018-08-28 Thread Jeff Kirsher
From: Sudheer Mogilappagari When a malicious operation is detected, the firmware triggers an interrupt, which is then picked up by the service task (specifically by ice_handle_mdd_event). A reset is scheduled if required. Tx hang detection works in a similar way, except the logic here monitors t

[net-next 15/15] ice: Fix and update driver version string

2018-08-28 Thread Jeff Kirsher
From: Anirudh Venkataramanan Remove the "ice" prefix for the driver version string and bump version to 0.7.1-k. Signed-off-by: Anirudh Venkataramanan Tested-by: Tony Brelinski Signed-off-by: Jeff Kirsher --- drivers/net/ethernet/intel/ice/ice_main.c | 2 +- 1 file changed, 1 insertion(+), 1

[net-next 14/15] ice: Introduce SERVICE_DIS flag and service routine functions

2018-08-28 Thread Jeff Kirsher
From: Akeem G Abodunrin This patch introduces SERVICE_DIS flag to use for stopping service task. This flag will be checked before scheduling new tasks. Also add new functions ice_service_task_stop to stop service task. Signed-off-by: Akeem G Abodunrin Signed-off-by: Anirudh Venkataramanan Test

[net-next 07/15] ice: Refactor VSI allocation, deletion and rebuild flow

2018-08-28 Thread Jeff Kirsher
From: Anirudh Venkataramanan This patch refactors aspects of the VSI allocation, deletion and rebuild flow. Some of the more noteworthy changes are described below. 1) On reset, all switch filters applied in the hardware are lost. In the rebuild flow, only MAC and broadcast filters are being

[net-next 09/15] ice: Clean up register file

2018-08-28 Thread Jeff Kirsher
From: Anirudh Venkataramanan This patch cleans up the existing register definitions. 1) Several instances of long defines names used in the BIT() macro were replaced to use the actual values they represent. As a result some defines for shifts (ending with _S) that were used only to crea

[net-next 11/15] ice: Implement ice_bridge_getlink and ice_bridge_setlink

2018-08-28 Thread Jeff Kirsher
From: Md Fahad Iqbal Polash ice_bridge_getlink returns the current bridge mode using ndo_dflt_bridge_getlink and the mode parameter available in first_switch->bridge_mode. ice_bridge_setlink is invoked when the bridge mode needs to changed. The value to be changed to is available as a netlink me

[net-next 02/15] ice: Updates to Tx scheduler code

2018-08-28 Thread Jeff Kirsher
From: Anirudh Venkataramanan 1) The maximum device nodes is a global value and shared by the whole device. Add element AQ command would fail if there is no space to add new nodes so the check for max nodes isn't required. So remove ice_sched_get_num_nodes_per_layer and ice_sched_val_max_

[net-next 08/15] ice: Implement handlers for ethtool PHY/link operations

2018-08-28 Thread Jeff Kirsher
From: Chinh Cao This patch implements handlers for ethtool get_link_ksettings and set_link_ksettings. Helper functions use by these handlers are also introduced in this patch. Signed-off-by: Chinh Cao Signed-off-by: Anirudh Venkataramanan Tested-by: Tony Brelinski Signed-off-by: Jeff Kirsher

[net-next 05/15] ice: Code optimization for ice_fill_sw_rule()

2018-08-28 Thread Jeff Kirsher
From: Zhenning Xiao Use the buffer in the s_rule structure directly instead of using a local array eth_hdr[DUMMY_ETH_HDR_LEN] Signed-off-by: Zhenning Xiao Signed-off-by: Anirudh Venkataramanan Tested-by: Tony Brelinski Signed-off-by: Jeff Kirsher --- drivers/net/ethernet/intel/ice/ice_switc

[net-next 04/15] ice: Prevent control queue operations during reset

2018-08-28 Thread Jeff Kirsher
From: Anirudh Venkataramanan Once reset is issued, the driver loses all control queue interfaces. Exercising control queue operations during reset is incorrect and may result in long timeouts. This patch introduces a new field 'reset_ongoing' in the hw structure. This is set to 1 by the core dri

Re: [PATCH net-next] virtio_net: force_napi_tx module param.

2018-08-28 Thread Willem de Bruijn
On Mon, Jul 30, 2018 at 2:06 AM Jason Wang wrote: > > > > On 2018年07月25日 08:17, Jon Olson wrote: > > On Tue, Jul 24, 2018 at 3:46 PM Michael S. Tsirkin wrote: > >> On Tue, Jul 24, 2018 at 06:31:54PM -0400, Willem de Bruijn wrote: > >>> On Tue, Jul 24, 2018 at 6:23 PM Michael S. Tsirkin > >>> wr

[PATCH net-next 04/15] nfp: add support for indirect HWinfo lookup

2018-08-28 Thread Jakub Kicinski
Management FW can adjust some of the information in the HWinfo table at runtime. In some cases reading the table directly will not yield correct results. Add a NSP command for looking up information. Up until now we weren't making use of any of the values which may get adjusted. Signed-off-by: J

[PATCH net-next 06/15] nfp: add support for NFP5000

2018-08-28 Thread Jakub Kicinski
Add NFP5000 to supported chips, the chip is backward compatible with NFP4000 and NFP6000, so core PCIe code needs to handle it the same way as 4k and 6k. Signed-off-by: Jakub Kicinski --- drivers/net/ethernet/netronome/nfp/nfp_main.c | 4 drivers/net/ethernet/netronome/nfp/nfpco

[PATCH net-next 09/15] nfp: add basic errors messages to target logic

2018-08-28 Thread Jakub Kicinski
Add error prints to CPP target encoding/decoding logic, otherwise it's quite hard to pin point the reasons why read or write operations fail. Signed-off-by: Jakub Kicinski Reviewed-by: Francois H. Theron --- .../net/ethernet/netronome/nfp/nfpcore/nfp_target.c | 12 ++-- 1 file changed,

[PATCH net-next 11/15] nfp: pass cpp_id to nfp_cpp_map_area()

2018-08-28 Thread Jakub Kicinski
Align nfp_cpp_map_area() with other CPP-level APIs and pass encoded cpp_id/dest rather than target, action, domain tuple. Signed-off-by: Jakub Kicinski Reviewed-by: Francois H. Theron --- drivers/net/ethernet/netronome/nfp/nfp_net_main.c| 8 drivers/net/ethernet/netronome/nfp/nfpc

[PATCH net-next 07/15] nfp: refactor the per-chip PCIe config

2018-08-28 Thread Jakub Kicinski
Use a switch statement instead of ifs for code dependent on chip version. While at it make sure we fail for unknown chip revisions. Signed-off-by: Jakub Kicinski --- .../netronome/nfp/nfpcore/nfp6000_pcie.c | 50 ++- .../ethernet/netronome/nfp/nfpcore/nfp_cpp.h | 4 ++ 2

[PATCH net-next 10/15] nfp: add RTsym access helpers

2018-08-28 Thread Jakub Kicinski
RTsyms may have special encodings for more complex symbol types. For example symbols which are placed in external memory unit's cache directly, constants or local memory. Add set of helpers which will check for those special encodings and handle them correctly. For now only add direct cache acces

[PATCH net-next 12/15] nfp: convert existing RTsym helpers to full target decoding

2018-08-28 Thread Jakub Kicinski
Make nfp_rtsym_{read,write}_le() and nfp_rtsym_map() use the new target resolution helpers to allow accessing in-cache symbols. Signed-off-by: Jakub Kicinski Reviewed-by: Francois H. Theron --- .../netronome/nfp/nfpcore/nfp_rtsym.c | 28 +-- 1 file changed, 14 insertions

[PATCH net-next 13/15] nfp: convert all RTsym users to use new read/write helpers

2018-08-28 Thread Jakub Kicinski
Convert all users of RTsym to the new set of helpers which handle all targets correctly. Signed-off-by: Jakub Kicinski Reviewed-by: Francois H. Theron --- drivers/net/ethernet/netronome/nfp/abm/ctrl.c | 28 ++- drivers/net/ethernet/netronome/nfp/nfp_main.c | 28 -

[PATCH net-next 08/15] nfp: save the MU locality field offset

2018-08-28 Thread Jakub Kicinski
We will soon need the MU locality field offset much more often than just for decoding MIP address. Save it in nfp_cpp for quick access. Note that we can already reuse the target config from nfp_cpp, no need to do the XPB read. Signed-off-by: Jakub Kicinski Reviewed-by: Francois H. Theron ---

[PATCH net-next 01/15] nfp: encapsulate NSP command arguments into structs

2018-08-28 Thread Jakub Kicinski
There is already a fair number of arguments to nfp_nsp_command() family of functions. Encapsulate them into structures to make adding new ones easier. No functional changes. Signed-off-by: Jakub Kicinski Reviewed-by: Dirk van der Merwe --- .../ethernet/netronome/nfp/nfpcore/nfp_nsp.c | 205 +

[PATCH net-next 14/15] nfp: support access to absolute RTsyms

2018-08-28 Thread Jakub Kicinski
Add support in nfpcore for reading the absolute RTsyms. Signed-off-by: Jakub Kicinski Reviewed-by: Francois H. Theron --- .../ethernet/netronome/nfp/nfpcore/nfp_nffw.h | 13 +++--- .../netronome/nfp/nfpcore/nfp_rtsym.c | 42 +-- 2 files changed, 46 insertions(+), 9 delet

[PATCH net-next 05/15] nfp: abm: look up MAC addresses via management FW

2018-08-28 Thread Jakub Kicinski
In multi-host scenarios Management FW may allocate MAC addresses at runtime, we have to use the indirect lookup to find them. Signed-off-by: Jakub Kicinski Reviewed-by: Dirk van der Merwe --- drivers/net/ethernet/netronome/nfp/abm/main.c | 34 ++- 1 file changed, 25 insertions(+

[PATCH net-next 02/15] nfp: attempt FW load from flash

2018-08-28 Thread Jakub Kicinski
Flash may contain a default NFP application FW. This application can either be put there by the user (with ethtool -f) or shipped with the card. If file system FW is not found, attempt to load this flash stored app FW. Signed-off-by: Jakub Kicinski Reviewed-by: Dirk van der Merwe --- drivers/

  1   2   >