[PATCH net-next v5] net: stmmac: Delete dead code for MDIO registration

2017-08-24 Thread Romain Perier
This code is no longer used, the logging function was changed by commit fbca164776e4 ("net: stmmac: Use the right logging function in stmmac_mdio_register"). It was previously showing information about the type of the IRQ, if it's polled, ignored or a normal interrupt. As we don't want information

RE: [PATCH v3 0/7] Add RSS to DPAA 1.x Ethernet driver

2017-08-24 Thread Madalin-cristian Bucur
> -Original Message- > From: David Miller [mailto:da...@davemloft.net] > Subject: Re: [PATCH v3 0/7] Add RSS to DPAA 1.x Ethernet driver > > From: David Miller > Date: Thu, 24 Aug 2017 09:42:20 -0700 (PDT) > > > From: Madalin Bucur > > Date: Thu, 24 Aug 2017 10:28:21 +0300 > > > >> This

[PATCH] net: sxgbe: check memory allocation failure

2017-08-24 Thread Christophe JAILLET
Check memory allocation failure and return -ENOMEM in such a case, as already done few lines below for another memory allocation. Signed-off-by: Christophe JAILLET --- drivers/net/ethernet/samsung/sxgbe/sxgbe_platform.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/net/ethernet/s

Re: nf_nat_pptp 4.12.3 kernel lockup/reboot

2017-08-24 Thread Florian Westphal
Denys Fedoryshchenko wrote: > >>> I am trying to upgrade kernel 4.11.8 to 4.12.3 (it is a nat/router, > >>> handling > >>> approx 2gbps of pppoe users traffic) and noticed that after while server > >>> rebooting(i have set reboot on panic and etc). > >>> I can't run serial console, and in pstore

Re: [PATCH net] net: xfrm: don't double-hold dst when sk_policy in use.

2017-08-24 Thread Steffen Klassert
On Wed, Aug 23, 2017 at 05:14:39PM +0900, Lorenzo Colitti wrote: > While removing dst_entry garbage collection, commit 52df157f17e5 > ("xfrm: take refcnt of dst when creating struct xfrm_dst bundle") > changed xfrm_resolve_and_create_bundle so it returns an xdst with > a refcount of 1 instead of 0.

Re: [PATCH] netvsc: fix deadlock betwen link status and removal

2017-08-24 Thread David Miller
From: Stephen Hemminger Date: Thu, 24 Aug 2017 16:49:16 -0700 > There is a deadlock possible when canceling the link status > delayed work queue. The removal process is run with RTNL held, > and the link status callback is acquring RTNL. > > Resolve the issue by using trylock and rescheduling. >

Re: [PATCH net-next] hv_netvsc: Fix rndis_filter_close error during netvsc_remove

2017-08-24 Thread David Miller
From: Haiyang Zhang Date: Thu, 24 Aug 2017 11:50:02 -0700 > From: Haiyang Zhang > > We now remove rndis filter before unregister_netdev(), which calls > device close. It involves closing rndis filter already removed. > > This patch fixes this error. > > Signed-off-by: Haiyang Zhang Applied.

Re: [PATCH] strparser: initialize all callbacks

2017-08-24 Thread David Miller
From: Eric Biggers Date: Thu, 24 Aug 2017 14:38:51 -0700 > From: Eric Biggers > > commit bbb03029a899 ("strparser: Generalize strparser") added more > function pointers to 'struct strp_callbacks'; however, kcm_attach() was > not updated to initialize them. This could cause the ->lock() and/or

Re: [PATCH net v1 0/3] tipc: buffer reassignment fixes

2017-08-24 Thread David Miller
From: Parthasarathy Bhuvaragan Date: Thu, 24 Aug 2017 16:31:21 +0200 > This series contains fixes for buffer reassignments and a context > imbalance. Series applied, thanks.

Re: [pull request][net-next 0/8] Mellanox, mlx5updates 2017-08-24

2017-08-24 Thread David Miller
From: Saeed Mahameed Date: Thu, 24 Aug 2017 16:21:44 +0300 > The following changes provide updates to mlx5 core driver. > > For more details please see tag log message below. > Please pull and let me know if there's any problem. Pulled, thanks Saeed.

Re: [PATCH net-next] hinic: uninitialized variable in hinic_api_cmd_init()

2017-08-24 Thread David Miller
From: Dan Carpenter Date: Thu, 24 Aug 2017 13:47:39 +0300 > We never set the error code in this function. > > Fixes: eabf0fad81d5 ("net-next/hinic: Initialize api cmd resources") > Signed-off-by: Dan Carpenter Applied, thanks.

Re: [PATCH net-next 0/4] net: mvpp2: fix the mac address retrieval logic

2017-08-24 Thread David Miller
From: Antoine Tenart Date: Thu, 24 Aug 2017 11:46:54 +0200 > The MAC address retrieval logic was broken and when using the PPv2 > driver on PPv2.2 engines I ended up using the same mac address on all > ports. This series of patches fixes this, and also tackle a possible bug > when defining the ma

[PATCH net-next 2/3 v9] net: arp: Add support for raw IP device

2017-08-24 Thread Subash Abhinov Kasiviswanathan
Define the raw IP type. This is needed for raw IP net devices like rmnet. Signed-off-by: Subash Abhinov Kasiviswanathan --- include/uapi/linux/if_arp.h | 1 + 1 file changed, 1 insertion(+) diff --git a/include/uapi/linux/if_arp.h b/include/uapi/linux/if_arp.h index cf73510..a2a6356 100644 ---

[PATCH net-next 3/3 v9] drivers: net: ethernet: qualcomm: rmnet: Initial implementation

2017-08-24 Thread Subash Abhinov Kasiviswanathan
RmNet driver provides a transport agnostic MAP (multiplexing and aggregation protocol) support in embedded module. Module provides virtual network devices which can be attached to any IP-mode physical device. This will be used to provide all MAP functionality on future hardware in a single consiste

[PATCH net-next 1/3 v9] net: ether: Add support for multiplexing and aggregation type

2017-08-24 Thread Subash Abhinov Kasiviswanathan
Define the multiplexing and aggregation (MAP) ether type 0x00F9. This is needed for receiving data in the MAP protocol like RMNET. This is not an officially registered ID. Signed-off-by: Subash Abhinov Kasiviswanathan --- include/uapi/linux/if_ether.h | 1 + 1 file changed, 1 insertion(+) diff

[PATCH net-next 0/3 v9] Add support for rmnet driver

2017-08-24 Thread Subash Abhinov Kasiviswanathan
This patch adds support for the rmnet driver which is required to support recent chipsets using Qualcomm Technologies, Inc. modems. The data from hardware follows the multiplexing and aggregation protocol (MAP). This driver can be used to register onto any physical network device in IP mode. Physi

Re: [PATCH net-next v2] net: mv643xx_eth: Be drop monitor friendly

2017-08-24 Thread Eric Dumazet
On Thu, 2017-08-24 at 20:55 -0700, Florian Fainelli wrote: > txq_reclaim() does the normal transmit queue reclamation and > rxq_deinit() does the RX ring cleanup, none of these are packet drops, > so use dev_consume_skb() for both locations. > > Signed-off-by: Florian Fainelli > --- > drivers/ne

Re: [PATCH net] net_sched: fix a refcount_t issue with noop_qdisc

2017-08-24 Thread David Miller
From: Eric Dumazet Date: Thu, 24 Aug 2017 21:12:28 -0700 > From: Eric Dumazet > > syzkaller reported a refcount_t warning [1] > > Issue here is that noop_qdisc refcnt was never really considered as > a true refcount, since qdisc_destroy() found TCQ_F_BUILTIN set : > > if (qdisc->flags & TCQ_F

[PATCH net-next 1/2] nfp: add basic SR-IOV ndo functions

2017-08-24 Thread Jakub Kicinski
From: Pablo Cascón Add basic ndo_set/get_vf to support SR-IOV. VF to egress phy static mapping by now. Use vfcfg ABI version 2 to write the info to the FW and collect the return value from the mailbox. Signed-off-by: Pablo Cascón Signed-off-by: Jimmy Kizito Signed-off-by: Rami Tomer Signed-

[PATCH net-next 0/2] nfp: SR-IOV ndos support

2017-08-24 Thread Jakub Kicinski
Hi! This set adds basic SR-IOV including setting/getting VF MAC addresses, VLANs, link state and spoofcheck settings. It is wired up for both vNICs and representors (note: ip link will not report VF settings on VF/PF representors because they are not linked to the PF PCI device). Pablo and team

[PATCH net-next 2/2] nfp: add basic SR-IOV ndo functions to representors

2017-08-24 Thread Jakub Kicinski
From: Simon Horman Add basic ndo_set/get_vf to support SR-IOV on all types of port representors. Signed-off-by: Simon Horman Signed-off-by: Dirk van der Merwe Reviewed-by: Jakub Kicinski --- drivers/net/ethernet/netronome/nfp/nfp_net_repr.c | 6 ++ 1 file changed, 6 insertions(+) diff -

Re: [PATCH net-next v2] e1000e: Be drop monitor friendly

2017-08-24 Thread David Miller
From: Florian Fainelli Date: Thu, 24 Aug 2017 20:58:24 -0700 > e1000_put_txbuf() cleans up the successfully transmitted TX packets, > e1000e_tx_hwtstamp_work() also does the successfully completes the > timestamped TX packets, e1000_clean_rx_ring() cleans up the RX ring and > e1000_remove() clean

Re: [PATCH net-next v2] net: mv643xx_eth: Be drop monitor friendly

2017-08-24 Thread David Miller
From: Florian Fainelli Date: Thu, 24 Aug 2017 20:55:40 -0700 > txq_reclaim() does the normal transmit queue reclamation and > rxq_deinit() does the RX ring cleanup, none of these are packet drops, > so use dev_consume_skb() for both locations. > > Signed-off-by: Florian Fainelli Applied.

[PATCH net] net_sched: fix a refcount_t issue with noop_qdisc

2017-08-24 Thread Eric Dumazet
From: Eric Dumazet syzkaller reported a refcount_t warning [1] Issue here is that noop_qdisc refcnt was never really considered as a true refcount, since qdisc_destroy() found TCQ_F_BUILTIN set : if (qdisc->flags & TCQ_F_BUILTIN || !refcount_dec_and_test(&qdisc->refcnt))) return; M

Re: [PATCH v3 3/4] net: stmmac: register parent MDIO node for sun8i-h3-emac

2017-08-24 Thread Florian Fainelli
On 08/24/2017 08:41 PM, Chen-Yu Tsai wrote: > On Fri, Aug 25, 2017 at 11:05 AM, Florian Fainelli > wrote: >> >> >> On 08/24/2017 07:54 PM, Chen-Yu Tsai wrote: >>> On Fri, Aug 25, 2017 at 3:59 AM, Florian Fainelli >>> wrote: On 08/24/2017 01:21 AM, Corentin Labbe wrote: > On Wed, Aug

[PATCH net-next v2] e1000e: Be drop monitor friendly

2017-08-24 Thread Florian Fainelli
e1000_put_txbuf() cleans up the successfully transmitted TX packets, e1000e_tx_hwtstamp_work() also does the successfully completes the timestamped TX packets, e1000_clean_rx_ring() cleans up the RX ring and e1000_remove() cleans up the timestampted packets. None of these functions should be report

[PATCH net-next v2] net: mv643xx_eth: Be drop monitor friendly

2017-08-24 Thread Florian Fainelli
txq_reclaim() does the normal transmit queue reclamation and rxq_deinit() does the RX ring cleanup, none of these are packet drops, so use dev_consume_skb() for both locations. Signed-off-by: Florian Fainelli --- drivers/net/ethernet/marvell/mv643xx_eth.c | 4 ++-- 1 file changed, 2 insertions(+

Re: [PATCH v3 3/4] net: stmmac: register parent MDIO node for sun8i-h3-emac

2017-08-24 Thread Chen-Yu Tsai
On Fri, Aug 25, 2017 at 11:05 AM, Florian Fainelli wrote: > > > On 08/24/2017 07:54 PM, Chen-Yu Tsai wrote: >> On Fri, Aug 25, 2017 at 3:59 AM, Florian Fainelli >> wrote: >>> On 08/24/2017 01:21 AM, Corentin Labbe wrote: On Wed, Aug 23, 2017 at 09:31:53AM -0700, Florian Fainelli wrote:

Re: XDP redirect measurements, gotchas and tracepoints

2017-08-24 Thread Michael Chan
On Wed, Aug 23, 2017 at 1:29 AM, Jesper Dangaard Brouer wrote: > On Tue, 22 Aug 2017 23:59:05 -0700 > Michael Chan wrote: > >> On Tue, Aug 22, 2017 at 6:06 PM, Alexander Duyck >> wrote: >> > On Tue, Aug 22, 2017 at 1:04 PM, Michael Chan >> > wrote: >> >> >> >> Right, but it's conceivable to ad

RE: [PATCH v2 net-next 1/1] hv_sock: implements Hyper-V transport for Virtual Sockets (AF_VSOCK)

2017-08-24 Thread Dexuan Cui
> From: David Miller [mailto:da...@davemloft.net] > Sent: Thursday, August 24, 2017 18:20 > > +#define VMBUS_PKT_TRAILER (sizeof(u64)) > > This is not the packet trailer, it's the size of the packet trailer. Thanks! I'll change it to VMBUS_PKT_TRAILER_SIZE. > > + /* Have we sent the zero-lengt

Re: [PATCH net-next] e1000e: Be drop monitor friendly

2017-08-24 Thread Florian Fainelli
On 08/24/2017 06:36 PM, Florian Fainelli wrote: > e1000_put_txbuf() cleans up the successfully transmitted TX packets, > e1000e_tx_hwtstamp_work() also does the successfully completes the > timestamped TX packets, e1000_clean_rx_ring() cleans up the RX ring and > e1000_remove() cleans up the time

Re: [PATCH v3 3/4] net: stmmac: register parent MDIO node for sun8i-h3-emac

2017-08-24 Thread Florian Fainelli
On 08/24/2017 07:54 PM, Chen-Yu Tsai wrote: > On Fri, Aug 25, 2017 at 3:59 AM, Florian Fainelli > wrote: >> On 08/24/2017 01:21 AM, Corentin Labbe wrote: >>> On Wed, Aug 23, 2017 at 09:31:53AM -0700, Florian Fainelli wrote: On 08/23/2017 12:49 AM, Maxime Ripard wrote: > Hi Florian, >>>

Re: nf_nat_pptp 4.12.3 kernel lockup/reboot

2017-08-24 Thread Denys Fedoryshchenko
On 2017-07-24 19:20, Florian Westphal wrote: Florian Westphal wrote: Denys Fedoryshchenko wrote: > Hi, > > I am trying to upgrade kernel 4.11.8 to 4.12.3 (it is a nat/router, handling > approx 2gbps of pppoe users traffic) and noticed that after while server > rebooting(i have set reboot on pa

Re: [PATCH v3 3/4] net: stmmac: register parent MDIO node for sun8i-h3-emac

2017-08-24 Thread Chen-Yu Tsai
On Fri, Aug 25, 2017 at 3:59 AM, Florian Fainelli wrote: > On 08/24/2017 01:21 AM, Corentin Labbe wrote: >> On Wed, Aug 23, 2017 at 09:31:53AM -0700, Florian Fainelli wrote: >>> On 08/23/2017 12:49 AM, Maxime Ripard wrote: Hi Florian, On Tue, Aug 22, 2017 at 11:35:01AM -0700, Floria

[PATCH] pktgen: add a new sample script for 40G and above link testing

2017-08-24 Thread Robert Hoo
From: Robert Ho It's hard to benchmark 40G+ network bandwidth using ordinary tools like iperf, netperf. I then tried with pktgen multiqueue sample scripts, but still cannot reach line rate. I then derived this NUMA awared irq affinity sample script from multi-queue sample one, successfully benchm

Re: [PATCH] staging: rtlwifi: Improve debugging by using debugfs

2017-08-24 Thread Andrew Lunn
On Thu, Aug 24, 2017 at 04:28:08PM -0500, Larry Finger wrote: > The changes in this commit are also being sent to the main rtlwifi > drivers in wireless-next; however, these changes will also be useful for > any debugging of r8822be before it gets moved into the main tree. > > Use debugfs to dump

Re: [PATCH net-next] net: mv643xx_eth: Be drop monitor friendly

2017-08-24 Thread David Miller
From: David Miller Date: Thu, 24 Aug 2017 18:27:56 -0700 (PDT) > From: Florian Fainelli > Date: Thu, 24 Aug 2017 16:04:25 -0700 > >> txq_reclaim() does the normal transmit queue reclamation and >> rxq_deinit() does the RX ring cleanup, none of these are packet drops, >> so use dev_consume_skb()

[PATCH net-next] e1000e: Be drop monitor friendly

2017-08-24 Thread Florian Fainelli
e1000_put_txbuf() cleans up the successfully transmitted TX packets, e1000e_tx_hwtstamp_work() also does the successfully completes the timestamped TX packets, e1000_clean_rx_ring() cleans up the RX ring and e1000_remove() cleans up the timestampted packets. None of these functions should be report

[PATCH net 0/2] r8169: Be drop monitor friendly

2017-08-24 Thread Florian Fainelli
Hi all, First patch may be questionable but no other driver appears to be doing that and while it is defendable to account for left packets as dropped during TX clean, this appears misleadning. I picked Stanislaw changes which brings us back to 2010, but this was present from pre-git days as well.

[PATCH net 2/2] r8169: Be drop monitor friendly

2017-08-24 Thread Florian Fainelli
rtl_tx() is the TX reclamation process whereas rtl8169_tx_clear_range() does the TX ring cleaning during shutdown, both of these functions should call dev_consume_skb_any() to be drop monitor friendly. Fixes: cac4b22f3d6a ("r8169: do not account fragments as packets") Fixes: eb781397904e ("r8169:

[PATCH net 1/2] r8169: Do not increment tx_dropped in TX ring cleaning

2017-08-24 Thread Florian Fainelli
rtl8169_tx_clear_range() is responsible for cleaning up the TX ring during interface shutdown, incrementing tx_dropped for every SKB that we left at the time in the ring is misleading. Fixes: cac4b22f3d6a ("r8169: do not account fragments as packets") Signed-off-by: Florian Fainelli --- drivers/

[PATCH net 0/2] r8169: Be drop monitor friendly

2017-08-24 Thread Florian Fainelli
Hi all, First patch may be questionable but no other driver appears to be doing that and while it is defendable to account for left packets as dropped during TX clean, this appears misleadning. I picked Stanislaw changes which brings us back to 2010, but this was present from pre-git days as well.

RE: Question about ip_defrag

2017-08-24 Thread liujian (CE)
> -Original Message- > From: Jesper Dangaard Brouer [mailto:bro...@redhat.com] > Sent: Friday, August 25, 2017 2:59 AM > To: liujian (CE) > Cc: da...@davemloft.net; kuz...@ms2.inr.ac.ru; yoshf...@linux-ipv6.org; > elena.reshet...@intel.com; eduma...@google.com; netdev@vger.kernel.org; > br

Re: [PATCH net-next] net: mv643xx_eth: Be drop monitor friendly

2017-08-24 Thread David Miller
From: Florian Fainelli Date: Thu, 24 Aug 2017 16:04:25 -0700 > txq_reclaim() does the normal transmit queue reclamation and > rxq_deinit() does the RX ring cleanup, none of these are packet drops, > so use dev_consume_skb() for both locations. > > Signed-off-by: Florian Fainelli Applied.

Re: [PATCH net-next v2] tg3: Be drop monitor friendly

2017-08-24 Thread David Miller
From: Florian Fainelli Date: Thu, 24 Aug 2017 17:47:11 -0700 > tg3_tx() does the normal packet TX completion, > tigon3_dma_hwbug_workaround() and tg3_tso_bug() both need to allocate a > new SKB that is suitable to workaround HW bugs, and finally > tg3_free_rings() is doing ring cleanup. Use dev_c

Re: [PATCH net] net: systemport: Free DMA coherent descriptors on errors

2017-08-24 Thread David Miller
From: Florian Fainelli Date: Thu, 24 Aug 2017 16:01:13 -0700 > In case bcm_sysport_init_tx_ring() is not able to allocate ring->cbs, we > would return with an error, and call bcm_sysport_fini_tx_ring() and it > would see that ring->cbs is NULL and do nothing. This would leak the > coherent DMA de

Re: [PATCH net] net: bcmgenet: Be drop monitor friendly

2017-08-24 Thread David Miller
From: Florian Fainelli Date: Thu, 24 Aug 2017 15:56:29 -0700 > There are 3 spots where we call dev_kfree_skb() but we are actually > just doing a normal SKB consumption: __bcmgenet_tx_reclaim() for normal > TX reclamation, bcmgenet_alloc_rx_buffers() during the initial RX ring > setup and bcmgene

Re: [PATCH net] bpf: fix bpf_setsockopts return value

2017-08-24 Thread David Miller
From: Yuchung Cheng Date: Thu, 24 Aug 2017 15:48:21 -0700 > This patch fixes a bug causing any sock operations to always return EINVAL. > > Fixes: a5192c52377e ("bpf: fix to bpf_setsockops"). > Reported-by: Neal Cardwell > Signed-off-by: Yuchung Cheng > Acked-by: Neal Cardwell > Acked-by: Cra

Re: [PATCH net] net: systemport: Be drop monitor friendly

2017-08-24 Thread David Miller
From: Florian Fainelli Date: Thu, 24 Aug 2017 15:20:41 -0700 > Utilize dev_consume_skb_any(cb->skb) in bcm_sysport_free_cb() which is > used when a TX packet is completed, as well as when the RX ring is > cleaned on shutdown. None of these two cases are packet drops, so be > drop monitor friendly

Re: [PATCH net-next v3 0/4] Route ICMPv6 errors with the flow when ECMP in use

2017-08-24 Thread David Miller
From: Jakub Sitnicki Date: Wed, 23 Aug 2017 09:58:27 +0200 > This patch set is another take at making Path MTU Discovery work when > server nodes are behind a router employing multipath routing in a > load-balance or anycast setup (that is, when not every end-node can be > reached by every path).

Re: [PATCH v2 net-next 1/1] hv_sock: implements Hyper-V transport for Virtual Sockets (AF_VSOCK)

2017-08-24 Thread David Miller
From: Dexuan Cui Date: Wed, 23 Aug 2017 04:52:14 + > +#define VMBUS_PKT_TRAILER(sizeof(u64)) This is not the packet trailer, it's the size of the packet trailer. Please make this macro name match more accurately what it is. > + /* Have we sent the zero-length packet (FIN)? */ > +

Re: [net-next:master 1328/1341] drivers/net/ethernet/mellanox/mlxsw/spectrum_dpipe.c:77:3: error: 'devlink_dpipe_header_ethernet' undeclared here (not in a function)

2017-08-24 Thread David Miller
From: kbuild test robot Date: Fri, 25 Aug 2017 08:16:01 +0800 > All error/warnings (new ones prefixed by >>): > >>> drivers/net/ethernet/mellanox/mlxsw/spectrum_dpipe.c:77:3: error: >>> 'devlink_dpipe_header_ethernet' undeclared here (not in a function) > &devlink_dpipe_header_ethernet, >

Re: [net-next:master 1324/1341] drivers/net//ethernet/mellanox/mlxsw/spectrum_dpipe.c:323:9: error: too few arguments to function 'devlink_dpipe_table_register'

2017-08-24 Thread David Miller
From: kbuild test robot Date: Fri, 25 Aug 2017 08:03:28 +0800 > All errors (new ones prefixed by >>): > >drivers/net//ethernet/mellanox/mlxsw/spectrum_dpipe.c: In function > 'mlxsw_sp_dpipe_erif_table_init': >>> drivers/net//ethernet/mellanox/mlxsw/spectrum_dpipe.c:323:9: error: too few >>

Re: [PATCH net-next] ipv6: Add sysctl for per namespace flow label reflection

2017-08-24 Thread David Miller
From: Jakub Sitnicki Date: Wed, 23 Aug 2017 09:55:41 +0200 > Reflecting IPv6 Flow Label at server nodes is useful in environments > that employ multipath routing to load balance the requests. As "IPv6 > Flow Label Reflection" standard draft [1] points out - ICMPv6 PTB error > messages generated i

Re: [PATCH net-next v2] tg3: Be drop monitor friendly

2017-08-24 Thread Michael Chan
On Thu, Aug 24, 2017 at 5:47 PM, Florian Fainelli wrote: > tg3_tx() does the normal packet TX completion, > tigon3_dma_hwbug_workaround() and tg3_tso_bug() both need to allocate a > new SKB that is suitable to workaround HW bugs, and finally > tg3_free_rings() is doing ring cleanup. Use dev_consum

[PATCH net-next v2] tg3: Be drop monitor friendly

2017-08-24 Thread Florian Fainelli
tg3_tx() does the normal packet TX completion, tigon3_dma_hwbug_workaround() and tg3_tso_bug() both need to allocate a new SKB that is suitable to workaround HW bugs, and finally tg3_free_rings() is doing ring cleanup. Use dev_consume_skb_any() for these 3 locations to be SKB drop monitor friendly.

Re: [PATCH net-next] tg3: Be drop monitor friendly

2017-08-24 Thread Florian Fainelli
On 08/24/2017 05:04 PM, Michael Chan wrote: > On Thu, Aug 24, 2017 at 4:25 PM, Florian Fainelli > wrote: >> >> tg3_tx() does the normal packet TX completion, >> tigon3_dma_hwbug_workaround() needs to allocate a new SKB that is >> suitable for the DMA hardware bug, and

[net-next:master 1328/1341] drivers/net/ethernet/mellanox/mlxsw/spectrum_dpipe.c:77:3: error: 'devlink_dpipe_header_ethernet' undeclared here (not in a function)

2017-08-24 Thread kbuild test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next.git master head: 39a7e5892418514db114ea4842d7d88aee6a61b8 commit: 6aecb36bc01fc9c84f24c4155e8850b6a1962f03 [1328/1341] mlxsw: spectrum_dpipe: Add IPv4 host table initial support config: i386-randconfig-sb0-08250550 (attached

[net-next:master 1324/1341] drivers/net//ethernet/mellanox/mlxsw/spectrum_dpipe.c:323:9: error: too few arguments to function 'devlink_dpipe_table_register'

2017-08-24 Thread kbuild test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next.git master head: 39a7e5892418514db114ea4842d7d88aee6a61b8 commit: ffd3cdccf214cf0df08856a6738544076c4cd548 [1324/1341] devlink: Add support for dynamic table size config: i386-randconfig-sb0-08250550 (attached as .config) co

[Patch net-next v2 3/4] net_sched: remove tc class reference counting

2017-08-24 Thread Cong Wang
For TC classes, their ->get() and ->put() are always paired, and the reference counting is completely useless, because: 1) For class modification and dumping paths, we already hold RTNL lock, so all of these ->get(),->change(),->put() are atomic. 2) For filter bindiing/unbinding, we use other

[Patch net-next v2 2/4] net_sched: introduce tclass_del_notify()

2017-08-24 Thread Cong Wang
Like for TC actions, ->delete() is a special case, we have to prepare and fill the notification before delete otherwise would get use-after-free after we remove the reference count. Signed-off-by: Cong Wang --- net/sched/sch_api.c | 39 +-- 1 file changed, 33

[Patch net-next v2 1/4] net_sched: get rid of more forward declarations

2017-08-24 Thread Cong Wang
This is not needed if we move them up properly. Signed-off-by: Cong Wang --- net/sched/sch_api.c | 348 +--- 1 file changed, 169 insertions(+), 179 deletions(-) diff --git a/net/sched/sch_api.c b/net/sched/sch_api.c index aaf552b8e120..330ffaea997

[Patch net-next v2 4/4] net_sched: kill u32_node pointer in Qdisc

2017-08-24 Thread Cong Wang
It is ugly to hide a u32-filter-specific pointer inside Qdisc, this breaks the TC layers: 1. Qdisc is a generic representation, should not have any specific data of any type 2. Qdisc layer is above filter layer, should only save filters in the list of struct tcf_proto. This pointer is used

[Patch net-next v2 0/4] net_sched: clean up tc classes and u32 filter

2017-08-24 Thread Cong Wang
Patch 1 and patch 2 prepare for patch 3. Major changes are in patch 3 and patch 4, details are there too. Cong Wang (4): net_sched: get rid of more forward declarations net_sched: introduce tclass_del_notify() net_sched: remove tc class reference counting net_sched: kill u32_node pointer i

[PATCH] netvsc: fix deadlock betwen link status and removal

2017-08-24 Thread Stephen Hemminger
There is a deadlock possible when canceling the link status delayed work queue. The removal process is run with RTNL held, and the link status callback is acquring RTNL. Resolve the issue by using trylock and rescheduling. If cancel is in process, that block it from happening. Fixes: 122a5f6410f4

Re: [PATCH net] bpf: fix bpf_setsockopts return value

2017-08-24 Thread Lawrence Brakmo
On 8/24/17, 4:37 PM, "Daniel Borkmann" wrote: On 08/25/2017 12:48 AM, Yuchung Cheng wrote: > This patch fixes a bug causing any sock operations to always return EINVAL. > > Fixes: a5192c52377e ("bpf: fix to bpf_setsockops"). > Reported-by: Neal Cardwell > Signed-off-by

Re: [PATCH net] bpf: fix bpf_setsockopts return value

2017-08-24 Thread Daniel Borkmann
On 08/25/2017 12:48 AM, Yuchung Cheng wrote: This patch fixes a bug causing any sock operations to always return EINVAL. Fixes: a5192c52377e ("bpf: fix to bpf_setsockops"). Reported-by: Neal Cardwell Signed-off-by: Yuchung Cheng Acked-by: Neal Cardwell Acked-by: Craig Gallek Ohh well, than

[PATCH net-next] tg3: Be drop monitor friendly

2017-08-24 Thread Florian Fainelli
tg3_tx() does the normal packet TX completion, tigon3_dma_hwbug_workaround() needs to allocate a new SKB that is suitable for the DMA hardware bug, and finally tg3_free_rings() is doing ring cleanup. Use dev_consume_skb_any() for these 3 locations to be SKB drop monitor friendly. Signed-off-by: Fl

Re: [PATCH] isdn: hisax: fix buffer overflow check

2017-08-24 Thread Arnd Bergmann
On Fri, Aug 25, 2017 at 12:58 AM, Arnd Bergmann wrote: > gcc-8 warns about a corner case that can overflow a memcpy buffer when a > length variable is negative. While the code checks for an overly large > value, it does not check for a negative length that would get turned > into a large positive

[PATCH net-next] net: mv643xx_eth: Be drop monitor friendly

2017-08-24 Thread Florian Fainelli
txq_reclaim() does the normal transmit queue reclamation and rxq_deinit() does the RX ring cleanup, none of these are packet drops, so use dev_consume_skb() for both locations. Signed-off-by: Florian Fainelli --- drivers/net/ethernet/marvell/mv643xx_eth.c | 4 ++-- 1 file changed, 2 insertions(+

[PATCH net] net: systemport: Free DMA coherent descriptors on errors

2017-08-24 Thread Florian Fainelli
In case bcm_sysport_init_tx_ring() is not able to allocate ring->cbs, we would return with an error, and call bcm_sysport_fini_tx_ring() and it would see that ring->cbs is NULL and do nothing. This would leak the coherent DMA descriptor area, so we need to free it on error before returning. Report

[PATCH] isdn: hisax: fix buffer overflow check

2017-08-24 Thread Arnd Bergmann
gcc-8 warns about a corner case that can overflow a memcpy buffer when a length variable is negative. While the code checks for an overly large value, it does not check for a negative length that would get turned into a large positive number: In function 'memcpy', inlined from 'skb_put_data' a

[PATCH net] net: bcmgenet: Be drop monitor friendly

2017-08-24 Thread Florian Fainelli
There are 3 spots where we call dev_kfree_skb() but we are actually just doing a normal SKB consumption: __bcmgenet_tx_reclaim() for normal TX reclamation, bcmgenet_alloc_rx_buffers() during the initial RX ring setup and bcmgenet_free_rx_buffers() during RX ring cleanup. Fixes: d6707bec5986 ("net:

RE: [PATCH net-next v3 2/7] netvsc: fix warnings reported by lockdep

2017-08-24 Thread Stephen Hemminger
These are false positives; lockdep is complaining about things that are safe It is just that annotations were missing or incorrect. -Original Message- From: David Woodhouse [mailto:dw...@infradead.org] Sent: Thursday, August 24, 2017 1:37 AM To: Stephen Hemminger ; KY Srinivasan ; Haiyan

[PATCH net] bpf: fix bpf_setsockopts return value

2017-08-24 Thread Yuchung Cheng
This patch fixes a bug causing any sock operations to always return EINVAL. Fixes: a5192c52377e ("bpf: fix to bpf_setsockops"). Reported-by: Neal Cardwell Signed-off-by: Yuchung Cheng Acked-by: Neal Cardwell Acked-by: Craig Gallek --- net/core/filter.c | 1 - 1 file changed, 1 deletion(-) di

Re: [PATCH net-next 3/3 v7] drivers: net: ethernet: qualcomm: rmnet: Initial implementation

2017-08-24 Thread Subash Abhinov Kasiviswanathan
+ +CFLAGS_rmnet.o := -I$(src) You do not need this CFLAGS rule, the local include files are included using "" double quotes so it uses the local directory always. Hi David I'll remove this. +static void rmnet_free_later(struct work_struct *work) +{ + struct rmnet_free_work *fwork; + +

Re: [iproute PATCH v3 0/6] Covscan: Misc fixes

2017-08-24 Thread Stephen Hemminger
On Thu, 24 Aug 2017 11:41:25 +0200 Phil Sutter wrote: > This series collects patches from v1 addressing miscellaneous issues > detected by covscan. > > Changes since v2: > - Dropped patch 1 since v2 discussion is still inconclusive. > - Replaced patch 2 by a more appropriate one given feedback f

Re: [iproute PATCH v3 6/6] lib/libnetlink: Don't pass NULL parameter to memcpy()

2017-08-24 Thread Stephen Hemminger
On Thu, 24 Aug 2017 11:41:31 +0200 Phil Sutter wrote: > Both addattr_l() and rta_addattr_l() may be called with NULL data > pointer and 0 alen parameters. Avoid calling memcpy() in that case. > > Signed-off-by: Phil Sutter > --- > lib/libnetlink.c | 6 -- > 1 file changed, 4 insertions(+),

[PATCH net] net: systemport: Be drop monitor friendly

2017-08-24 Thread Florian Fainelli
Utilize dev_consume_skb_any(cb->skb) in bcm_sysport_free_cb() which is used when a TX packet is completed, as well as when the RX ring is cleaned on shutdown. None of these two cases are packet drops, so be drop monitor friendly. Suggested-by: Eric Dumazet Fixes: 80105befdb4b ("net: systemport: a

Re: [iproute PATCH v4 0/6] Covscan: Fixes for string termination

2017-08-24 Thread Stephen Hemminger
On Thu, 24 Aug 2017 11:51:44 +0200 Phil Sutter wrote: > This series collects patches from v1 dealing with code potentially > leaving string buffers unterminated. This does not include situations > where it happens for parsed interface names since an overall solution > was attempted for that and i

Re: [PATCH net-next 09/13] net: mvpp2: dynamic reconfiguration of the PHY mode

2017-08-24 Thread Russell King - ARM Linux
On Thu, Aug 24, 2017 at 07:45:19PM +0200, Andrew Lunn wrote: > > The 88x3310 driver in the kernel knows about these combinations and > > sets the phy interface parameter correctly depending on whether the > > PHY has configured itself for copper at whatever speed or SFP+. > > So when the PHY decid

Re: [PATCH v4] net: sunrpc: svcsock: fix NULL-pointer exception

2017-08-24 Thread J. Bruce Fields
On Wed, Aug 23, 2017 at 06:33:42AM -0400, Jeff Layton wrote: > I think this one looks fine. Bruce, do you mind picking this one up? It > might also be reasonable for stable... Yep, thanks to you both, I'll plan to send a pull request tonight or tomorrow. --b.

Re: [Patch net-next] net_sched: remove tc class reference counting

2017-08-24 Thread Cong Wang
On Thu, Aug 24, 2017 at 12:32 PM, David Miller wrote: > From: Cong Wang > Date: Tue, 22 Aug 2017 21:38:10 -0700 > >> For TC classes, their ->get() and ->put() are always paired, and the >> reference counting is completely useless, because: >> >> 1) For class modification and dumping paths, we alr

[PATCH] cfg80211: Use tabs for identation

2017-08-24 Thread Himanshu Jha
Removed whitespaces and added necessary tabs conforming to coding style. Issue found using checkpatch.pl Signed-off-by: Himanshu Jha --- net/wireless/chan.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/net/wireless/chan.c b/net/wireless/chan.c index b8aa5a7..13c95e5

Re: [iproute PATCH v4 0/4] Covscan: Fix potential NULL pointer dereferences

2017-08-24 Thread Stephen Hemminger
On Thu, 24 Aug 2017 11:46:30 +0200 Phil Sutter wrote: > This series collects patches from v1 which eliminate possible cases of > NULL pointer dereferences. > > Changes since v3: > - Dropped upstream rejected patch 2. > > Phil Sutter (4): > ifstat, nstat: Check fdopen() return value > tc/q_n

Re: [PATCH net] virtio_net: be drop monitor friend

2017-08-24 Thread Michael S. Tsirkin
On Thu, Aug 24, 2017 at 09:02:49AM -0700, Eric Dumazet wrote: > From: Eric Dumazet > > This change is needed to not fool drop monitor. > (perf record ... -e skb:kfree_skb ) > > Packets were properly sent and are consumed after TX completion. > > Signed-off-by: Eric Dumazet Acked-by: Michael S

[PATCH] strparser: initialize all callbacks

2017-08-24 Thread Eric Biggers
From: Eric Biggers commit bbb03029a899 ("strparser: Generalize strparser") added more function pointers to 'struct strp_callbacks'; however, kcm_attach() was not updated to initialize them. This could cause the ->lock() and/or ->unlock() function pointers to be set to garbage values, causing a c

Re: [PATCH][next] net: hinic: fix comparison of a uint16_t type with -1

2017-08-24 Thread David Miller
From: Colin King Date: Wed, 23 Aug 2017 16:39:36 +0100 > From: Colin Ian King > > The comparison of hw_ioctxt.rx_buf_sz_idx == -1 is always false because > rx_buf_sz_idx is a uint16_t. Fix this by explicitly casting -1 to uint16_t. > > Detected by CoverityScan, CID#1454559 ("Operands don't aff

[PATCH] staging: rtlwifi: Improve debugging by using debugfs

2017-08-24 Thread Larry Finger
The changes in this commit are also being sent to the main rtlwifi drivers in wireless-next; however, these changes will also be useful for any debugging of r8822be before it gets moved into the main tree. Use debugfs to dump register and btcoex status, and also write registers and h2c. We create

Re: [PATCH net-next 1/3] gre: refactor the gre_fb_xmit

2017-08-24 Thread David Miller
Please repost this series with a proper "[PATCH net-next 0/3] ..." header posting. Thank you.

Re: [PATCH net-next 2/5] ipv6: sr: add support for encapsulation of L2 frames

2017-08-24 Thread David Miller
From: David Lebrun Date: Wed, 23 Aug 2017 17:32:00 +0200 > + case SEG6_IPTUN_MODE_L2ENCAP: > + head = sizeof(struct ipv6hdr) + 14; > + break; This 14 is ETH_HLEN. > > + if (pskb_expand_head(skb, skb->mac_len, 0, GFP_ATOMIC) < 0) > +

Re: [PATCH] tipc: Fix tipc_sk_reinit handling of -EAGAIN

2017-08-24 Thread David Miller
From: Bob Peterson Date: Wed, 23 Aug 2017 10:43:02 -0400 (EDT) > In 9dbbfb0ab6680c6a85609041011484e6658e7d3c function tipc_sk_reinit > had additional logic added to loop in the event that function > rhashtable_walk_next() returned -EAGAIN. No worries. > > However, if rhashtable_walk_start return

Re: [PATCH] [net-next] qlge: avoid memcpy buffer overflow

2017-08-24 Thread David Miller
From: Arnd Bergmann Date: Wed, 23 Aug 2017 15:59:49 +0200 > gcc-8.0.0 (snapshot) points out that we copy a variable-length string > into a fixed length field using memcpy() with the destination length, > and that ends up copying whatever follows the string: > > inlined from 'ql_core_dump' at

Re: [PATCH net-next] virtio-net: invoke zerocopy callback on xmit path if no tx napi

2017-08-24 Thread Michael S. Tsirkin
On Thu, Aug 24, 2017 at 04:20:39PM -0400, Willem de Bruijn wrote: > >> Traffic shaping can introduce msec timescale latencies. > >> > >> The delay may actually be a useful signal. If the guest does not > >> orphan skbs early, TSQ will throttle the socket causing host > >> queue build up. > >> > >>

Re: [PATCH net-next] virtio-net: invoke zerocopy callback on xmit path if no tx napi

2017-08-24 Thread Willem de Bruijn
>> Traffic shaping can introduce msec timescale latencies. >> >> The delay may actually be a useful signal. If the guest does not >> orphan skbs early, TSQ will throttle the socket causing host >> queue build up. >> >> But, if completions are queued in-order, unrelated flows may be >> throttled as

Re: [PATCH v3 3/4] net: stmmac: register parent MDIO node for sun8i-h3-emac

2017-08-24 Thread Florian Fainelli
On 08/24/2017 01:21 AM, Corentin Labbe wrote: > On Wed, Aug 23, 2017 at 09:31:53AM -0700, Florian Fainelli wrote: >> On 08/23/2017 12:49 AM, Maxime Ripard wrote: >>> Hi Florian, >>> >>> On Tue, Aug 22, 2017 at 11:35:01AM -0700, Florian Fainelli wrote: >>> So I think what you are saying is eithe

Re: [PATCH v3 3/4] net: stmmac: register parent MDIO node for sun8i-h3-emac

2017-08-24 Thread Corentin Labbe
On Thu, Aug 24, 2017 at 10:21:24AM +0200, Corentin Labbe wrote: > On Wed, Aug 23, 2017 at 09:31:53AM -0700, Florian Fainelli wrote: > > On 08/23/2017 12:49 AM, Maxime Ripard wrote: > > > Hi Florian, > > > > > > On Tue, Aug 22, 2017 at 11:35:01AM -0700, Florian Fainelli wrote: > > > So I think

Re: [PATCH] net/mlx4_core: make mlx4_profile const

2017-08-24 Thread David Miller
From: Bhumika Goyal Date: Wed, 23 Aug 2017 18:17:39 +0530 > Make these const as they are only used in a copy operation. > > Signed-off-by: Bhumika Goyal Applied to net-next.

Re: [PATCH net] virtio_net: be drop monitor friend

2017-08-24 Thread Eric Dumazet
On Thu, 2017-08-24 at 11:50 -0700, David Miller wrote: > From: Eric Dumazet > Date: Thu, 24 Aug 2017 09:02:49 -0700 > > > From: Eric Dumazet > > > > This change is needed to not fool drop monitor. > > (perf record ... -e skb:kfree_skb ) > > > > Packets were properly sent and are consumed after

Re: [PATCH] net/mlx5e: make mlx5e_profile const

2017-08-24 Thread David Miller
From: Bhumika Goyal Date: Wed, 23 Aug 2017 18:22:01 +0530 > Make this const as it is only passed as an argument to the function > mlx5e_create_netdev and the corresponding argument is of type const. > > Signed-off-by: Bhumika Goyal Applied to net-next.

  1   2   3   >