Re: [PATCH net-next] net: sched: act_ife: fix memory leak in ife init

2018-07-11 Thread David Miller
From: Vlad Buslov Date: Mon, 9 Jul 2018 14:33:26 +0300 > Free params if tcf_idr_check_alloc() returned error. > > Fixes: 0190c1d452a9 ("net: sched: atomically check-allocate action") > Reported-by: Dan Carpenter > Signed-off-by: Vlad Buslov Applied.

Re: [PATCH net-next] cxgb4: specify IQTYPE in fw_iq_cmd

2018-07-11 Thread David Miller
From: Ganesh Goudar Date: Mon, 9 Jul 2018 16:52:03 +0530 > From: Arjun Vynipadath > > congestion argument passed to t4_sge_alloc_rxq() is used > to differentiate between nic/ofld queues. > > Signed-off-by: Arjun Vynipadath > Signed-off-by: Ganesh Goudar Applied.

Re: [PATCH net v2 0/5] net/ipv6: addr_gen_mode fixes

2018-07-11 Thread David Miller
From: Sabrina Dubroca Date: Mon, 9 Jul 2018 12:25:13 +0200 > This series fixes bugs in handling of the addr_gen_mode option, mainly > related to the sysctl. A minor netlink issue was also present in the > initial commit introducing the option on a per-netdevice basis. > > v2: add patch 4,

Re: [PATCH resend] rhashtable: detect when object movement might have invalidated a lookup

2018-07-11 Thread David Miller
From: David Miller Date: Wed, 11 Jul 2018 22:46:58 -0700 (PDT) > From: NeilBrown > Date: Fri, 06 Jul 2018 17:08:35 +1000 > >> >> Some users of rhashtable might need to change the key >> of an object and move it to a different location in the table. >> Other users might want to allocate

Re: [PATCH net-next] net/sched: flower: Fix null pointer dereference when run tc vlan command

2018-07-11 Thread David Miller
From: Jianbo Liu Date: Mon, 9 Jul 2018 02:26:20 + > Zahari issued tc vlan command without setting vlan_ethtype, which will > crash kernel. To avoid this, we must check tb[TCA_FLOWER_KEY_VLAN_ETH_TYPE] > is not null before use it. > Also we don't need to dump vlan_ethtype or cvlan_ethtype in

[PATCH net-next] net/tls: Removed redundant variable from 'struct tls_sw_context_rx'

2018-07-11 Thread Vakul Garg
The variable 'decrypted' in 'struct tls_sw_context_rx' is redundant and is being set/unset without purpose. Simplified the code by removing it. Signed-off-by: Vakul Garg --- include/net/tls.h | 1 - net/tls/tls_sw.c | 87 --- 2 files

Re: [PATCH iproute2-next] ipaddress: fix label matching

2018-07-11 Thread Vincent Bernat
❦ 11 juillet 2018 21:01 -0400, David Ahern  : >> +++ b/ip/ipaddress.c >> @@ -837,11 +837,6 @@ int print_linkinfo(const struct sockaddr_nl *who, >> if (!name) >> return -1; >> >> -if (filter.label && >> -(!filter.family || filter.family == AF_PACKET) && >> -

Re: 答复: [PATCH] net: convert gro_count to bitmask

2018-07-11 Thread David Miller
From: "Li,Rongqing" Date: Thu, 12 Jul 2018 03:03:51 + > > >> -邮件原件- >> 发件人: David Miller [mailto:da...@davemloft.net] >> 发送时间: 2018年7月12日 10:49 >> 收件人: Li,Rongqing >> 抄送: netdev@vger.kernel.org >> 主题: Re: [PATCH] net: convert gro_count to bitmask >> >> From: Li RongQing >> Date:

[PATCH bpf-next 1/7] xdp: add per mode attributes for attached programs

2018-07-11 Thread Jakub Kicinski
In preparation for support of simultaneous driver and hardware XDP support add per-mode attributes. The catch-all IFLA_XDP_PROG_ID will still be reported, but user space can now also access the program ID in a new IFLA_XDP__PROG_ID attribute. Signed-off-by: Jakub Kicinski Reviewed-by: Quentin

[PATCH bpf-next 4/7] xdp: support simultaneous driver and hw XDP attachment

2018-07-11 Thread Jakub Kicinski
Split the query of HW-attached program from the software one. Introduce new .ndo_bpf command to query HW-attached program. This will allow drivers to install different programs in HW and SW at the same time. Netlink can now also carry multiple programs on dump (in which case mode will be set to

[PATCH bpf-next 3/7] xdp: factor out common program/flags handling from drivers

2018-07-11 Thread Jakub Kicinski
Basic operations drivers perform during xdp setup and query can be moved to helpers in the core. Encapsulate program and flags into a structure and add helpers. Note that the structure is intended as the "main" program information source in the driver. Most drivers will additionally place the

[PATCH bpf-next 5/7] netdevsim: add support for simultaneous driver and hw XDP

2018-07-11 Thread Jakub Kicinski
Allow netdevsim to accept driver and offload attachment of XDP BPF programs at the same time. Signed-off-by: Jakub Kicinski Reviewed-by: Quentin Monnet --- drivers/net/netdevsim/bpf.c | 32 +++-- drivers/net/netdevsim/netdev.c | 3 +-

[PATCH bpf-next 7/7] nfp: add support for simultaneous driver and hw XDP

2018-07-11 Thread Jakub Kicinski
Split handling of offloaded and driver programs completely. Since offloaded programs always come with XDP_FLAGS_HW_MODE set in reality there could be no sharing, anyway, programs would only be installed in driver or in hardware. Splitting the handling allows us to install programs in HW and in

[PATCH bpf-next 0/7] xdp: simultaneous driver and HW XDP

2018-07-11 Thread Jakub Kicinski
Hi! This set is adding support for loading driver and offload XDP at the same time. This enables advanced use cases where some of the work is offloaded to the NIC and some is done by the host. Separate netlink attributes are added for each mode of operation. Driver callbacks for offload are

[PATCH bpf-next 6/7] selftests/bpf: add test for multiple programs

2018-07-11 Thread Jakub Kicinski
Add tests for having an XDP program attached in the driver and another one attached in HW simultaneously. Signed-off-by: Jakub Kicinski Reviewed-by: Quentin Monnet --- tools/testing/selftests/bpf/test_offload.py | 63 + 1 file changed, 63 insertions(+) diff --git

[PATCH bpf-next 2/7] xdp: don't make drivers report attachment mode

2018-07-11 Thread Jakub Kicinski
prog_attached of struct netdev_bpf should have been superseded by simply setting prog_id long time ago, but we kept it around to allow offloading drivers to communicate attachment mode (drv vs hw). Subsequently drivers were also allowed to report back attachment flags (prog_flags), and since

答复: [PATCH] net: convert gro_count to bitmask

2018-07-11 Thread Li,Rongqing
> -邮件原件- > 发件人: Eric Dumazet [mailto:eric.duma...@gmail.com] > 发送时间: 2018年7月11日 19:32 > 收件人: Li,Rongqing ; netdev@vger.kernel.org > 主题: Re: [PATCH] net: convert gro_count to bitmask > > > > On 07/11/2018 02:15 AM, Li RongQing wrote: > > gro_hash size is 192 bytes, and uses 3 cache

答复: [PATCH] net: convert gro_count to bitmask

2018-07-11 Thread Li,Rongqing
> -邮件原件- > 发件人: David Miller [mailto:da...@davemloft.net] > 发送时间: 2018年7月12日 10:49 > 收件人: Li,Rongqing > 抄送: netdev@vger.kernel.org > 主题: Re: [PATCH] net: convert gro_count to bitmask > > From: Li RongQing > Date: Wed, 11 Jul 2018 17:15:53 +0800 > > > + clear_bit(index,

Re: [PATCH] net: convert gro_count to bitmask

2018-07-11 Thread David Miller
From: Li RongQing Date: Wed, 11 Jul 2018 17:15:53 +0800 > + clear_bit(index, >gro_bitmask); Please don't use atomics here, at least use __clear_bit(). This is why I did the operations by hand in my version of the patch. Also, if you are going to preempt my patch, at least retain

Re: Bug report: epoll can fail to report EPOLLOUT when unix datagram socket peer is closed

2018-07-11 Thread Jason Baron
On 06/26/2018 10:18 AM, Ian Lance Taylor wrote: > I'm reporting what appears to be a bug in the Linux kernel's epoll > support. It seems that epoll appears to sometimes fail to report an > EPOLLOUT event when the other side of an AF_UNIX/SOCK_DGRAM socket is > closed. This bug report started

答复: [PATCH] net: convert gro_count to bitmask

2018-07-11 Thread Li,Rongqing
> -邮件原件- > 发件人: Stefano Brivio [mailto:sbri...@redhat.com] > 发送时间: 2018年7月11日 18:52 > 收件人: Li,Rongqing > 抄送: netdev@vger.kernel.org; Eric Dumazet > 主题: Re: [PATCH] net: convert gro_count to bitmask > > On Wed, 11 Jul 2018 17:15:53 +0800 > Li RongQing wrote: > > > @@ -5380,6 +5382,12

Re: [PATCH net-next] net: sched: fix unprotected access to rcu cookie pointer

2018-07-11 Thread Marcelo Ricardo Leitner
On Mon, Jul 09, 2018 at 11:44:38PM +0300, Vlad Buslov wrote: > > On Mon 09 Jul 2018 at 20:34, Marcelo Ricardo Leitner > wrote: > > On Mon, Jul 09, 2018 at 08:26:47PM +0300, Vlad Buslov wrote: > >> Fix action attribute size calculation function to take rcu read lock and > >> access act_cookie

Re: [PATCH iproute2-next] ipaddress: fix label matching

2018-07-11 Thread David Ahern
On 7/11/18 7:36 AM, Vincent Bernat wrote: > diff --git a/ip/ipaddress.c b/ip/ipaddress.c > index 5009bfe6d2e3..20ef6724944e 100644 > --- a/ip/ipaddress.c > +++ b/ip/ipaddress.c > @@ -837,11 +837,6 @@ int print_linkinfo(const struct sockaddr_nl *who, > if (!name) > return -1; >

Re: [PATCH v4 iproute2-next 0/3] Add support for ETF qdisc

2018-07-11 Thread David Ahern
On 7/9/18 7:56 PM, Jesus Sanchez-Palencia wrote: > fixes since v3: > - Add support for clock names with the "CLOCK_" prefix; > - Print clock name on print_opt(); > - Use strcasecmp() instead of strncasecmp(). > > > The ETF (earliest txtime first) qdisc was recently merged into net-next > [1],

[PATCH bpf-next 2/6] bpf: Sync bpf.h to tools/

2018-07-11 Thread Andrey Ignatov
Sync BPF_SOCK_OPS_TCP_LISTEN_CB related UAPI changes to tools/. Signed-off-by: Andrey Ignatov Acked-by: Alexei Starovoitov --- tools/include/uapi/linux/bpf.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tools/include/uapi/linux/bpf.h b/tools/include/uapi/linux/bpf.h index

[PATCH bpf-next 0/6] TCP-BPF callback for listening sockets

2018-07-11 Thread Andrey Ignatov
This patchset adds TCP-BPF callback for listening sockets. Patch 0001 provides more details and is the main patch in the set. Patch 0006 adds selftest for the new callback. Other patches are bug fixes and improvements in TCP-BPF selftest to make it easier to extend in 0006. Andrey Ignatov

[PATCH bpf-next 1/6] bpf: Add BPF_SOCK_OPS_TCP_LISTEN_CB

2018-07-11 Thread Andrey Ignatov
Add new TCP-BPF callback that is called on listen(2) right after socket transition to TCP_LISTEN state. It fills the gap for listening sockets in TCP-BPF. For example BPF program can set BPF_SOCK_OPS_STATE_CB_FLAG when socket becomes listening and track later transition from TCP_LISTEN to

[PATCH bpf-next 6/6] selftests/bpf: Test case for BPF_SOCK_OPS_TCP_LISTEN_CB

2018-07-11 Thread Andrey Ignatov
Cover new TCP-BPF callback in test_tcpbpf: when listen() is called on socket, set BPF_SOCK_OPS_STATE_CB_FLAG so that BPF_SOCK_OPS_STATE_CB callback can be called on future state transition, and when such a transition happens (TCP_LISTEN -> TCP_CLOSE), track it in the map and verify it in user

[PATCH bpf-next 4/6] selftests/bpf: Switch test_tcpbpf_user to cgroup_helpers

2018-07-11 Thread Andrey Ignatov
Switch to cgroup_helpers to simplify the code and fix cgroup cleanup: before cgroup was not cleaned up after the test. It also removes SYSTEM macro, that only printed error, but didn't terminate the test. Signed-off-by: Andrey Ignatov Acked-by: Alexei Starovoitov ---

[PATCH bpf-next 5/6] selftests/bpf: Better verification in test_tcpbpf

2018-07-11 Thread Andrey Ignatov
Reduce amount of copy/paste for debug info when result is verified in the test and keep that info together with values being checked so that they won't get out of sync. It also improves debug experience: instead of checking manually what doesn't match in debug output for all fields, only

[PATCH bpf-next 3/6] selftests/bpf: Fix const'ness in cgroup_helpers

2018-07-11 Thread Andrey Ignatov
Lack of const in cgroup helpers signatures forces to write ugly client code. Fix it. Signed-off-by: Andrey Ignatov Acked-by: Alexei Starovoitov --- tools/testing/selftests/bpf/cgroup_helpers.c | 6 +++--- tools/testing/selftests/bpf/cgroup_helpers.h | 6 +++--- 2 files changed, 6

Apply for a 3% loan...

2018-07-11 Thread Matt Adams
Hello, We offer L oans at 3% interest rate per annum. If intereted, contact me with amount needed and L oan duration for more details...

Re: [PATCH bpf 0/4] Consistent sendmsg error reporting in AF_XDP

2018-07-11 Thread Alexei Starovoitov
On Wed, Jul 11, 2018 at 10:12:48AM +0200, Magnus Karlsson wrote: > This patch set adjusts the AF_XDP TX error reporting so that it becomes > consistent between copy mode and zero-copy. First some background: > > Copy-mode for TX uses the SKB path in which the action of sending the > packet is

Confirm And Verify Your Mail ID You Must Open

2018-07-11 Thread Blocked From Sending And Receiving Emails
You will be blocked from sending and receiving emails Dear @Pen Webmail Email User This message is from Information Technology Services of This EMAIL to all our Staff. We are currently upgrading our database and e-mail center and this is our final notification to you. We have sent several

Re: [BUG] bonded interfaces drop bpdu (stp) frames

2018-07-11 Thread महेश बंडेवार
On Wed, Jul 11, 2018 at 3:23 PM, Michal Soltys wrote: > > Hi, > > As weird as that sounds, this is what I observed today after bumping > kernel version. I have a setup where 2 bonds are attached to linux > bridge and physically are connected to two switches doing MSTP (and > linux bridge is just

Re: [PATCH bpf] bpf: fix panic due to oob in bpf_prog_test_run_skb

2018-07-11 Thread Alexei Starovoitov
On Wed, Jul 11, 2018 at 03:30:14PM +0200, Daniel Borkmann wrote: > sykzaller triggered several panics similar to the below: > > [...] > [ 248.851531] BUG: KASAN: use-after-free in _copy_to_user+0x5c/0x90 > [ 248.857656] Read of size 985 at addr 88080172 by task a.out/1425 >

[BUG net-next] BUG triggered with GRO SKB list_head changes

2018-07-11 Thread Tyler Hicks
Starting with the following net-next commit, I see a BUG when starting a LXD container inside of a KVM guest using virtio-net: d4546c2509b1 net: Convert GRO SKB handling to list_head. Here's what the kernel spits out: kernel BUG at /var/scm/kernel/linux/include/linux/skbuff.h:2080! invalid

[BUG] bonded interfaces drop bpdu (stp) frames

2018-07-11 Thread Michal Soltys
Hi, As weird as that sounds, this is what I observed today after bumping kernel version. I have a setup where 2 bonds are attached to linux bridge and physically are connected to two switches doing MSTP (and linux bridge is just passing them). Initially I suspected some changes related to bridge

Re: [PATCH net-next 2/2] net: phy: add phy_speed_down and phy_speed_up

2018-07-11 Thread Heiner Kallweit
On 11.07.2018 23:33, Florian Fainelli wrote: > > > On 07/11/2018 02:08 PM, Heiner Kallweit wrote: >> On 11.07.2018 22:55, Andrew Lunn wrote: +/** + * phy_speed_down - set speed to lowest speed supported by both link partners + * @phydev: the phy_device struct + * @sync:

Re: [PATCH net-next 2/2] net: phy: add phy_speed_down and phy_speed_up

2018-07-11 Thread Florian Fainelli
On 07/11/2018 02:08 PM, Heiner Kallweit wrote: > On 11.07.2018 22:55, Andrew Lunn wrote: >>> +/** >>> + * phy_speed_down - set speed to lowest speed supported by both link >>> partners >>> + * @phydev: the phy_device struct >>> + * @sync: perform action synchronously >>> + * >>> + *

Re: [PATCH net-next 2/2] net: phy: add phy_speed_down and phy_speed_up

2018-07-11 Thread Heiner Kallweit
On 11.07.2018 22:55, Andrew Lunn wrote: >> +/** >> + * phy_speed_down - set speed to lowest speed supported by both link >> partners >> + * @phydev: the phy_device struct >> + * @sync: perform action synchronously >> + * >> + * Description: Typically used to save energy when waiting for a WoL

Re: [PATCH net-next 1/2] net: phy: add helper phy_config_aneg

2018-07-11 Thread Florian Fainelli
On 07/11/2018 01:30 PM, Heiner Kallweit wrote: > This functionality will also be needed in subsequent patches of this > series, therefore factor it out to a helper. > > Signed-off-by: Heiner Kallweit Reviewed-by: Florian Fainelli -- Florian

Re: [PATCH net-next 2/2] net: phy: add phy_speed_down and phy_speed_up

2018-07-11 Thread Andrew Lunn
> +/** > + * phy_speed_down - set speed to lowest speed supported by both link partners > + * @phydev: the phy_device struct > + * @sync: perform action synchronously > + * > + * Description: Typically used to save energy when waiting for a WoL packet > + */ > +int phy_speed_down(struct phy_device

Re: [PATCH net-next 1/2] net: phy: add helper phy_config_aneg

2018-07-11 Thread Andrew Lunn
On Wed, Jul 11, 2018 at 10:30:27PM +0200, Heiner Kallweit wrote: > This functionality will also be needed in subsequent patches of this > series, therefore factor it out to a helper. > > Signed-off-by: Heiner Kallweit Reviewed-by: Andrew Lunn Andrew

Re: [PATCH net-next] tc-testing: add geneve options in tunnel_key unit tests

2018-07-11 Thread Lucas Bates
On Tue, Jul 10, 2018 at 9:22 PM, Jakub Kicinski wrote: > From: Pieter Jansen van Vuuren > > Extend tc tunnel_key action unit tests with geneve options. Tests > include testing single and multiple geneve options, as well as > testing geneve options that are expected to fail. > > Signed-off-by:

Re: [PATCH bpf-next] bpf: better availability probing for seg6 helpers

2018-07-11 Thread Daniel Borkmann
On 07/10/2018 09:20 PM, Daniel Borkmann wrote: > On 07/10/2018 06:54 PM, Mathieu Xhonneux wrote: >> bpf_lwt_seg6_* helpers require CONFIG_IPV6_SEG6_BPF, and currently >> return -EOPNOTSUPP to indicate unavailability. This patch forces the >> BPF verifier to reject programs using these helpers when

[PATCH net-next 2/2] net: phy: add phy_speed_down and phy_speed_up

2018-07-11 Thread Heiner Kallweit
Some network drivers include functionality to speed down the PHY when suspending and just waiting for a WoL packet because this saves energy. This functionality is quite generic, therefore let's factor it out to phylib. Signed-off-by: Heiner Kallweit --- drivers/net/phy/phy.c | 78

Re: [PATCH iproute2-next] ipaddress: fix label matching

2018-07-11 Thread Vincent Bernat
❦ 11 juillet 2018 13:03 -0700, Stephen Hemminger  : >> Since 9516823051ce, "ip addr show label lo:1" doesn't work >> anymore (doesn't show any address, despite a matching label). >> Reverting to return 0 instead of -1 fix the issue. >> >> However, the condition says: "if we filter by label

[PATCH net-next 1/2] net: phy: add helper phy_config_aneg

2018-07-11 Thread Heiner Kallweit
This functionality will also be needed in subsequent patches of this series, therefore factor it out to a helper. Signed-off-by: Heiner Kallweit --- drivers/net/phy/phy.c | 13 + 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/drivers/net/phy/phy.c

[PATCH net-next 0/2] net: phy: add functionality to speed down PHY when waiting for WoL packet

2018-07-11 Thread Heiner Kallweit
Some network drivers include functionality to speed down the PHY when suspending and just waiting for a WoL packet because this saves energy. This patch is based on our recent discussion about factoring out this functionality to phylib. First user will be the r8169 driver. Heiner Kallweit (2):

Re: [net-next PATCH] net: ipv4: fix listify ip_rcv_finish in case of forwarding

2018-07-11 Thread Jesper Dangaard Brouer
On Wed, 11 Jul 2018 16:41:35 +0100 Edward Cree wrote: > On 11/07/18 16:01, Jesper Dangaard Brouer wrote: > > In commit 5fa12739a53d ("net: ipv4: listify ip_rcv_finish") calling > > dst_input(skb) was split-out. The ip_sublist_rcv_finish() just calls > > dst_input(skb) in a loop. > > > > The

Re: [PATCH bpf-next v3 00/13] tools: bpf: extend bpftool prog load

2018-07-11 Thread Daniel Borkmann
On 07/10/2018 11:42 PM, Jakub Kicinski wrote: > Hi! > > This series starts with two minor clean ups to test_offload.py > selftest script. > > The next 11 patches extend the abilities of bpftool prog load > beyond the simple cgroup use cases. Three new parameters are > added: > > - type -

Re: [net-next PATCH] net: ipv4: fix listify ip_rcv_finish in case of forwarding

2018-07-11 Thread Jesper Dangaard Brouer
On Wed, 11 Jul 2018 19:05:20 + Saeed Mahameed wrote: > On Wed, 2018-07-11 at 17:01 +0200, Jesper Dangaard Brouer wrote: > > Only driver sfc actually uses this, but I don't have this NIC, so I > > tested this on mlx5, with my own changes to make it use > > netif_receive_skb_list(), > > but

Re: [PATCH] of: mdio: Support fixed links in of_phy_get_and_connect()

2018-07-11 Thread Andrew Lunn
On Wed, Jul 11, 2018 at 07:45:11PM +0200, Linus Walleij wrote: > By a simple extension of of_phy_get_and_connect() drivers > that have a fixed link on e.g. RGMII can support also > fixed links, so in addition to: > > ethernet-port { > phy-mode = "rgmii"; > phy-handle = <>; > }; > >

Re: [PATCH bpf-next v4 3/3] bpf: btf: print map dump and lookup with btf info

2018-07-11 Thread Jakub Kicinski
On Tue, 10 Jul 2018 20:21:11 -0700, Okash Khawaja wrote: > + if (err || btf_info.btf_size > last_size) { > + err = errno; errno may not be set in case btf_info.btf_size > last_size errno is positive, while other error return codes are negative. > + goto exit_free; >

Re: [PATCH iproute2-next] ipaddress: fix label matching

2018-07-11 Thread Stephen Hemminger
On Wed, 11 Jul 2018 13:36:03 +0200 Vincent Bernat wrote: > Since 9516823051ce, "ip addr show label lo:1" doesn't work > anymore (doesn't show any address, despite a matching label). > Reverting to return 0 instead of -1 fix the issue. > > However, the condition says: "if we filter by label

Re: [PATCH net-next 2/5 v3] net: gemini: Improve connection prints

2018-07-11 Thread Andrew Lunn
On Wed, Jul 11, 2018 at 09:32:42PM +0200, Linus Walleij wrote: > Switch over to using a module parameter and debug prints > that can be controlled by this or ethtool like everyone > else. Depromote all other prints to debug messages. > > The phy_print_status() was already in place, albeit never >

Re: [PATCH net-next 5/5 v3] net: gemini: Indicate that we can handle jumboframes

2018-07-11 Thread Andrew Lunn
On Wed, Jul 11, 2018 at 09:32:45PM +0200, Linus Walleij wrote: > The hardware supposedly handles frames up to 10236 bytes and > implements .ndo_change_mtu() so accept 10236 minus the ethernet > header for a VLAN tagged frame on the netdevices. Use > ETH_MIN_MTU as minimum MTU. > > Signed-off-by:

[PATCH v3 net-next 01/19] net: Add decrypted field to skb

2018-07-11 Thread Boris Pismenny
The decrypted bit is propogated to cloned/copied skbs. This will be used later by the inline crypto receive side offload of tls. Signed-off-by: Boris Pismenny Signed-off-by: Ilya Lesokhin --- include/linux/skbuff.h | 7 ++- net/core/skbuff.c | 6 ++ 2 files changed, 12

[PATCH v3 net-next 18/19] net/mlx5e: IPsec, fix byte count in CQE

2018-07-11 Thread Boris Pismenny
This patch fixes the byte count indication in CQE for processed IPsec packets that contain a metadata header. Signed-off-by: Boris Pismenny --- drivers/net/ethernet/mellanox/mlx5/core/en_accel/ipsec_rxtx.c | 1 + drivers/net/ethernet/mellanox/mlx5/core/en_accel/ipsec_rxtx.h | 2 +-

[PATCH v3 net-next 03/19] net: Add TLS rx resync NDO

2018-07-11 Thread Boris Pismenny
Add new netdev tls op for resynchronizing HW tls context Signed-off-by: Boris Pismenny --- include/linux/netdevice.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h index b683971..0434df3 100644 --- a/include/linux/netdevice.h +++

[PATCH v3 net-next 14/19] net/mlx5e: TLS, add Innova TLS rx data path

2018-07-11 Thread Boris Pismenny
Implement the TLS rx offload data path according to the requirements of the TLS generic NIC offload infrastructure. Special metadata ethertype is used to pass information to the hardware. When hardware loses synchronization a special resync request metadata message is used to request resync.

[PATCH v3 net-next 16/19] net/mlx5e: TLS, build TLS netdev from capabilities

2018-07-11 Thread Boris Pismenny
This patch enables TLS Rx based on available HW capabilities. Signed-off-by: Boris Pismenny --- drivers/net/ethernet/mellanox/mlx5/core/en_accel/tls.c | 18 -- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/drivers/net/ethernet/mellanox/mlx5/core/en_accel/tls.c

[PATCH v3 net-next 05/19] tls: Refactor tls_offload variable names

2018-07-11 Thread Boris Pismenny
For symmetry, we rename tls_offload_context to tls_offload_context_tx before we add tls_offload_context_rx. Signed-off-by: Boris Pismenny --- .../net/ethernet/mellanox/mlx5/core/en_accel/tls.h | 6 +++--- include/net/tls.h | 16 +++---

[PATCH v3 net-next 19/19] net/mlx5e: Kconfig, mutually exclude compilation of TLS and IPsec accel

2018-07-11 Thread Boris Pismenny
We currently have no devices that support both TLS and IPsec using the accel framework, and the current code does not support both IPsec and TLS. This patch prevents such combinations. Signed-off-by: Boris Pismenny --- drivers/net/ethernet/mellanox/mlx5/core/Kconfig | 1 + 1 file changed, 1

KASAN: slab-out-of-bounds Read in rds_cong_queue_updates (2)

2018-07-11 Thread syzbot
Hello, syzbot found the following crash on: HEAD commit:0026129c8629 rhashtable: add restart routine in rhashtable.. git tree: net console output: https://syzkaller.appspot.com/x/log.txt?x=10b7ced040 kernel config: https://syzkaller.appspot.com/x/.config?x=b88de6eac8694da6

[PATCH v3 net-next 06/19] tls: Split decrypt_skb to two functions

2018-07-11 Thread Boris Pismenny
Previously, decrypt_skb also updated the TLS context. Now, decrypt_skb only decrypts the payload using the current context, while decrypt_skb_update also updates the state. Later, in the tls_device Rx flow, we will use decrypt_skb directly. Signed-off-by: Boris Pismenny --- include/net/tls.h |

[PATCH v3 net-next 17/19] net/mlx5: Accel, add common metadata functions

2018-07-11 Thread Boris Pismenny
This patch adds common functions to handle mellanox metadata headers. These functions are used by IPsec and TLS to process FPGA metadata. Signed-off-by: Boris Pismenny --- .../net/ethernet/mellanox/mlx5/core/accel/accel.h | 37 ++

[PATCH v3 net-next 11/19] net/mlx5e: TLS, refactor variable names

2018-07-11 Thread Boris Pismenny
For symmetry, we rename mlx5e_tls_offload_context to mlx5e_tls_offload_context_tx before we add mlx5e_tls_offload_context_rx. Signed-off-by: Boris Pismenny Reviewed-by: Aviad Yehezkel Reviewed-by: Tariq Toukan --- drivers/net/ethernet/mellanox/mlx5/core/en_accel/tls.c | 2 +-

[PATCH v3 net-next 08/19] tls: Fill software context without allocation

2018-07-11 Thread Boris Pismenny
This patch allows tls_set_sw_offload to fill the context in case it was already allocated previously. We will use it in TLS_DEVICE to fill the RX software context. Signed-off-by: Boris Pismenny --- net/tls/tls_sw.c | 34 ++ 1 file changed, 22 insertions(+), 12

[PATCH v3 net-next 07/19] tls: Split tls_sw_release_resources_rx

2018-07-11 Thread Boris Pismenny
This patch splits tls_sw_release_resources_rx into two functions one which releases all inner software tls structures and another that also frees the containing structure. In TLS_DEVICE we will need to release the software structures without freeeing the containing structure, which contains other

[PATCH v3 net-next 00/19] TLS offload rx, netdev & mlx5

2018-07-11 Thread Boris Pismenny
Hi, The following series provides TLS RX inline crypto offload. v2->v3: - Fix typo - Adjust cover letter - Fix bug in zero copy flows - Use network byte order for the record number in resync - Adjust the sequence provided in resync v1->v2: - Fix bisectability problems

[PATCH v3 net-next 15/19] net/mlx5e: TLS, add software statistics

2018-07-11 Thread Boris Pismenny
This patch adds software statistics for TLS to count important events. Signed-off-by: Boris Pismenny --- drivers/net/ethernet/mellanox/mlx5/core/en_accel/tls.c | 3 +++ drivers/net/ethernet/mellanox/mlx5/core/en_accel/tls.h | 4

[PATCH v3 net-next 13/19] net/mlx5e: TLS, add innova rx support

2018-07-11 Thread Boris Pismenny
Add the mlx5 implementation of the TLS Rx routines to add/del TLS contexts, also add the tls_dev_resync_rx routine to work with the TLS inline Rx crypto offload infrastructure. Signed-off-by: Boris Pismenny Signed-off-by: Ilya Lesokhin --- .../net/ethernet/mellanox/mlx5/core/en_accel/tls.c |

[PATCH v3 net-next 10/19] tls: Fix zerocopy_from_iter iov handling

2018-07-11 Thread Boris Pismenny
zerocopy_from_iter iterates over the message, but it doesn't revert the updates made by the iov iteration. This patch fixes it. Now, the iov can be used after calling zerocopy_from_iter. Fixes: 3c4d75591 ("tls: kernel TLS support") Signed-off-by: Boris Pismenny --- net/tls/tls_sw.c | 1 + 1

[PATCH v3 net-next 02/19] net: Add TLS RX offload feature

2018-07-11 Thread Boris Pismenny
From: Ilya Lesokhin This patch adds a netdev feature to configure TLS RX inline crypto offload. Signed-off-by: Ilya Lesokhin Signed-off-by: Boris Pismenny --- include/linux/netdev_features.h | 2 ++ net/core/ethtool.c | 1 + 2 files changed, 3 insertions(+) diff --git

[PATCH v3 net-next 09/19] tls: Add rx inline crypto offload

2018-07-11 Thread Boris Pismenny
This patch completes the generic infrastructure to offload TLS crypto to a network device. It enables the kernel to skip decryption and authentication of some skbs marked as decrypted by the NIC. In the fast path, all packets received are decrypted by the NIC and the performance is comparable to

[PATCH v3 net-next 12/19] net/mlx5: Accel, add TLS rx offload routines

2018-07-11 Thread Boris Pismenny
In Innova TLS, TLS contexts are added or deleted via a command message over the SBU connection. The HW then sends a response message over the same connection. Complete the implementation for Innova TLS (FPGA-based) hardware by adding support for rx inline crypto offload. Signed-off-by: Boris

KASAN: use-after-free Read in p9_fd_poll

2018-07-11 Thread syzbot
Hello, syzbot found the following crash on: HEAD commit:30c2c32d7f70 Merge tag 'drm-fixes-2018-07-10' of git://ano.. git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=1662c5b240 kernel config: https://syzkaller.appspot.com/x/.config?x=25856fac4e580aa7

[PATCH v3 net-next 04/19] tcp: Don't coalesce decrypted and encrypted SKBs

2018-07-11 Thread Boris Pismenny
Prevent coalescing of decrypted and encrypted SKBs in GRO and TCP layer. Signed-off-by: Boris Pismenny Signed-off-by: Ilya Lesokhin --- net/ipv4/tcp_input.c | 12 net/ipv4/tcp_offload.c | 3 +++ 2 files changed, 15 insertions(+) diff --git a/net/ipv4/tcp_input.c

[PATCH net-next 4/5 v3] net: gemini: Move main init to port

2018-07-11 Thread Linus Walleij
The initialization sequence for the ethernet, setting up interrupt routing and such things, need to be done after both the ports are clocked and reset. Before this the config will not "take". Move the initialization to the port probe function and keep track of init status in the state.

[PATCH net-next 5/5 v3] net: gemini: Indicate that we can handle jumboframes

2018-07-11 Thread Linus Walleij
The hardware supposedly handles frames up to 10236 bytes and implements .ndo_change_mtu() so accept 10236 minus the ethernet header for a VLAN tagged frame on the netdevices. Use ETH_MIN_MTU as minimum MTU. Signed-off-by: Linus Walleij --- ChangeLog v2->v3: - No changes, just resending with the

[PATCH net-next 2/5 v3] net: gemini: Improve connection prints

2018-07-11 Thread Linus Walleij
Switch over to using a module parameter and debug prints that can be controlled by this or ethtool like everyone else. Depromote all other prints to debug messages. The phy_print_status() was already in place, albeit never really used because the debuglevel hiding it had to be set up using

[PATCH net-next 3/5 v3] net: gemini: Allow multiple ports to instantiate

2018-07-11 Thread Linus Walleij
The code was not tested with two ports actually in use at the same time. (I blame this on lack of actual hardware using that feature.) Now after locating a system using both ports, add necessary fix to make both ports come up. Signed-off-by: Linus Walleij --- ChangeLog v2->v3: - No changes, just

[PATCH net-next 1/5 v3] net: gemini: Look up L3 maxlen from table

2018-07-11 Thread Linus Walleij
The code to calculate the hardware register enumerator for the maximum L3 length isn't entirely simple to read. Use the existing defines and rewrite the function into a table look-up. Acked-by: Michał Mirosław Signed-off-by: Linus Walleij --- ChangeLog v2->v3: - Collected Michał's ACK.

Re: [PATCH v3 net-next] net/sched: add skbprio scheduler

2018-07-11 Thread Marcelo Ricardo Leitner
On Tue, Jul 10, 2018 at 07:25:53PM -0700, Cong Wang wrote: > On Mon, Jul 9, 2018 at 2:40 PM Marcelo Ricardo Leitner > wrote: > > > > On Mon, Jul 09, 2018 at 05:03:31PM -0400, Michel Machado wrote: > > >Changing TC_PRIO_MAX from 15 to 63 risks breaking backward > > > compatibility > > > with

Re: [PATCH net-next 5/5 v2] net: gemini: Indicate that we can handle jumboframes

2018-07-11 Thread Linus Walleij
On Wed, Jul 4, 2018 at 10:35 PM Andrew Lunn wrote: > > On Wed, Jul 04, 2018 at 08:33:24PM +0200, Linus Walleij wrote: > > The hardware supposedly handles frames up to 10236 bytes and > > implements .ndo_change_mtu() so accept 10236 minus the ethernet > > header for a VLAN tagged frame on the

Re: [net-next PATCH] net: ipv4: fix listify ip_rcv_finish in case of forwarding

2018-07-11 Thread Saeed Mahameed
On Wed, 2018-07-11 at 17:01 +0200, Jesper Dangaard Brouer wrote: > Only driver sfc actually uses this, but I don't have this NIC, so I > tested this on mlx5, with my own changes to make it use > netif_receive_skb_list(), > but I'm not ready to upstream the mlx5 driver change yet. Thanks Jesper

Re: [PATCH net-next v2 04/11] devlink: Add support for region get command

2018-07-11 Thread Jakub Kicinski
On Wed, 11 Jul 2018 13:43:01 +0300, Alex Vesker wrote: > + DEVLINK_ATTR_REGION_SIZE, /* u32 */ > + err = nla_put_u64_64bit(msg, DEVLINK_ATTR_REGION_SIZE, > + region->size, > + DEVLINK_ATTR_PAD); Size in the comment

Re: [PATCH v3 net-next] net/sched: add skbprio scheduler

2018-07-11 Thread Marcelo Ricardo Leitner
On Tue, Jul 10, 2018 at 07:32:43PM -0700, Cong Wang wrote: > On Mon, Jul 9, 2018 at 12:53 PM Marcelo Ricardo Leitner > wrote: > > > > On Mon, Jul 09, 2018 at 02:18:33PM -0400, Michel Machado wrote: > > > > > >2. sch_prio.c does not have a global limit on the number of packets on > > > all its

[PATCH] of: mdio: Support fixed links in of_phy_get_and_connect()

2018-07-11 Thread Linus Walleij
By a simple extension of of_phy_get_and_connect() drivers that have a fixed link on e.g. RGMII can support also fixed links, so in addition to: ethernet-port { phy-mode = "rgmii"; phy-handle = <>; }; This setup with a fixed-link node and no phy-handle will now also work just

[PATCH net v2] KEYS: DNS: fix parsing multiple options

2018-07-11 Thread Eric Biggers
From: Eric Biggers My recent fix for dns_resolver_preparse() printing very long strings was incomplete, as shown by syzbot which still managed to hit the WARN_ONCE() in set_precision() by adding a crafted "dns_resolver" key: precision 50001 too large WARNING: CPU: 7 PID: 864 at

[PATCH net] nsh: set mac len based on inner packet

2018-07-11 Thread Willem de Bruijn
From: Willem de Bruijn When pulling the NSH header in nsh_gso_segment, set the mac length based on the encapsulated packet type. skb_reset_mac_len computes an offset to the network header, which here still points to the outer packet: > skb_reset_network_header(skb); > [...] >

[PATCH net] packet: reset network header if packet shorter than ll reserved space

2018-07-11 Thread Willem de Bruijn
From: Willem de Bruijn If variable length link layer headers result in a packet shorter than dev->hard_header_len, reset the network header offset. Else skb->mac_len may exceed skb->len after skb_mac_reset_len. packet_sendmsg_spkt already has similar logic. Fixes: b84bbaf7a6c8 ("packet: in

[PATCH net] selftests: in udpgso_bench do not test udp zerocopy

2018-07-11 Thread Willem de Bruijn
From: Willem de Bruijn The udpgso benchmark compares various configurations of UDP and TCP. Including one that is not upstream, udp zerocopy. This is a leftover from the earlier RFC patchset. The test is part of kselftests and run in continuous spinners. Remove the failing case to make the test

[PATCH net-next 08/10] s390/qeth: add a L3 xmit wrapper

2018-07-11 Thread Julian Wiedmann
In preparation for future work, move the high-level xmit work into a separate wrapper. This matches the L2 xmit code. Signed-off-by: Julian Wiedmann --- drivers/s390/net/qeth_l3_main.c | 122 +--- 1 file changed, 65 insertions(+), 57 deletions(-) diff --git

[PATCH net-next 05/10] s390/qeth: consolidate ccwgroup driver definition

2018-07-11 Thread Julian Wiedmann
Reshuffle the code a bit so that everything is in one place. Signed-off-by: Julian Wiedmann --- drivers/s390/net/qeth_core_main.c | 42 +++ 1 file changed, 21 insertions(+), 21 deletions(-) diff --git a/drivers/s390/net/qeth_core_main.c

[PATCH net-next 03/10] s390/qeth: fine-tune RX modesetting

2018-07-11 Thread Julian Wiedmann
Changing a device's address lists (or its promisc mode) already triggers an RX modeset, there's no need to do it manually from the L2 driver's ndo_vlan_rx_kill_vid() hook. Also when setting a device online, dev_open() already calls dev_set_rx_mode(). So a manual modeset is only necessary from the

[PATCH net-next 00/10] s390/qeth: updates 2018-07-11

2018-07-11 Thread Julian Wiedmann
Hi Dave, please apply this first batch of qeth patches for net-next. It brings the usual cleanups, and some performance improvements to the transmit paths. Thanks, Julian Julian Wiedmann (10): s390/qeth: various buffer management cleanups s390/qeth: remove unused buffer->aob pointer

[PATCH net-next 10/10] s390/qeth: speed-up IPv4 OSA xmit

2018-07-11 Thread Julian Wiedmann
Move the xmit of offload-eligible (ie IPv4) traffic on OSA over to the new, copy-free path. As with L2, we'll need to preserve the skb_orphan() behaviour of the old code path until TX completion is sufficiently fast. Signed-off-by: Julian Wiedmann --- drivers/s390/net/qeth_l3_main.c | 33

  1   2   >