Re: [next-queue PATCH v5 3/5] net/sched: Introduce Credit Based Shaper (CBS) qdisc

2017-10-10 Thread Jiri Pirko
Wed, Oct 11, 2017 at 02:43:58AM CEST, vinicius.go...@intel.com wrote: >This queueing discipline implements the shaper algorithm defined by >the 802.1Q-2014 Section 8.6.8.2 and detailed in Annex L. > >It's primary usage is to apply some bandwidth reservation to user >defined traffic classes, which a

Re: [PATCH] wcn36xx: Remove unnecessary rcu_read_unlock in wcn36xx_bss_info_changed

2017-10-10 Thread Bjorn Andersson
On Sun 08 Oct 06:06 PDT 2017, Jia-Ju Bai wrote: > No rcu_read_lock is called, but rcu_read_unlock is still called. > Thus rcu_read_unlock should be removed. > Thanks, not sure how I could miss that one. Kalle can you please include this in a v4.14-rc pull request? : Fixes: 39efc7cc7ccf ("wcn3

[PATCH v2 1/7] net: qrtr: Invoke sk_error_report() after setting sk_err

2017-10-10 Thread Bjorn Andersson
Rather than manually waking up any context sleeping on the sock to signal an error we should call sk_error_report(). This has the added benefit that in-kernel consumers can override this notification with its own callback. Signed-off-by: Bjorn Andersson --- Changes since v1: - None net/qrtr/qr

[PATCH v2 4/7] net: qrtr: Pass source and destination to enqueue functions

2017-10-10 Thread Bjorn Andersson
Defer writing the message header to the skb until its time to enqueue the packet. As the receive path is reworked to decode the message header as it's received from the transport and only pass around the payload in the skb this change means that we do not have to fill out the full message header ju

[PATCH v2 2/7] net: qrtr: Move constants to header file

2017-10-10 Thread Bjorn Andersson
The constants are used by both the name server and clients, so clarify their value and move them to the uapi header. Signed-off-by: Bjorn Andersson --- Changes since v1: - None include/uapi/linux/qrtr.h | 3 +++ net/qrtr/qrtr.c | 2 -- 2 files changed, 3 insertions(+), 2 deletions(-)

[PATCH v2 0/7] net: qrtr: Fixes and support receiving version 2 packets

2017-10-10 Thread Bjorn Andersson
On the latest Qualcomm platforms remote processors are sending packets with version 2 of the message header. This series starts off with some fixes and then refactors the qrtr code to support receiving messages of both version 1 and version 2. As all remotes are backwards compatible transmitted pa

[PATCH v2 3/7] net: qrtr: Add control packet definition to uapi

2017-10-10 Thread Bjorn Andersson
The QMUX protocol specification defines structure of the special control packet messages being sent between handlers of the control port. Add these to the uapi header, as this structure and the associated types are shared between the kernel and all userspace handlers of control messages. Signed-o

[PATCH v2 5/7] net: qrtr: Clean up control packet handling

2017-10-10 Thread Bjorn Andersson
As the message header generation is deferred the internal functions for generating control packets can be simplified. This patch modifies qrtr_alloc_ctrl_packet() to, in addition to the sk_buff, return a reference to a struct qrtr_ctrl_pkt, which clarifies and simplifies the helpers to the point t

[PATCH v2 7/7] net: qrtr: Support decoding incoming v2 packets

2017-10-10 Thread Bjorn Andersson
Add the necessary logic for decoding incoming messages of version 2 as well. Also make sure there's room for the bigger of version 1 and 2 headers in the code allocating skbs for outgoing messages. Signed-off-by: Bjorn Andersson --- Changes since v1: - Dropped __packed from struct qrtr_hdr_v2

[PATCH v2 6/7] net: qrtr: Use sk_buff->cb in receive path

2017-10-10 Thread Bjorn Andersson
Rather than parsing the header of incoming messages throughout the implementation do it once when we retrieve the message and store the relevant information in the "cb" member of the sk_buff. This allows us to, in a later commit, decode version 2 messages into this same structure. Signed-off-by:

Re: [patch net-next 0/4] net: sched: get rid of cls_flower->egress_dev

2017-10-10 Thread Jiri Pirko
Tue, Oct 10, 2017 at 11:46:22PM CEST, gerlitz...@gmail.com wrote: >On Wed, Oct 11, 2017 at 12:13 AM, Jiri Pirko wrote: >> Tue, Oct 10, 2017 at 07:24:21PM CEST, gerlitz...@gmail.com wrote: > >> Or, as I replied to you earlier, the issue you describe is totally >> unrelated to this patchset as you s

Re: [PATCH v8 01/20] crypto: change transient busy return code to -EAGAIN

2017-10-10 Thread Herbert Xu
On Sat, Oct 07, 2017 at 10:51:42AM +0300, Gilad Ben-Yossef wrote: > On Sat, Oct 7, 2017 at 6:05 AM, Herbert Xu > wrote: > > On Tue, Sep 05, 2017 at 03:38:40PM +0300, Gilad Ben-Yossef wrote: > >> > >> diff --git a/crypto/algif_hash.c b/crypto/algif_hash.c > >> index 5e92bd2..3b3c154 100644 > >> --

Re: [net-next V6 PATCH 0/5] New bpf cpumap type for XDP_REDIRECT

2017-10-10 Thread John Fastabend
On 10/10/2017 05:47 AM, Jesper Dangaard Brouer wrote: > Introducing a new way to redirect XDP frames. Notice how no driver > changes are necessary given the design of XDP_REDIRECT. > > This redirect map type is called 'cpumap', as it allows redirection > XDP frames to remote CPUs. The remote CPU

[PATCH net] net/ncsi: Don't limit vids based on hot_channel

2017-10-10 Thread Samuel Mendoza-Jonas
Currently we drop any new VLAN ids if there are more than the current (or last used) channel can support. Most importantly this is a problem if no channel has been selected yet, resulting in a segfault. Secondly this does not necessarily reflect the capabilities of any other channels. Instead only

Re: High CPU load by native_queued_spin_lock_slowpath

2017-10-10 Thread Sergey K.
I'm using ifb0 device for outgoing traffic. I have one bond0 interface with exit to the Internet, and 2 interfaces eth0 and eth2 to local users. ifb0 - for shaping Internet traffic from bond0 to eth2 or eth0. All outgoing traffic to the eth0 and eth2 redirecting to ifb0. > What about multiple ifb

Re: [net-next V6 PATCH 1/5] bpf: introduce new bpf cpu map type BPF_MAP_TYPE_CPUMAP

2017-10-10 Thread Jesper Dangaard Brouer
On Wed, 11 Oct 2017 00:48:40 +0200 Daniel Borkmann wrote: > On 10/10/2017 02:47 PM, Jesper Dangaard Brouer wrote: > [...] > > +static struct bpf_map *cpu_map_alloc(union bpf_attr *attr) > > +{ > > + struct bpf_cpu_map *cmap; > > + int err = -ENOMEM; > > + u64 cost; > > + int ret; > > + >

[PATCH] r8169: only enable PCI wakeups when WOL is active

2017-10-10 Thread Daniel Drake
rtl_init_one() currently enables PCI wakeups if the ethernet device is found to be WOL-capable. There is no need to do this when rtl8169_set_wol() will correctly enable or disable the same wakeup flag when WOL is activated/deactivated. This works around an ACPI DSDT bug which prevents the Acer lap

[PATCH net-next 6/7] net: qualcomm: rmnet: Convert the muxed endpoint to hlist

2017-10-10 Thread Subash Abhinov Kasiviswanathan
Rather than using a static array, use a hlist to store the muxed endpoints and use the mux id to query the rmnet_device. This is useful as usually very few mux ids are used. Signed-off-by: Subash Abhinov Kasiviswanathan Cc: Dan Williams --- drivers/net/ethernet/qualcomm/rmnet/rmnet_config.c | 7

[PATCH net-next 5/7] net: qualcomm: rmnet: Remove duplicate setting of rmnet_devices

2017-10-10 Thread Subash Abhinov Kasiviswanathan
The rmnet_devices information is already stored in muxed_ep, so storing this in rmnet_devices[] again is redundant. Signed-off-by: Subash Abhinov Kasiviswanathan --- drivers/net/ethernet/qualcomm/rmnet/rmnet_config.h | 1 - drivers/net/ethernet/qualcomm/rmnet/rmnet_vnd.c| 8 2 files

[PATCH net-next 2/7] net: qualcomm: rmnet: Remove some unused defines

2017-10-10 Thread Subash Abhinov Kasiviswanathan
Most of these constants were used in the initial patchset where custom netlink configuration was used and hence are no longer relevant. Signed-off-by: Subash Abhinov Kasiviswanathan --- drivers/net/ethernet/qualcomm/rmnet/rmnet_private.h | 8 1 file changed, 8 deletions(-) diff --git a

[PATCH net-next 4/7] net: qualcomm: rmnet: Remove duplicate setting of rmnet private info

2017-10-10 Thread Subash Abhinov Kasiviswanathan
The end point is set twice in the local_ep as well as the mux_id and the real_dev in the rmnet private structure. Remove the local_ep. While these elements are equivalent, rmnet_endpoint will be used only as part of the rmnet_port for muxed scenarios in VND mode. Signed-off-by: Subash Abhinov Kasi

[PATCH net-next 7/7] net: qualcomm: rmnet: Implement bridge mode

2017-10-10 Thread Subash Abhinov Kasiviswanathan
Add support to bridge two devices which can send multiplexing and aggregation (MAP) data. This is done only when the data itself is not going to be consumed in the stack but is being passed on to a different endpoint. This is mainly used for testing. Signed-off-by: Subash Abhinov Kasiviswanathan

[PATCH net-next 1/7] net: qualcomm: rmnet: Remove existing logic for bridge mode

2017-10-10 Thread Subash Abhinov Kasiviswanathan
This will be rewritten in the following patches. Signed-off-by: Subash Abhinov Kasiviswanathan --- drivers/net/ethernet/qualcomm/rmnet/rmnet_config.h | 1 - .../net/ethernet/qualcomm/rmnet/rmnet_handlers.c | 77 +++--- 2 files changed, 9 insertions(+), 69 deletions(-) diff --

[PATCH net-next 3/7] net: qualcomm: rmnet: Move rmnet_mode to rmnet_port

2017-10-10 Thread Subash Abhinov Kasiviswanathan
Mode information on the real device makes it easier to route packets to rmnet device or bridged device based on the configuration. Signed-off-by: Subash Abhinov Kasiviswanathan --- drivers/net/ethernet/qualcomm/rmnet/rmnet_config.c | 12 +--- drivers/net/ethernet/qualcomm/rmnet/rmnet_c

[PATCH net-next 0/7] Rewrite some existing functionality

2017-10-10 Thread Subash Abhinov Kasiviswanathan
This series fixes some of the broken rmnet functionality. Bridge mode is re-written and made useable and the muxed_ep is converted to hlist. Patches 1-5 are cleanups in preparation for these changes. Patch 6 does the hlist conversion. Patch 7 has the implementation of the rmnet bridge mode. Suba

Re: [PATCH 0/4] RCU: introduce noref debug

2017-10-10 Thread Paul E. McKenney
On Mon, Oct 09, 2017 at 06:53:12PM +0200, Paolo Abeni wrote: > On Fri, 2017-10-06 at 09:34 -0700, Paul E. McKenney wrote: > > On Fri, Oct 06, 2017 at 05:10:09PM +0200, Paolo Abeni wrote: > > > Hi, > > > > > > On Fri, 2017-10-06 at 06:34 -0700, Paul E. McKenney wrote: > > > > On Fri, Oct 06, 2017 a

ipsec: Fix dst leak in xfrm_bundle_create().

2017-10-10 Thread David Miller
If we cannot find a suitable inner_mode value, we will leak the currently allocated 'xdst'. The fix is to make sure it is linked into the chain before erroring out. Signed-off-by: David S. Miller --- Steffen, I found this via visual inspection. Please double check my work before applying this

Re: [PATCH net 2/2] net: call cgroup_sk_alloc() earlier in sk_clone_lock()

2017-10-10 Thread David Miller
From: Eric Dumazet Date: Tue, 10 Oct 2017 19:12:33 -0700 > If for some reason, the newly allocated child need to be freed, > we will call cgroup_put() (via sk_free_unlock_clone()) while the > corresponding cgroup_get() was not yet done, and we will free memory > too soon. > > Fixes: d979a39d7242

Re: [PATCH net 1/2] Revert "net: defer call to cgroup_sk_alloc()"

2017-10-10 Thread David Miller
From: Eric Dumazet Date: Tue, 10 Oct 2017 19:12:32 -0700 > This reverts commit fbb1fb4ad415cb31ce944f65a5ca700aaf73a227. > > This was not the proper fix, lets cleanly revert it, so that > following patch can be carried to stable versions. > > sock_cgroup_ptr() callers do not expect a NULL retur

Re: [next-queue PATCH v5 0/5] TSN: Add qdisc based config interface for CBS

2017-10-10 Thread David Miller
From: Vinicius Costa Gomes Date: Tue, 10 Oct 2017 17:43:55 -0700 > Changes since v4: > - Added a software implementation of the CBS algorithm; This series now looks fine to me. I'll give others a chance to review it.

Re: [PATCH RFC 0/3] tun zerocopy stats

2017-10-10 Thread Jason Wang
On 2017年10月11日 03:11, Willem de Bruijn wrote: On Tue, Oct 10, 2017 at 1:39 PM, David Miller wrote: From: Willem de Bruijn Date: Tue, 10 Oct 2017 11:29:33 -0400 If there is a way to expose these stats through vhost_net directly, instead of through tun, that may be better. But I did not see

Re: [PATCH net 0/7] net: qualcomm: rmnet: Fix some existing functionality

2017-10-10 Thread David Miller
From: Subash Abhinov Kasiviswanathan Date: Tue, 10 Oct 2017 18:20:22 -0600 > This series fixes some of the broken rmnet functionality from the initial > patchset. Bridge mode is re-written and made useable and the muxed_ep is > converted to hlist. > > Patches 1-5 are cleanups in preparation for

Re: [Patch net-next] tcp: add a tracepoint for tcp_retransmit_skb()

2017-10-10 Thread Alexei Starovoitov
On Tue, Oct 10, 2017 at 11:58:53PM +0200, Hannes Frederic Sowa wrote: > Alexei Starovoitov writes: > > > On Mon, Oct 09, 2017 at 10:35:47PM -0700, Cong Wang wrote: > > [...] > > >> + trace_tcp_retransmit_skb(sk, skb, segs); > > > > I'm happy to see new tracepoints being added to tcp st

Re: [Patch net-next] tcp: add a tracepoint for tcp_retransmit_skb()

2017-10-10 Thread Alexei Starovoitov
On Tue, Oct 10, 2017 at 02:37:11PM -0700, Cong Wang wrote: > > > > More concrete, if you can make this trace_tcp_retransmit_skb() to record > > sk, skb pointers and err code at the end of __tcp_retransmit_skb() it will > > solve > > our need as well. > > > Note, currently I only call trace_tcp_r

Re: Regression in throughput between kvm guests over virtual bridge

2017-10-10 Thread Jason Wang
On 2017年10月06日 04:07, Matthew Rosato wrote: On 09/25/2017 04:18 PM, Matthew Rosato wrote: On 09/22/2017 12:03 AM, Jason Wang wrote: On 2017年09月21日 03:38, Matthew Rosato wrote: Seems to make some progress on wakeup mitigation. Previous patch tries to reduce the unnecessary traversal of waitq

[PATCH net-next] net: hns3: make local functions static

2017-10-10 Thread Wei Yongjun
Fixes the following sparse warnings: drivers/net/ethernet/hisilicon/hns3/hns3pf/hns3_ethtool.c:464:5: warning: symbol 'hns3_change_all_ring_bd_num' was not declared. Should it be static? drivers/net/ethernet/hisilicon/hns3/hns3pf/hns3_ethtool.c:477:5: warning: symbol 'hns3_set_ringparam' was not

[PATCH net-next 2/2] net sched act_vlan: VLAN action rewrite to use RCU lock/unlock and update

2017-10-10 Thread Manish Kurup
Using a spinlock in the VLAN action causes performance issues when the VLAN action is used on multiple cores. Rewrote the VLAN action to use RCU read locking for reads and updates instead. Signed-off-by: Manish Kurup --- include/net/tc_act/tc_vlan.h | 21 - net/sched/act_vlan.c

[PATCH v3] mac80211: aead api to reduce redundancy

2017-10-10 Thread Xiang Gao
Currently, the aes_ccm.c and aes_gcm.c are almost line by line copy of each other. This patch reduce code redundancy by moving the code in these two files to crypto/aead_api.c to make it a higher level aead api. The file aes_ccm.c and aes_gcm.c are removed and all the functions there are now implem

[PATCH net-next 1/2] net sched act_vlan: Change stats update to use per-core stats

2017-10-10 Thread Manish Kurup
The VLAN action maintains one set of stats across all cores, and uses a spinlock to synchronize updates to it from the same. Changed this to use a per-CPU stats context instead. This change will result in better performance. Signed-off-by: Manish Kurup --- net/sched/act_vlan.c | 10 ++ 1

Re: [PATCH] mac80211: aead api to reduce redundancy

2017-10-10 Thread Xiang Gao
2017-10-09 3:09 GMT-04:00 Johannes Berg : > On Sun, 2017-10-08 at 01:43 -0400, Xiang Gao wrote: >> >> By the way, I'm still struggling on how to run unit tests. It might >> take time for me to make it run on my machine. > > I can run it easily, so don't worry about it too much. Running it is of > c

[PATCH net 1/2] Revert "net: defer call to cgroup_sk_alloc()"

2017-10-10 Thread Eric Dumazet
This reverts commit fbb1fb4ad415cb31ce944f65a5ca700aaf73a227. This was not the proper fix, lets cleanly revert it, so that following patch can be carried to stable versions. sock_cgroup_ptr() callers do not expect a NULL return value. Signed-off-by: Eric Dumazet Cc: Johannes Weiner Cc: Tejun H

[PATCH net 2/2] net: call cgroup_sk_alloc() earlier in sk_clone_lock()

2017-10-10 Thread Eric Dumazet
If for some reason, the newly allocated child need to be freed, we will call cgroup_put() (via sk_free_unlock_clone()) while the corresponding cgroup_get() was not yet done, and we will free memory too soon. Fixes: d979a39d7242 ("cgroup: duplicate cgroup reference when cloning sockets") Signed-off

RE: [net-next,RESEND] igb: add function to get maximum RSS queues

2017-10-10 Thread Brown, Aaron F
> From: netdev-ow...@vger.kernel.org [mailto:netdev- > ow...@vger.kernel.org] On Behalf Of Zhang Shengju > Sent: Tuesday, September 19, 2017 6:41 AM > To: Kirsher, Jeffrey T ; intel-wired- > l...@lists.osuosl.org; netdev@vger.kernel.org > Subject: [net-next,RESEND] igb: add function to get maximum

[next-queue PATCH v5 0/5] TSN: Add qdisc based config interface for CBS

2017-10-10 Thread Vinicius Costa Gomes
Hi, Changes since v4: - Added a software implementation of the CBS algorithm; Changes since v3: - None, only a clean patchset without old patches; Changes since v2: - squashed the patch introducing the userspace API into the patch implementing CBS; Changes since v1: - Solved the mqprio d

RE: [PATCH net] driver: e1000: fix race condition between e1000_down() and e1000_watchdog

2017-10-10 Thread Brown, Aaron F
> From: netdev-ow...@vger.kernel.org [mailto:netdev- > ow...@vger.kernel.org] On Behalf Of Vincenzo Maffione > Sent: Saturday, September 16, 2017 9:00 AM > To: Kirsher, Jeffrey T > Cc: intel-wired-...@lists.osuosl.org; netdev@vger.kernel.org; linux- > ker...@vger.kernel.org; Vincenzo Maffione > S

[next-queue PATCH v5 1/5] net/sched: Check for null dev_queue on create flow

2017-10-10 Thread Vinicius Costa Gomes
From: Jesus Sanchez-Palencia In qdisc_alloc() the dev_queue pointer was used without any checks being performed. If qdisc_create() gets a null dev_queue pointer, it just passes it along to qdisc_alloc(), leading to a crash. That happens if a root qdisc implements select_queue() and returns a null

[iproute2 net-next v2 3/3] man: Add initial manpage for tc-cbs(8)

2017-10-10 Thread Vinicius Costa Gomes
Signed-off-by: Vinicius Costa Gomes --- man/man8/tc-cbs.8 | 112 ++ 1 file changed, 112 insertions(+) create mode 100644 man/man8/tc-cbs.8 diff --git a/man/man8/tc-cbs.8 b/man/man8/tc-cbs.8 new file mode 100644 index ..97e00c84 --- /de

[iproute2 net-next v2 1/3] update headers with CBS API [ONLY FOR TESTING]

2017-10-10 Thread Vinicius Costa Gomes
The headers will be updated when iproute2 fetches the headers from net-next, this patch is only to ease testing. Signed-off-by: Vinicius Costa Gomes --- include/linux/pkt_sched.h | 18 ++ 1 file changed, 18 insertions(+) diff --git a/include/linux/pkt_sched.h b/include/linux/pkt

[iproute2 net-next v2 2/3] tc: Add support for the CBS qdisc

2017-10-10 Thread Vinicius Costa Gomes
The Credit Based Shaper (CBS) queueing discipline allows bandwidth reservation with sub-milisecond precision. It is defined by the 802.1Q-2014 specification (section 8.6.8.2 and Annex L). The syntax is: tc qdisc add dev DEV parent NODE cbs locredit hicredit sendslope

[next-queue PATCH v5 3/5] net/sched: Introduce Credit Based Shaper (CBS) qdisc

2017-10-10 Thread Vinicius Costa Gomes
This queueing discipline implements the shaper algorithm defined by the 802.1Q-2014 Section 8.6.8.2 and detailed in Annex L. It's primary usage is to apply some bandwidth reservation to user defined traffic classes, which are mapped to different queues via the mqprio qdisc. Only a simple software

[next-queue PATCH v5 4/5] net/sched: Add support for HW offloading for CBS

2017-10-10 Thread Vinicius Costa Gomes
This adds support for offloading the CBS algorithm to the controller, if supported. Signed-off-by: Vinicius Costa Gomes --- net/sched/sch_cbs.c | 92 ++--- 1 file changed, 81 insertions(+), 11 deletions(-) diff --git a/net/sched/sch_cbs.c b/net/sc

[next-queue PATCH v5 5/5] igb: Add support for CBS offload

2017-10-10 Thread Vinicius Costa Gomes
From: Andre Guedes This patch adds support for Credit-Based Shaper (CBS) qdisc offload from Traffic Control system. This support enable us to leverage the Forwarding and Queuing for Time-Sensitive Streams (FQTSS) features from Intel i210 Ethernet Controller. FQTSS is the former 802.1Qav standard

[next-queue PATCH v5 2/5] mqprio: Implement select_queue class_ops

2017-10-10 Thread Vinicius Costa Gomes
From: Jesus Sanchez-Palencia When replacing a child qdisc from mqprio, tc_modify_qdisc() must fetch the netdev_queue pointer that the current child qdisc is associated with before creating the new qdisc. Currently, when using mqprio as root qdisc, the kernel will end up getting the queue #0 poin

[jkirsher/next-queue PATCH v4 4/6] i40e: Admin queue definitions for cloud filters

2017-10-10 Thread Amritha Nambiar
Add new admin queue definitions and extended fields for cloud filter support. Define big buffer for extended general fields in Add/Remove Cloud filters command. v3: Shortened some lengthy struct names. v2: Added I40E_CHECK_STRUCT_LEN check to AQ command structs and added AQ definitions to i40evf f

[jkirsher/next-queue PATCH v4 3/6] i40e: Cloud filter mode for set_switch_config command

2017-10-10 Thread Amritha Nambiar
Add definitions for L4 filters and switch modes based on cloud filters modes and extend the set switch config command to include the additional cloud filter mode. Signed-off-by: Amritha Nambiar Signed-off-by: Kiran Patil --- drivers/net/ethernet/intel/i40e/i40e_adminq_cmd.h | 30 +

[jkirsher/next-queue PATCH v4 1/6] cls_flower: Offload classid to hardware

2017-10-10 Thread Amritha Nambiar
The classid on a filter is used to match a packet to a class. tcf_result structure contains the class ID of the class to which the packet belongs. This patch enables offloading the classid to the hardware. Signed-off-by: Amritha Nambiar --- include/net/pkt_cls.h |1 + net/sched/cls_flower.c

[jkirsher/next-queue PATCH v4 0/6] tc-flower based cloud filters in i40e

2017-10-10 Thread Amritha Nambiar
This patch series enables configuring cloud filters in i40e using the tc-flower classifier. The classification function of the filter is to match a packet to a class. cls_flower is extended to offload classid to hardware. The offloaded classid is used direct matched packets to a traffic class on th

[jkirsher/next-queue PATCH v4 5/6] i40e: Clean up of cloud filters

2017-10-10 Thread Amritha Nambiar
Introduce the cloud filter datastructure and cleanup of cloud filters associated with the device. v2: Moved field comments in struct i40e_cloud_filter to the right. Removed hlist_empty check from i40e_cloud_filter_exit() Signed-off-by: Amritha Nambiar --- drivers/net/ethernet/intel/i40e/i40e.h

[jkirsher/next-queue PATCH v4 6/6] i40e: Enable cloud filters via tc-flower

2017-10-10 Thread Amritha Nambiar
This patch enables tc-flower based hardware offloads. tc flower filter provided by the kernel is configured as driver specific cloud filter. The patch implements functions and admin queue commands needed to support cloud filters in the driver and adds cloud filters to configure these tc-flower filt

[jkirsher/next-queue PATCH v4 2/6] i40e: Map TCs with the VSI seids

2017-10-10 Thread Amritha Nambiar
Add mapping of TCs with the seids of the channel VSIs. TC0 will be mapped to the main VSI seid and all other TCs are mapped to the seid of the corresponding channel VSI. Signed-off-by: Amritha Nambiar --- drivers/net/ethernet/intel/i40e/i40e.h |1 + drivers/net/ethernet/intel/i40e/i40e_

[PATCH net 3/7] net: qualcomm: rmnet: Move rmnet_mode to rmnet_port

2017-10-10 Thread Subash Abhinov Kasiviswanathan
Mode information on the real device makes it easier to route packets to rmnet device or bridged device based on the configuration. Fixes: ceed73a2cf4a ("drivers: net: ethernet: qualcomm: rmnet: Initial implementation") Signed-off-by: Subash Abhinov Kasiviswanathan --- drivers/net/ethernet/qualc

[PATCH net 4/7] net: qualcomm: rmnet: Remove duplicate setting of rmnet private info

2017-10-10 Thread Subash Abhinov Kasiviswanathan
The end point is set twice in the local_ep as well as the mux_id and the real_dev in the rmnet private structure. Remove the local_ep. While these elements are equivalent, rmnet_endpoint will be used only as part of the rmnet_port for muxed scenarios in VND mode. Fixes: ceed73a2cf4a ("drivers: net

[PATCH net 6/7] net: qualcomm: rmnet: Convert the muxed endpoint to hlist

2017-10-10 Thread Subash Abhinov Kasiviswanathan
Rather than using a static array, use a hlist to store the muxed endpoints and use the mux id to query the rmnet_device. This is useful as usually very few mux ids are used. Fixes: ceed73a2cf4a ("drivers: net: ethernet: qualcomm: rmnet: Initial implementation") Signed-off-by: Subash Abhinov Kasiv

[PATCH net 1/7] net: qualcomm: rmnet: Remove existing logic for bridge mode

2017-10-10 Thread Subash Abhinov Kasiviswanathan
This will be rewritten in the following patches. Fixes: ceed73a2cf4a ("drivers: net: ethernet: qualcomm: rmnet: Initial implementation") Signed-off-by: Subash Abhinov Kasiviswanathan --- drivers/net/ethernet/qualcomm/rmnet/rmnet_config.h | 1 - .../net/ethernet/qualcomm/rmnet/rmnet_handlers.c

[PATCH net 5/7] net: qualcomm: rmnet: Remove duplicate setting of rmnet_devices

2017-10-10 Thread Subash Abhinov Kasiviswanathan
The rmnet_devices information is already stored in muxed_ep, so storing this in rmnet_devices[] again is redundant. Fixes: ceed73a2cf4a ("drivers: net: ethernet: qualcomm: rmnet: Initial implementation") Signed-off-by: Subash Abhinov Kasiviswanathan --- drivers/net/ethernet/qualcomm/rmnet/rmnet

[PATCH net 7/7] net: qualcomm: rmnet: Implement bridge mode

2017-10-10 Thread Subash Abhinov Kasiviswanathan
Add support to bridge two devices which can send multiplexing and aggregation (MAP) data. This is done only when the data itself is not going to be consumed in the stack but is being passed on to a different endpoint. This is mainly used for testing. Fixes: ceed73a2cf4a ("drivers: net: ethernet: q

[PATCH net 2/7] net: qualcomm: rmnet: Remove some unused defines

2017-10-10 Thread Subash Abhinov Kasiviswanathan
Most of these constants were used in the initial patchset where custom netlink configuration was used and hence are no longer relevant. Fixes: ceed73a2cf4a ("drivers: net: ethernet: qualcomm: rmnet: Initial implementation") Signed-off-by: Subash Abhinov Kasiviswanathan --- drivers/net/ethernet/

[PATCH net 0/7] net: qualcomm: rmnet: Fix some existing functionality

2017-10-10 Thread Subash Abhinov Kasiviswanathan
This series fixes some of the broken rmnet functionality from the initial patchset. Bridge mode is re-written and made useable and the muxed_ep is converted to hlist. Patches 1-5 are cleanups in preparation for these changes. Patch 6 does the hlist conversion. Patch 7 has the implementation of the

[PATCH net-next v3 5/5] selinux: bpf: Add addtional check for bpf object file receive

2017-10-10 Thread Chenbo Feng
From: Chenbo Feng Introduce a bpf object related check when sending and receiving files through unix domain socket as well as binder. It checks if the receiving process have privilege to read/write the bpf map or use the bpf program. This check is necessary because the bpf maps and programs are u

[PATCH net-next v3 2/5] bpf: Add tests for eBPF file mode

2017-10-10 Thread Chenbo Feng
From: Chenbo Feng Two related tests are added into bpf selftest to test read only map and write only map. The tests verified the read only and write only flags are working on hash maps. Signed-off-by: Chenbo Feng --- tools/testing/selftests/bpf/test_maps.c | 48

[PATCH net-next v3 1/5] bpf: Add file mode configuration into bpf maps

2017-10-10 Thread Chenbo Feng
From: Chenbo Feng Introduce the map read/write flags to the eBPF syscalls that returns the map fd. The flags is used to set up the file mode when construct a new file descriptor for bpf maps. To not break the backward capability, the f_flags is set to O_RDWR if the flag passed by syscall is 0. Ot

[PATCH net-next v3 3/5] security: bpf: Add LSM hooks for bpf object related syscall

2017-10-10 Thread Chenbo Feng
From: Chenbo Feng Introduce several LSM hooks for the syscalls that will allow the userspace to access to eBPF object such as eBPF programs and eBPF maps. The security check is aimed to enforce a per object security protection for eBPF object so only processes with the right priviliges can read/w

[PATCH net-next v3 4/5] selinux: bpf: Add selinux check for eBPF syscall operations

2017-10-10 Thread Chenbo Feng
From: Chenbo Feng Implement the actual checks introduced to eBPF related syscalls. This implementation use the security field inside bpf object to store a sid that identify the bpf object. And when processes try to access the object, selinux will check if processes have the right privileges. The

[PATCH net-next v3 0/5] bpf: security: New file mode and LSM hooks for eBPF object permission control

2017-10-10 Thread Chenbo Feng
From: Chenbo Feng Much like files and sockets, eBPF objects are accessed, controlled, and shared via a file descriptor (FD). Unlike files and sockets, the existing mechanism for eBPF object access control is very limited. Currently there are two options for granting accessing to eBPF operations:

Re: [PATCH net-next v2] openvswitch: add ct_clear action

2017-10-10 Thread David Miller
From: Pravin Shelar Date: Tue, 10 Oct 2017 16:34:29 -0700 > On Tue, Oct 10, 2017 at 1:54 PM, Eric Garver wrote: >> This adds a ct_clear action for clearing conntrack state. ct_clear is >> currently implemented in OVS userspace, but is not backed by an action >> in the kernel datapath. This is us

Re: [PATCH net-next v2] openvswitch: add ct_clear action

2017-10-10 Thread Pravin Shelar
On Tue, Oct 10, 2017 at 1:54 PM, Eric Garver wrote: > This adds a ct_clear action for clearing conntrack state. ct_clear is > currently implemented in OVS userspace, but is not backed by an action > in the kernel datapath. This is useful for flows that may modify a > packet tuple after a ct lookup

Re: [PATCH net-next] net: dst: move cpu inside ifdef to avoid compilation warning

2017-10-10 Thread David Miller
From: Jakub Kicinski Date: Tue, 10 Oct 2017 15:05:39 -0700 > If CONFIG_DST_CACHE is not selected cpu variable > will be unused and we will see a compilation warning. > Move it under the ifdef. > > Reported-by: kbuild test robot > Fixes: d66f2b91f95b ("bpf: don't rely on the verifier lock for me

Re: [net-next V6 PATCH 1/5] bpf: introduce new bpf cpu map type BPF_MAP_TYPE_CPUMAP

2017-10-10 Thread Daniel Borkmann
On 10/10/2017 02:47 PM, Jesper Dangaard Brouer wrote: [...] +static struct bpf_map *cpu_map_alloc(union bpf_attr *attr) +{ + struct bpf_cpu_map *cmap; + int err = -ENOMEM; + u64 cost; + int ret; + + if (!capable(CAP_SYS_ADMIN)) + return ERR_PTR(-EPERM);

[PATCH] hdlc: Convert timers to use timer_setup()

2017-10-10 Thread Kees Cook
In preparation for unconditionally passing the struct timer_list pointer to all timer callbacks, switch to using the new timer_setup() and from_timer() to pass the timer pointer explicitly. This adds a pointer back to the net_device, and drops needless open-coded resetting of the .function and .dat

[PATCH net-next] net: dst: move cpu inside ifdef to avoid compilation warning

2017-10-10 Thread Jakub Kicinski
If CONFIG_DST_CACHE is not selected cpu variable will be unused and we will see a compilation warning. Move it under the ifdef. Reported-by: kbuild test robot Fixes: d66f2b91f95b ("bpf: don't rely on the verifier lock for metadata_dst allocation") Signed-off-by: Jakub Kicinski --- net/core/dst

[PATCH] i40e: only redistribute MSI-X vectors when needed

2017-10-10 Thread Shannon Nelson
Whether or not there are vectors_left, we only need to redistribute our vectors if we didn't get as many as we requested. With the current check, the code will try to redistribute even if we did in fact get all the vectors we requested - this can happen when we have more CPUs than we do vectors.

Re: [Patch net-next] tcp: add a tracepoint for tcp_retransmit_skb()

2017-10-10 Thread Hannes Frederic Sowa
Alexei Starovoitov writes: > On Mon, Oct 09, 2017 at 10:35:47PM -0700, Cong Wang wrote: [...] >> +trace_tcp_retransmit_skb(sk, skb, segs); > > I'm happy to see new tracepoints being added to tcp stack, but I'm concerned > with practical usability of them. > Like the above tracepoint

Re: [patch net-next 3/4] net: sched: convert cls_flower->egress_dev users to tc_setup_cb_egdev infra

2017-10-10 Thread Or Gerlitz
On Wed, Oct 11, 2017 at 12:16 AM, Jiri Pirko wrote: > Tue, Oct 10, 2017 at 10:08:23PM CEST, gerlitz...@gmail.com wrote: >>On Tue, Oct 10, 2017 at 10:30 AM, Jiri Pirko wrote: >>> The only user of cls_flower->egress_dev is mlx5. >> >>but nfp supports decap action offload too and from the flower cod

Re: [patch net-next 0/4] net: sched: get rid of cls_flower->egress_dev

2017-10-10 Thread Or Gerlitz
On Wed, Oct 11, 2017 at 12:13 AM, Jiri Pirko wrote: > Tue, Oct 10, 2017 at 07:24:21PM CEST, gerlitz...@gmail.com wrote: > Or, as I replied to you earlier, the issue you describe is totally > unrelated to this patchset as you see the issue with the current net-next. Jiri, the point I wanted to ma

[PATCH v2 nf-next 1/2] netfilter: x_tables: make xt_replace_table wait until old rules are not used anymore

2017-10-10 Thread Florian Westphal
xt_replace_table relies on table replacement counter retrieval (which uses xt_recseq to synchronize pcpu counters). This is fine, however with large rule set get_counters() can take a very long time -- it needs to synchronize all counters because it has to assume concurrent modifications can occur

[PATCH v2 nf-next 2/2] netfilter: x_tables: don't use seqlock when fetching old counters

2017-10-10 Thread Florian Westphal
after previous commit xt_replace_table will wait until all cpus had even seqcount (i.e., no cpu is accessing old ruleset). Add a 'old' counter retrival version that doesn't synchronize counters. Its not needed, the old counters are not in use anymore at this point. This speeds up table replacemen

[PATCH v2 nf-next] netfilter: x_tables: speed up iptables-restore

2017-10-10 Thread Florian Westphal
iptables-restore can take quite a long time when sytem is busy, in order of half a minute or more. The main reason for this is the way ip(6)tables performs table swap, or, more precisely, expensive sequence lock synchronizations when reading counters. When xt_replace_table assigns the new ruleset

Re: [Patch net-next] tcp: add a tracepoint for tcp_retransmit_skb()

2017-10-10 Thread Cong Wang
On Tue, Oct 10, 2017 at 10:38 AM, Alexei Starovoitov wrote: > > I'm happy to see new tracepoints being added to tcp stack, but I'm concerned > with practical usability of them. > Like the above tracepoint definition makes it not very useful from bpf point > of view, > since 'sk' pointer is not re

Re: [PATCH v2] xdp: Sample xdp program implementing ip forward

2017-10-10 Thread David Daney
On 10/10/2017 10:19 AM, Stephen Hemminger wrote: On Tue, 10 Oct 2017 12:58:52 +0530 Christina Jacob wrote: +/* Get the mac address of the interface given interface name */ +static long *getmac(char *iface) +{ + int fd; + struct ifreq ifr; + long *mac = NULL; + + fd = so

Re: [PATCH net-next v2 6/7] bpf: don't rely on the verifier lock for metadata_dst allocation

2017-10-10 Thread kbuild test robot
Hi Jakub, [auto build test WARNING on net-next/master] url: https://github.com/0day-ci/linux/commits/Jakub-Kicinski/bpf-get-rid-of-global-verifier-state-and-reuse-instruction-printer/20171011-021905 config: x86_64-randconfig-a0-10110234 (attached as .config) compiler: gcc-4.4 (Debian 4.4.7-8)

Re: [PATCH net-next v2 4/5] selinux: bpf: Add selinux check for eBPF syscall operations

2017-10-10 Thread kbuild test robot
Hi Chenbo, [auto build test WARNING on net-next/master] url: https://github.com/0day-ci/linux/commits/Chenbo-Feng/bpf-security-New-file-mode-and-LSM-hooks-for-eBPF-object-permission-control/20171011-010349 config: x86_64-randconfig-u0-10110310 (attached as .config) compiler: gcc-6 (Debian 6.2

Re: [patch net-next 1/4] net: sched: make tc_action_ops->get_dev return dev and avoid passing net

2017-10-10 Thread Jiri Pirko
Tue, Oct 10, 2017 at 07:44:53PM CEST, xiyou.wangc...@gmail.com wrote: >On Tue, Oct 10, 2017 at 12:30 AM, Jiri Pirko wrote: >> -static int tcf_mirred_device(const struct tc_action *a, struct net *net, >> -struct net_device **mirred_dev) >> +static struct net_device *tcf_

Re: [PATCH net-next] cxgb4: Add support for new flash parts

2017-10-10 Thread David Miller
From: Ganesh Goudar Date: Tue, 10 Oct 2017 12:44:13 +0530 > Add support for new flash parts identification, and > also cleanup the flash Part identifying and decoding > code. > > Based on the original work of Casey Leedom > > Signed-off-by: Ganesh Goudar Applied.

Re: [PATCH net-next] cxgb4: add new T5 pci device id's

2017-10-10 Thread David Miller
From: Ganesh Goudar Date: Tue, 10 Oct 2017 12:45:02 +0530 > Add 0x50aa and 0x50ab T5 device id's. > > Signed-off-by: Ganesh Goudar Applied.

Re: [patch net-next 3/4] net: sched: convert cls_flower->egress_dev users to tc_setup_cb_egdev infra

2017-10-10 Thread Jiri Pirko
Tue, Oct 10, 2017 at 10:08:23PM CEST, gerlitz...@gmail.com wrote: >On Tue, Oct 10, 2017 at 10:30 AM, Jiri Pirko wrote: >> The only user of cls_flower->egress_dev is mlx5. > >but nfp supports decap action offload too and from the flower code >stand point, I guess they are both the same, right? how

Re: [patch net-next 0/4] net: sched: get rid of cls_flower->egress_dev

2017-10-10 Thread Jiri Pirko
Tue, Oct 10, 2017 at 07:24:21PM CEST, gerlitz...@gmail.com wrote: >Jiri, > >FWIW, as I reported to you earlier, I was playing with tc encap/decap rules >on 4.14-rc+ (net) before >applying any patch of this series, and something is messy w.r.t to decap >rules. I don't see >them removed at all when u

[PATCH] rtl8xxxu: mark expected switch fall-throughs

2017-10-10 Thread Gustavo A. R. Silva
In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through. Cc: Jes Sorensen Cc: Kalle Valo Cc: linux-wirel...@vger.kernel.org Cc: netdev@vger.kernel.org Signed-off-by: Gustavo A. R. Silva --- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.

Re: [PATCH] rtl8xxxu: mark expected switch fall-throughs

2017-10-10 Thread Florian Fainelli
On 10/10/2017 12:35 PM, Jes Sorensen wrote: > On 10/10/2017 03:30 PM, Gustavo A. R. Silva wrote: >> In preparation to enabling -Wimplicit-fallthrough, mark switch cases >> where we are expecting to fall through. > > While this isn't harmful, to me this looks like pointless patch churn > for zero g

[PATCH net-next v2] openvswitch: add ct_clear action

2017-10-10 Thread Eric Garver
This adds a ct_clear action for clearing conntrack state. ct_clear is currently implemented in OVS userspace, but is not backed by an action in the kernel datapath. This is useful for flows that may modify a packet tuple after a ct lookup has already occurred. Signed-off-by: Eric Garver --- v2:

Re: [ovs-dev] [PATCH net-next] openvswitch: add ct_clear action

2017-10-10 Thread Joe Stringer
On 10 October 2017 at 12:13, Eric Garver wrote: > On Tue, Oct 10, 2017 at 10:24:20AM -0700, Joe Stringer wrote: >> On 10 October 2017 at 08:09, Eric Garver wrote: >> > On Tue, Oct 10, 2017 at 05:33:48AM -0700, Joe Stringer wrote: >> >> On 9 October 2017 at 21:41, Pravin Shelar wrote: >> >> > On

  1   2   3   >