RE: [RFC PATCH v2 03/14] xsk: add umem fill queue support and mmap

2018-04-12 Thread Karlsson, Magnus
> -Original Message- > From: Michael S. Tsirkin [mailto:m...@redhat.com] > Sent: Thursday, April 12, 2018 4:16 AM > To: Björn Töpel > Cc: Karlsson, Magnus ; Duyck, Alexander H > ; alexander.du...@gmail.com; > john.fastab...@gmail.com; a...@fb.com; bro...@redhat.com; > willemdebruijn.ker.

KMSAN: uninit-value in netif_skb_features

2018-04-12 Thread syzbot
Hello, syzbot hit the following crash on https://github.com/google/kmsan.git/master commit e2ab7e8abba47a2f2698216258e5d8727ae58717 (Fri Apr 6 16:24:31 2018 +) kmsan: temporarily disable visitAsmInstruction() to help syzbot syzbot dashboard link: https://syzkaller.appspot.com/bug?extid=0

KMSAN: uninit-value in __netif_receive_skb_core

2018-04-12 Thread syzbot
Hello, syzbot hit the following crash on https://github.com/google/kmsan.git/master commit e2ab7e8abba47a2f2698216258e5d8727ae58717 (Fri Apr 6 16:24:31 2018 +) kmsan: temporarily disable visitAsmInstruction() to help syzbot syzbot dashboard link: https://syzkaller.appspot.com/bug?extid=b

Re: KMSAN: uninit-value in netif_skb_features

2018-04-12 Thread Dmitry Vyukov
On Thu, Apr 12, 2018 at 10:01 AM, syzbot wrote: > Hello, > > syzbot hit the following crash on https://github.com/google/kmsan.git/master > commit > e2ab7e8abba47a2f2698216258e5d8727ae58717 (Fri Apr 6 16:24:31 2018 +) > kmsan: temporarily disable visitAsmInstruction() to help syzbot > syzbot d

Re: KMSAN: uninit-value in __netif_receive_skb_core

2018-04-12 Thread Dmitry Vyukov
On Thu, Apr 12, 2018 at 10:01 AM, syzbot wrote: > Hello, > > syzbot hit the following crash on https://github.com/google/kmsan.git/master > commit > e2ab7e8abba47a2f2698216258e5d8727ae58717 (Fri Apr 6 16:24:31 2018 +) > kmsan: temporarily disable visitAsmInstruction() to help syzbot > syzbot d

Re: net_dim() may use uninitialized data

2018-04-12 Thread Tal Gilboa
On 4/5/2018 4:13 PM, Geert Uytterhoeven wrote: Hi Tal, With gcc-4.1.2: drivers/net/ethernet/broadcom/bcmsysport.c: In function ‘bcm_sysport_poll’: include/linux/net_dim.h:354: warning: ‘curr_stats.ppms’ may be used uninitialized in this function include/linux/net_dim.h:354: warni

[PATCH v2 net] net: fix deadlock while clearing neighbor proxy table

2018-04-12 Thread Wolfgang Bumiller
When coming from ndisc_netdev_event() in net/ipv6/ndisc.c, neigh_ifdown() is called with &nd_tbl, locking this while clearing the proxy neighbor entries when eg. deleting an interface. Calling the table's pndisc_destructor() with the lock still held, however, can cause a deadlock: When a multicast

Re: [RFC PATCH v2 03/14] xsk: add umem fill queue support and mmap

2018-04-12 Thread Jesper Dangaard Brouer
On Thu, 12 Apr 2018 07:38:25 + "Karlsson, Magnus" wrote: > > -Original Message- > > From: Michael S. Tsirkin [mailto:m...@redhat.com] > > Sent: Thursday, April 12, 2018 4:16 AM > > To: Björn Töpel > > Cc: Karlsson, Magnus ; Duyck, Alexander H > > ; alexander.du...@gmail.com; > > john

Re: WARNING in kobject_add_internal

2018-04-12 Thread Dmitry Vyukov
On Thu, Apr 12, 2018 at 2:29 AM, Yuan, Linyu (NSB - CN/Shanghai) wrote: > Hi, > > I have a question, > "can syzbot auto test each tree with newest changeset" ? Hi Yuan, Please elaborate. What trees? What newest changeset? Test against what criteria? >> -Original Message- >> From: netdev

Re: WARNING in kobject_add_internal

2018-04-12 Thread Dmitry Vyukov
On Thu, Apr 12, 2018 at 12:04 PM, Dmitry Vyukov wrote: > On Thu, Apr 12, 2018 at 2:29 AM, Yuan, Linyu (NSB - CN/Shanghai) > wrote: >> Hi, >> >> I have a question, >> "can syzbot auto test each tree with newest changeset" ? > > Hi Yuan, > > Please elaborate. > What trees? What newest changeset? Te

[PATCH] selftests: add headers_install to lib.mk

2018-04-12 Thread Anders Roxell
If the kernel headers aren't installed we can't build all the tests. Add a new make target rule 'khdr' in the file lib.mk to generate the kernel headers and that gets include for every test-dir Makefile that includes lib.mk If the testdir in turn have its own sub-dirs the top_srcdir needs to be set

Re: [RFC PATCH v2 14/14] samples/bpf: sample application for AF_XDP sockets

2018-04-12 Thread Jesper Dangaard Brouer
On Tue, 27 Mar 2018 18:59:19 +0200 Björn Töpel wrote: > +static void dump_stats(void) > +{ > + unsigned long stop_time = get_nsecs(); > + long dt = stop_time - start_time; > + int i; > + > + for (i = 0; i < num_socks; i++) { > + double rx_pps = xsks[i]->rx_npkts * 1000

RE: [RFC PATCH v2 14/14] samples/bpf: sample application for AF_XDP sockets

2018-04-12 Thread Karlsson, Magnus
> -Original Message- > From: Jesper Dangaard Brouer [mailto:bro...@redhat.com] > Sent: Thursday, April 12, 2018 1:05 PM > To: Björn Töpel > Cc: Karlsson, Magnus ; Duyck, Alexander H > ; alexander.du...@gmail.com; > john.fastab...@gmail.com; a...@fb.com; > willemdebruijn.ker...@gmail.com;

Re: [PATCH] net: ieee802154: atusb: Replace GFP_ATOMIC with GFP_KERNEL in atusb_probe

2018-04-12 Thread Stefan Schmidt
Hello. On 04/11/2018 04:14 AM, Jia-Ju Bai wrote: > atusb_probe() is never called in atomic context. > This function is only set as ".probe" in struct usb_driver. > > Despite never getting called from atomic context, > atusb_probe() calls usb_alloc_urb() with GFP_ATOMIC, > which does not sleep for

Re: net: hang in unregister_netdevice: waiting for lo to become free

2018-04-12 Thread Dmitry Vyukov
On Wed, Feb 21, 2018 at 3:53 PM, Tommi Rantala wrote: > On 20.02.2018 18:26, Neil Horman wrote: >> >> On Tue, Feb 20, 2018 at 09:14:41AM +0100, Dmitry Vyukov wrote: >>> >>> On Tue, Feb 20, 2018 at 8:56 AM, Tommi Rantala >>> wrote: On 19.02.2018 20:59, Dmitry Vyukov wrote: > > Is

Re: iproute2-4.16.0 no longer accepts routes via fe80::1

2018-04-12 Thread Thomas Deutschmann
Hi, well, it isn't just "fe80::1", it is any IPv6 address which will be rejected if not called with "-6". I run bisect: > git bisect start > # good: [50b8a842e8c098cddb213f5b3076526df88826e8] v4.15.0 > git bisect good 50b8a842e8c098cddb213f5b3076526df88826e8 > # bad: [4b6c4177ee66421770f0bbcc765c

Re: [bpf-next PATCH 1/4] bpf: sockmap, free memory on sock close with cork data

2018-04-12 Thread Simon Horman
On Sun, Apr 01, 2018 at 08:00:54AM -0700, John Fastabend wrote: > If a socket with pending cork data is closed we do not return the > memory to the socket until the garbage collector free's the psock > structure. The garbage collector though can run after the sock has > completed its close operatio

XDP performance regression due to CONFIG_RETPOLINE Spectre V2

2018-04-12 Thread Jesper Dangaard Brouer
Heads-up XDP performance nerds! I got an unpleasant surprise when I updated my GCC compiler (to support the option -mindirect-branch=thunk-extern). My XDP redirect performance numbers when cut in half; from approx 13Mpps to 6Mpps (single CPU core). I've identified the issue, which is caused by k

[PATCH 1/4] lan78xx: Read MAC address from DT if present

2018-04-12 Thread Phil Elwell
There is a standard mechanism for locating and using a MAC address from the Device Tree. Use this facility in the lan78xx driver to support applications without programmed EEPROM or OTP. At the same time, regularise the handling of the different address sources. Signed-off-by: Phil Elwell --- dr

[PATCH 3/4] lan78xx: Read LED modes from Device Tree

2018-04-12 Thread Phil Elwell
Add support for DT property "microchip,led-modes", a vector of two cells (u32s) in the range 0-15, each of which sets the mode for one of the two LEDs. Some possible values are: 0=link/activity 1=link1000/activity 2=link100/activity 3=link10/activity 4=link100/1000/activ

[PATCH 4/4] dt-bindings: Document the DT bindings for lan78xx

2018-04-12 Thread Phil Elwell
The Microchip LAN78XX family of devices are Ethernet controllers with a USB interface. Despite being discoverable devices it can be useful to be able to configure them from Device Tree, particularly in low-cost applications without an EEPROM or programmed OTP. Document the supported properties in

[PATCH 2/4] lan78xx: Read initial EEE setting from Device Tree

2018-04-12 Thread Phil Elwell
Add two new Device Tree properties: * microchip,eee-enabled - a boolean to enable EEE * microchip,tx-lpi-timer - time in microseconds to wait after TX goes idle before entering the low power state (default 600) Signed-off-by: Phil Elwell ---

[PATCH 0/4] lan78xx: Read configuration from Device Tree

2018-04-12 Thread Phil Elwell
The Microchip LAN78XX family of devices are Ethernet controllers with a USB interface. Despite being discoverable devices it can be useful to be able to configure them from Device Tree, particularly in low-cost applications without an EEPROM or programmed OTP. This patch set adds support for readi

Re: [PATCHv2 net] sctp: do not check port in sctp_inet6_cmp_addr

2018-04-12 Thread Neil Horman
On Thu, Apr 12, 2018 at 02:24:31PM +0800, Xin Long wrote: > pf->cmp_addr() is called before binding a v6 address to the sock. It > should not check ports, like in sctp_inet_cmp_addr. > > But sctp_inet6_cmp_addr checks the addr by invoking af(6)->cmp_addr, > sctp_v6_cmp_addr where it also compares

[PATCH net 0/2] sfc: couple of ARFS fixes

2018-04-12 Thread Edward Cree
Two issues introduced by my recent asynchronous filter handling changes: 1. The old filter_rfs_insert would replace a matching filter of equal priority; we need to pass the appropriate argument to filter_insert to make it do the same. 2. It's possible to cause the kernel to hammer ndo_rx_flow

[PATCH net 1/2] sfc: insert ARFS filters with replace_equal=true

2018-04-12 Thread Edward Cree
Necessary to allow redirecting a flow when the application moves. Fixes: 3af0f34290f6 ("sfc: replace asynchronous filter operations") Signed-off-by: Edward Cree --- drivers/net/ethernet/sfc/rx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/sfc/rx.c b/d

[PATCH net 2/2] sfc: limit ARFS workitems in flight per channel

2018-04-12 Thread Edward Cree
A misconfigured system (e.g. with all interrupts affinitised to all CPUs) may produce a storm of ARFS steering events. With the existing sfc ARFS implementation, that could create a backlog of workitems that grinds the system to a halt. To prevent this, limit the number of workitems that may

Re: [PATCH 4/4] dt-bindings: Document the DT bindings for lan78xx

2018-04-12 Thread Andrew Lunn
On Thu, Apr 12, 2018 at 02:55:36PM +0100, Phil Elwell wrote: > The Microchip LAN78XX family of devices are Ethernet controllers with > a USB interface. Despite being discoverable devices it can be useful to > be able to configure them from Device Tree, particularly in low-cost > applications withou

Re: [RFC PATCH v2 03/14] xsk: add umem fill queue support and mmap

2018-04-12 Thread Michael S. Tsirkin
On Thu, Apr 12, 2018 at 07:38:25AM +, Karlsson, Magnus wrote: > I think you are definitely right in that there are ways in which > we can improve performance here. That said, the current queue > performs slightly better than the previous one we had that was > more or less a copy of one of your

Re: [PATCH 1/4] lan78xx: Read MAC address from DT if present

2018-04-12 Thread Andrew Lunn
Hi Phil > - ret = lan78xx_write_reg(dev, RX_ADDRL, addr_lo); > - ret = lan78xx_write_reg(dev, RX_ADDRH, addr_hi); > + mac_addr = of_get_mac_address(dev->udev->dev.of_node); It might be better to use the higher level eth_platform_get_mac_address(

Re: [PATCH net-next] Per interface IPv4 stats (CONFIG_IP_IFSTATS_TABLE)

2018-04-12 Thread kbuild test robot
Hi Stephen, Thank you for the patch! Perhaps something to improve: [auto build test WARNING on net-next/master] url: https://github.com/0day-ci/linux/commits/Stephen-Suryaputra/Per-interface-IPv4-stats-CONFIG_IP_IFSTATS_TABLE/20180412-181719 reproduce: # apt-get install sparse

Re: [PATCH 4/4] dt-bindings: Document the DT bindings for lan78xx

2018-04-12 Thread Phil Elwell
Hi Andrew, On 12/04/2018 15:04, Andrew Lunn wrote: > On Thu, Apr 12, 2018 at 02:55:36PM +0100, Phil Elwell wrote: >> The Microchip LAN78XX family of devices are Ethernet controllers with >> a USB interface. Despite being discoverable devices it can be useful to >> be able to configure them from De

Re: [RFC PATCH v2 00/14] Introducing AF_XDP support

2018-04-12 Thread Björn Töpel
2018-04-11 20:43 GMT+02:00 Alexei Starovoitov : > On 4/11/18 5:17 AM, Björn Töpel wrote: >> >> >> In the current RFC you are required to create both an Rx and Tx >> queue to bind the socket, which is just weird for your "Rx on one >> device, Tx to another" scenario. I'll fix that in the next RFC. >

Re: [PATCH 2/4] lan78xx: Read initial EEE setting from Device Tree

2018-04-12 Thread Andrew Lunn
On Thu, Apr 12, 2018 at 02:55:34PM +0100, Phil Elwell wrote: > Add two new Device Tree properties: > * microchip,eee-enabled - a boolean to enable EEE > * microchip,tx-lpi-timer - time in microseconds to wait after TX goes >idle before entering the low power state >

Re: [PATCH 4/4] dt-bindings: Document the DT bindings for lan78xx

2018-04-12 Thread Andrew Lunn
On Thu, Apr 12, 2018 at 03:10:57PM +0100, Phil Elwell wrote: > Hi Andrew, > > On 12/04/2018 15:04, Andrew Lunn wrote: > > On Thu, Apr 12, 2018 at 02:55:36PM +0100, Phil Elwell wrote: > >> The Microchip LAN78XX family of devices are Ethernet controllers with > >> a USB interface. Despite being disc

Re: [PATCH 1/4] lan78xx: Read MAC address from DT if present

2018-04-12 Thread Phil Elwell
Hi Andrew, On 12/04/2018 15:06, Andrew Lunn wrote: > Hi Phil > >> -ret = lan78xx_write_reg(dev, RX_ADDRL, addr_lo); >> -ret = lan78xx_write_reg(dev, RX_ADDRH, addr_hi); >> +mac_addr = of_get_mac_address(dev->udev->dev.of_node); > > It might be

[PATCH] net: ethernet: ti: cpsw: fix tx vlan priority mapping

2018-04-12 Thread Ivan Khoronzhuk
The CPDMA_TX_PRIORITY_MAP in real is vlan pcp field priority mapping register and basically replaces vlan pcp field for tagged packets. So, set it to be 1:1 mapping. Signed-off-by: Ivan Khoronzhuk --- Based on net/master drivers/net/ethernet/ti/cpsw.c | 2 +- 1 file changed, 1 insertion(+), 1 d

Re: [PATCH 3/4] lan78xx: Read LED modes from Device Tree

2018-04-12 Thread Andrew Lunn
On Thu, Apr 12, 2018 at 02:55:35PM +0100, Phil Elwell wrote: > Add support for DT property "microchip,led-modes", a vector of two > cells (u32s) in the range 0-15, each of which sets the mode for one > of the two LEDs. Some possible values are: > > 0=link/activity 1=link1000/activity

Re: [PATCH 3/4] lan78xx: Read LED modes from Device Tree

2018-04-12 Thread Phil Elwell
Hi Andrew, On 12/04/2018 15:26, Andrew Lunn wrote: > On Thu, Apr 12, 2018 at 02:55:35PM +0100, Phil Elwell wrote: >> Add support for DT property "microchip,led-modes", a vector of two >> cells (u32s) in the range 0-15, each of which sets the mode for one >> of the two LEDs. Some possible values ar

Re: [PATCH 4/4] dt-bindings: Document the DT bindings for lan78xx

2018-04-12 Thread Andrew Lunn
On Thu, Apr 12, 2018 at 02:55:36PM +0100, Phil Elwell wrote: > The Microchip LAN78XX family of devices are Ethernet controllers with > a USB interface. Despite being discoverable devices it can be useful to > be able to configure them from Device Tree, particularly in low-cost > applications withou

Re: [PATCH 4/4] dt-bindings: Document the DT bindings for lan78xx

2018-04-12 Thread Phil Elwell
Hi Andrew, On 12/04/2018 15:30, Andrew Lunn wrote: > On Thu, Apr 12, 2018 at 02:55:36PM +0100, Phil Elwell wrote: >> The Microchip LAN78XX family of devices are Ethernet controllers with >> a USB interface. Despite being discoverable devices it can be useful to >> be able to configure them from De

Re: [PATCH 3/4] lan78xx: Read LED modes from Device Tree

2018-04-12 Thread Andrew Lunn
> @@ -2097,6 +2098,25 @@ static int lan78xx_phy_init(struct lan78xx_net *dev) > (void)lan78xx_set_eee(dev->net, &edata); > } > > + if (!of_property_read_u32_array(dev->udev->dev.of_node, > + "microchip,led-modes", > +

Re: XDP performance regression due to CONFIG_RETPOLINE Spectre V2

2018-04-12 Thread Christoph Hellwig
On Thu, Apr 12, 2018 at 03:50:29PM +0200, Jesper Dangaard Brouer wrote: > --- > Implement support for keeping the DMA mapping through the XDP return > call, to remove RX map/unmap calls. Implement bulking for XDP > ndo_xdp_xmit and XDP return frame API. Bulking allows to perform DMA >

Re: [PATCH 3/5] net: stmmac: dwmac-sun8i: Allow getting syscon regmap from device

2018-04-12 Thread Maxime Ripard
On Wed, Apr 11, 2018 at 10:16:39PM +0800, Icenowy Zheng wrote: > From: Chen-Yu Tsai > > On the Allwinner R40 SoC, the "GMAC clock" register is in the CCU > address space; on the A64 SoC this register is in the SRAM controller > address space, and with a different offset. > > To access the regist

Re: XDP performance regression due to CONFIG_RETPOLINE Spectre V2

2018-04-12 Thread Christoph Hellwig
On Thu, Apr 12, 2018 at 04:51:23PM +0200, Christoph Hellwig wrote: > On Thu, Apr 12, 2018 at 03:50:29PM +0200, Jesper Dangaard Brouer wrote: > > --- > > Implement support for keeping the DMA mapping through the XDP return > > call, to remove RX map/unmap calls. Implement bulking for XD

Re: [PATCH 5/5] arm64: allwinner: a64: add SRAM controller device tree node

2018-04-12 Thread Maxime Ripard
Hi, On Wed, Apr 11, 2018 at 10:16:41PM +0800, Icenowy Zheng wrote: > Allwinner A64 has a SRAM controller, and in the device tree currently > we have a syscon node to enable EMAC driver to access the EMAC clock > register. As SRAM controller driver can now export regmap for this > register, replace

Re: [RFC v3 net-next 13/18] net/sched: Introduce the TBS Qdisc

2018-04-12 Thread Richard Cochran
On Wed, Apr 11, 2018 at 04:38:44PM -0700, Jesus Sanchez-Palencia wrote: > Just breaking this down a bit, yes, TAI is the network time base, and the NICs > PTP clock use that because PTP is (commonly) based on TAI. After the PHCs have > been synchronized over the network (e.g. with ptp4l), my unders

Re: [PATCH net 2/2] sfc: limit ARFS workitems in flight per channel

2018-04-12 Thread David Miller
From: Edward Cree Date: Thu, 12 Apr 2018 15:02:50 +0100 > A misconfigured system (e.g. with all interrupts affinitised to all CPUs) > may produce a storm of ARFS steering events. With the existing sfc ARFS > implementation, that could create a backlog of workitems that grinds the > system to

Re: [PATCH 3/5] net: stmmac: dwmac-sun8i: Allow getting syscon regmap from device

2018-04-12 Thread Icenowy Zheng
于 2018年4月12日 GMT+08:00 下午10:56:28, Maxime Ripard 写到: >On Wed, Apr 11, 2018 at 10:16:39PM +0800, Icenowy Zheng wrote: >> From: Chen-Yu Tsai >> >> On the Allwinner R40 SoC, the "GMAC clock" register is in the CCU >> address space; on the A64 SoC this register is in the SRAM controller >> address

Re: [PATCH 2/4] lan78xx: Read initial EEE setting from Device Tree

2018-04-12 Thread Phil Elwell
Andrew, On 12/04/2018 15:16, Andrew Lunn wrote: > On Thu, Apr 12, 2018 at 02:55:34PM +0100, Phil Elwell wrote: >> Add two new Device Tree properties: >> * microchip,eee-enabled - a boolean to enable EEE >> * microchip,tx-lpi-timer - time in microseconds to wait after TX goes >>

RE: [RFC PATCH v2 03/14] xsk: add umem fill queue support and mmap

2018-04-12 Thread Karlsson, Magnus
> -Original Message- > From: Michael S. Tsirkin [mailto:m...@redhat.com] > Sent: Thursday, April 12, 2018 4:05 PM > To: Karlsson, Magnus > Cc: Björn Töpel ; Duyck, Alexander H > ; alexander.du...@gmail.com; > john.fastab...@gmail.com; a...@fb.com; bro...@redhat.com; > willemdebruijn.ker.

Re: [RFC v3 net-next 13/18] net/sched: Introduce the TBS Qdisc

2018-04-12 Thread Miroslav Lichvar
On Thu, Apr 12, 2018 at 08:03:49AM -0700, Richard Cochran wrote: > On Wed, Apr 11, 2018 at 04:38:44PM -0700, Jesus Sanchez-Palencia wrote: > > Just breaking this down a bit, yes, TAI is the network time base, and the > > NICs > > PTP clock use that because PTP is (commonly) based on TAI. After the

RE: [PATCH 3/4] lan78xx: Read LED modes from Device Tree

2018-04-12 Thread Woojung.Huh
> > @@ -2097,6 +2098,25 @@ static int lan78xx_phy_init(struct lan78xx_net *dev) > > (void)lan78xx_set_eee(dev->net, &edata); > > } > > > > + if (!of_property_read_u32_array(dev->udev->dev.of_node, > > + "microchip,led-modes", > > +

Re: [linux-sunxi] Re: [PATCH 3/5] net: stmmac: dwmac-sun8i: Allow getting syscon regmap from device

2018-04-12 Thread Chen-Yu Tsai
On Thu, Apr 12, 2018 at 11:11 PM, Icenowy Zheng wrote: > > > 于 2018年4月12日 GMT+08:00 下午10:56:28, Maxime Ripard > 写到: >>On Wed, Apr 11, 2018 at 10:16:39PM +0800, Icenowy Zheng wrote: >>> From: Chen-Yu Tsai >>> >>> On the Allwinner R40 SoC, the "GMAC clock" register is in the CCU >>> address space

Re: [PATCH net 2/2] sfc: limit ARFS workitems in flight per channel

2018-04-12 Thread Edward Cree
On 12/04/18 16:11, David Miller wrote: > From: Edward Cree > Date: Thu, 12 Apr 2018 15:02:50 +0100 > >> A misconfigured system (e.g. with all interrupts affinitised to all CPUs) >> may produce a storm of ARFS steering events. With the existing sfc ARFS >> implementation, that could create a bac

Re: [PATCH 08/15] ASoC: pxa: remove the dmaengine compat need

2018-04-12 Thread Mark Brown
On Mon, Apr 02, 2018 at 04:26:49PM +0200, Robert Jarzmik wrote: > As the pxa architecture switched towards the dmaengine slave map, the > old compatibility mechanism to acquire the dma requestor line number and > priority are not needed anymore. Acked-by: Mark Brown If there's no dependency I'm

Re: XDP performance regression due to CONFIG_RETPOLINE Spectre V2

2018-04-12 Thread Jesper Dangaard Brouer
On Thu, 12 Apr 2018 16:56:53 +0200 Christoph Hellwig wrote: > On Thu, Apr 12, 2018 at 04:51:23PM +0200, Christoph Hellwig wrote: > > On Thu, Apr 12, 2018 at 03:50:29PM +0200, Jesper Dangaard Brouer wrote: > > > --- > > > Implement support for keeping the DMA mapping through the XDP

Re: [PATCH net 2/2] sfc: limit ARFS workitems in flight per channel

2018-04-12 Thread David Miller
From: Edward Cree Date: Thu, 12 Apr 2018 16:24:46 +0100 > This code is not handling expiration of old ARFS filters, it's inserting >  new ones. Then simply make the work process a queue, and add entries to the queue here if the work is already scheduled. Is there a reason why that wouldn't work

Re: [PATCH net-next] Per interface IPv4 stats (CONFIG_IP_IFSTATS_TABLE)

2018-04-12 Thread Stephen Suryaputra
Thanks for the feedbacks. Please see the detail below: On Wed, Apr 11, 2018 at 3:37 PM, Julian Anastasov wrote: [snip] >> - __IP_INC_STATS(net, IPSTATS_MIB_INHDRERRORS); >> + __IP_INC_STATS(net, skb_dst(skb)->dev, IPSTATS_MIB_INHDRERRORS); > > May be skb->dev if we want to account

Re: [PATCH net] tcp: md5: reject TCP_MD5SIG or TCP_MD5SIG_EXT on established sockets

2018-04-12 Thread Yuchung Cheng
On Wed, Apr 11, 2018 at 2:36 PM, Eric Dumazet wrote: > > syzbot/KMSAN reported an uninit-value in tcp_parse_options() [1] > > I believe this was caused by a TCP_MD5SIG being set on live > flow. > > This is highly unexpected, since TCP option space is limited. > > For instance, presence of TCP MD5

Re: TCP one-by-one acking - RFC interpretation question

2018-04-12 Thread Yuchung Cheng
On Wed, Apr 11, 2018 at 5:06 AM, Michal Kubecek wrote: > On Wed, Apr 11, 2018 at 12:58:37PM +0200, Michal Kubecek wrote: >> There is something else I don't understand, though. In the case of >> acking previously sacked and never retransmitted segment, >> tcp_clean_rtx_queue() calculates the parame

Re: [PATCH v2] net: dsa: b53: Using sleep-able operations in b53_switch_reset_gpio

2018-04-12 Thread Florian Fainelli
On 04/11/2018 06:48 PM, Jia-Ju Bai wrote: > b53_switch_reset_gpio() is never called in atomic context. > > The call chain ending up at b53_switch_reset_gpio() is: > [1] b53_switch_reset_gpio() <- b53_switch_reset() <- > b53_reset_switch() <- b53_setup() > > b53_switch_reset_gpio() is set as

Re: v6/sit tunnels and VRFs

2018-04-12 Thread Jeff Barnhill
Hi David, In the slides referenced, you recommend adding an "unreachable default" route to the end of each VRF route table. In my testing (for v4) this results in a change to fib lookup failures such that instead of ENETUNREACH being returned, EHOSTUNREACH is returned since the fib finds the unre

Re: [PATCH 08/15] ASoC: pxa: remove the dmaengine compat need

2018-04-12 Thread Robert Jarzmik
Mark Brown writes: > On Mon, Apr 02, 2018 at 04:26:49PM +0200, Robert Jarzmik wrote: >> As the pxa architecture switched towards the dmaengine slave map, the >> old compatibility mechanism to acquire the dma requestor line number and >> priority are not needed anymore. > > Acked-by: Mark Brown >

[PATCH] NFC: fix attrs checks in netlink interface

2018-04-12 Thread Andrey Konovalov
nfc_genl_deactivate_target() relies on the NFC_ATTR_TARGET_INDEX attribute being present, but doesn't check whether it is actually provided by the user. Same goes for nfc_genl_fw_download() and NFC_ATTR_FIRMWARE_NAME. This patch adds appropriate checks. Found with syzkaller. Signed-off-by: Andre

Re: [Cluster-devel] [PATCH v2 0/2] gfs2: Stop using rhashtable_walk_peek

2018-04-12 Thread Bob Peterson
- Original Message - > Here's a second version of the patch (now a patch set) to eliminate > rhashtable_walk_peek in gfs2. > > The first patch introduces lockref_put_not_zero, the inverse of > lockref_get_not_zero. > > The second patch eliminates rhashtable_walk_peek in gfs2. In > gfs2_g

Re: SRIOV switchdev mode BoF minutes

2018-04-12 Thread Samudrala, Sridhar
On 11/12/2017 11:49 AM, Or Gerlitz wrote: Hi Dave and all, During and after the BoF on SRIOV switchdev mode, we came into a consensus among the developers from four different HW vendors (CC audience) that a correct thing to do would be to disallow any new extensions to the legacy mode. The idea

[RFC net-next] ipv6: send netlink notifications for manually configured addresses

2018-04-12 Thread Lorenzo Bianconi
Send a netlink notification when userspace adds a manually configured address if DAD is enabled and optimistic flag isn't set. Moreover send RTM_DELADDR notifications for tentative addresses. Some userspace applications (e.g. NetworkManager) are interested in addr netlink events albeit the address

Re: [PATCH net] net: dsa: mv88e6xxx: Fix receive time stamp race condition.

2018-04-12 Thread Richard Cochran
On Mon, Apr 09, 2018 at 07:19:31AM -0700, Richard Cochran wrote: > Dave, please hold off on this patch. I am seeing new problems in my > testing with this applied. I still need to get to the bottom of > this. Looks like the new problems are a HW/board glitch. The patch is good to go. Thanks,

Re: XDP_TX for virtio_net not working in recent kernel?

2018-04-12 Thread Kimitoshi Takahashi
Hello Jason, The patch fixed the issue. Thank you very much! On 04/11/2018 10:50 AM, Jason Wang wrote: I suspect a kick is missed in the XDP_TX case. Could you please try the attached patch to see if it fixes the issue? Thanks -- Kimitoshi Takahashi

[PATCH net 1/3] l2tp: hold reference on tunnels in netlink dumps

2018-04-12 Thread Guillaume Nault
l2tp_tunnel_find_nth() is unsafe: no reference is held on the returned tunnel, therefore it can be freed whenever the caller uses it. This patch defines l2tp_tunnel_get_nth() which works similarly, but also takes a reference on the returned tunnel. The caller then has to drop it after it stops usin

[PATCH net 3/3] l2tp: hold reference on tunnels printed in l2tp/tunnels debugfs file

2018-04-12 Thread Guillaume Nault
Use l2tp_tunnel_get_nth() instead of l2tp_tunnel_find_nth(), to be safe against concurrent tunnel deletion. Use the same mechanism as in l2tp_ppp.c for dropping the reference taken by l2tp_tunnel_get_nth(). That is, drop the reference just before looking up the next tunnel. In case of error, drop

[PATCH net 0/3] l2tp: remove unsafe calls to l2tp_tunnel_find_nth()

2018-04-12 Thread Guillaume Nault
Using l2tp_tunnel_find_nth() is racy, because the returned tunnel can go away as soon as this function returns. This series introduce l2tp_tunnel_get_nth() as a safe replacement to fixes these races. With this series, all unsafe tunnel/session lookups are finally gone. Guillaume Nault (3): l2tp

[PATCH net 2/3] l2tp: hold reference on tunnels printed in pppol2tp proc file

2018-04-12 Thread Guillaume Nault
Use l2tp_tunnel_get_nth() instead of l2tp_tunnel_find_nth(), to be safe against concurrent tunnel deletion. Unlike sessions, we can't drop the reference held on tunnels in pppol2tp_seq_show(). Tunnels are reused across several calls to pppol2tp_seq_start() when iterating over sessions. These itera

[net] xfrm: allow to release xfrm_state with flush

2018-04-12 Thread Jacek Kalwas
Call to flush SAs doesn't release xfrm_state in case there was a traffic associated with that state and state was already deleted. Given patch calls xfrm_policy_cache_flush despite of actual states deleted in xfrm_state_flush function. Signed-off-by: Jacek Kalwas --- net/xfrm/xfrm_state.c | 6 +

[net] xfrm: cover crypto status in xfrm_input

2018-04-12 Thread Jacek Kalwas
Status checking in xfrm_input doesn't cover CRYPTO_GENERIC_ERROR and CRYPTO_INVALID_PACKET_SYNTAX. Given patch adds additional check for CRYPTO_INVALID_PACKET_SYNTAX and treats CRYPTO_GENERIC_ERROR as status matching LINUX_MIB_XFRMINERROR. Signed-off-by: Jacek Kalwas --- net/xfrm/xfrm_input.c |

[net] udp: enable UDP checksum offload for ESP

2018-04-12 Thread Jacek Kalwas
In case NIC has support for ESP TX CSUM offload skb->ip_summed is not set to CHECKSUM_PARTIAL which results in checksum calculated by SW. Fix enables ESP TX CSUM for UDP by extending condition with check for NETIF_F_HW_ESP_TX_CSUM. Signed-off-by: Jacek Kalwas --- net/ipv4/ip_output.c | 2 +- 1

Re: [RFC net-next 1/2] net: net-porcfs: Reduce rcu lock critical section

2018-04-12 Thread Saeed Mahameed
On Wed, 2018-04-11 at 19:59 -0700, Eric Dumazet wrote: > > On 04/11/2018 04:47 PM, Saeed Mahameed wrote: > > > > Well if we allow devices to access HW counters via FW command > > interfaces in ndo_get_stats and by testing mlx5 where we query up > > to 5 > > hw registers, it could take 100us, stil

[PATCH net-next] ipv6: provide Kconfig switch to disable accept_ra by default

2018-04-12 Thread Matthias Schiffer
Many distributions and users prefer to handle router advertisements in userspace; one example is OpenWrt, which includes a combined RA and DHCPv6 client. For such configurations, accept_ra should not be enabled by default. As setting net.ipv6.conf.default.accept_ra via sysctl.conf or similar facil

Re: [PATCH net-next] Per interface IPv4 stats (CONFIG_IP_IFSTATS_TABLE)

2018-04-12 Thread Julian Anastasov
Hello, On Thu, 12 Apr 2018, Stephen Suryaputra wrote: > Thanks for the feedbacks. Please see the detail below: > > On Wed, Apr 11, 2018 at 3:37 PM, Julian Anastasov wrote: > [snip] > >> - __IP_INC_STATS(net, IPSTATS_MIB_INHDRERRORS); > >> + __IP_INC_STATS(net, skb_dst(skb)->dev

Re: [PATCH] net: ethernet: ti: cpsw: fix tx vlan priority mapping

2018-04-12 Thread Grygorii Strashko
On 04/12/2018 09:25 AM, Ivan Khoronzhuk wrote: > The CPDMA_TX_PRIORITY_MAP in real is vlan pcp field priority mapping > register and basically replaces vlan pcp field for tagged packets. > So, set it to be 1:1 mapping. "Otherwise, it will cause unexpected change of egress vlan tagged packets, l

Re: SRIOV switchdev mode BoF minutes

2018-04-12 Thread Or Gerlitz
On Thu, Apr 12, 2018 at 8:05 PM, Samudrala, Sridhar wrote: > On 11/12/2017 11:49 AM, Or Gerlitz wrote: >> >> Hi Dave and all, >> >> During and after the BoF on SRIOV switchdev mode, we came into a >> consensus among the developers from four different HW vendors (CC >> audience) that a correct thin

Re: SRIOV switchdev mode BoF minutes

2018-04-12 Thread Samudrala, Sridhar
On 4/12/2018 1:20 PM, Or Gerlitz wrote: On Thu, Apr 12, 2018 at 8:05 PM, Samudrala, Sridhar wrote: On 11/12/2017 11:49 AM, Or Gerlitz wrote: Hi Dave and all, During and after the BoF on SRIOV switchdev mode, we came into a consensus among the developers from four different HW vendors (CC audi

Re: linux-next on x60: network manager often complains "network is disabled" after resume

2018-04-12 Thread Pavel Machek
On Mon 2018-03-19 18:33:56, Pavel Machek wrote: > On Mon 2018-03-19 10:40:08, Dan Williams wrote: > > On Mon, 2018-03-19 at 10:21 +0100, Pavel Machek wrote: > > > On Mon 2018-03-19 05:17:45, Woody Suwalski wrote: > > > > Pavel Machek wrote: > > > > > Hi! > > > > > > > > > > With recent linux-next,

Re: [PATCH] net/mlx5: remove some extraneous spaces in indentations

2018-04-12 Thread Saeed Mahameed
On Mon, 2018-04-09 at 13:43 +0100, Colin King wrote: > From: Colin Ian King > > There are several lines where there is an extraneous space causing > indentation misalignment. Remove them. > > Cleans up Cocconelle warnings: > > ./drivers/net/ethernet/mellanox/mlx5/core/qp.c:409:3-18: code aligne

[PATCH ipsec-next] selftests: add xfrm state-policy-monitor to rtnetlink.sh

2018-04-12 Thread Shannon Nelson
Add a simple set of tests for the IPsec xfrm commands. Signed-off-by: Shannon Nelson --- tools/testing/selftests/net/rtnetlink.sh | 103 +++ 1 file changed, 103 insertions(+) diff --git a/tools/testing/selftests/net/rtnetlink.sh b/tools/testing/selftests/net/rtnetli

Re: [RFC bpf-next v2 4/8] bpf: add documentation for eBPF helpers (23-32)

2018-04-12 Thread Alexei Starovoitov
On Tue, Apr 10, 2018 at 03:41:53PM +0100, Quentin Monnet wrote: > Add documentation for eBPF helper functions to bpf.h user header file. > This documentation can be parsed with the Python script provided in > another commit of the patch series, in order to provide a RST document > that can later be

Re: [bpf PATCH 0/3] BPF, a couple sockmap fixes

2018-04-12 Thread Daniel Borkmann
On 04/12/2018 01:56 AM, John Fastabend wrote: > While testing sockmap with more programs (besides our test programs) > I found a couple issues. > > The attached series fixes an issue where pinned maps were not > working correctly, blocking sockets returned zero, and an error > path that when the s

Re: [PATCH] net/tls: Remove VLA usage

2018-04-12 Thread David Miller
From: Kees Cook Date: Tue, 10 Apr 2018 17:52:34 -0700 > In the quest to remove VLAs from the kernel[1], this replaces the VLA > size with the only possible size used in the code, and adds a mechanism > to double-check future IV sizes. > > [1] > https://lkml.kernel.org/r/CA+55aFzCG-zNmZwX4A2FQpa

Re: [PATCHv2] mISDN: Remove VLAs

2018-04-12 Thread David Miller
From: Laura Abbott Date: Tue, 10 Apr 2018 18:04:29 -0700 > There's an ongoing effort to remove VLAs[1] from the kernel to eventually > turn on -Wvla. Remove the VLAs from the mISDN code by switching to using > kstrdup in one place and using an upper bound in another. > > Signed-off-by: Laura Abb

Re: [PATCH] net: stmmac: fix missing support for 802.1AD tag on reception

2018-04-12 Thread David Miller
From: Elad Nachman Date: Wed, 11 Apr 2018 15:07:40 + > --- a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c2018-04-11 > 17:04:00.586057300 +0300 > +++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c2018-04-11 > 17:05:33.601992400 +0300 > @@ -3293,17 +3293,19 @@ dma_map_err: > > sta

Re: [PATCH v2 net] lan78xx: PHY DSP registers initialization to address EEE link drop issues with long cables

2018-04-12 Thread David Miller
From: Raghuram Chary J Date: Wed, 11 Apr 2018 20:36:36 +0530 > The patch is to configure DSP registers of PHY device > to handle Gbe-EEE failures with >40m cable length. > > Fixes: 55d7de9de6c3 ("Microchip's LAN7800 family USB 2/3 to 10/100/1000 > Ethernet device driver") > Signed-off-by: Raghu

Re: [net 1/1] tipc: fix unbalanced reference counter

2018-04-12 Thread David Miller
From: Jon Maloy Date: Wed, 11 Apr 2018 22:52:09 +0200 > When a topology subscription is created, we may encounter (or KASAN > may provoke) a failure to create a corresponding service instance in > the binding table. Instead of letting the tipc_nametbl_subscribe() > report the failure back to the

Re: [PATCH net] tcp: md5: reject TCP_MD5SIG or TCP_MD5SIG_EXT on established sockets

2018-04-12 Thread David Miller
From: Eric Dumazet Date: Wed, 11 Apr 2018 14:36:28 -0700 > syzbot/KMSAN reported an uninit-value in tcp_parse_options() [1] > > I believe this was caused by a TCP_MD5SIG being set on live > flow. > > This is highly unexpected, since TCP option space is limited. > > For instance, presence of TC

Re: [PATCH net] net: validate attribute sizes in neigh_dump_table()

2018-04-12 Thread David Miller
From: Eric Dumazet Date: Wed, 11 Apr 2018 14:46:00 -0700 > Since neigh_dump_table() calls nlmsg_parse() without giving policy > constraints, attributes can have arbirary size that we must validate > > Reported by syzbot/KMSAN : ... > Fixes: 21fdd092acc7 ("net: Add support for filtering neigh du

Re: [PATCH v2 net 0/2] ibmvnic: Fix parameter change request handling

2018-04-12 Thread David Miller
From: Nathan Fontenot Date: Wed, 11 Apr 2018 10:09:26 -0500 > When updating parameters for the ibmvnic driver there is a possibility > of entering an infinite loop if a return value other that a partial > success is received from sending the login CRQ. > > Also, a deadlock can occur on the rtnl

Re: [PATCH] selftests: net: add in_netns.sh to TEST_PROGS

2018-04-12 Thread David Miller
From: Anders Roxell Date: Wed, 11 Apr 2018 17:17:34 +0200 > Script in_netns.sh isn't installed. > > running psock_fanout test > > ./run_afpackettests: line 12: ./in_netns.sh: No such file or directory > [FAIL] > > running psock_tpacke

Re: [PATCH net] strparser: Fix incorrect strp->need_bytes value.

2018-04-12 Thread David Miller
From: Doron Roberts-Kedes Date: Wed, 11 Apr 2018 15:05:16 -0700 > strp_data_ready resets strp->need_bytes to 0 if strp_peek_len indicates > that the remainder of the message has been received. However, > do_strp_work does not reset strp->need_bytes to 0. If do_strp_work > completes a partial mess

Re: [net 1/1] tipc: fix missing initializer in tipc_sendmsg()

2018-04-12 Thread David Miller
From: Jon Maloy Date: Thu, 12 Apr 2018 01:15:48 +0200 > The stack variable 'dnode' in __tipc_sendmsg() may theoretically > end up tipc_node_get_mtu() as an unitilalized variable. > > We fix this by intializing the variable at declaration. We also add > a default else clause to the two conditiona

Re: [PATCH net 0/4] nfp: improve signal handing on FW waits and flower control message processing

2018-04-12 Thread David Miller
From: Jakub Kicinski Date: Wed, 11 Apr 2018 16:47:34 -0700 > The first part of this set aims to improve handling of interrupted > waits. Patch 1 makes waiting for management FW responses > uninterruptible while patch 2 adds a message when signal arrives > while waiting for an NFP mutex. We can'

  1   2   >