[PATCH net] ipv4: remove warning in ip_recv_error

2018-05-23 Thread Willem de Bruijn
From: Willem de Bruijn A precondition check in ip_recv_error triggered on an otherwise benign race. Remove the warning. The warning triggers when passing an ipv6 socket to this ipv4 error handling function. RaceFuzzer was able to trigger it due to a race in setsockopt

Re: [PATCH net-next 00/13] nfp: abm: add basic support for advanced buffering NIC

2018-05-23 Thread David Miller
From: Jakub Kicinski Date: Mon, 21 May 2018 22:12:42 -0700 > This series lays groundwork for advanced buffer management NIC feature. > It makes necessary NFP core changes, spawns representors and adds devlink > glue. Following series will add the actual buffering

Re: [PATCH v2 1/1] tools/lib/libbpf.c: fix string format to allow build on arm32

2018-05-23 Thread Daniel Borkmann
On 05/23/2018 06:17 PM, Sirio Balmelli wrote: > On arm32, 'cd tools/testing/selftests/bpf && make' fails with: > > libbpf.c:80:10: error: format ‘%ld’ expects argument of type ‘long int’, but > argument 4 has type ‘int64_t {aka long long int}’ [-Werror=format=] >(func)("libbpf: " fmt,

Re: [PATCH bpf-next] bpf: btf: Avoid variable length array

2018-05-23 Thread Joe Perches
On Wed, 2018-05-23 at 10:46 -0700, Martin KaFai Lau wrote: > Sparse warning: > kernel/bpf/btf.c:1985:34: warning: Variable length array is used. Perhaps use ARRAY_SIZE directly instead of indirectly via a #define > diff --git a/kernel/bpf/btf.c b/kernel/bpf/btf.c [] > @@ -1970,6 +1970,8 @@

Re: [PATCH v2] ath10k: transmit queued frames after waking queues

2018-05-23 Thread Rajkumar Manoharan
On 2018-05-23 09:25, Erik Stromdahl wrote: On 05/22/2018 11:15 PM, Niklas Cassel wrote: [...] Perhaps it would be possible to call ath10k_mac_tx_push_pending() from the equivalent to ath10k_htt_txrx_compl_task(), but from SDIO's point of view. An equivalent for SDIO would most likely be

[PATCH bpf-next] bpf: btf: Avoid variable length array

2018-05-23 Thread Martin KaFai Lau
Sparse warning: kernel/bpf/btf.c:1985:34: warning: Variable length array is used. This patch moves the nr_secs from btf_check_sec_info() to a macro. Fixes: f80442a4cd18 ("bpf: btf: Change how section is supported in btf_header") Signed-off-by: Martin KaFai Lau ---

Re: [PATCH net V2 0/4] Fix several issues of virtio-net mergeable XDP

2018-05-23 Thread David Miller
From: Jason Wang Date: Tue, 22 May 2018 11:44:27 +0800 > Please review the patches that tries to fix sevreal issues of > virtio-net mergeable XDP. > > Changes from V1: > - check against 1 before decreasing instead of resetting to 1 > - typoe fixes Series applied and queued

Re: [PATCH v3 net-next 0/2] bpfilter

2018-05-23 Thread Greg KH
On Wed, May 23, 2018 at 01:26:48PM -0400, David Miller wrote: > From: Alexei Starovoitov > Date: Mon, 21 May 2018 19:22:28 -0700 > > > v2->v3: > > - followed Luis's suggestion and significantly simplied first patch > > with shmem_kernel_file_setup+kernel_write. Added kdoc for

Re: [PATCH v3 net-next 0/2] bpfilter

2018-05-23 Thread David Miller
From: Alexei Starovoitov Date: Mon, 21 May 2018 19:22:28 -0700 > v2->v3: > - followed Luis's suggestion and significantly simplied first patch > with shmem_kernel_file_setup+kernel_write. Added kdoc for new helper > - fixed typos and race to access pipes with mutex > - tested

Re: [PATCH bpf-next v3 4/7] tools/bpf: add ksym_get_addr() in trace_helpers

2018-05-23 Thread Martin KaFai Lau
On Tue, May 22, 2018 at 09:30:48AM -0700, Yonghong Song wrote: > Given a kernel function name, ksym_get_addr() will return the kernel > address for this function, or 0 if it cannot find this function name > in /proc/kallsyms. This function will be used later when a kernel > address is used to

Re: [PATCH bpf-next v3 2/7] bpf: introduce bpf subcommand BPF_TASK_FD_QUERY

2018-05-23 Thread Martin KaFai Lau
On Tue, May 22, 2018 at 09:30:46AM -0700, Yonghong Song wrote: > Currently, suppose a userspace application has loaded a bpf program > and attached it to a tracepoint/kprobe/uprobe, and a bpf > introspection tool, e.g., bpftool, wants to show which bpf program > is attached to which

Re: [PATCH net-next v4 0/2] openvswitch: Support conntrack zone limit

2018-05-23 Thread David Miller
From: Yi-Hung Wei Date: Mon, 21 May 2018 17:16:03 -0700 > v3->v4: > - Addresses comments from Parvin that include simplify netlink API, > and remove unncessary RCU lockings. > - Rebases to master. Pravin, please review.

Re: [PATCH net-next 2/3] net/ipv6: Udate fib6_table_lookup tracepoint

2018-05-23 Thread David Ahern
On 5/23/18 11:09 AM, David Miller wrote: > From: dsah...@kernel.org > Date: Mon, 21 May 2018 14:24:42 -0700 > >> +__entry->err = ip6_rt_type_to_error(f6i->fib6_type); > > As the kbuild bot discovered, this doesn't work when IPV6=m. > yep. I'll take a look later today. Thinking

Re: [PATCH net-next 2/3] net/ipv6: Udate fib6_table_lookup tracepoint

2018-05-23 Thread David Miller
From: dsah...@kernel.org Date: Mon, 21 May 2018 14:24:42 -0700 > + __entry->err = ip6_rt_type_to_error(f6i->fib6_type); As the kbuild bot discovered, this doesn't work when IPV6=m.

Re: [PATCH net] net: phy: broadcom: Fix bcm_write_exp()

2018-05-23 Thread Florian Fainelli
On 05/22/2018 06:20 PM, Florian Fainelli wrote: > Hi Andrew, > > On 05/22/2018 05:15 PM, Andrew Lunn wrote: >> On Tue, May 22, 2018 at 05:04:49PM -0700, Florian Fainelli wrote: >>> On newer PHYs, we need to select the expansion register to write with >>> setting bits [11:8] to 0xf. This was done

Re: [PATCH 2/4] arcnet: com20020: bindings for smsc com20020

2018-05-23 Thread Rob Herring
On Thu, May 17, 2018 at 03:06:26PM +0200, Andrea Greco wrote: > From: Andrea Greco > > Add devicetree bindings for smsc com20020 > > Signed-off-by: Andrea Greco > --- > .../devicetree/bindings/net/smsc-com20020.txt | 21 > + > 1

[PATCH net-next] selftests: net: Test headroom handling of ip6_gre devices

2018-05-23 Thread Petr Machata
Commit 5691484df961 ("net: ip6_gre: Fix headroom request in ip6erspan_tunnel_xmit()") and commit 01b8d064d58b ("net: ip6_gre: Request headroom in __gre6_xmit()") fix problems in reserving headroom in the packets tunneled through ip6gre/tap and ip6erspan netdevices. These two patches included

[PATCH net-next v2 08/12] amd-xgbe: Add ethtool show/set channels support

2018-05-23 Thread Tom Lendacky
Add ethtool support to show and set the device channel configuration. Changing the channel configuration will result in a device restart. Signed-off-by: Tom Lendacky --- drivers/net/ethernet/amd/xgbe/xgbe-drv.c | 25 +

[PATCH net-next v2 12/12] amd-xgbe: Improve SFP 100Mbps auto-negotiation

2018-05-23 Thread Tom Lendacky
After changing speed to 100Mbps as a result of auto-negotiation (AN), some 10/100/1000Mbps SFPs indicate a successful link (no faults or loss of signal), but cannot successfully transmit or receive data. These SFPs required an extra auto-negotiation (AN) after the speed change in order to operate

[PATCH net-next v2 09/12] amd-xgbe: Always attempt link training in KR mode

2018-05-23 Thread Tom Lendacky
Link training is always attempted when in KR mode, but the code is structured to check if link training has been enabled before attempting to perform it. Since that check will always be true, simplify the code to always enable and start link training during KR auto-negotiation. Signed-off-by:

[PATCH net-next v2 11/12] amd-xgbe: Update the BelFuse quirk to support SGMII

2018-05-23 Thread Tom Lendacky
Instead of using a quirk to make the BelFuse 1GBT-SFP06 part look like a 1000baseX part, program the SFP PHY to support SGMII and 10/100/1000 baseT. Signed-off-by: Tom Lendacky --- drivers/net/ethernet/amd/xgbe/xgbe-phy-v2.c | 109 +++ 1 file

[PATCH net-next v2 10/12] amd-xgbe: Advertise FEC support with the KR re-driver

2018-05-23 Thread Tom Lendacky
When a KR re-driver is present, indicate the FEC support is available during auto-negotiation. Signed-off-by: Tom Lendacky --- drivers/net/ethernet/amd/xgbe/xgbe-phy-v2.c |4 1 file changed, 4 insertions(+) diff --git

[PATCH net-next v2 07/12] amd-xgbe: Prepare for ethtool set-channel support

2018-05-23 Thread Tom Lendacky
In order to support being able to dynamically set/change the number of Rx and Tx channels, update the code to: - Move alloc and free of device memory into callable functions - Move setting of the real number of Rx and Tx channels to device startup - Move mapping of the RSS channels to device

[PATCH net-next v2 05/12] amd-xgbe: Add ethtool support to retrieve SFP module info

2018-05-23 Thread Tom Lendacky
Add support to get SFP module information using ethtool. Signed-off-by: Tom Lendacky --- drivers/net/ethernet/amd/xgbe/xgbe-ethtool.c | 18 +++ drivers/net/ethernet/amd/xgbe/xgbe-mdio.c| 21 drivers/net/ethernet/amd/xgbe/xgbe-phy-v2.c | 137

[PATCH net-next v2 06/12] amd-xgbe: Add ethtool show/set ring parameter support

2018-05-23 Thread Tom Lendacky
Add ethtool support to show and set the number of the Rx and Tx ring descriptors. Changing the ring configuration will result in a device restart. Signed-off-by: Tom Lendacky --- drivers/net/ethernet/amd/xgbe/xgbe-drv.c |6 --

[PATCH net-next v2 03/12] amd-xgbe: Remove use of comm_owned field

2018-05-23 Thread Tom Lendacky
The comm_owned field can hide logic where double locking is attempted and prevent multiple threads for the same device from accessing the mutex properly. Remove the comm_owned field and use the mutex API exclusively for gaining ownership. The current driver has been audited and is obtaining

[PATCH net-next v2 04/12] amd-xgbe: Remove field that indicates SFP diagnostic support

2018-05-23 Thread Tom Lendacky
The driver currently sets an indication of whether the SFP supports, and that the driver can obtain, diagnostics data. This isn't currently used by the driver and the logic to set this indicator is flawed because the field is cleared each time the SFP is checked and only set when a new SFP is

[PATCH net-next v2 02/12] amd-xgbe: Read and save the port property registers during probe

2018-05-23 Thread Tom Lendacky
Read and save the port property registers once during the device probe and then use the saved values as they are needed. Signed-off-by: Tom Lendacky --- drivers/net/ethernet/amd/xgbe/xgbe-pci.c| 34 ++ drivers/net/ethernet/amd/xgbe/xgbe-phy-v2.c | 68

[PATCH net-next v2 00/12] amd-xgbe: AMD XGBE driver updates 2018-05-21

2018-05-23 Thread Tom Lendacky
The following updates are included in this driver update series: - Fix the debug output for the max channels count - Read (once) and save the port property registers during probe - Remove the use of the comm_owned field - Remove unused SFP diagnostic support indicator field - Add ethtool

[PATCH net-next v2 01/12] amd-xgbe: Fix debug output of max channel counts

2018-05-23 Thread Tom Lendacky
A debug output print statement uses the wrong variable to output the maximum Rx channel count (cut and paste error, basically). Fix the statement to use the proper variable. Signed-off-by: Tom Lendacky --- drivers/net/ethernet/amd/xgbe/xgbe-pci.c |2 +- 1 file

[PATCH net-next 3/3] selftests: forwarding: Test removal of mirroring

2018-05-23 Thread Petr Machata
Test that when flower-based mirror action is removed, mirroring stops. Signed-off-by: Petr Machata --- tools/testing/selftests/net/forwarding/mirror_gre_flower.sh | 8 1 file changed, 8 insertions(+) diff --git

[PATCH net-next 2/3] selftests: forwarding: Test removal of underlay route

2018-05-23 Thread Petr Machata
When underlay route is removed, the mirrored traffic should not be forwarded. Signed-off-by: Petr Machata --- .../selftests/net/forwarding/mirror_gre_changes.sh | 30 ++ 1 file changed, 30 insertions(+) diff --git

[PATCH net-next 1/3] selftests: forwarding: Test mirroring to deleted device

2018-05-23 Thread Petr Machata
Tests that the mirroring code catches up with deletion of a mirrored-to device. Signed-off-by: Petr Machata --- .../selftests/net/forwarding/mirror_gre_changes.sh | 38 ++ 1 file changed, 38 insertions(+) diff --git

[PATCH net-next 0/3] selftests: forwarding: Additions to mirror-to-gretap tests

2018-05-23 Thread Petr Machata
This patchset is for a handful of edge cases in mirror-to-gretap scenarios: removal of mirrored-to netdevice (#1), removal of underlay route for tunnel remote endpoint (#2) and cessation of mirroring upon removal of flower mirroring rule (#3). Petr Machata (3): selftests: forwarding: Test

Re: [PATCH v2] ath10k: transmit queued frames after waking queues

2018-05-23 Thread Erik Stromdahl
On 05/22/2018 11:15 PM, Niklas Cassel wrote: Earlier we observed performance issues in calling push_pending from each tx completion. IMHO this change may introduce the same problem again. I prefer functional TX over performance issues, but I agree that it is unfortunate that SDIO doesn't

[PATCH net] net : sched: cls_api: deal with egdev path only if needed

2018-05-23 Thread Or Gerlitz
When dealing with ingress rule on a netdev, if we did fine through the conventional path, there's no need to continue into the egdev route, and we can stop right there. Not doing so may cause a 2nd rule to be added by the cls api layer with the ingress being the egdev. For example, under sriov

Re: [PATCH net-next v11 2/5] netvsc: refactor notifier/event handling code to use the failover framework

2018-05-23 Thread Samudrala, Sridhar
On 5/22/2018 11:27 PM, Jiri Pirko wrote: Tue, May 22, 2018 at 10:54:29PM CEST, sridhar.samudr...@intel.com wrote: On 5/22/2018 9:12 AM, Jiri Pirko wrote: Fixing the subj, sorry about that. Tue, May 22, 2018 at 05:46:21PM CEST, m...@redhat.com wrote: On Tue, May 22, 2018 at 05:36:14PM +0200,

[PATCH v2 1/1] tools/lib/libbpf.c: fix string format to allow build on arm32

2018-05-23 Thread Sirio Balmelli
On arm32, 'cd tools/testing/selftests/bpf && make' fails with: libbpf.c:80:10: error: format ‘%ld’ expects argument of type ‘long int’, but argument 4 has type ‘int64_t {aka long long int}’ [-Werror=format=] (func)("libbpf: " fmt, ##__VA_ARGS__); \ ^ libbpf.c:83:30: note: in

Re: [PATCH 1/1] tools/lib/libbpf.c: fix string format to allow build on arm32

2018-05-23 Thread Sirio Balmelli
On Wed, May 23, 2018 at 08:49:47AM -0700, Martin KaFai Lau wrote: > On Wed, May 23, 2018 at 12:41:14PM +0200, Daniel Borkmann wrote: > > [ +Martin ] > > > > On 05/21/2018 08:59 AM, Sirio Balmelli wrote: > > > On arm32, 'cd tools/testing/selftests/bpf && make' fails with: > > > > > >

Re: [net-next 1/6] net/dcb: Add dcbnl buffer attribute

2018-05-23 Thread John Fastabend
On 05/23/2018 08:37 AM, Huy Nguyen wrote: > > > On 5/23/2018 8:52 AM, John Fastabend wrote: >> It would be nice though if the API gave us some hint on max/min/stride >> of allowed values. Could the get API return these along with current >> value? Presumably the allowed max size could change

Re: [PATCH v2 bpf-next 1/5] bpf: Hooks for sys_sendmsg

2018-05-23 Thread Martin KaFai Lau
On Tue, May 22, 2018 at 04:40:02PM -0700, Andrey Ignatov wrote: > In addition to already existing BPF hooks for sys_bind and sys_connect, > the patch provides new hooks for sys_sendmsg. > > It leverages existing BPF program type `BPF_PROG_TYPE_CGROUP_SOCK_ADDR` > that provides access to socket

Re: [PATCH] ppp: remove the PPPIOCDETACH ioctl

2018-05-23 Thread David Miller
From: Guillaume Nault Date: Wed, 23 May 2018 15:57:08 +0200 > I'd rather add > + if (cmd == PPPIOCDETACH) { > + err = -EINVAL; > + goto out; > + } > > Making PPPIOCDETACH unknown to ppp_generic means that the ioctl would > be handled by the

Re: [PATCH v2] packet: track ring entry use using a shadow ring to prevent RX ring overrun

2018-05-23 Thread Willem de Bruijn
On Wed, May 23, 2018 at 11:29 AM, Jon Rosen (jrosen) wrote: > > >> -Original Message- >> From: Willem de Bruijn [mailto:willemdebruijn.ker...@gmail.com] >> Sent: Wednesday, May 23, 2018 9:37 AM >> To: Jon Rosen (jrosen) >> Cc: David S. Miller

Re: pull-request: mac80211 2018-05-23

2018-05-23 Thread David Miller
From: Johannes Berg Date: Wed, 23 May 2018 11:47:57 +0200 > Just another handful of fixes as we wind down towards the > merge window. > > Please pull and let me know if there's any problem. Pulled, thanks Johannes. Please don't tell me you will soon queue up a patch

Re: [PATCH 1/1] tools/lib/libbpf.c: fix string format to allow build on arm32

2018-05-23 Thread Martin KaFai Lau
On Wed, May 23, 2018 at 12:41:14PM +0200, Daniel Borkmann wrote: > [ +Martin ] > > On 05/21/2018 08:59 AM, Sirio Balmelli wrote: > > On arm32, 'cd tools/testing/selftests/bpf && make' fails with: > > > > libbpf.c:80:10: error: format ‘%ld’ expects argument of type ‘long int’, > > but argument 4

[PATCH V4 4/8] ARM: dts: stm32: Add syscfg on stm32mp1

2018-05-23 Thread Christophe Roullier
System configuration controller is mainly used to manage the compensation cell and other IOs and system related settings. Signed-off-by: Christophe Roullier --- arch/arm/boot/dts/stm32mp157c.dtsi | 5 + 1 file changed, 5 insertions(+) diff --git

[PATCH V4 8/8] dt-bindings: stm32: add compatible for syscon

2018-05-23 Thread Christophe Roullier
This patch describes syscon DT bindings. Signed-off-by: Christophe Roullier --- Documentation/devicetree/bindings/arm/stm32.txt| 10 -- .../devicetree/bindings/arm/stm32/stm32-syscon.txt | 14 ++

[PATCH V4 7/8] ARM: dts: stm32: add support of ethernet on stm32mp157c-ev1

2018-05-23 Thread Christophe Roullier
MAC is connected to a PHY in RGMII mode. Signed-off-by: Christophe Roullier --- arch/arm/boot/dts/stm32mp157c-ev1.dts | 20 1 file changed, 20 insertions(+) diff --git a/arch/arm/boot/dts/stm32mp157c-ev1.dts

[PATCH V4 3/8] ARM: dts: stm32: add ethernet pins to stm32mp157c

2018-05-23 Thread Christophe Roullier
Add ethernet pins on stm32mp157c. Signed-off-by: Christophe Roullier --- arch/arm/boot/dts/stm32mp157-pinctrl.dtsi | 46 +++ 1 file changed, 46 insertions(+) diff --git a/arch/arm/boot/dts/stm32mp157-pinctrl.dtsi

[PATCH V4 0/8] net: ethernet: stmmac: add support for stm32mp1

2018-05-23 Thread Christophe Roullier
Patches to have Ethernet support on stm32mp1 Changelog: Remark from Rob Herring Move Documentation/devicetree/bindings/arm/stm32.txt in Documentation/devicetree/bindings/arm/stm32/stm32.txt and create Documentation/devicetree/bindings/arm/stm32/stm32-syscon.txt Replace also in

[PATCH V4 6/8] net: stmmac: add dwmac-4.20a compatible

2018-05-23 Thread Christophe Roullier
Manage dwmac-4.20a version from synopsys Signed-off-by: Christophe Roullier --- drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c

[PATCH V4 5/8] ARM: dts: stm32: Add ethernet dwmac on stm32mp1

2018-05-23 Thread Christophe Roullier
Add Ethernet support (Synopsys MAC IP 4.20a) on stm32mp1 SOC. Enable feature supported by the stmmac driver, such as TSO. Signed-off-by: Christophe Roullier --- arch/arm/boot/dts/stm32mp157c.dtsi | 30 ++ 1 file changed, 30 insertions(+)

[PATCH V4 2/8] dt-bindings: stm32-dwmac: add support of MPU families

2018-05-23 Thread Christophe Roullier
Add description for Ethernet MPU families fields Signed-off-by: Christophe Roullier Reviewed-by: Rob Herring --- Documentation/devicetree/bindings/net/stm32-dwmac.txt | 18 -- 1 file changed, 16 insertions(+), 2 deletions(-) diff

[PATCH V4 1/8] net: ethernet: stmmac: add adaptation for stm32mp157c.

2018-05-23 Thread Christophe Roullier
Glue codes to support stm32mp157c device and stay compatible with stm32 mcu family Signed-off-by: Christophe Roullier --- drivers/net/ethernet/stmicro/stmmac/dwmac-stm32.c | 270 -- 1 file changed, 255 insertions(+), 15 deletions(-) diff --git

Re: [RFC PATCH 0/6] net: ethernet: ti: cpsw: add MQPRIO and CBS Qdisc offload

2018-05-23 Thread Grygorii Strashko
Hi Ivan, On 05/18/2018 04:15 PM, Ivan Khoronzhuk wrote: This series adds MQPRIO and CBS Qdisc offload for TI cpsw driver. It potentially can be used in audio video bridging (AVB) and time sensitive networking (TSN). Patchset was tested on AM572x EVM and BBB boards. Last patch from this series

Re: WARNING in ip_recv_error

2018-05-23 Thread Willem de Bruijn
On Sun, May 20, 2018 at 7:13 PM, Willem de Bruijn wrote: > On Fri, May 18, 2018 at 2:59 PM, Willem de Bruijn > wrote: >> On Fri, May 18, 2018 at 2:46 PM, Willem de Bruijn >> wrote: >>> On Fri, May

Re: [PATCH net-next v3 0/7] Add support for QCA8334 switch

2018-05-23 Thread Florian Fainelli
On 05/22/2018 11:20 PM, Michal Vokáč wrote: > This series basically adds support for a QCA8334 ethernet switch to the > qca8k driver. It is a four-port variant of the already supported seven > port QCA8337. Register map is the same for the whole familly and all chips > have the same device ID. >

Re: [PATCH net-next v3 2/7] net: dsa: qca8k: Add support for QCA8334 switch

2018-05-23 Thread Florian Fainelli
On 05/22/2018 11:20 PM, Michal Vokáč wrote: > Add support for the four-port variant of the Qualcomm QCA833x switch. > > Signed-off-by: Michal Vokáč > Reviewed-by: Andrew Lunn Reviewed-by: Florian Fainelli -- Florian

Re: [net-next 1/6] net/dcb: Add dcbnl buffer attribute

2018-05-23 Thread Huy Nguyen
On 5/23/2018 8:52 AM, John Fastabend wrote: It would be nice though if the API gave us some hint on max/min/stride of allowed values. Could the get API return these along with current value? Presumably the allowed max size could change with devlink buffer changes in how the global buffer is

Re: [PATCH net-next v3 1/7] net: dsa: qca8k: Add QCA8334 binding documentation

2018-05-23 Thread Florian Fainelli
On 05/22/2018 11:20 PM, Michal Vokáč wrote: > Add support for the four-port variant of the Qualcomm QCA833x switch. > > The CPU port default link settings can be reconfigured using > a fixed-link sub-node. > > Signed-off-by: Michal Vokáč > Reviewed-by: Rob Herring

RE: [PATCH v2] packet: track ring entry use using a shadow ring to prevent RX ring overrun

2018-05-23 Thread Jon Rosen (jrosen)
> -Original Message- > From: Willem de Bruijn [mailto:willemdebruijn.ker...@gmail.com] > Sent: Wednesday, May 23, 2018 9:37 AM > To: Jon Rosen (jrosen) > Cc: David S. Miller ; Willem de Bruijn > ; Eric Dumazet >

Re: [PATCH net-next] sfc: stop the TX queue before pushing new buffers

2018-05-23 Thread Edward Cree
On 23/05/18 10:41, Martin Habets wrote: > efx_enqueue_skb() can push new buffers for the xmit_more functionality. > We must stops the TX queue before this or else the TX queue does not get > restarted and we get a netdev watchdog. > > In the error handling we may now need to unwind more than 1

Re: [net-next 1/6] net/dcb: Add dcbnl buffer attribute

2018-05-23 Thread Huy Nguyen
On 5/23/2018 4:23 AM, Jakub Kicinski wrote: >From patch description it seems like your default setup is shared buffer split 50% (lossy)/50% (all prios) and the example you give changes that to 25% (lossy)/25%x3 prio groups. With existing devlink API could this be modelled by three ingress

Re: [bpf-next V4 PATCH 6/8] xdp: change ndo_xdp_xmit API to support bulking

2018-05-23 Thread Jesper Dangaard Brouer
On Wed, 23 May 2018 07:42:14 -0700 John Fastabend wrote: > On 05/18/2018 06:35 AM, Jesper Dangaard Brouer wrote: > [...] > > Couple suggestions for some optimizations/improvements but otherwise > looks good to me. > > Thanks, > John > [...] > > diff --git

Re: [net-next] i40iw/i40e: Remove link dependency on i40e

2018-05-23 Thread Jason Gunthorpe
On Wed, May 23, 2018 at 08:03:44AM -0700, Alexander Duyck wrote: > On Tue, May 22, 2018 at 11:19 PM, Christoph Hellwig > wrote: > > On Tue, May 22, 2018 at 02:04:06PM -0700, Jeff Kirsher wrote: > >> > Why would you want to do this? The rdma driver is non-functional > >> >

Re: [net-next 1/6] net/dcb: Add dcbnl buffer attribute

2018-05-23 Thread Huy Nguyen
I hope that is not true, since we (Netronome) are trying to use it for NIC configuration, too. We should generalize the API if need be. Yes, it is up to your company. devlink is static tool. DCBNL are intended to be dynamically configured by switch. In real world, not many people configure

Re: [bpf-next V4 PATCH 3/8] xdp: add tracepoint for devmap like cpumap have

2018-05-23 Thread Jesper Dangaard Brouer
On Wed, 23 May 2018 07:24:03 -0700 John Fastabend wrote: > > @@ -219,8 +221,8 @@ void __dev_map_insert_ctx(struct bpf_map *map, u32 bit) > > static int bq_xmit_all(struct bpf_dtab_netdev *obj, > > struct xdp_bulk_queue *bq) > > { > > - unsigned

Re: [net-next] i40iw/i40e: Remove link dependency on i40e

2018-05-23 Thread Alexander Duyck
On Tue, May 22, 2018 at 11:19 PM, Christoph Hellwig wrote: > On Tue, May 22, 2018 at 02:04:06PM -0700, Jeff Kirsher wrote: >> > Why would you want to do this? The rdma driver is non-functional >> > without the ethernet driver, so why on earth would we want to defeat >> > the

Re: [PATCH v2 net] stmmac: strip vlan tag on reception only for 8021q tagged frames

2018-05-23 Thread Elad Nachman
Jose, I am not sure which drivers you have checked. I guess most non-networking embedded drivers never use 802.1AD so they stay broken unknowingly. Specifically, I have tested Intel e1000e based card which works correctly versus stmmac which works incorrectly. If you check netdev.c in e1000e

Re: [PATCH V3 8/8] dt-bindings: stm32: add compatible for syscon

2018-05-23 Thread Rob Herring
On Wed, May 23, 2018 at 4:32 AM, Christophe ROULLIER wrote: > On 05/22/2018 07:22 PM, Rob Herring wrote: >> On Mon, May 21, 2018 at 10:07:26AM +0200, Christophe Roullier wrote: >>> This patch describes syscon DT bindings. >>> >>> Signed-off-by: Christophe Roullier

Re: [bpf-next V4 PATCH 6/8] xdp: change ndo_xdp_xmit API to support bulking

2018-05-23 Thread John Fastabend
On 05/18/2018 06:35 AM, Jesper Dangaard Brouer wrote: > This patch change the API for ndo_xdp_xmit to support bulking > xdp_frames. > > When kernel is compiled with CONFIG_RETPOLINE, XDP sees a huge slowdown. > Most of the slowdown is caused by DMA API indirect function calls, but > also the

[PATCH net-next 2/4] net/smc: lock smc_lgr_list in port_terminate()

2018-05-23 Thread Ursula Braun
From: Hans Wippel Currently, smc_port_terminate() is not holding the lock of the lgr list while it is traversing the list. This patch adds locking to this function and changes smc_lgr_terminate() accordingly. Signed-off-by: Hans Wippel

[PATCH net-next 3/4] net/smc: urgent data support

2018-05-23 Thread Ursula Braun
From: Stefan Raspl Add support for out of band data send and receive. Signed-off-by: Stefan Raspl Signed-off-by: Ursula Braun --- net/smc/af_smc.c | 24 ++- net/smc/smc.h | 15 +++ net/smc/smc_cdc.c | 44

[PATCH net-next 1/4] net/smc: return 0 for ioctl calls in states INIT and CLOSED

2018-05-23 Thread Ursula Braun
A connected SMC-socket contains addresses of descriptors for the send buffer and the rmb (receive buffer). Fields of these descriptors are used to determine the answer for certain ioctl requests. Add extra handling for unconnected SMC socket states without valid buffer descriptor addresses.

[PATCH net-next 4/4] net/smc: longer delay when freeing client link groups

2018-05-23 Thread Ursula Braun
Client link group creation always follows the server linkgroup creation. If peer creates a new server link group, client has to create a new client link group. If peer reuses a server link group for a new connection, client has to reuse its client link group as well. To avoid out-of-sync

[PATCH net-next 0/4] patches 2018-05-23

2018-05-23 Thread Ursula Braun
Dave, here are more smc-patches for net-next: Patch 1 fixes an ioctl problem detected by syzbot. Patch 2 improves smc_lgr_list locking in case of abnormal link group termination. If you want to receive a version for the net-tree, please let me know. It would look somewhat different, since the

[PATCH net-next 2/2] cxgb4: do L1 config when module is inserted

2018-05-23 Thread Ganesh Goudar
trigger an L1 configure operation when a transceiver module is inserted in order to cause current "sticky" options like Requested Forward Error Correction to be reapplied. Signed-off-by: Casey Leedom Signed-off-by: Ganesh Goudar ---

[PATCH net-next 1/2] cxgb4: change the port capability bits definition

2018-05-23 Thread Ganesh Goudar
MDI Port Capabilities bit definitions were inconsistent with regard to the MDI enum values. 2 bits used to define MDI in the port capabilities are not really separable, it's a 2-bit field with 4 different values. Change the port capability bit definitions to be "AUTO" and "STRAIGHT" in order to

Re: [bpf-next V4 PATCH 3/8] xdp: add tracepoint for devmap like cpumap have

2018-05-23 Thread John Fastabend
On 05/18/2018 06:34 AM, Jesper Dangaard Brouer wrote: > Notice how this allow us get XDP statistic without affecting the XDP > performance, as tracepoint is no-longer activated on a per packet basis. > > Signed-off-by: Jesper Dangaard Brouer > --- [...] > #include > diff

Re: [PATCH bpf-next v3 10/10] tools: bpftool: add delimiters to multi-function JITed dumps

2018-05-23 Thread Sandipan Das
On 05/23/2018 07:20 PM, Daniel Borkmann wrote: > On 05/23/2018 12:37 PM, Sandipan Das wrote: > [...] >> Other than that, for powerpc64, there is a problem with the way the >> binutils disassembler code (in "opcodes/ppc-dis.c") passes arguments >> to the callback fprintf_json(). >> >> In

Re: [PATCH] ppp: remove the PPPIOCDETACH ioctl

2018-05-23 Thread Guillaume Nault
On Tue, May 22, 2018 at 08:59:52PM -0700, Eric Biggers wrote: > From: Eric Biggers > > The PPPIOCDETACH ioctl effectively tries to "close" the given ppp file > before f_count has reached 0, which is fundamentally a bad idea. It > does check 'f_count < 2', which excludes

Re: [net-next 1/6] net/dcb: Add dcbnl buffer attribute

2018-05-23 Thread John Fastabend
On 05/23/2018 02:43 AM, Jiri Pirko wrote: > Tue, May 22, 2018 at 07:20:26AM CEST, jakub.kicin...@netronome.com wrote: >> On Mon, 21 May 2018 14:04:57 -0700, Saeed Mahameed wrote: >>> From: Huy Nguyen >>> >>> In this patch, we add dcbnl buffer attribute to allow user >>> change

Re: [PATCH bpf-next v3 10/10] tools: bpftool: add delimiters to multi-function JITed dumps

2018-05-23 Thread Daniel Borkmann
On 05/23/2018 12:37 PM, Sandipan Das wrote: [...] > Other than that, for powerpc64, there is a problem with the way the > binutils disassembler code (in "opcodes/ppc-dis.c") passes arguments > to the callback fprintf_json(). > > In fprintf_json(), we always expect the va_list elements to resolve

Re: [PATCH net-next] tipc: eliminate complaint of KMSAN uninit-value in tipc_conn_rcv_sub

2018-05-23 Thread Ying Xue
On 05/20/2018 11:00 AM, David Miller wrote: > From: Ying Xue > Date: Fri, 18 May 2018 19:50:55 +0800 > >> As variable s of struct tipc_subscr type is not initialized >> in tipc_conn_rcv_from_sock() before it is used in tipc_conn_rcv_sub(), >> KMSAN reported the following

Re: [PATCH v2] packet: track ring entry use using a shadow ring to prevent RX ring overrun

2018-05-23 Thread Willem de Bruijn
On Wed, May 23, 2018 at 7:54 AM, Jon Rosen (jrosen) wrote: >> > For the ring, there is no requirement to allocate exactly the amount >> > specified by the user request. Safer than relying on shared memory >> > and simpler than the extra allocation in this patch would be to

Re: KASAN: use-after-free Read in remove_wait_queue (2)

2018-05-23 Thread Guillaume Nault
On Tue, May 22, 2018 at 08:29:58PM -0700, Eric Biggers wrote: > On Fri, May 18, 2018 at 06:02:23PM +0200, Guillaume Nault wrote: > > On Sun, May 13, 2018 at 11:11:55PM -0700, Eric Biggers wrote: > > > [+ppp list and maintainer] > > > > > > This is a bug in ppp_generic.c; it still happens on

Re: Expected result when racing listen(2) on two sockets bound to the same address

2018-05-23 Thread Kirill Tkhai
Hi, On 23.05.2018 14:15, Alexander Kurtz wrote: > [Please keep me CC'ed; I'm not subscribed to the list] > > Hi! > > The program shown below (also available at [0]) does the following: > > * Create two sockets > * Enable SO_REUSEADDR on both > * Bind both sockets to [::1]:12345 > * Spawn

Re: [PATCH 1/1] selftests/bpf: Makefile fix "missing" headers on build with -idirafter

2018-05-23 Thread Daniel Borkmann
On 05/21/2018 09:00 AM, Sirio Balmelli wrote: > Selftests fail to build on several distros/architectures because of > missing headers files. > > On a Ubuntu/x86_64 some missing headers are: > asm/byteorder.h, asm/socket.h, asm/sockios.h > > On a Debian/arm32 build already fails at

Re: [PATCH v4 0/3] IR decoding using BPF

2018-05-23 Thread Daniel Borkmann
On 05/18/2018 04:07 PM, Sean Young wrote: > The kernel IR decoders (drivers/media/rc/ir-*-decoder.c) support the most > widely used IR protocols, but there are many protocols which are not > supported[1]. For example, the lirc-remotes[2] repo has over 2700 remotes, > many of which are not

[PATCH bpf-next v2 1/3] bpf: add ability to configure unprivileged BPF via boot-time parameter

2018-05-23 Thread Eugene Syromiatnikov
This patch introduces two configuration options, UNPRIVILEGED_BPF_BOOTPARAM and UNPRIVILEGED_BPF_BOOTPARAM_VALUE, that allow configuring the initial value of kernel.unprivileged_bpf_disabled sysctl knob, which is useful for the cases when disabling unprivileged bpf() access during the early boot

[PATCH bpf-next v2 0/3] bpf: add boot parameters for sysctl knobs

2018-05-23 Thread Eugene Syromiatnikov
Some BPF sysctl knobs affect the loading of BPF programs, and during system boot/init stages these sysctls are not yet configured. A concrete example is systemd, that has implemented loading of BPF programs. Thus, to allow controlling these setting at early boot, this patch set adds the ability

[PATCH bpf-next v2 2/3] bpf: add ability to configure BPF JIT hardening via boot-time parameter

2018-05-23 Thread Eugene Syromiatnikov
This patch introduces two configuration options, BPF_JIT_HARDEN_BOOTPARAM and BPF_JIT_HARDEN_BOOTPARAM_VALUE, that allow configuring the initial value of net.core.bpf_jit_harden sysctl knob, which is useful for enforcing JIT hardening during the early boot. Signed-off-by: Eugene Syromiatnikov

[PATCH bpf-next v2 3/3] bpf: add ability to configure BPF JIT kallsyms export at the boot time

2018-05-23 Thread Eugene Syromiatnikov
This patch introduces two configuration options, BPF_JIT_KALLSYMS_BOOTPARAM and BPF_JIT_KALLSYMS_BOOTPARAM_VALUE, that allow configuring the initial value of net.core.bpf_jit_kallsyms sysctl knob. This enables export of addresses of JIT'ed BPF programs that created during the early boot.

pull-request: mac80211-next 2018-05-23

2018-05-23 Thread Johannes Berg
Hi Dave, Here's a new version of the pull request for net-next, now with the stack size fixes included, which were the reason I withdrew my earlier one. Other things are also included all over the map. Please pull and let me know if there's any problem. Thanks, johannes The following changes

[PATCH net-next] ixgbe: introduce a helper to simplify code

2018-05-23 Thread YueHaibing
ixgbe_dbg_reg_ops_read and ixgbe_dbg_netdev_ops_read copy-pasting the same code except for ixgbe_dbg_netdev_ops_buf/ixgbe_dbg_reg_ops_buf, so introduce a helper ixgbe_dbg_common_ops_read to remove redundant code. Signed-off-by: YueHaibing ---

Re: [PATCH 0/3] bpf: add boot parameters for sysctl knobs

2018-05-23 Thread Jesper Dangaard Brouer
On Wed, 23 May 2018 13:35:47 +0200 Eugene Syromiatnikov wrote: > On Mon, May 21, 2018 at 11:58:13AM -0700, Alexei Starovoitov wrote: > > On Mon, May 21, 2018 at 02:29:30PM +0200, Eugene Syromiatnikov wrote: > > > Hello. > > > > > > This patch set adds ability to set default

RE: [PATCH v2] packet: track ring entry use using a shadow ring to prevent RX ring overrun

2018-05-23 Thread Jon Rosen (jrosen)
> > For the ring, there is no requirement to allocate exactly the amount > > specified by the user request. Safer than relying on shared memory > > and simpler than the extra allocation in this patch would be to allocate > > extra shadow memory at the end of the ring (and not mmap that). > > > >

Re: [PATCH 0/3] bpf: add boot parameters for sysctl knobs

2018-05-23 Thread Eugene Syromiatnikov
On Mon, May 21, 2018 at 11:58:13AM -0700, Alexei Starovoitov wrote: > On Mon, May 21, 2018 at 02:29:30PM +0200, Eugene Syromiatnikov wrote: > > Hello. > > > > This patch set adds ability to set default values for > > kernel.unprivileged_bpf_disable, net.core.bpf_jit_harden, > >

Re: [PATCH v2 1/1] drivers core: multi-threading device shutdown

2018-05-23 Thread Pavel Tatashin
Hi Pavel, Thank you for looking at this patch. BTW, the version 5 is out. The latest thread is anchered here: http://lkml.kernel.org/r/20180516024004.28977-1-pasha.tatas...@oracle.com > ixgbe is network card, right? So ... it does not have any persistent > state and no moving parts, and there's

Re: [bpf-next V4 PATCH 1/8] bpf: devmap introduce dev_map_enqueue

2018-05-23 Thread Jesper Dangaard Brouer
On Wed, 23 May 2018 11:34:22 +0200 Daniel Borkmann wrote: > > +int dev_map_enqueue(struct bpf_dtab_netdev *dst, struct xdp_buff *xdp) > > +{ > > + struct net_device *dev = dst->dev; > > + struct xdp_frame *xdpf; > > + int err; > > + > > + if

<    1   2   3   4   >