RE: [PATCH 3/3] powerpc: bpf: implement in-register swap for 64-bit endian operations

2017-01-13 Thread David Laight
From: Naveen N. Rao > Sent: 13 January 2017 17:10 > Generate instructions to perform the endian conversion using registers, > rather than generating two memory accesses. > > The "way easier and faster" comment was obviously for the author, not > the processor. That rather depends on whether the

[PATCH] net: constify mdiobb_ops structures

2017-01-13 Thread Bhumika Goyal
Declare mdiobb_ops structures as const as they are only stored in the ops field of mdiobb_ctrl structures. This field is of type const, so mdiobb_ops structures having this property can be declared const too. Done using Coccinelle: @r disable optional_qualifier@ identifier x; position p; @@

Re: [Patch net] atm: remove an unnecessary loop

2017-01-13 Thread Cong Wang
On Fri, Jan 13, 2017 at 5:23 AM, Francois Romieu wrote: > Cong Wang : > [...] >> alloc_skb(GFP_KERNEL) itself is sleeping, so the new wait api is still >> needed. > > The task state change warning is the symptom. > > The deeply nested alloc_skb is

Re: [Patch net] atm: remove an unnecessary loop

2017-01-13 Thread Cong Wang
On Fri, Jan 13, 2017 at 9:10 AM, David Miller wrote: > From: Francois Romieu > Date: Fri, 13 Jan 2017 01:07:00 +0100 > >> Were alloc_skb moved one level up in the call stack, there would be >> no need to use the new wait api in the subsequent page, thus

Re: [PATCH] flow disector: check if arp_eth is null rather than arp

2017-01-13 Thread Eric Dumazet
On Fri, 2017-01-13 at 18:25 +, Colin Ian King wrote: > On 13/01/17 18:24, Eric Dumazet wrote: > > It looks that we try very hard to add critical bugs in flow dissector. > > > > This is embarrassing really. > > > > I am questioning if the __skb_header_pointer() is correct > > > > Why using

Re: [net PATCH 5/5] virtio_net: XDP support for adjust_head

2017-01-13 Thread John Fastabend
On 17-01-13 09:23 AM, Michael S. Tsirkin wrote: > On Thu, Jan 12, 2017 at 01:45:19PM -0800, John Fastabend wrote: >> Add support for XDP adjust head by allocating a 256B header region >> that XDP programs can grow into. This is only enabled when a XDP >> program is loaded. >> >> In order to ensure

Re: [pull request][for-next] Mellanox mlx5 Reorganize core driver directory layout

2017-01-13 Thread Leon Romanovsky
On Fri, Jan 13, 2017 at 12:14:07PM -0500, David Miller wrote: > From: Saeed Mahameed > Date: Thu, 12 Jan 2017 19:22:34 +0200 > > > This pull request includes one patch from Leon, this patch as described > > below will change the driver directory structure and layout for

Re: [PATCH net-next] sctp: remove dead code from sctp_apply_peer_addr_params

2017-01-13 Thread Marcelo Ricardo Leitner
On Fri, Jan 13, 2017 at 06:27:32PM -0200, Marcelo Ricardo Leitner wrote: > sctp_frag_point() doesn't store anything, and thus just calling it > cannot do anything useful. Please ignore this one. Will post another one with s/dead code/useless code/ , as the code not really dead.. > >

[PATCH net-next 0/2] sfc: TX PIO fixes

2017-01-13 Thread Edward Cree
Edward Cree (2): sfc: allow PIO more often sfc: get PIO buffer size from the NIC drivers/net/ethernet/sfc/ef10.c | 21 +++-- drivers/net/ethernet/sfc/net_driver.h | 9 + drivers/net/ethernet/sfc/nic.h| 19 ---

Re: [pull request][for-next] Mellanox mlx5 Reorganize core driver directory layout

2017-01-13 Thread Saeed Mahameed
On Fri, Jan 13, 2017 at 7:14 PM, David Miller wrote: > From: Saeed Mahameed > Date: Thu, 12 Jan 2017 19:22:34 +0200 > >> This pull request includes one patch from Leon, this patch as described >> below will change the driver directory structure and

[PATCHv3 net-next 7/7] sctp: implement sender-side procedures for SSN Reset Request Parameter

2017-01-13 Thread Xin Long
This patch is to implement sender-side procedures for the Outgoing and Incoming SSN Reset Request Parameter described in rfc6525 section 5.1.2 and 5.1.3. It is also add sockopt SCTP_RESET_STREAMS in rfc6525 section 6.3.2 for users. Note that the new asoc member strreset_outstanding is to make

Re: [PATCH 2/3] powerpc: bpf: flush the entire JIT buffer

2017-01-13 Thread Alexei Starovoitov
On Fri, Jan 13, 2017 at 10:40:01PM +0530, Naveen N. Rao wrote: > With bpf_jit_binary_alloc(), we allocate at a page granularity and fill > the rest of the space with illegal instructions to mitigate BPF spraying > attacks, while having the actual JIT'ed BPF program at a random location > within

[PATCH net-next] sctp: remove useless code from sctp_apply_peer_addr_params

2017-01-13 Thread Marcelo Ricardo Leitner
sctp_frag_point() doesn't store anything, and thus just calling it cannot do anything useful. sctp_apply_peer_addr_params is only called by sctp_setsockopt_peer_addr_params. When operating on an asoc, sctp_setsockopt_peer_addr_params will call sctp_apply_peer_addr_params once for the asoc, and

Re: Commit 1fe8e0... (include more headers in if_tunnel.h) breaks my user-space build.

2017-01-13 Thread Stephen Hemminger
On Fri, 13 Jan 2017 11:12:32 -0800 Ben Greear wrote: > I am including netinet/ip.h, and also linux/if_tunnel.h, and the linux/ip.h > conflicts with > netinet/ip.h. > > Maybe my build environment is screwed up, but maybe also it would be better to > just let the user

[PATCH net-next] sctp: remove unused var from sctp_process_asconf

2017-01-13 Thread Marcelo Ricardo Leitner
Assigned but not used. Signed-off-by: Marcelo Ricardo Leitner --- net/sctp/sm_make_chunk.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/net/sctp/sm_make_chunk.c b/net/sctp/sm_make_chunk.c index

[PATCH net-next] sctp: remove dead code from sctp_apply_peer_addr_params

2017-01-13 Thread Marcelo Ricardo Leitner
sctp_frag_point() doesn't store anything, and thus just calling it cannot do anything useful. sctp_apply_peer_addr_params is only called by sctp_setsockopt_peer_addr_params. When operating on an asoc, sctp_setsockopt_peer_addr_params will call sctp_apply_peer_addr_params once for the asoc, and

[PATCH net 3/3] be2net: fix MAC addr setting on privileged BE3 VFs

2017-01-13 Thread Ivan Vecera
During interface opening MAC address stored in netdev->dev_addr is programmed in the HW with exception of BE3 VFs where the initial MAC is programmed by parent PF. This is OK when MAC address is not changed when an interfaces is down. In this case the requested MAC is stored to netdev->dev_addr

Re: [pull request][for-next] Mellanox mlx5 Reorganize core driver directory layout

2017-01-13 Thread Tom Herbert
On Fri, Jan 13, 2017 at 12:29 PM, Leon Romanovsky wrote: > On Fri, Jan 13, 2017 at 12:14:07PM -0500, David Miller wrote: >> From: Saeed Mahameed >> Date: Thu, 12 Jan 2017 19:22:34 +0200 >> >> > This pull request includes one patch from Leon, this patch as

Commit 1fe8e0... (include more headers in if_tunnel.h) breaks my user-space build.

2017-01-13 Thread Ben Greear
I am including netinet/ip.h, and also linux/if_tunnel.h, and the linux/ip.h conflicts with netinet/ip.h. Maybe my build environment is screwed up, but maybe also it would be better to just let the user include appropriate headers before including if_tunnel.h and revert this patch?

Re: Commit 1fe8e0... (include more headers in if_tunnel.h) breaks my user-space build.

2017-01-13 Thread Ben Greear
On 01/13/2017 11:12 AM, Ben Greear wrote: I am including netinet/ip.h, and also linux/if_tunnel.h, and the linux/ip.h conflicts with netinet/ip.h. Maybe my build environment is screwed up, but maybe also it would be better to just let the user include appropriate headers before including

Re: [net PATCH v3 3/5] virtio_net: factor out xdp handler for readability

2017-01-13 Thread John Fastabend
On 17-01-12 11:40 PM, Jason Wang wrote: > > > On 2017年01月13日 10:51, John Fastabend wrote: >> At this point the do_xdp_prog is mostly if/else branches handling >> the different modes of virtio_net. So remove it and handle running >> the program in the per mode handlers. >> >> Signed-off-by: John

Re: [PATCH 1/3] powerpc: bpf: remove redundant check for non-null image

2017-01-13 Thread Alexei Starovoitov
On Fri, Jan 13, 2017 at 10:40:00PM +0530, Naveen N. Rao wrote: > From: Daniel Borkmann > > We have a check earlier to ensure we don't proceed if image is NULL. As > such, the redundant check can be removed. > > Signed-off-by: Daniel Borkmann > [Added

[PATCH net-next 2/2] sfc: get PIO buffer size from the NIC

2017-01-13 Thread Edward Cree
The 8000 series SFC NICs have 4K PIO buffers, rather than the 2K of the 7000 series. Rather than having a hard-coded PIO buffer size (ER_DZ_TX_PIOBUF_SIZE), read it from the GET_CAPABILITIES_V2 MCDI response. Signed-off-by: Edward Cree ---

[PATCH net-next 1/2] sfc: allow PIO more often

2017-01-13 Thread Edward Cree
If an option descriptor has been sent on a queue but not followed by a packet, there will have been no completion event, so the read and write counts won't match and we'll think we can't do PIO. This combines with the fact that we have two TX queues (for en/disable checksum offload), and that

Re: kill off pci_enable_msi_{exact,range}

2017-01-13 Thread Tom Lendacky
On 1/13/2017 11:15 AM, Christoph Hellwig wrote: > On Fri, Jan 13, 2017 at 11:13:21AM -0600, Bjorn Helgaas wrote: >> I dropped the empty commit and replaced the xgbe patch with the one below. >> Can you take a look at [1] and make sure it's what you expected? > > This looks great, thanks! >

[PATCH net 1/3] be2net: fix status check in be_cmd_pmac_add()

2017-01-13 Thread Ivan Vecera
Return value from be_mcc_notify_wait() contains a base completion status together with an additional status. The base_status() macro need to be used to access base status. Fixes: e3a7ae2 be2net: Changing MAC Address of a VF was broken Cc: Sathya Perla Cc: Ajit Khaparde

[PATCH net 2/3] be2net: don't delete MAC on close on unprivileged BE3 VFs

2017-01-13 Thread Ivan Vecera
BE3 VFs without FILTMGMT privilege are not allowed to modify its MAC, VLAN table and UC/MC lists. So don't try to delete MAC on such VFs. Cc: Sathya Perla Cc: Ajit Khaparde Cc: Sriharsha Basavapatna Cc:

Re: [net PATCH v3 5/5] virtio_net: XDP support for adjust_head

2017-01-13 Thread John Fastabend
On 17-01-12 11:41 PM, Jason Wang wrote: > > > On 2017年01月13日 10:52, John Fastabend wrote: >> Add support for XDP adjust head by allocating a 256B header region >> that XDP programs can grow into. This is only enabled when a XDP >> program is loaded. >> >> In order to ensure that we do not have

Re: Commit 1fe8e0... (include more headers in if_tunnel.h) breaks my user-space build.

2017-01-13 Thread Stephen Hemminger
On Fri, 13 Jan 2017 11:50:32 -0800 Ben Greear wrote: > On 01/13/2017 11:41 AM, Stephen Hemminger wrote: > > On Fri, 13 Jan 2017 11:12:32 -0800 > > Ben Greear wrote: > > > >> I am including netinet/ip.h, and also linux/if_tunnel.h, and the >

Re: Commit 1fe8e0... (include more headers in if_tunnel.h) breaks my user-space build.

2017-01-13 Thread Ben Greear
On 01/13/2017 11:41 AM, Stephen Hemminger wrote: On Fri, 13 Jan 2017 11:12:32 -0800 Ben Greear wrote: I am including netinet/ip.h, and also linux/if_tunnel.h, and the linux/ip.h conflicts with netinet/ip.h. Maybe my build environment is screwed up, but maybe also it

ANNOUNCE: Netdev 2.1 in Montreal

2017-01-13 Thread Jamal Hadi Salim
Folks, We are pleased to announce Netdev 2.1 (year 2, conference 1) in the beautiful city of Montreal, Canada on the 6th to 8th of April. The website is now online: http://www.netdevconf.org/2.1/ Netdev 2.1 will be held back to back with netconf2017.1 (http://vger.kernel.org/netconf2017.html)

[PATCH net-next] netlink: do not enter direct reclaim from netlink_trim()

2017-01-13 Thread Eric Dumazet
From: Eric Dumazet In commit d35c99ff77ecb ("netlink: do not enter direct reclaim from netlink_dump()") we made sure to not trigger expensive memory reclaim. Problem is that a bit later, netlink_trim() might be called and trigger memory reclaim. netlink_trim() should be

Re: [PATCH net] net: systemport: Decouple flow control from __bcm_sysport_tx_reclaim

2017-01-13 Thread David Miller
From: Florian Fainelli Date: Thu, 12 Jan 2017 12:09:09 -0800 > The __bcm_sysport_tx_reclaim() function is used to reclaim transmit > resources in different places within the driver. Most of them should > not affect the state of the transit flow control. > > Introduce

Re: [PATCH net v3] ipv6: sr: fix several BUGs when preemption is enabled

2017-01-13 Thread David Miller
From: David Lebrun Date: Thu, 12 Jan 2017 21:30:01 +0100 > When CONFIG_PREEMPT=y, CONFIG_IPV6=m and CONFIG_SEG6_HMAC=y, > seg6_hmac_init() is called during the initialization of the ipv6 module. > This causes a subsequent call to smp_processor_id() with preemption >

Re: [RFC PATCH] tcp: accept RST for rcv_nxt - 1 after receiving a FIN

2017-01-13 Thread Eric Dumazet
On Fri, 2017-01-13 at 12:28 -0500, Jason Baron wrote: > i, > > (Re-sending - seems like my reply was lost) > > I wanted to define this condition as narrowly as I could. I'm ok > dropping it - > I'm not sure its going to make much difference in practice. So to that end, > dropping this extra

[PATCH][V2] flow dissector: check if arp_eth is null rather than arp

2017-01-13 Thread Colin King
From: Colin Ian King arp is being checked instead of arp_eth to see if the call to __skb_header_pointer failed. Fix this by checking arp_eth is null instead of arp. Also fix to use length hlen rather than hlen - sizeof(_arp); thanks to Eric Dumazet for spotting this

Re: [PATCH v2 0/2] bpf: add longest prefix match map

2017-01-13 Thread David Miller
From: Daniel Mack Date: Thu, 12 Jan 2017 18:29:20 +0100 > Feedback is much appreciated. Daniel and Alexei, can I get a review please?

Re: resend: tcp: performance issue with fastopen connections (mss > window)

2017-01-13 Thread Eric Dumazet
On Fri, Jan 13, 2017 at 9:07 AM, Alexey Kodanev wrote: > Hi Eric, > On 13.01.2017 18:35, Eric Dumazet wrote: >> Care to send a packetdrill test so that we have a clear picture of what >> is going on ? > > Is it capable of making two connections in the single test, one

Re: [net PATCH v3 2/5] net: virtio: wrap rtnl_lock in test for calling with lock already held

2017-01-13 Thread John Fastabend
On 17-01-13 08:34 AM, Stephen Hemminger wrote: > On Thu, 12 Jan 2017 18:51:00 -0800 > John Fastabend wrote: > >> >> -static void free_receive_bufs(struct virtnet_info *vi) >> +static void free_receive_bufs(struct virtnet_info *vi, bool need_lock) >> { >> struct

Re: [PATCH v2] tcp: fix tcp_fastopen unaligned access complaints on sparc

2017-01-13 Thread David Miller
From: Shannon Nelson Date: Thu, 12 Jan 2017 14:24:58 -0800 > Fix up a data alignment issue on sparc by swapping the order > of the cookie byte array field with the length field in > struct tcp_fastopen_cookie, and making it a proper union > to clean up the typecasting.

Re: [PATCH net-next] mii_bus: increase MII_BUS_ID_SIZE to 61

2017-01-13 Thread Florian Fainelli
On 01/13/2017 08:31 AM, Andrew Lunn wrote: > On Fri, Jan 13, 2017 at 04:19:12PM +0100, Volodymyr Bendiuga wrote: >> From: Volodymyr Bendiuga >> >> Some bus names are pretty long and do not fit into 20 chars. >> >> Signed-off-by: Volodymyr Bendiuga

Re: resend: tcp: performance issue with fastopen connections (mss > window)

2017-01-13 Thread Alexey Kodanev
Hi Eric, On 13.01.2017 18:35, Eric Dumazet wrote: > On Fri, 2017-01-13 at 18:01 +0300, Alexey Kodanev wrote: >> Hi, >> >> Got the issue when running LTP/netstress test on localhost with mss >> greater than the send window advertised by client (right after 3WHS). >> Here is the testscenario that

Re: [PATCH v3 1/8] arm: put types.h in uapi

2017-01-13 Thread Russell King - ARM Linux
On Fri, Jan 13, 2017 at 11:46:39AM +0100, Nicolas Dichtel wrote: > This header file is exported, thus move it to uapi. I'm taking this patch, but with the following commit log: Due to the way kbuild works, this header was unintentionally exported back in 2013 when it was created, despite it

Re: [RFC PATCH] tcp: accept RST for rcv_nxt - 1 after receiving a FIN

2017-01-13 Thread Jason Baron
On 01/11/2017 10:48 AM, Eric Dumazet wrote: > On Thu, 2017-01-05 at 16:33 -0500, Jason Baron wrote: > >> >> +/* Accept RST for rcv_nxt - 1 after a FIN. >> + * When tcp connections are abruptly terminated from Mac OSX (via ^C), a >> + * FIN is sent followed by a RST packet. The RST is sent with

Re: [PATCH][V2] flow dissector: check if arp_eth is null rather than arp

2017-01-13 Thread Eric Dumazet
On Fri, 2017-01-13 at 18:48 +, Colin King wrote: > From: Colin Ian King > > arp is being checked instead of arp_eth to see if the call to > __skb_header_pointer failed. Fix this by checking arp_eth is > null instead of arp. Also fix to use length hlen rather than

[PATCHv3 net-next 4/7] sctp: add stream reconf primitive

2017-01-13 Thread Xin Long
This patch is to add a primitive based on sctp primitive frame for sending stream reconf request. It works as the other primitives, and create a SCTP_CMD_REPLY command to send the request chunk out. sctp_primitive_RECONF would be the api to send a reconf request chunk. Signed-off-by: Xin Long

[PATCHv3 net-next 5/7] sctp: add reconf_enable in asoc ep and netns

2017-01-13 Thread Xin Long
This patch is to add reconf_enable field in all of asoc ep and netns to indicate if they support stream reset. When initializing, asoc reconf_enable get the default value from ep reconf_enable which is from netns netns reconf_enable by default. It is also to add reconf_capable in asoc peer part

[PATCHv3 net-next 3/7] sctp: add stream reconf timer

2017-01-13 Thread Xin Long
This patch is to add a per transport timer based on sctp timer frame for stream reconf chunk retransmission. It would start after sending a reconf request chunk, and stop after receiving the response chunk. If the timer expires, besides retransmitting the reconf request chunk, it would also do

[PATCHv3 net-next 2/7] sctp: add support for generating stream reconf ssn reset request chunk

2017-01-13 Thread Xin Long
This patch is to add asoc strreset_outseq and strreset_inseq for saving the reconf request sequence, initialize them when create assoc and process init, and also to define Incoming and Outgoing SSN Reset Request Parameter described in rfc6525 section 4.1 and 4.2, As they can be in one same chunk

[PATCHv3 net-next 1/7] sctp: add a common helper function to generate stream reconf chunk

2017-01-13 Thread Xin Long
This patch is to define a common api used to alloc memory and initialize reconf chunk header that described in rfc6525 section 3.1. All reconf chunks will be generated by calling this helper function. Signed-off-by: Xin Long --- include/linux/sctp.h | 6 ++

Re: kill off pci_enable_msi_{exact,range}

2017-01-13 Thread Bjorn Helgaas
On Fri, Jan 13, 2017 at 09:05:53AM +0100, Christoph Hellwig wrote: > On Fri, Jan 13, 2017 at 08:55:03AM +0100, Christoph Hellwig wrote: > > On Thu, Jan 12, 2017 at 03:29:00PM -0600, Bjorn Helgaas wrote: > > > Applied all three (with Tom's ack on the amd-xgbe patch) to pci/msi for > > > v4.11,

Re: [PATCH net-next] netlink: do not enter direct reclaim from netlink_trim()

2017-01-13 Thread Alexei Starovoitov
On Fri, Jan 13, 2017 at 09:11:22AM -0800, Eric Dumazet wrote: > From: Eric Dumazet > > In commit d35c99ff77ecb ("netlink: do not enter direct reclaim from > netlink_dump()") we made sure to not trigger expensive memory reclaim. > > Problem is that a bit later,

Re: resend: tcp: performance issue with fastopen connections (mss > window)

2017-01-13 Thread Eric Dumazet
On Fri, 2017-01-13 at 12:32 -0500, Neal Cardwell wrote: > On Fri, Jan 13, 2017 at 12:14 PM, Eric Dumazet wrote: > > > > On Fri, Jan 13, 2017 at 9:07 AM, Alexey Kodanev > > wrote: > > > Hi Eric, > > > On 13.01.2017 18:35, Eric Dumazet wrote: > > > >

Re: [PATCH] flow disector: check if arp_eth is null rather than arp

2017-01-13 Thread Eric Dumazet
On Fri, 2017-01-13 at 13:34 +, Colin King wrote: > From: Colin Ian King > > arp is being checked instead of arp_eth to see if the call to > __skb_header_pointer failed. Fix this by checking arp_eth is > null instead of arp. > > CoverityScan CID#1396428 ("Logically

[PATCHv3 net-next 0/7] sctp: add sender-side procedures for stream reconf ssn reset request chunk

2017-01-13 Thread Xin Long
Patch 7/7 is to implement sender-side procedures for the Outgoing and Incoming SSN Reset Request Parameter described in rfc6525 section 5.1.2 and 5.1.3 Patches 1-6/7 are ahead of it to define some apis and asoc members for it. Note that with this patchset, asoc->reconf_enable has no chance yet

Re: [net PATCH 5/5] virtio_net: XDP support for adjust_head

2017-01-13 Thread Michael S. Tsirkin
On Thu, Jan 12, 2017 at 01:45:19PM -0800, John Fastabend wrote: > Add support for XDP adjust head by allocating a 256B header region > that XDP programs can grow into. This is only enabled when a XDP > program is loaded. > > In order to ensure that we do not have to unwind queue headroom push >

Re: [PATCH v2 1/2] bpf: add a longest prefix match trie map implementation

2017-01-13 Thread Alexei Starovoitov
On Thu, Jan 12, 2017 at 06:29:21PM +0100, Daniel Mack wrote: > This trie implements a longest prefix match algorithm that can be used > to match IP addresses to a stored set of ranges. > > Internally, data is stored in an unbalanced trie of nodes that has a > maximum height of n, where n is the

[PATCH net-next 2/2] mpls: Packet stats

2017-01-13 Thread Robert Shearman
Having MPLS packet stats is useful for observing network operation and for diagnosing network problems. In the absence of anything better, RFC2863 and RFC3813 are used for guidance for which stats to expose and the semantics of them. In particular rx_noroutes maps to in unknown protos in RFC2863.

[PATCH net-next 1/2] net: AF-specific RTM_GETSTATS attributes

2017-01-13 Thread Robert Shearman
Add the functionality for including address-family-specific per-link stats in RTM_GETSTATS messages. This is done through adding a new IFLA_STATS_AF_SPEC attribute under which address family attributes are nested and then the AF-specific attributes can be further nested. This follows the model of

[PATCH net-next 0/2] mpls: Packet stats

2017-01-13 Thread Robert Shearman
This patchset records per-interface packet stats in the MPLS forwarding path and exports them using a nest of attributes root at a new IFLA_STATS_AF_SPEC attribute as part of RTM_GETSTATS messages: [IFLA_STATS_AF_SPEC] -> [AF_MPLS] -> [MPLS_STATS_LINK] -> struct mpls_link_stats The first

Re: kill off pci_enable_msi_{exact,range}

2017-01-13 Thread Christoph Hellwig
On Fri, Jan 13, 2017 at 11:13:21AM -0600, Bjorn Helgaas wrote: > I dropped the empty commit and replaced the xgbe patch with the one below. > Can you take a look at [1] and make sure it's what you expected? This looks great, thanks!

Re: [Patch net] atm: remove an unnecessary loop

2017-01-13 Thread David Miller
From: Francois Romieu Date: Fri, 13 Jan 2017 01:07:00 +0100 > Were alloc_skb moved one level up in the call stack, there would be > no need to use the new wait api in the subsequent page, thus easing > pre 3.19 longterm kernel maintenance (at least those on korg page). > >

[PATCH 3/3] powerpc: bpf: implement in-register swap for 64-bit endian operations

2017-01-13 Thread Naveen N. Rao
Generate instructions to perform the endian conversion using registers, rather than generating two memory accesses. The "way easier and faster" comment was obviously for the author, not the processor. Signed-off-by: Naveen N. Rao ---

[PATCH 2/3] powerpc: bpf: flush the entire JIT buffer

2017-01-13 Thread Naveen N. Rao
With bpf_jit_binary_alloc(), we allocate at a page granularity and fill the rest of the space with illegal instructions to mitigate BPF spraying attacks, while having the actual JIT'ed BPF program at a random location within the allocated space. Under this scenario, it would be better to flush the

Re: Setting link down or up in software

2017-01-13 Thread Mason
On 13/01/2017 17:28, Zefir Kurtisi wrote: > As for your specific problem: since I fought myself with the PHY/ETH > subsystems > over the past months, I might remember something relevant to your issue. > Could you > give some more info on your setup (PHY driver, opmode (SGMII, RGMII, etc.), >

[PATCH 1/3] powerpc: bpf: remove redundant check for non-null image

2017-01-13 Thread Naveen N. Rao
From: Daniel Borkmann We have a check earlier to ensure we don't proceed if image is NULL. As such, the redundant check can be removed. Signed-off-by: Daniel Borkmann [Added similar changes for classic BPF JIT] Signed-off-by: Naveen N. Rao

Re: [pull request][for-next] Mellanox mlx5 Reorganize core driver directory layout

2017-01-13 Thread David Miller
From: Saeed Mahameed Date: Thu, 12 Jan 2017 19:22:34 +0200 > This pull request includes one patch from Leon, this patch as described > below will change the driver directory structure and layout for better, > logical and modular driver files separation. > > This change is

Re: resend: tcp: performance issue with fastopen connections (mss > window)

2017-01-13 Thread Neal Cardwell
On Fri, Jan 13, 2017 at 12:14 PM, Eric Dumazet wrote: > > On Fri, Jan 13, 2017 at 9:07 AM, Alexey Kodanev > wrote: > > Hi Eric, > > On 13.01.2017 18:35, Eric Dumazet wrote: > > >> Care to send a packetdrill test so that we have a clear picture of

Re: [PATCH 3/3] powerpc: bpf: implement in-register swap for 64-bit endian operations

2017-01-13 Thread 'Naveen N. Rao'
On 2017/01/13 05:17PM, David Laight wrote: > From: Naveen N. Rao > > Sent: 13 January 2017 17:10 > > Generate instructions to perform the endian conversion using registers, > > rather than generating two memory accesses. > > > > The "way easier and faster" comment was obviously for the author,

Re: [PATCH] flow disector: check if arp_eth is null rather than arp

2017-01-13 Thread Colin Ian King
On 13/01/17 18:24, Eric Dumazet wrote: > On Fri, 2017-01-13 at 13:34 +, Colin King wrote: >> From: Colin Ian King >> >> arp is being checked instead of arp_eth to see if the call to >> __skb_header_pointer failed. Fix this by checking arp_eth is >> null instead of

[PATCHv3 net-next 6/7] sctp: add sockopt SCTP_ENABLE_STREAM_RESET

2017-01-13 Thread Xin Long
This patch is to add sockopt SCTP_ENABLE_STREAM_RESET to get/set strreset_enable to indicate which reconf request type it supports, which is described in rfc6525 section 6.3.1. Signed-off-by: Xin Long --- include/net/sctp/structs.h | 4 +++ include/uapi/linux/sctp.h | 7

[PATCH net] bpf: rework prog_digest into prog_tag

2017-01-13 Thread Daniel Borkmann
Commit 7bd509e311f4 ("bpf: add prog_digest and expose it via fdinfo/netlink") was recently discussed, partially due to admittedly suboptimal name of "prog_digest" in combination with sha1 hash usage, thus inevitably and rightfully concerns about its security in terms of collision resistance were

Re: [PATCH net-next v2 08/10] net: dsa: Add support for platform data

2017-01-13 Thread Florian Fainelli
On 01/13/2017 06:04 AM, Andrew Lunn wrote: >> index cd91070b5467..d326fc4afad7 100644 >> --- a/net/dsa/dsa2.c >> +++ b/net/dsa/dsa2.c >> @@ -81,17 +81,23 @@ static void dsa_dst_del_ds(struct dsa_switch_tree *dst, >> >> static bool dsa_port_is_valid(struct dsa_port *port) >> { >> -return

Re: [PATCH net-next 2/2] mpls: Packet stats

2017-01-13 Thread Roopa Prabhu
On 1/13/17, 10:14 AM, Robert Shearman wrote: > Having MPLS packet stats is useful for observing network operation and > for diagnosing network problems. In the absence of anything better, > RFC2863 and RFC3813 are used for guidance for which stats to expose > and the semantics of them. In

Re: [pull request][for-next] Mellanox mlx5 Reorganize core driver directory layout

2017-01-13 Thread Rick Jones
On 01/13/2017 02:56 PM, Tom Herbert wrote: On Fri, Jan 13, 2017 at 2:45 PM, Saeed Mahameed what configuration are you running ? what traffic ? Nothing fancy. 8 queues and 20 concurrent netperf TCP_STREAMs trips it. Not a lot of them, but I don't think we really should ever see these errors.

Re: [PATCH v2 7/8] net: Rename TCA*BPF_DIGEST to ..._SHA256

2017-01-13 Thread Daniel Borkmann
On 01/11/2017 07:19 PM, Andy Lutomirski wrote: On Wed, Jan 11, 2017 at 1:09 AM, Daniel Borkmann wrote: [...] Ok. Sleeping over this a bit, how about a general rename into "prog_tag" for fdinfo and TCA_BPF_TAG resp. TCA_ACT_BPF_TAG for the netlink attributes, fwiw, it

Re: [Patch net] atm: remove an unnecessary loop

2017-01-13 Thread Francois Romieu
Cong Wang : [...] > If you can justify API is not broken by doing that, I am more than happy > to do it, as I already stated in the latter patch: > > "Of course, the logic itself is suspicious, other sendmsg() > could handle skb allocation failure very well, not sure >

Re: [PATCH v2 net-next] Introduce a sysctl that modifies the value of PROT_SOCK.

2017-01-13 Thread Krister Johansen
On Thu, Jan 12, 2017 at 09:22:13AM -0500, David Miller wrote: > From: Krister Johansen > > The use case for this change is to allow containerized processes to bind > > to priviliged ports, but prevent them from ever being allowed to modify > > their container's network

Re: [PATCH] i40e: Invoke softirqs after napi_reschedule

2017-01-13 Thread David Miller
From: Benjamin Poirier Date: Thu, 12 Jan 2017 17:04:14 -0800 > The following message is logged from time to time when using i40e: > NOHZ: local_softirq_pending 08 > > i40e may schedule napi from a workqueue. Afterwards, softirqs are not run > in a deterministic time frame.

Re: [PATCH net-next] net/mlx5e: Support bpf_xdp_adjust_head()

2017-01-13 Thread Martin KaFai Lau
On Fri, Jan 13, 2017 at 03:58:46PM +0200, Saeed Mahameed wrote: > >> > @@ -680,7 +687,7 @@ static inline void mlx5e_xmit_xdp_frame(struct > >> > mlx5e_rq *rq, > >> > memset(wqe, 0, sizeof(*wqe)); > >> > > >> > /* copy the inline part */ > >> > -

Re: [PATCH net-next v2 08/10] net: dsa: Add support for platform data

2017-01-13 Thread Florian Fainelli
On 01/13/2017 06:11 AM, Andrew Lunn wrote: >> static int _dsa_register_switch(struct dsa_switch *ds, struct device *dev) >> { >> +struct dsa_chip_data *pdata = dev->platform_data; >> struct device_node *np = dev->of_node; >> struct dsa_switch_tree *dst; >> struct device_node

Re: [pull request][for-next] Mellanox mlx5 Reorganize core driver directory layout

2017-01-13 Thread Saeed Mahameed
On Sat, Jan 14, 2017 at 12:06 AM, Tom Herbert wrote: > On Fri, Jan 13, 2017 at 12:29 PM, Leon Romanovsky wrote: >> On Fri, Jan 13, 2017 at 12:14:07PM -0500, David Miller wrote: >>> From: Saeed Mahameed >>> Date: Thu, 12 Jan 2017

Re: [pull request][for-next] Mellanox mlx5 Reorganize core driver directory layout

2017-01-13 Thread Tom Herbert
On Fri, Jan 13, 2017 at 2:59 PM, Rick Jones wrote: > On 01/13/2017 02:56 PM, Tom Herbert wrote: >> >> On Fri, Jan 13, 2017 at 2:45 PM, Saeed Mahameed >>> >>> what configuration are you running ? what traffic ? >>> >> Nothing fancy. 8 queues and 20 concurrent netperf

Re: [PATCH net] mlx4: do not call napi_schedule() without care

2017-01-13 Thread Alexander Duyck
On Fri, Jan 13, 2017 at 8:39 AM, Eric Dumazet wrote: > From: Eric Dumazet > > Disable BH around the call to napi_schedule() to avoid following warning > > [ 52.095499] NOHZ: local_softirq_pending 08 > [ 52.421291] NOHZ: local_softirq_pending 08 >

Re: [PATCH net] mlx4: do not call napi_schedule() without care

2017-01-13 Thread Eric Dumazet
On Fri, 2017-01-13 at 15:07 -0800, Alexander Duyck wrote: > On Fri, Jan 13, 2017 at 8:39 AM, Eric Dumazet wrote: > > From: Eric Dumazet > > > > Disable BH around the call to napi_schedule() to avoid following warning > > > > [ 52.095499] NOHZ:

Re: [PATCH net] bpf: rework prog_digest into prog_tag

2017-01-13 Thread Andy Lutomirski
On Fri, Jan 13, 2017 at 3:41 PM, Daniel Borkmann wrote: > On 01/14/2017 12:16 AM, Andy Lutomirski wrote: >> >> On Fri, Jan 13, 2017 at 2:38 PM, Daniel Borkmann >> wrote: >>> >>> Commit 7bd509e311f4 ("bpf: add prog_digest and expose it via >>>

Re: [PATCH net] bpf: rework prog_digest into prog_tag

2017-01-13 Thread Daniel Borkmann
On 01/14/2017 12:49 AM, Andy Lutomirski wrote: On Fri, Jan 13, 2017 at 3:41 PM, Daniel Borkmann wrote: On 01/14/2017 12:16 AM, Andy Lutomirski wrote: On Fri, Jan 13, 2017 at 2:38 PM, Daniel Borkmann wrote: Commit 7bd509e311f4 ("bpf: add

Re: [Patch net] atm: remove an unnecessary loop

2017-01-13 Thread Francois Romieu
Cong Wang : > On Fri, Jan 13, 2017 at 5:23 AM, Francois Romieu wrote: [...] > > alloc_skb() does not need to be in the "while" loop. > > This is exactly what I describe in my changelog, don't know > why you want to repeat it... Because it is

Re: [Patch net] atm: remove an unnecessary loop

2017-01-13 Thread Francois Romieu
Francois Romieu : [...] Now with a proper error code. Have a nice night. diff --git a/net/atm/common.c b/net/atm/common.c index a3ca922..e20d040 100644 --- a/net/atm/common.c +++ b/net/atm/common.c @@ -62,21 +62,16 @@ static void vcc_remove_socket(struct sock *sk)

Re: [Patch net] atm: remove an unnecessary loop

2017-01-13 Thread Cong Wang
On Fri, Jan 13, 2017 at 4:15 PM, Francois Romieu wrote: > Cong Wang : >> On Fri, Jan 13, 2017 at 5:23 AM, Francois Romieu >> wrote: > [...] >> > alloc_skb() does not need to be in the "while" loop. >> >> This is exactly what

Re: [PATCH v5 02/13] net: ethernet: aquantia: Common functions and definitions

2017-01-13 Thread David Miller
From: Alexander Loktionov Date: Thu, 12 Jan 2017 21:02:18 -0800 > +#define AQ_OBJ_HEADER spinlock_t lock; atomic_t flags; atomic_t busy_count > + > +struct aq_obj_s { > + AQ_OBJ_HEADER; > +}; Please don't hide multiple declarations and types inside of a

[PATCH next] ipvlan: fix dev_id creation corner case.

2017-01-13 Thread Mahesh Bandewar
From: Mahesh Bandewar In the last patch da36e13cf65 ("ipvlan: improvise dev_id generation logic in IPvlan") I missed some part of Dave's suggestion and because of that the dev_id creation could fail in a corner case scenario. This would happen when more or less 64k devices

Re: [net PATCH v3 5/5] virtio_net: XDP support for adjust_head

2017-01-13 Thread John Fastabend
On 17-01-13 12:08 PM, John Fastabend wrote: > On 17-01-12 11:41 PM, Jason Wang wrote: >> >> >> On 2017年01月13日 10:52, John Fastabend wrote: >>> Add support for XDP adjust head by allocating a 256B header region >>> that XDP programs can grow into. This is only enabled when a XDP >>> program is

Re: [PATCH v5 11/13] net: ethernet: aquantia: Ethtool support

2017-01-13 Thread Florian Fainelli
On 01/12/2017 09:02 PM, Alexander Loktionov wrote: > From: David VomLehn > > Add the driver interfaces required for support by the ethtool utility. > > Signed-off-by: Alexander Loktionov > Signed-off-by: Dmitrii Tarakanov

Re: Commit 1fe8e0... (include more headers in if_tunnel.h) breaks my user-space build.

2017-01-13 Thread Ben Greear
On 01/13/2017 02:08 PM, Stephen Hemminger wrote: On Fri, 13 Jan 2017 11:50:32 -0800 Ben Greear wrote: On 01/13/2017 11:41 AM, Stephen Hemminger wrote: On Fri, 13 Jan 2017 11:12:32 -0800 Ben Greear wrote: I am including netinet/ip.h, and

Re: [PATCH net-next 1/2] net: AF-specific RTM_GETSTATS attributes

2017-01-13 Thread Roopa Prabhu
On 1/13/17, 10:14 AM, Robert Shearman wrote: > Add the functionality for including address-family-specific per-link > stats in RTM_GETSTATS messages. This is done through adding a new > IFLA_STATS_AF_SPEC attribute under which address family attributes are > nested and then the AF-specific

Re: [pull request][for-next] Mellanox mlx5 Reorganize core driver directory layout

2017-01-13 Thread Tom Herbert
On Fri, Jan 13, 2017 at 2:45 PM, Saeed Mahameed wrote: > On Sat, Jan 14, 2017 at 12:06 AM, Tom Herbert wrote: >> On Fri, Jan 13, 2017 at 12:29 PM, Leon Romanovsky wrote: >>> On Fri, Jan 13, 2017 at 12:14:07PM -0500, David Miller

Re: [PATCH net] bpf: rework prog_digest into prog_tag

2017-01-13 Thread Andy Lutomirski
On Fri, Jan 13, 2017 at 2:38 PM, Daniel Borkmann wrote: > Commit 7bd509e311f4 ("bpf: add prog_digest and expose it via > fdinfo/netlink") was recently discussed, partially due to > admittedly suboptimal name of "prog_digest" in combination > with sha1 hash usage, thus

[PATCH net-next] net: ipv6: Allow shorthand delete of all nexthops in multipath route

2017-01-13 Thread David Ahern
IPv4 allows multipath routes to be deleted using just the prefix and length. For example: $ ip ro ls vrf red unreachable default metric 8192 1.1.1.0/24 nexthop via 10.100.1.254 dev eth1 weight 1 nexthop via 10.11.200.2 dev eth11.200 weight 1 10.11.200.0/24 dev

Re: [Patch net] atm: remove an unnecessary loop

2017-01-13 Thread Chas Williams
On Fri, 2017-01-13 at 10:20 -0800, Cong Wang wrote: > On Fri, Jan 13, 2017 at 9:10 AM, David Miller wrote: > > From: Francois Romieu > > Date: Fri, 13 Jan 2017 01:07:00 +0100 > > > >> Were alloc_skb moved one level up in the call stack, there would be >

  1   2   3   >