Re: [RFC 02/10] IB/hfi-vnic: Virtual Network Interface Controller (VNIC) Bus driver

2016-11-30 Thread Vishwanathapura, Niranjana
On Tue, Nov 29, 2016 at 09:21:13AM -0700, Jason Gunthorpe wrote: On Mon, Nov 28, 2016 at 10:29:38PM -0800, Vishwanathapura, Niranjana wrote: On Thu, Nov 24, 2016 at 09:15:45AM -0700, Jason Gunthorpe wrote: >>And will move the hfi_vnic module under >>???drivers/infiniband/ulp/hfi_vnic???. > >I

Re: [RFC 02/10] IB/hfi-vnic: Virtual Network Interface Controller (VNIC) Bus driver

2016-11-30 Thread Vishwanathapura, Niranjana
On Tue, Nov 29, 2016 at 09:50:09AM -0700, Jason Gunthorpe wrote: On Tue, Nov 29, 2016 at 04:44:37PM +, Hefty, Sean wrote: > You are not making a subsystem. Don't overcomplicate things. A > multi-part device device can just directly link. The VNIC may be usable over multiple generations of

Re: [PATCH net] tipc: check minimum bearer MTU

2016-11-30 Thread kbuild test robot
Hi Michal, [auto build test ERROR on net/master] url: https://github.com/0day-ci/linux/commits/Michal-Kubecek/tipc-check-minimum-bearer-MTU/20161201-140555 config: i386-randconfig-s0-201648 (attached as .config) compiler: gcc-6 (Debian 6.2.0-3) 6.2.0 20160901 reproduce: # save the

Re: [PATCH net-next v2 1/2] tcp: randomize tcp timestamp offsets for each connection

2016-11-30 Thread Yuchung Cheng
On Wed, Nov 30, 2016 at 4:28 AM, Florian Westphal wrote: > > jiffies based timestamps allow for easy inference of number of devices > behind NAT translators and also makes tracking of hosts simpler. > > commit ceaa1fef65a7c2e ("tcp: adding a per-socket timestamp offset") > added

Re: [PATCH net-next v2 2/2] tcp: allow to turn tcp timestamp randomization off

2016-11-30 Thread Yuchung Cheng
On Wed, Nov 30, 2016 at 4:28 AM, Florian Westphal wrote: > Eric says: "By looking at tcpdump, and TS val of xmit packets of multiple > flows, we can deduct the relative qdisc delays (think of fq pacing). > This should work even if we have one flow per remote peer." > > Having

Re: Re: [PATCH] ipv6:ip6_xmit remove unnecessary np NULL check

2016-11-30 Thread Eric Dumazet
On Thu, 2016-12-01 at 06:14 +, Rohit Thapliyal wrote: > Hi, > Hi, Do not top post on netdev, and do not use HTML format : it wont reach netdev. > > Found at just one place in ping_v6_sendmsg, where np is checked for > NULL. > > And I am not sure, if it is really required there also. >

Re: [PATCH net-next v6 4/6] bpf: Add support for reading socket family, type, protocol

2016-11-30 Thread Alexei Starovoitov
On Wed, Nov 30, 2016 at 10:16:48AM -0800, David Ahern wrote: > Add socket family, type and protocol to bpf_sock allowing bpf programs > read-only access. > > Signed-off-by: David Ahern ... > +static u32 convert_sock_access(int sock_field, int dst_reg, int src_reg, > +

Re: [PATCH net-next v6 6/6] samples/bpf: add userspace example for prohibiting sockets

2016-11-30 Thread Alexei Starovoitov
On Wed, Nov 30, 2016 at 10:16:50AM -0800, David Ahern wrote: > Add examples preventing a process in a cgroup from opening a socket > based family, protocol and type. > > Signed-off-by: David Ahern ... > +++ b/samples/bpf/sock_flags_kern.c > @@ -0,0 +1,37 @@ > +#include

Re: [RFC PATCH net-next v2] ipv6: implement consistent hashing for equal-cost multipath routing

2016-11-30 Thread Hannes Frederic Sowa
On Wed, Nov 30, 2016, at 20:49, David Miller wrote: > From: David Lebrun > Date: Tue, 29 Nov 2016 18:15:18 +0100 > > > When multiple nexthops are available for a given route, the routing engine > > chooses a nexthop by computing the flow hash through

Re: pull-request: wireless-drivers 2016-11-29

2016-11-30 Thread Kalle Valo
David Miller writes: > From: Kalle Valo > Date: Tue, 29 Nov 2016 16:59:44 +0200 > >> if there's still time here's one more patch to 3.9. I think this is good >> to have in 3.9 as it fixes an issue where we were printing uninitialised >> memory in

[PATCH net] net: bcmgenet: Utilize correct struct device for all DMA operations

2016-11-30 Thread Florian Fainelli
__bcmgenet_tx_reclaim() is not using the struct device reference when doing its unmap operation, which made the DMA-API debugging warn about it. Fix this by always using >pdev->dev throughout the driver, using an identical device reference for all map/unmap calls. Fixes: 1c1008c793fa ("net:

Re: [v5,1/5] soc: qcom: smem_state: Fix include for ERR_PTR()

2016-11-30 Thread Valo, Kalle
Kalle Valo writes: > "Valo, Kalle" writes: > >> Bjorn Andersson writes: >> >>> On Wed 16 Nov 10:49 PST 2016, Kalle Valo wrote: >>> Bjorn Andersson wrote: > The correct include

Re: [WIP] net+mlx4: auto doorbell

2016-11-30 Thread Tom Herbert
On Wed, Nov 30, 2016 at 6:32 PM, Eric Dumazet wrote: > On Wed, 2016-11-30 at 17:16 -0800, Tom Herbert wrote: >> On Wed, Nov 30, 2016 at 4:27 PM, Eric Dumazet wrote: >> > >> > Another issue I found during my tests last days, is a problem with BQL,

Re: [PATCH net] vhost_net: don't continue to call the recvmsg when meet errors

2016-11-30 Thread Michael S. Tsirkin
On Thu, Dec 01, 2016 at 04:41:40AM +, wangyunjian wrote: > >-Original Message- > >From: Jason Wang [mailto:jasow...@redhat.com] > >Sent: Thursday, December 01, 2016 11:37 AM > >To: Michael S. Tsirkin > >Cc: wangyunjian; netdev@vger.kernel.org; linux-ker...@vger.kernel.org; caihe >

RE: [PATCH net] vhost_net: don't continue to call the recvmsg when meet errors

2016-11-30 Thread wangyunjian
>-Original Message- >From: Jason Wang [mailto:jasow...@redhat.com] >Sent: Thursday, December 01, 2016 11:37 AM >To: Michael S. Tsirkin >Cc: wangyunjian; netdev@vger.kernel.org; linux-ker...@vger.kernel.org; caihe >Subject: Re: [PATCH net] vhost_net: don't continue to call the recvmsg when

Re: [net-next PATCH v3 0/6] XDP for virtio_net

2016-11-30 Thread John Fastabend
On 16-11-30 10:56 AM, Michael S. Tsirkin wrote: > On Wed, Nov 30, 2016 at 10:41:04AM -0800, John Fastabend wrote: >> On 16-11-30 10:35 AM, Michael S. Tsirkin wrote: >>> On Tue, Nov 29, 2016 at 12:05:20PM -0800, John Fastabend wrote: This implements virtio_net for the mergeable buffers and

Re: [net-next PATCH v3 3/6] virtio_net: Add XDP support

2016-11-30 Thread John Fastabend
On 16-11-30 10:54 AM, Michael S. Tsirkin wrote: > On Tue, Nov 29, 2016 at 12:10:21PM -0800, John Fastabend wrote: >> From: John Fastabend >> >> This adds XDP support to virtio_net. Some requirements must be >> met for XDP to be enabled depending on the mode. First it

linux-next: manual merge of the tip tree with the net-next tree

2016-11-30 Thread Stephen Rothwell
Hi all, Today's linux-next merge of the tip tree got a conflict in: drivers/net/ethernet/sfc/Kconfig between commit: 5a6681e22c14 ("sfc: separate out SFC4000 ("Falcon") support into new sfc-falcon driver") from the net-next tree and commit: d1cbfd771ce8 ("ptp_clock: Allow for it to be

Re: [PATCH] tcp_bbr: fix Kconfig to be able to make BBR the default congestion algorithm

2016-11-30 Thread David Miller
From: Bernhard Held Date: Wed, 30 Nov 2016 23:31:29 +0100 > Add missing line to be able to make BBR the default > congestion algorithm. > > Signed-off-by: Bernhard Held The current tree already has this fix.

Re: [PATCH net] vhost_net: don't continue to call the recvmsg when meet errors

2016-11-30 Thread Jason Wang
On 2016年12月01日 11:27, Michael S. Tsirkin wrote: On Thu, Dec 01, 2016 at 11:26:21AM +0800, Jason Wang wrote: > > >On 2016年12月01日 11:21, Michael S. Tsirkin wrote: > >On Thu, Dec 01, 2016 at 02:48:59AM +, wangyunjian wrote: > > > >-Original Message- > > > >From: Michael S. Tsirkin

Re: [PATCH net] vhost_net: don't continue to call the recvmsg when meet errors

2016-11-30 Thread Michael S. Tsirkin
On Thu, Dec 01, 2016 at 11:26:21AM +0800, Jason Wang wrote: > > > On 2016年12月01日 11:21, Michael S. Tsirkin wrote: > > On Thu, Dec 01, 2016 at 02:48:59AM +, wangyunjian wrote: > > > > -Original Message- > > > > From: Michael S. Tsirkin [mailto:m...@redhat.com] > > > > Sent: Wednesday,

Re: DSA vs envelope frames

2016-11-30 Thread Florian Fainelli
On 11/30/2016 07:10 AM, Andrew Lunn wrote: >> What is not really clear - what if several tagging protocols are used >> together. AFAIU, things may be more complex that simple appending of >> tags, e.g. EDSA tag can carry VLAN id inside. > > Hi Nikita > > At least for all current tagging

Re: [PATCH net] vhost_net: don't continue to call the recvmsg when meet errors

2016-11-30 Thread Jason Wang
On 2016年12月01日 11:21, Michael S. Tsirkin wrote: On Thu, Dec 01, 2016 at 02:48:59AM +, wangyunjian wrote: -Original Message- From: Michael S. Tsirkin [mailto:m...@redhat.com] Sent: Wednesday, November 30, 2016 9:41 PM To: wangyunjian Cc: jasow...@redhat.com; netdev@vger.kernel.org;

Re: [PATCH net] vhost_net: don't continue to call the recvmsg when meet errors

2016-11-30 Thread Michael S. Tsirkin
On Thu, Dec 01, 2016 at 02:48:59AM +, wangyunjian wrote: > > >-Original Message- > >From: Michael S. Tsirkin [mailto:m...@redhat.com] > >Sent: Wednesday, November 30, 2016 9:41 PM > >To: wangyunjian > >Cc: jasow...@redhat.com; netdev@vger.kernel.org; > >linux-ker...@vger.kernel.org;

Re: [PATCH net] vhost_net: don't continue to call the recvmsg when meet errors

2016-11-30 Thread Jason Wang
On 2016年11月30日 21:40, Michael S. Tsirkin wrote: On Wed, Nov 30, 2016 at 08:10:57PM +0800, Yunjian Wang wrote: When we meet an error(err=-EBADFD) recvmsg, How do you get EBADFD? Won't vhost_net_rx_peek_head_len return 0 in this case, breaking the loop? the error handling in vhost

Re: [PATCH net] vhost_net: don't continue to call the recvmsg when meet errors

2016-11-30 Thread Jason Wang
On 2016年12月01日 10:48, wangyunjian wrote: -Original Message- From: Michael S. Tsirkin [mailto:m...@redhat.com] Sent: Wednesday, November 30, 2016 9:41 PM To: wangyunjian Cc: jasow...@redhat.com; netdev@vger.kernel.org; linux-ker...@vger.kernel.org; caihe Subject: Re: [PATCH net]

Re: [WIP] net+mlx4: auto doorbell

2016-11-30 Thread Eric Dumazet
On Wed, 2016-11-30 at 18:32 -0800, Eric Dumazet wrote: > I simply suggest we try to queue the qdisc for further servicing as we > do today, from net_tx_action(), but we might use a different bit, so > that we leave the opportunity for another cpu to get __QDISC_STATE_SCHED > before we grab it

RE: [PATCH net] vhost_net: don't continue to call the recvmsg when meet errors

2016-11-30 Thread wangyunjian
>-Original Message- >From: Michael S. Tsirkin [mailto:m...@redhat.com] >Sent: Wednesday, November 30, 2016 9:41 PM >To: wangyunjian >Cc: jasow...@redhat.com; netdev@vger.kernel.org; linux-ker...@vger.kernel.org; >caihe >Subject: Re: [PATCH net] vhost_net: don't continue to call the

Re: Initial thoughts on TXDP

2016-11-30 Thread Florian Westphal
Tom Herbert wrote: > Posting for discussion Warning: You are not going to like this reply... > Now that XDP seems to be nicely gaining traction Yes, I regret to see that. XDP seems useful to create impressive benchmark numbers (and little else). I will send a

Re: [WIP] net+mlx4: auto doorbell

2016-11-30 Thread Eric Dumazet
On Wed, 2016-11-30 at 17:16 -0800, Tom Herbert wrote: > On Wed, Nov 30, 2016 at 4:27 PM, Eric Dumazet wrote: > > > > Another issue I found during my tests last days, is a problem with BQL, > > and more generally when driver stops/starts the queue. > > > > When under stress

[PATCH net v2 1/3] ipv4: Set skb->protocol properly for local output

2016-11-30 Thread Eli Cooper
When xfrm is applied to TSO/GSO packets, it follows this path: xfrm_output() -> xfrm_output_gso() -> skb_gso_segment() where skb_gso_segment() relies on skb->protocol to function properly. This patch sets skb->protocol to ETH_P_IP before dst_output() is called, fixing a bug where GSO

[PATCH net v2 3/3] Revert: "ip6_tunnel: Update skb->protocol to ETH_P_IPV6 in ip6_tnl_xmit()"

2016-11-30 Thread Eli Cooper
This reverts commit ae148b085876fa771d9ef2c05f85d4b4bf09ce0d ("ip6_tunnel: Update skb->protocol to ETH_P_IPV6 in ip6_tnl_xmit()"). skb->protocol is now set in __ip_local_out() and __ip6_local_out() before dst_output() is called. It is no longer necessary to do it for each tunnel. Cc:

[PATCH net v2 2/3] ipv6: Set skb->protocol properly for local output

2016-11-30 Thread Eli Cooper
When xfrm is applied to TSO/GSO packets, it follows this path: xfrm_output() -> xfrm_output_gso() -> skb_gso_segment() where skb_gso_segment() relies on skb->protocol to function properly. This patch sets skb->protocol to ETH_P_IPV6 before dst_output() is called, fixing a bug where GSO

linux-next: manual merge of the net-next tree with the net tree

2016-11-30 Thread Stephen Rothwell
Hi all, Today's linux-next merge of the net-next tree got a conflict in: net/sched/cls_flower.c between commit: 725cbb62e7ad ("sched: cls_flower: remove from hashtable only in case skip sw flag is not set") from the net tree and commit: 13fa876ebd03 ("net/sched: cls_flower: merge

linux-next: manual merge of the net-next tree with the arm-soc tree

2016-11-30 Thread Stephen Rothwell
Hi all, Today's linux-next merge of the net-next tree got a conflict in: arch/arm64/boot/dts/broadcom/ns2.dtsi between commit: e79249143f46 ("arm64: dts: Add Broadcom Northstar2 device tree entries for PDC driver.") from the arm-soc tree and commit: dddc3c9d7d02 ("arm64: dts: NS2: add

linux-next: manual merge of the net-next tree with the net tree

2016-11-30 Thread Stephen Rothwell
Hi all, Today's linux-next merge of the net-next tree got a conflict in: drivers/net/ethernet/cadence/macb.c between commit: a0b44eea372b ("net: macb: fix the RX queue reset in macb_rx()") from the net tree and commit: b410d13e10db ("net: macb: Use variables with defaults for tx/rx

Re: [WIP] net+mlx4: auto doorbell

2016-11-30 Thread Tom Herbert
On Wed, Nov 30, 2016 at 4:27 PM, Eric Dumazet wrote: > > Another issue I found during my tests last days, is a problem with BQL, > and more generally when driver stops/starts the queue. > > When under stress and BQL stops the queue, driver TX completion does a > lot of

Re: [WIP] net+mlx4: auto doorbell

2016-11-30 Thread Eric Dumazet
Another issue I found during my tests last days, is a problem with BQL, and more generally when driver stops/starts the queue. When under stress and BQL stops the queue, driver TX completion does a lot of work, and servicing CPU also takes over further qdisc_run(). The work-flow is : 1)

Re: [PATCH net] fib_trie: Avoid expensive update of suffix length when not required

2016-11-30 Thread Robert Shearman
On 29/11/16 23:14, Alexander Duyck wrote: On Tue, Nov 29, 2016 at 9:46 AM, Robert Shearman wrote: With certain distributions of routes it can take a long time to add and delete further routes at scale. For example, with a route for 10.37.96.0/20 present it takes 47s to

Re: [PATCH net] tipc: check minimum bearer MTU

2016-11-30 Thread Ben Hutchings
On Wed, 2016-11-30 at 11:24 +0100, Michal Kubecek wrote: > On Wed, Nov 30, 2016 at 10:57:02AM +0100, Michal Kubecek wrote: > > Qian Zhang (张谦) reported a potential socket buffer overflow in > > tipc_msg_build() which is also known as CVE-2016-8632: due to > > insufficient checks, a buffer overflow

Package has been sent.

2016-11-30 Thread Linda Guo
Your shipment(s) is scheduled for delivery Scheduled Delivery Date: 12/02/2016 Shipper: Chambers Group. Kindly view the attached document for shipment/delivery details and tracking procedure. You can also request a delivery change (e.g. reschedule or reroute) from the tracking detail.

[PATCH net-next v3] ipv6 addrconf: Implemented enhanced DAD (RFC7527)

2016-11-30 Thread Erik Nordmark
Implemented RFC7527 Enhanced DAD. IPv6 duplicate address detection can fail if there is some temporary loopback of Ethernet frames. RFC7527 solves this by including a random nonce in the NS messages used for DAD, and if an NS is received with the same nonce it is assumed to be a looped back DAD

Re: [PATCH net-next v4 3/4] bpf: BPF for lightweight tunnel infrastructure

2016-11-30 Thread Alexei Starovoitov
On Wed, Nov 30, 2016 at 05:10:10PM +0100, Thomas Graf wrote: > Registers new BPF program types which correspond to the LWT hooks: > - BPF_PROG_TYPE_LWT_IN => dst_input() > - BPF_PROG_TYPE_LWT_OUT => dst_output() > - BPF_PROG_TYPE_LWT_XMIT => lwtunnel_xmit() > > The separate program types

Re: [PATCH net-next 5/6] net: dsa: mv88e6xxx: add helper for switch ready

2016-11-30 Thread Andrew Lunn
> +static int mv88e6xxx_wait_switch_ready(struct mv88e6xxx_chip *chip) > +{ > + const unsigned long timeout = jiffies + 1 * HZ; > + bool ready; > + int err; > + > + /* Wait up to 1 second for switch to be ready. > + * The switch is ready when all units inside the device (ATU,

Re: [PATCH net-next 3/6] net: dsa: mv88e6xxx: add a software reset op

2016-11-30 Thread Andrew Lunn
> diff --git a/drivers/net/dsa/mv88e6xxx/mv88e6xxx.h > b/drivers/net/dsa/mv88e6xxx/mv88e6xxx.h > index ab52c37..9e51405 100644 > --- a/drivers/net/dsa/mv88e6xxx/mv88e6xxx.h > +++ b/drivers/net/dsa/mv88e6xxx/mv88e6xxx.h > @@ -765,6 +765,9 @@ struct mv88e6xxx_ops { > int (*phy_write)(struct

Re: [PATCH net-next 2/6] net: dsa: mv88e6xxx: add helper to hardware reset

2016-11-30 Thread Andrew Lunn
On Wed, Nov 30, 2016 at 05:59:26PM -0500, Vivien Didelot wrote: > Add an helper to toggle the eventual GPIO connected to the reset pin. > > Signed-off-by: Vivien Didelot Reviewed-by: Andrew Lunn Andrew

Re: [PATCH net-next 1/6] net: dsa: mv88e6xxx: add helper to disable ports

2016-11-30 Thread Andrew Lunn
On Wed, Nov 30, 2016 at 05:59:25PM -0500, Vivien Didelot wrote: > Before resetting a switch, the ports should be set to the Disabled state > and the transmit queues should be drained. > > Add an helper to explicit that. > > Signed-off-by: Vivien Didelot

Re: [PATCH] tcp_bbr: fix Kconfig to be able to make BBR the default congestion algorithm

2016-11-30 Thread Eric Dumazet
On Wed, 2016-11-30 at 23:31 +0100, Bernhard Held wrote: > Add missing line to be able to make BBR the default > congestion algorithm. > > Signed-off-by: Bernhard Held > --- > net/ipv4/Kconfig | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/net/ipv4/Kconfig

[PATCH net-next 2/6] net: dsa: mv88e6xxx: add helper to hardware reset

2016-11-30 Thread Vivien Didelot
Add an helper to toggle the eventual GPIO connected to the reset pin. Signed-off-by: Vivien Didelot --- drivers/net/dsa/mv88e6xxx/chip.c | 22 ++ 1 file changed, 14 insertions(+), 8 deletions(-) diff --git

[PATCH net-next 4/6] net: dsa: mv88e6xxx: add a PPU polling op

2016-11-30 Thread Vivien Didelot
Marvell chips with controllable PPU have 2 bits to identify the PPU state. Chips without PPU control have their PPU enable by default and have only 1 bit to read the PPU state. The only state we care about is the PPU active and polling state (meaning PortStatus registers are available for

[PATCH net-next 0/6] net: dsa: mv88e6xxx: rework reset and PPU code

2016-11-30 Thread Vivien Didelot
Old Marvell chips (like 88E6060) don't have a PHY Polling Unit (PPU). Next chips (like 88E6185) have a PPU, which has exclusive access to the PHY registers, thus must be disabled before access. Newer chips (like 88E6352) have an indirect mechanism to access the PHY registers whenever, thus loose

[PATCH net-next 6/6] net: dsa: mv88e6xxx: add PPU enable/disable ops

2016-11-30 Thread Vivien Didelot
Some Marvell chips can enable/disable the PPU on demand. This is needed to access the PHY registers when there is no indirection mechanism. Add two new ppu_enable and ppu_disable ops to describe this and finally get rid of the MV88E6XXX_FLAG_PPU* flags. Signed-off-by: Vivien Didelot

[PATCH net-next 5/6] net: dsa: mv88e6xxx: add helper for switch ready

2016-11-30 Thread Vivien Didelot
All Marvell switches (even 88E6060) have a bit to inform that the switch is ready to accept frames. Implement that in mv88e6xxx_g1_init_ready(). If the switch has a PPU, we must wait until its state is active polling, otherwise we cannot access PortStatus registers. Nicely wrap all that in a

[PATCH net-next 1/6] net: dsa: mv88e6xxx: add helper to disable ports

2016-11-30 Thread Vivien Didelot
Before resetting a switch, the ports should be set to the Disabled state and the transmit queues should be drained. Add an helper to explicit that. Signed-off-by: Vivien Didelot --- drivers/net/dsa/mv88e6xxx/chip.c | 34 +++--- 1

[PATCH net-next 3/6] net: dsa: mv88e6xxx: add a software reset op

2016-11-30 Thread Vivien Didelot
Marvell chips have different way to issue a software reset. Old chips (such as 88E6060) have a reset bit in an ATU control register. Newer chips moved this bit in a Global control register. Chips with controllable PPU should reset the PPU when resetting the switch. Add a new reset operation to

Re: [WIP] net+mlx4: auto doorbell

2016-11-30 Thread Eric Dumazet
On Wed, 2016-11-30 at 23:30 +0100, Jesper Dangaard Brouer wrote: > On Wed, 30 Nov 2016 11:30:00 -0800 > Eric Dumazet wrote: > > > On Wed, 2016-11-30 at 20:17 +0100, Jesper Dangaard Brouer wrote: > > > > > Don't take is as critique Eric. I was hoping your patch would

[PATCH net] packet: fix race condition in packet_set_ring

2016-11-30 Thread Eric Dumazet
From: Philip Pettersson When packet_set_ring creates a ring buffer it will initialize a struct timer_list if the packet version is TPACKET_V3. This value can then be raced by a different thread calling setsockopt to set the version to TPACKET_V1 before

Initial thoughts on TXDP

2016-11-30 Thread Tom Herbert
Posting for discussion Now that XDP seems to be nicely gaining traction we can start to consider the next logical step which is to apply the principles of XDP to accelerating transport protocols in the kernel. For lack of a better name I'll refer to this as Transport eXpress Data Path, or

Re: [PATCH net-next] bpf, xdp: drop rcu_read_lock from bpf_prog_run_xdp and move to caller

2016-11-30 Thread Jakub Kicinski
On Wed, 30 Nov 2016 22:16:06 +0100, Daniel Borkmann wrote: > After 326fe02d1ed6 ("net/mlx4_en: protect ring->xdp_prog with rcu_read_lock"), > the rcu_read_lock() in bpf_prog_run_xdp() is superfluous, since callers > need to hold rcu_read_lock() already to make sure BPF program doesn't > get

[PATCH 2/2] net: ethernet: altera: TSE: do not use tx queue lock in tx completion handler

2016-11-30 Thread Lino Sanfilippo
The driver already uses its private lock for synchronization between xmit and xmit completion handler making the additional use of the xmit_lock unnecessary. Furthermore the driver does not set NETIF_F_LLTX resulting in xmit to be called with the xmit_lock held and then taking the private lock

[PATCH 1/2] net: ethernet: altera: TSE: Remove unneeded dma sync for tx buffers

2016-11-30 Thread Lino Sanfilippo
An explicit dma sync for device directly after mapping as well as an explicit dma sync for cpu directly before unmapping is unnecessary and costly on the hotpath. So remove these calls. Signed-off-by: Lino Sanfilippo --- drivers/net/ethernet/altera/altera_tse_main.c | 10

Re: [PATCH v2 1/7] net: dt-bindings: add RGMII TX delay configuration to meson8b-dwmac

2016-11-30 Thread Martin Blumenstingl
On Wed, Nov 30, 2016 at 10:44 PM, Rob Herring wrote: > On Fri, Nov 25, 2016 at 02:01:50PM +0100, Martin Blumenstingl wrote: >> This allows configuring the RGMII TX clock delay. The RGMII clock is >> generated by underlying hardware of the the Meson 8b / GXBB DWMAC glue. >> The

[PATCH] tcp_bbr: fix Kconfig to be able to make BBR the default congestion algorithm

2016-11-30 Thread Bernhard Held
Add missing line to be able to make BBR the default congestion algorithm. Signed-off-by: Bernhard Held --- net/ipv4/Kconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/net/ipv4/Kconfig b/net/ipv4/Kconfig index 300b068..b54b3ca 100644 --- a/net/ipv4/Kconfig +++

Re: [WIP] net+mlx4: auto doorbell

2016-11-30 Thread Jesper Dangaard Brouer
On Wed, 30 Nov 2016 11:30:00 -0800 Eric Dumazet wrote: > On Wed, 2016-11-30 at 20:17 +0100, Jesper Dangaard Brouer wrote: > > > Don't take is as critique Eric. I was hoping your patch would have > > solved this issue of being sensitive to TX completion adjustments. You

Re: [PATCH 4/6] net: ethernet: ti: cpts: add ptp pps support

2016-11-30 Thread Richard Cochran
On Wed, Nov 30, 2016 at 02:43:57PM -0600, Grygorii Strashko wrote: > > In order to produce the PPS edge correctly, you would have to adjust > > the comparison value whenever cc.mult changes, > > yes. And that is done in cpts_ptp_adjfreq() > if (cpts->ts_comp_enabled) >

[PATCH] net: atarilance: use %8ph for printing hex string

2016-11-30 Thread Rasmus Villemoes
This is already using the %pM printf extension; might as well also use %ph to make the code smaller. Signed-off-by: Rasmus Villemoes --- drivers/net/ethernet/amd/atarilance.c | 8 ++-- 1 file changed, 2 insertions(+), 6 deletions(-) diff --git

[PATCH 00/11] Netfilter fixes for net

2016-11-30 Thread Pablo Neira Ayuso
Hi David, This is a large batch of Netfilter fixes for net, they are: 1) Three patches to fix NAT conversion to rhashtable: Switch to rhlist structure that allows to have several objects with the same key. Moreover, fix wrong comparison logic in nf_nat_bysource_cmp() as this is

[PATCH 10/11] netfilter: ipv6: nf_defrag: drop mangled skb on ream error

2016-11-30 Thread Pablo Neira Ayuso
From: Florian Westphal Dmitry Vyukov reported GPF in network stack that Andrey traced down to negative nh offset in nf_ct_frag6_queue(). Problem is that all network headers before fragment header are pulled. Normal ipv6 reassembly will drop the skb when errors occur further down

[PATCH 11/11] netfilter: arp_tables: fix invoking 32bit "iptable -P INPUT ACCEPT" failed in 64bit kernel

2016-11-30 Thread Pablo Neira Ayuso
From: Hongxu Jia Since 09d9686047db ("netfilter: x_tables: do compat validation via translate_table"), it used compatr structure to assign newinfo structure. In translate_compat_table of ip_tables.c and ip6_tables.c, it used compatr->hook_entry to replace

Re: [PATCH net] cdc_ether: Fix handling connection notification

2016-11-30 Thread Kristian Evensen
On Wed, Nov 30, 2016 at 10:51 PM, Bjørn Mork wrote: > Kristian Evensen writes: > >> +void usbnet_cdc_zte_status(struct usbnet *dev, struct urb *urb) >> +{ >> + struct usb_cdc_notification *event; >> + >> + if (urb->actual_length <

[PATCH 09/11] netfilter: nat: fix crash when conntrack entry is re-used

2016-11-30 Thread Pablo Neira Ayuso
From: Florian Westphal Stas Nichiporovich reports oops in nf_nat_bysource_cmp(), trying to access nf_conn struct at address 0xff50. This is the result of fetching a null rhash list (struct embedded at offset 176; 0 - 176 gets us ...fff50). The problem is that

[PATCH 04/11] netfilter: nft_hash: validate maximum value of u32 netlink hash attribute

2016-11-30 Thread Pablo Neira Ayuso
From: Laura Garcia Liebana Use the function nft_parse_u32_check() to fetch the value and validate the u32 attribute into the hash len u8 field. This patch revisits 4da449ae1df9 ("netfilter: nft_exthdr: Add size check on u8 nft_exthdr attributes"). Fixes: cb1b69b0b15b

[PATCH 03/11] netfilter: fix nf_conntrack_helper documentation

2016-11-30 Thread Pablo Neira Ayuso
From: Florian Westphal Since kernel 4.7 this defaults to off. Signed-off-by: Florian Westphal Signed-off-by: Pablo Neira Ayuso --- Documentation/networking/nf_conntrack-sysctl.txt | 7 +-- 1 file changed, 5 insertions(+), 2

[PATCH 08/11] netfilter: nft_range: add the missing NULL pointer check

2016-11-30 Thread Pablo Neira Ayuso
From: Liping Zhang Otherwise, kernel panic will happen if the user does not specify the related attributes. Fixes: 0f3cd9b36977 ("netfilter: nf_tables: add range expression") Signed-off-by: Liping Zhang Signed-off-by: Pablo Neira Ayuso

[PATCH 07/11] netfilter: nf_tables: fix inconsistent element expiration calculation

2016-11-30 Thread Pablo Neira Ayuso
From: "Anders K. Pedersen" As Liping Zhang reports, after commit a8b1e36d0d1d ("netfilter: nft_dynset: fix element timeout for HZ != 1000"), priv->timeout was stored in jiffies, while set->timeout was stored in milliseconds. This is inconsistent and incorrect. Firstly, we

[PATCH 05/11] netfilter: nat: fix cmp return value

2016-11-30 Thread Pablo Neira Ayuso
From: Florian Westphal The comparator works like memcmp, i.e. 0 means objects are equal. In other words, when objects are distinct they are treated as identical, when they are distinct they are allegedly the same. The first case is rare (distinct objects are unlikely to get

[PATCH 02/11] netfilter: Update nf_send_reset6 to consider L3 domain

2016-11-30 Thread Pablo Neira Ayuso
From: David Ahern nf_send_reset6 is not considering the L3 domain and lookups are sent to the wrong table. For example consider the following output rule: ip6tables -A OUTPUT -p tcp --dport 12345 -j REJECT --reject-with tcp-reset using perf to analyze lookups via the

[PATCH 01/11] netfilter: Update ip_route_me_harder to consider L3 domain

2016-11-30 Thread Pablo Neira Ayuso
From: David Ahern ip_route_me_harder is not considering the L3 domain and sending lookups to the wrong table. For example consider the following output rule: iptables -I OUTPUT -p tcp --dport 12345 -j REJECT --reject-with tcp-reset using perf to analyze lookups via

[PATCH 06/11] netfilter: nat: switch to new rhlist interface

2016-11-30 Thread Pablo Neira Ayuso
From: Florian Westphal I got offlist bug report about failing connections and high cpu usage. This happens because we hit 'elasticity' checks in rhashtable that refuses bucket list exceeding 16 entries. The nat bysrc hash unfortunately needs to insert distinct objects that share

Re: [PATCH net] cdc_ether: Fix handling connection notification

2016-11-30 Thread Bjørn Mork
Kristian Evensen writes: > +void usbnet_cdc_zte_status(struct usbnet *dev, struct urb *urb) > +{ > + struct usb_cdc_notification *event; > + > + if (urb->actual_length < sizeof(*event)) > + return; > + > + event = urb->transfer_buffer; > + > +

[PATCH v5 net-next 4/7] net: mvneta: Convert to be 64 bits compatible

2016-11-30 Thread Gregory CLEMENT
From: Marcin Wojtas Prepare the mvneta driver in order to be usable on the 64 bits platform such as the Armada 3700. [gregory.clem...@free-electrons.com]: this patch was extract from a larger one to ease review and maintenance. Signed-off-by: Marcin Wojtas

[PATCH v5 net-next 1/7] net: mvneta: Optimize rx path for small frame

2016-11-30 Thread Gregory CLEMENT
For small frame reuse the phys_addr variable instead of accessing the uncacheable value in the rx descriptor. Signed-off-by: Gregory CLEMENT --- drivers/net/ethernet/marvell/mvneta.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

Re: [PATCH v2 1/7] net: dt-bindings: add RGMII TX delay configuration to meson8b-dwmac

2016-11-30 Thread Rob Herring
On Fri, Nov 25, 2016 at 02:01:50PM +0100, Martin Blumenstingl wrote: > This allows configuring the RGMII TX clock delay. The RGMII clock is > generated by underlying hardware of the the Meson 8b / GXBB DWMAC glue. > The configuration depends on the actual hardware (no delay may be > needed due to

[PATCH v5 net-next 5/7] net: mvneta: Only disable mvneta_bm for 64-bits

2016-11-30 Thread Gregory CLEMENT
Actually only the mvneta_bm support is not 64-bits compatible. The mvneta code itself can run on 64-bits architecture. Signed-off-by: Gregory CLEMENT --- drivers/net/ethernet/marvell/Kconfig | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git

[PATCH v5 net-next 2/7] net: mvneta: Do not allocate buffer in rxq init with HWBM

2016-11-30 Thread Gregory CLEMENT
For HWBM all buffers are allocated in mvneta_bm_construct() and in runtime they are put into descriptors by hardware. There is no need to fill them at this point. Suggested-by: Marcin Wojtas Signed-off-by: Gregory CLEMENT ---

[PATCH v5 net-next 3/7] net: mvneta: Use cacheable memory to store the rx buffer virtual address

2016-11-30 Thread Gregory CLEMENT
Until now the virtual address of the received buffer were stored in the cookie field of the rx descriptor. However, this field is 32-bits only which prevents to use the driver on a 64-bits architecture. With this patch the virtual address is stored in an array not shared with the hardware (no

[PATCH v5 net-next 0/7] Support Armada 37xx SoC (ARMv8 64-bits) in mvneta driver

2016-11-30 Thread Gregory CLEMENT
Hi, The Armada 37xx is a new ARMv8 SoC from Marvell using same network controller as the older Armada 370/38x/XP SoCs. This series adapts the driver in order to be able to use it on this new SoC. The main changes are: - 64-bits support: the first patches allow using the driver on a 64-bit

[PATCH v5 net-next 7/7] ARM64: dts: marvell: Add network support for Armada 3700

2016-11-30 Thread Gregory CLEMENT
Add neta nodes for network support both in device tree for the SoC and the board. Signed-off-by: Gregory CLEMENT --- arch/arm64/boot/dts/marvell/armada-3720-db.dts | 23 +++- arch/arm64/boot/dts/marvell/armada-37xx.dtsi | 23

[PATCH v5 net-next 6/7] net: mvneta: Add network support for Armada 3700 SoC

2016-11-30 Thread Gregory CLEMENT
From: Marcin Wojtas Armada 3700 is a new ARMv8 SoC from Marvell using same network controller as older Armada 370/38x/XP. There are however some differences that needed taking into account when adding support for it: * open default MBUS window to 4GB of DRAM - Armada 3700

Re: [PATCH v3 net-next 2/3] openvswitch: Use is_skb_forwardable() for length check.

2016-11-30 Thread Jarno Rajahalme
> On Nov 30, 2016, at 5:51 AM, Jiri Benc wrote: > > On Tue, 29 Nov 2016 15:30:52 -0800, Jarno Rajahalme wrote: >> @@ -504,11 +485,20 @@ void ovs_vport_send(struct vport *vport, struct >> sk_buff *skb, u8 mac_proto) >> goto drop; >> } >> >> -if

Re: [PATCH v4 net-next 3/7] net: mvneta: Use cacheable memory to store the rx buffer virtual address

2016-11-30 Thread Gregory CLEMENT
Hi David, On mer., nov. 30 2016, David Miller wrote: > From: Gregory CLEMENT > Date: Tue, 29 Nov 2016 15:55:21 +0100 > >> +/* Virtual address of the RX buffer */ >> +void **buf_virt_addr; >> + >> /* Virtual address of the

Re: [PATCH] ethtool: mark mask values as ULL values

2016-11-30 Thread David Miller
From: Jacob Keller Date: Tue, 29 Nov 2016 15:08:47 -0800 > If compiling with signed checks enabled, there will be warnings > generated by the ETHTOOL_RX_FLOW_SPEC_RING(_VF) masks. These are > currently marked as signed constants, which will generate warnings when >

[PATCH net-next] bpf, xdp: drop rcu_read_lock from bpf_prog_run_xdp and move to caller

2016-11-30 Thread Daniel Borkmann
After 326fe02d1ed6 ("net/mlx4_en: protect ring->xdp_prog with rcu_read_lock"), the rcu_read_lock() in bpf_prog_run_xdp() is superfluous, since callers need to hold rcu_read_lock() already to make sure BPF program doesn't get released in the background. Thus, drop it from bpf_prog_run_xdp(), as it

Re: [net PATCH 0/2] Don't use lco_csum to compute IPv4 checksum

2016-11-30 Thread Jeff Kirsher
On Wed, 2016-11-30 at 09:47 -0500, David Miller wrote: > From: Alexander Duyck > Date: Mon, 28 Nov 2016 10:42:18 -0500 > > > When I implemented the GSO partial support in the Intel drivers I was > using > > lco_csum to compute the checksum that we needed to plug into

Re: [PATCH] netns: avoid disabling irq for netns id

2016-11-30 Thread David Miller
From: Paul Moore Date: Wed, 30 Nov 2016 15:35:46 -0500 > On Wed, Nov 30, 2016 at 2:58 PM, David Miller wrote: >> From: Paul Moore >> Date: Tue, 29 Nov 2016 17:11:29 -0500 >> >>> From: Paul Moore >>> >>> Bring back

[PATCH net-next] net/mlx5e: skip loopback selftest with !CONFIG_INET

2016-11-30 Thread Arnd Bergmann
When CONFIG_INET is disabled, the new selftest results in a link error: drivers/net/ethernet/mellanox/mlx5/core/mlx5_core.o: In function `mlx5e_test_loopback': en_selftest.c:(.text.mlx5e_test_loopback+0x2ec): undefined reference to `ip_send_check'

Re: Regression: [PATCH] mlx4: give precise rx/tx bytes/packets counters

2016-11-30 Thread Eric Dumazet
On Wed, 2016-11-30 at 22:42 +0200, Saeed Mahameed wrote: > On Wed, Nov 30, 2016 at 7:35 PM, Eric Dumazet wrote: > > On Wed, 2016-11-30 at 18:46 +0200, Saeed Mahameed wrote: > > > >> we had/still have the proper stats they are the ones that > >> mlx4_en_fold_software_stats

Re: [PATCH net-next] sock: reset sk_err for ICMP packets read from error queue

2016-11-30 Thread Maciej Żenczykowski
On Wed, Nov 30, 2016 at 8:01 PM, Soheil Hassas Yeganeh wrote: > From: Soheil Hassas Yeganeh > > Only when ICMP packets are enqueued onto the error queue, > sk_err is also set. Before f5f99309fa74 (sock: do not set sk_err > in sock_dequeue_err_skb), a

Re: [PATCH 4/6] net: ethernet: ti: cpts: add ptp pps support

2016-11-30 Thread Grygorii Strashko
On 11/30/2016 12:45 PM, Richard Cochran wrote: > On Mon, Nov 28, 2016 at 05:04:26PM -0600, Grygorii Strashko wrote: >> +static cycle_t cpts_cc_ns2cyc(struct cpts *cpts, u64 nsecs) >> +{ >> +cycle_t cyc = (nsecs << cpts->cc.shift) + nsecs; >> + >> +do_div(cyc, cpts->cc.mult); >> + >> +

Re: DSA vs. SWTICHDEV ?

2016-11-30 Thread Jiri Pirko
Wed, Nov 30, 2016 at 07:09:27PM CET, and...@lunn.ch wrote: >> Something like that. I need to run routing protocols on the switch I/Fs and >> egress >> pkgs on selected switch I/Fs bypassing ARP, just like DSA does with its >> vendor >> tags. > >Does the switch have an equivalent tagging

  1   2   3   4   >