[PATCH net] mlxsw: __mlxsw_sp_port_headroom_set(): Fix a use of local variable

2019-02-16 Thread Ido Schimmel
From: Petr Machata The function-local variable "delay" enters the loop interpreted as delay in bits. However, inside the loop it gets overwritten by the result of mlxsw_sp_pg_buf_delay_get(), and thus leaves the loop as quantity in cells. Thus on second and further loop iterations, the headroom f

Re: pull-request: bpf-next 2019-02-16

2019-02-16 Thread David Miller
From: Alexei Starovoitov Date: Sat, 16 Feb 2019 19:42:33 -0800 > The following pull-request contains BPF updates for your *net-next* tree. > > The main changes are: > > 1) numerous libbpf API improvements, from Andrii, Andrey, Yonghong. > > 2) test all bpf progs in alu32 mode, from Jiong. > >

Re: pull-request: bpf 2019-02-16

2019-02-16 Thread David Miller
From: Alexei Starovoitov Date: Sat, 16 Feb 2019 19:14:18 -0800 > The following pull-request contains BPF updates for your *net* tree. > > The main changes are: > > 1) fix lockdep false positive in bpf_get_stackid(), from Alexei. > > 2) several AF_XDP fixes, from Bjorn, Magnus, Davidlohr. > >

Re: [RFC PATCH] bonding: use mutex lock in bond_get_stats()

2019-02-16 Thread Cong Wang
On Fri, Feb 15, 2019 at 8:19 AM Kefeng Wang wrote: > > With CONFIG_DEBUG_SPINLOCK=y, we find following stack, > > BUG: spinlock wrong CPU on CPU#0, ip/16047 > lock: 0x803f5febc998, .magic: dead4ead, .owner: ip/16047, .owner_cpu: 0 > CPU: 1 PID: 16047 Comm: ip Kdump: loaded Tainted: G

Re: [PATCH net-next 3/4] net: phy: marvell10g: use genphy_c45_an_config_an

2019-02-16 Thread Andrew Lunn
> This is not strictly equivalent though because marvell10g only checks > for the 1baseT_Full bit set whereas genphy_c45_an_config_an() calls > linkmode_adv_to_mii_10gbt_adv_t() which you recently updated to also > check for 2.5G and 5G. This sounds about the right decision, but I > wonder if

Re: [PATCH net-next 2/4] net: phy: add genphy_c45_an_config_an

2019-02-16 Thread Andrew Lunn
On Sat, Feb 16, 2019 at 06:44:24PM -0800, Florian Fainelli wrote: > > > On 2/16/2019 11:51 AM, Heiner Kallweit wrote: > > From: Andrew Lunn > > C45 configuration of 10/100 and multi-giga bit auto negotiation > > advertisement is standardized. Configuration of 1000Base-T however > > appears to be

[PATCH net-next] cxgb4: Mask out interrupts that are not enabled.

2019-02-16 Thread Vishal Kulkarni
There are rare cases where a PL_INT_CAUSE bit may end up getting set when the corresponding PL_INT_ENABLE bit isn't set. Signed-off-by: Vishal Kulkarni --- drivers/net/ethernet/chelsio/cxgb4/t4_hw.c | 10 -- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/drivers/net/ethern

Re: [PATCH net-next] iptunnel: NULL pointer deref for ip_md_tunnel_xmit

2019-02-16 Thread wenxu
On 2019/2/15 下午5:38, Alan Maguire wrote: > Naresh Kamboju noted the following oops during execution of selftest > tools/testing/selftests/bpf/test_tunnel.sh on x86_64: > > [ 274.120445] BUG: unable to handle kernel NULL pointer dereference > at > [ 274.128285] #PF error: [INSTR]

Re: [PATCH net-next] ip_tunnel: Fix DST_METADATA dst_entry handle in tnl_update_pmtu

2019-02-16 Thread wenxu
On 2019/2/17 上午11:35, wenxu wrote: > On 2019/2/17 上午12:34, Alexei Starovoitov wrote: >> On Sat, Feb 16, 2019 at 2:11 AM wrote: >>> From: wenxu >>> >>> BUG report in selftests: bpf: test_tunnel.sh >>> >>> Testing IPIP tunnel... >>> BUG: unable to handle kernel NULL pointer dereference at 0

pull-request: bpf-next 2019-02-16

2019-02-16 Thread Alexei Starovoitov
Hi David, The following pull-request contains BPF updates for your *net-next* tree. The main changes are: 1) numerous libbpf API improvements, from Andrii, Andrey, Yonghong. 2) test all bpf progs in alu32 mode, from Jiong. 3) skb->sk access and bpf_sk_fullsock(), bpf_tcp_sock() helpers, from M

Re: [PATCH net-next] ip_tunnel: Fix DST_METADATA dst_entry handle in tnl_update_pmtu

2019-02-16 Thread wenxu
On 2019/2/17 上午12:34, Alexei Starovoitov wrote: > On Sat, Feb 16, 2019 at 2:11 AM wrote: >> From: wenxu >> >> BUG report in selftests: bpf: test_tunnel.sh >> >> Testing IPIP tunnel... >> BUG: unable to handle kernel NULL pointer dereference at >> PGD 0 P4D 0 >> Oops: 0010 [#1] SM

pull-request: bpf 2019-02-16

2019-02-16 Thread Alexei Starovoitov
Hi David, The following pull-request contains BPF updates for your *net* tree. The main changes are: 1) fix lockdep false positive in bpf_get_stackid(), from Alexei. 2) several AF_XDP fixes, from Bjorn, Magnus, Davidlohr. 3) fix narrow load from struct bpf_sock, from Martin. 4) mips JIT fixes

Re: [PATCH RFC] net: bridge: don't flood known multicast traffic when snooping is enabled

2019-02-16 Thread Florian Fainelli
On 2/15/2019 5:04 AM, Nikolay Aleksandrov wrote: > The behaviour since b00589af3b04 ("bridge: disable snooping if there is > no querier") is wrong, we shouldn't be flooding multicast traffic when > there is an mdb entry and we know where it should be forwarded to when > multicast snooping is ena

Re: [PATCH bpf-next] tools/libbpf: support bigger BTF data sizes

2019-02-16 Thread Alexei Starovoitov
On Fri, Feb 15, 2019 at 07:52:18PM -0800, Andrii Nakryiko wrote: > While it's understandable why kernel limits number of BTF types to 65535 > and size of string section to 64KB, in libbpf as user-space library it's > too restrictive. E.g., pahole converting DWARF to BTF type information > for Linux

Re: [PATCH net-next 4/4] net: phy: marvell10g: check for newly set aneg in mv3310_config_aneg

2019-02-16 Thread Florian Fainelli
On 2/16/2019 11:53 AM, Heiner Kallweit wrote: > Even if the advertisement registers content didn't change, we may have > just switched to aneg, and therefore have to trigger an aneg restart. > This matches the behavior of genphy_config_aneg(). > > Signed-off-by: Heiner Kallweit Reviewed-by: F

Re: [PATCH net-next 3/4] net: phy: marvell10g: use genphy_c45_an_config_an

2019-02-16 Thread Florian Fainelli
On 2/16/2019 11:52 AM, Heiner Kallweit wrote: > From: Andrew Lunn > Use new function genphy_c45_config_aneg() in mv3310_config_aneg(). > > Signed-off-by: Andrew Lunn > [hkallwe...@gmail.com: patch splitted] > Signed-off-by: Heiner Kallweit > --- > drivers/net/phy/marvell10g.c | 22 +

Re: [PATCH bpf-next] selftests: bpf: test_lwt_ip_encap: add negative tests.

2019-02-16 Thread Alexei Starovoitov
On Sat, Feb 16, 2019 at 04:13:12PM -0700, David Ahern wrote: > On 2/15/19 4:49 PM, Peter Oskolkov wrote: > > @@ -178,7 +205,7 @@ set -e # exit on error > > # configure IPv4 GRE device in NS3, and a route to it via the "bottom" > > route > > ip -netns ${NS3} tunnel add gre_dev mode gre rem

Re: [PATCH net-next 2/4] net: phy: add genphy_c45_an_config_an

2019-02-16 Thread Florian Fainelli
On 2/16/2019 11:51 AM, Heiner Kallweit wrote: > From: Andrew Lunn > C45 configuration of 10/100 and multi-giga bit auto negotiation > advertisement is standardized. Configuration of 1000Base-T however > appears to be vendor specific. Move the generic code out of the > Marvell driver into the co

Re: [PATCH net-next 1/4] net: phy: add helper linkmode_adv_to_mii_10gbt_adv_t

2019-02-16 Thread Florian Fainelli
On 2/16/2019 11:50 AM, Heiner Kallweit wrote: > Add a helper linkmode_adv_to_mii_10gbt_adv_t(), similar to > linkmode_adv_to_mii_adv_t. > > Signed-off-by: Heiner Kallweit Reviewed-by: Florian Fainelli -- Florian

Re: [PATCH net-next v2 2/2] net: phy: use mii_10gbt_stat_mod_linkmode_lpa_t in genphy_c45_read_lpa

2019-02-16 Thread Florian Fainelli
On 2/16/2019 8:26 AM, Heiner Kallweit wrote: > Use mii_10gbt_stat_mod_linkmode_lpa_t() in genphy_c45_read_lpa() to > simplify the code. > > Signed-off-by: Heiner Kallweit Reviewed-by: Florian Fainelli -- Florian

Re: [PATCH v2 net-next 1/2] net: phy: disable aneg in genphy_c45_pma_setup_forced

2019-02-16 Thread Florian Fainelli
On 2/16/2019 11:44 AM, Heiner Kallweit wrote: > When genphy_c45_pma_setup_forced() is called the "aneg enabled" bit may > still be set, therefore clear it. This is also in line with what > genphy_setup_forced() does for Clause 22. > > v2: > - fix typo > > Signed-off-by: Heiner Kallweit Revie

Re: [PATCH v2 net-next 2/2] net: phy: marvell10g: improve mv3310_config_aneg

2019-02-16 Thread Florian Fainelli
On 2/16/2019 11:44 AM, Heiner Kallweit wrote: > Now that genphy_c45_pma_setup_forced() makes sure the "aneg enabled" > bit is cleared, the call to genphy_c45_an_disable_aneg() isn't needed > any longer. And the code pattern is now the same as in > genphy_config_aneg(). > > Signed-off-by: Heiner

Re: [PATCH net-next v2 1/2] net: phy: add helper mii_10gbt_stat_mod_linkmode_lpa_t

2019-02-16 Thread Florian Fainelli
On 2/16/2019 8:26 AM, Heiner Kallweit wrote: > Similar to the existing helpers for the Clause 22 registers add helper > mii_10gbt_stat_mod_linkmode_lpa_t. > > Note that this helper is defined in linux/mdio.h, not like the > Clause 22 helpers in linux/mii.h. Reason is that the Clause 45 register

Re: [net-next, PATCH v2] net: stmmac: use correct define to get rx timestamp on GMAC4

2019-02-16 Thread David Miller
From: Alexandre Torgue Date: Thu, 14 Feb 2019 17:03:44 +0100 > In dwmac4_wrback_get_rx_timestamp_status we looking for a RX timestamp. > For that receive descriptors are handled and so we should use defines > related to receive descriptors. It'll no change the functional behavior > as RDES3_RDES1

Re: [PATCH net-next] net/tls: Move protocol constants from cipher context to tls context

2019-02-16 Thread David Miller
From: Vakul Garg Date: Thu, 14 Feb 2019 07:11:35 + > Each tls context maintains two cipher contexts (one each for tx and rx > directions). For each tls session, the constants such as protocol > version, ciphersuite, iv size, associated data size etc are same for > both the directions and need

Re: [PATCH] atm: clean up vcc_seq_next()

2019-02-16 Thread David Miller
From: Dan Carpenter Date: Thu, 14 Feb 2019 09:56:35 +0300 > It's confusing to call PTR_ERR(v). The PTR_ERR() function is basically > a fancy cast to long so it makes you wonder, was IS_ERR() intended? But > that doesn't make sense because vcc_walk() doesn't return error > pointers. > > This pa

Re: [PATCH net-next] sock: consistent handling of extreme SO_SNDBUF/SO_RCVBUF values

2019-02-16 Thread David Miller
From: Guillaume Nault Date: Wed, 13 Feb 2019 04:30:34 +0100 > SO_SNDBUF and SO_RCVBUF (and their *BUFFORCE version) may overflow or > underflow their input value. This patch aims at providing explicit > handling of these extreme cases, to get a clear behaviour even with > values bigger than INT_M

Re: [PATCH bpf-next] selftests: bpf: test_lwt_ip_encap: add negative tests.

2019-02-16 Thread David Ahern
On 2/15/19 4:49 PM, Peter Oskolkov wrote: > @@ -178,7 +205,7 @@ set -e # exit on error > # configure IPv4 GRE device in NS3, and a route to it via the "bottom" > route > ip -netns ${NS3} tunnel add gre_dev mode gre remote ${IPv4_1} local > ${IPv4_GRE} ttl 255 > ip -netns ${NS3}

Re: [PATCH net-next 1/2] net: phy: disable aneg in genphy_c45_pma_setup_forced

2019-02-16 Thread Heiner Kallweit
On 16.02.2019 23:43, Russell King - ARM Linux admin wrote: > On Sat, Feb 16, 2019 at 08:10:24PM +0100, Heiner Kallweit wrote: >> When genphy_c45_pma_setup_forced() is called the "aneg enabled" bit may >> still be set, therefore clear it. This is also in line with what >> genphy_setup_forced() does

Re: [PATCH net-next 1/2] net: phy: disable aneg in genphy_c45_pma_setup_forced

2019-02-16 Thread Russell King - ARM Linux admin
On Sat, Feb 16, 2019 at 08:10:24PM +0100, Heiner Kallweit wrote: > When genphy_c45_pma_setup_forced() is called the "aneg enabled" bit may > still be set, therefore clear it. This is also in line with what > genphy_setup_forced() does for Clause 22. > > Signed-off-by: Heiner Kallweit > --- > dri

ax25: fix possible use-after-free

2019-02-16 Thread f6bvp
Patch applied successfully on Linux draws-f6bvp 4.14.79-v7+ #1159 SMP Sun Nov 4 17:50:20 GMT 2018 armv7l GNU/Linux However ax25_route_lock_use and ax25_route_lock_unuse() are not declared and compile failed. make : on entre dans le répertoire « /usr/src/linux-headers-4.14.79-v7+ » CC [M] /

Re: [PATCH] net: Fix for_each_netdev_feature on Big endian

2019-02-16 Thread David Miller
From: Eric Dumazet Date: Sat, 16 Feb 2019 13:01:28 -0800 > This commit added a call to fls64(), but not the needed include. > > This might break some uses I think. > > I suggest the following fix : > > diff --git a/include/linux/netdev_features.h b/include/linux/netdev_features.h > index > c5

Re: [PATCH] net: Fix for_each_netdev_feature on Big endian

2019-02-16 Thread Eric Dumazet
On 02/15/2019 08:24 PM, David Miller wrote: > From: Hauke Mehrtens > Date: Fri, 15 Feb 2019 17:58:54 +0100 > >> The features attribute is of type u64 and stored in the native endianes on >> the system. The for_each_set_bit() macro takes a pointer to a 32 bit array >> and goes over the bits in

Re: [PATCH RFC] net: bridge: don't flood known multicast traffic when snooping is enabled

2019-02-16 Thread Linus Lüssing
On Sat, Feb 16, 2019 at 09:27:26PM +0200, niko...@cumulusnetworks.com wrote: > >>The no querier condition is not currently reflected via switchdev, so > >>the behavior you're proposing in your patch is what actually happens > >in > >>the data plane. > >> > >>We already hit the problem Linus mention

Re: [pull request][net-next 00/13] Mellanox, BlueField SmartNIC

2019-02-16 Thread David Miller
From: Saeed Mahameed Date: Fri, 15 Feb 2019 17:34:39 -0800 > This series adds the support for Melanox BlueField SmartNIC. > For more information please see tag log below. > > Please note the merge commit of mlx5-next at the base of the pull request: > 259fae5a2cff ("Merge branch 'mlx5-next' of

Re: [PATCH RFC] net: bridge: don't flood known multicast traffic when snooping is enabled

2019-02-16 Thread Linus Lüssing
Hi Nik, hi Ido, By the way speaking about the IGMP/MLD querier mechanism. Not sure if you are subscribed to the p...@ietf.org or mcast-w...@ietf.org mailing lists. There was a call for volunteers to progress IGMP/MLD to standards track not that long ago: "[pim] Volunteers needed for work on prog

[PATCH net-next 3/4] net: phy: marvell10g: use genphy_c45_an_config_an

2019-02-16 Thread Heiner Kallweit
From: Andrew Lunn Use new function genphy_c45_config_aneg() in mv3310_config_aneg(). Signed-off-by: Andrew Lunn [hkallwe...@gmail.com: patch splitted] Signed-off-by: Heiner Kallweit --- drivers/net/phy/marvell10g.c | 22 +- 1 file changed, 1 insertion(+), 21 deletions(-) d

[PATCH net-next 2/4] net: phy: add genphy_c45_an_config_an

2019-02-16 Thread Heiner Kallweit
From: Andrew Lunn C45 configuration of 10/100 and multi-giga bit auto negotiation advertisement is standardized. Configuration of 1000Base-T however appears to be vendor specific. Move the generic code out of the Marvell driver into the common phy-c45.c file. Signed-off-by: Andrew Lunn [hkallwe.

[PATCH net-next 4/4] net: phy: marvell10g: check for newly set aneg in mv3310_config_aneg

2019-02-16 Thread Heiner Kallweit
Even if the advertisement registers content didn't change, we may have just switched to aneg, and therefore have to trigger an aneg restart. This matches the behavior of genphy_config_aneg(). Signed-off-by: Heiner Kallweit --- drivers/net/phy/marvell10g.c | 10 ++ 1 file changed, 10 inse

[PATCH net-next 1/4] net: phy: add helper linkmode_adv_to_mii_10gbt_adv_t

2019-02-16 Thread Heiner Kallweit
Add a helper linkmode_adv_to_mii_10gbt_adv_t(), similar to linkmode_adv_to_mii_adv_t. Signed-off-by: Heiner Kallweit --- include/linux/mdio.h | 25 + 1 file changed, 25 insertions(+) diff --git a/include/linux/mdio.h b/include/linux/mdio.h index 5b872c45f..5a65f32d8 1006

[PATCH net-next 0/4] net: phy: add and use genphy_c45_an_config_an

2019-02-16 Thread Heiner Kallweit
This series adds genphy_c45_an_config_an() and uses it in the marvell10g diver. In addition patch 4 aligns the aneg configuration with what is done in genphy_config_aneg(). Heiner Kallweit (4): net: phy: add helper linkmode_adv_to_mii_10gbt_adv_t net: phy: add genphy_c45_an_config_an net: ph

[PATCH v2 net-next 2/2] net: phy: marvell10g: improve mv3310_config_aneg

2019-02-16 Thread Heiner Kallweit
Now that genphy_c45_pma_setup_forced() makes sure the "aneg enabled" bit is cleared, the call to genphy_c45_an_disable_aneg() isn't needed any longer. And the code pattern is now the same as in genphy_config_aneg(). Signed-off-by: Heiner Kallweit --- drivers/net/phy/marvell10g.c | 9 ++--- 1

[PATCH v2 net-next 1/2] net: phy: disable aneg in genphy_c45_pma_setup_forced

2019-02-16 Thread Heiner Kallweit
When genphy_c45_pma_setup_forced() is called the "aneg enabled" bit may still be set, therefore clear it. This is also in line with what genphy_setup_forced() does for Clause 22. v2: - fix typo Signed-off-by: Heiner Kallweit --- drivers/net/phy/phy-c45.c | 6 +- 1 file changed, 5 insertions

[PATCH v2 net-next 0/2] net: phy: disable aneg in genphy_c45_pma_setup_forced

2019-02-16 Thread Heiner Kallweit
When genphy_c45_pma_setup_forced() is called the "aneg enabled" bit may still be set, therefore clear it. This is also in line with what genphy_setup_forced() does for Clause 22. v2: - fix a typo in patch 1 Heiner Kallweit (2): net: phy: disable aneg in genphy_c45_pma_setup_forced net: phy: m

Re: [PATCH net-next 1/2] net: phy: disable aneg in genphy_c45_pma_setup_forced

2019-02-16 Thread Heiner Kallweit
On 16.02.2019 20:31, Stefano Brivio wrote: > Hi, > > On Sat, 16 Feb 2019 20:10:24 +0100 > Heiner Kallweit wrote: > >> When genphy_c45_pma_setup_forced() is called the "aneg enabled" bit may >> still be set, therefore clear it. This is also in line with what >> genphy_setup_forced() does for Clau

Re: [PATCH net-next 1/2] net: phy: disable aneg in genphy_c45_pma_setup_forced

2019-02-16 Thread Stefano Brivio
Hi, On Sat, 16 Feb 2019 20:10:24 +0100 Heiner Kallweit wrote: > When genphy_c45_pma_setup_forced() is called the "aneg enabled" bit may > still be set, therefore clear it. This is also in line with what > genphy_setup_forced() does for Clause 22. > > Signed-off-by: Heiner Kallweit > --- > dri

Re: [PATCH RFC] net: bridge: don't flood known multicast traffic when snooping is enabled

2019-02-16 Thread nikolay
On 16 February 2019 21:15:21 EET, niko...@cumulusnetworks.com wrote: >On 16 February 2019 20:43:53 EET, Ido Schimmel >wrote: >>On Sat, Feb 16, 2019 at 10:05:40AM +0200, Nikolay Aleksandrov wrote: >>> On 15/02/2019 19:13, Linus Lüssing wrote: >>> > On Fri, Feb 15, 2019 at 03:04:27PM +0200, Nikolay

Re: [PATCH RFC] net: bridge: don't flood known multicast traffic when snooping is enabled

2019-02-16 Thread nikolay
On 16 February 2019 20:43:53 EET, Ido Schimmel wrote: >On Sat, Feb 16, 2019 at 10:05:40AM +0200, Nikolay Aleksandrov wrote: >> On 15/02/2019 19:13, Linus Lüssing wrote: >> > On Fri, Feb 15, 2019 at 03:04:27PM +0200, Nikolay Aleksandrov >wrote: >> >> Every user would expect to have traffic forwarde

Re: [PATCH v2 1/2] Provide in-kernel headers for making it easy to extend the kernel

2019-02-16 Thread Manoj
Joel Fernandes writes: > On Thu, Feb 14, 2019 at 07:19:29PM -0800, Alexei Starovoitov wrote: >> On Mon, Feb 11, 2019 at 09:35:59AM -0500, Joel Fernandes (Google) wrote: >> > Introduce in-kernel headers and other artifacts which are made available >> > as an archive through proc (/proc/kheaders.t

[PATCH net-next 1/2] net: phy: disable aneg in genphy_c45_pma_setup_forced

2019-02-16 Thread Heiner Kallweit
When genphy_c45_pma_setup_forced() is called the "aneg enabled" bit may still be set, therefore clear it. This is also in line with what genphy_setup_forced() does for Clause 22. Signed-off-by: Heiner Kallweit --- drivers/net/phy/phy-c45.c | 4 1 file changed, 4 insertions(+) diff --git a/

[PATCH net-next 2/2] net: phy: marvell10g: improve mv3310_config_aneg

2019-02-16 Thread Heiner Kallweit
Now that genphy_c45_pma_setup_forced() makes sure the "aneg enabled" bit is cleared, the call to genphy_c45_an_disable_aneg() isn't needed any longer. And the code pattern is now the same as in genphy_config_aneg(). Signed-off-by: Heiner Kallweit --- drivers/net/phy/marvell10g.c | 9 ++--- 1

[PATCH net-next 0/2] net: phy: disable aneg in genphy_c45_pma_setup_forced

2019-02-16 Thread Heiner Kallweit
When genphy_c45_pma_setup_forced() is called the "aneg enabled" bit may still be set, therefore clear it. This is also in line with what genphy_setup_forced() does for Clause 22. Heiner Kallweit (2): net: phy: disable aneg in genphy_c45_pma_setup_forced net: phy: marvell10g: improve mv3310_con

[Patch net-next 2/2] net_sched: fix a memory leak in cls_tcindex

2019-02-16 Thread Cong Wang
(cherry picked from commit 033b228e7f26b29ae37f8bfa1bc6b209a5365e9f) When tcindex_destroy() destroys all the filter results in the perfect hash table, it invokes the walker to delete each of them. However, results with class==0 are skipped in either tcindex_walk() or tcindex_delete(), which causes

[Patch net-next 1/2] net_sched: fix a race condition in tcindex_destroy()

2019-02-16 Thread Cong Wang
(cherry picked from commit 8015d93ebd27484418d4952284fd02172fa4b0b2) tcindex_destroy() invokes tcindex_destroy_element() via a walker to delete each filter result in its perfect hash table, and tcindex_destroy_element() calls tcindex_delete() which schedules tcf RCU works to do the final deletion

[ROSE] Bug : waiting for rose module to become free

2019-02-16 Thread f6bvp
Hi, A nastly bug is still pending in ROSE module that prevents it to be removed. When trying to remove rose module we enter into an endless loop with displayed message : "waiting for rose module to become free" A patch from Richard Stern had been committed a while ago but it did not get a chance

Re: [PATCH RFC] net: bridge: don't flood known multicast traffic when snooping is enabled

2019-02-16 Thread Ido Schimmel
On Sat, Feb 16, 2019 at 10:05:40AM +0200, Nikolay Aleksandrov wrote: > On 15/02/2019 19:13, Linus Lüssing wrote: > > On Fri, Feb 15, 2019 at 03:04:27PM +0200, Nikolay Aleksandrov wrote: > >> Every user would expect to have traffic forwarded only to the configured > >> mdb destination when snooping

Re: [RFC PATCH] bonding: use mutex lock in bond_get_stats()

2019-02-16 Thread Eric Dumazet
On Fri, Feb 15, 2019 at 9:36 PM Kefeng Wang wrote: > > > > On 2019/2/15 21:57, Eric Dumazet wrote: > > On Fri, Feb 15, 2019 at 5:37 AM Kefeng Wang > > wrote: > >> > >> With CONFIG_DEBUG_SPINLOCK=y, we find following stack, > >> > >> BUG: spinlock wrong CPU on CPU#0, ip/16047 > >> lock: 0x

Re: [PATCH net-next 1/3] net: stmmac: Fix NAPI poll in TX path when in multi-queue

2019-02-16 Thread Lendacky, Thomas
On 2/15/19 6:35 PM, Florian Fainelli wrote: > On 2/15/19 5:42 AM, Jose Abreu wrote: >> Commit 8fce33317023 introduced the concept of NAPI per-channel and >> independent cleaning of TX path. >> >> This is currently breaking performance in some cases. The scenario >> happens when all packets are be

Re: [PATCH net-next] ip_tunnel: Fix DST_METADATA dst_entry handle in tnl_update_pmtu

2019-02-16 Thread Alexei Starovoitov
On Sat, Feb 16, 2019 at 2:11 AM wrote: > > From: wenxu > > BUG report in selftests: bpf: test_tunnel.sh > > Testing IPIP tunnel... > BUG: unable to handle kernel NULL pointer dereference at > PGD 0 P4D 0 > Oops: 0010 [#1] SMP PTI > CPU: 0 PID: 16822 Comm: ping Not tainted 5.0.0-r

[PATCH v2 net-next 2/2] net: sock: undefine SOCK_DEBUGGING

2019-02-16 Thread Yafang Shao
SOCK_DEBUG() is a old facility for debugging. If the user want to use it for debugging, the user must modify the application first, that doesn't seem like a good way. Now we have more powerful facilities, i.e. bpf or tracepoint, for this kind of debugging purpose. So we'd better disable it by defau

[PATCH v2 net-next 1/2] tcp: clean up SOCK_DEBUG()

2019-02-16 Thread Yafang Shao
Per discussion with Daniel[1] and Eric[2], these SOCK_DEBUG() calles in TCP are not needed now. We'd better clean up it. [1] https://patchwork.ozlabs.org/patch/1035573/ [2] https://patchwork.ozlabs.org/patch/1040533/ Signed-off-by: Yafang Shao --- net/ipv4/tcp_input.c | 19 +--

[PATCH v2 net-next 0/2] clean up SOCK_DEBUG()

2019-02-16 Thread Yafang Shao
Per discussion with Daniel[1] and Eric[2], these SOCK_DEBUG() calles in TCP are not needed now. We'd better clean up it. Plus undefine SOCK_DEBUGGING by default. [1] https://patchwork.ozlabs.org/patch/1035573/ [2] https://patchwork.ozlabs.org/patch/1040533/ Yafang Shao (2): tcp: clean up SOCK

[PATCH net-next v2 1/2] net: phy: add helper mii_10gbt_stat_mod_linkmode_lpa_t

2019-02-16 Thread Heiner Kallweit
Similar to the existing helpers for the Clause 22 registers add helper mii_10gbt_stat_mod_linkmode_lpa_t. Note that this helper is defined in linux/mdio.h, not like the Clause 22 helpers in linux/mii.h. Reason is that the Clause 45 register constants are defined in uapi/linux/mdio.h. And uapi/linu

[PATCH net-next v2 2/2] net: phy: use mii_10gbt_stat_mod_linkmode_lpa_t in genphy_c45_read_lpa

2019-02-16 Thread Heiner Kallweit
Use mii_10gbt_stat_mod_linkmode_lpa_t() in genphy_c45_read_lpa() to simplify the code. Signed-off-by: Heiner Kallweit --- drivers/net/phy/phy-c45.c | 10 +- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/drivers/net/phy/phy-c45.c b/drivers/net/phy/phy-c45.c index 7af5fa81d.

[PATCH net-next v2 0/2] net: phy: add helpers for handling C45 10GBT AN register values

2019-02-16 Thread Heiner Kallweit
Similar to the existing helpers for the Clause 22 registers add helpers to deal with converting Clause 45 advertisement registers to / from link mode bitmaps. Note that these helpers are defined in linux/mdio.h, not like the Clause 22 helpers in linux/mii.h. Reason is that the Clause 45 register c

[BUG] [FIX] net: dsa: oops in br_vlan_enabled

2019-02-16 Thread Frank Wunderlich
Hi, i've found an oops in 4.19.23/10, seems to be fixed anyhow in 5.0 (also works in 4.14.101) root@bpi-r2:~# ip link add link lan0 name lan0.5 type vlan id 5 root@bpi-r2:~# ip addr add 192.168.5.200/24 brd 192.168.5.255 dev lan0.5 root@bpi-r2:~# ip link set dev lan0 up root@bpi-r2:~# ip link se

Re: [PATCH net-next 1/2] net: phy: add helpers for handling C45 10GBT AN register values

2019-02-16 Thread Heiner Kallweit
On 16.02.2019 17:00, Andrew Lunn wrote: > On Fri, Feb 15, 2019 at 09:57:49PM +0100, Heiner Kallweit wrote: >> Similar to the existing helpers for the Clause 22 registers add helpers >> to deal with converting Clause 45 advertisement registers to / from >> link mode bitmaps. >> >> Note that these he

Re: [PATCH net-next 1/2] net: phy: add helpers for handling C45 10GBT AN register values

2019-02-16 Thread Andrew Lunn
On Fri, Feb 15, 2019 at 09:57:49PM +0100, Heiner Kallweit wrote: > Similar to the existing helpers for the Clause 22 registers add helpers > to deal with converting Clause 45 advertisement registers to / from > link mode bitmaps. > > Note that these helpers are defined in linux/mdio.h, not like th

Re: [PATCH v2] net: dsa: Implement flow_dissect callback for tag_dsa.

2019-02-16 Thread Andrew Lunn
On Sat, Feb 16, 2019 at 08:35:24AM +, Rundong Ge wrote: > RPS not work for DSA devices since the 'skb_get_hash' > will always get the invalid hash for dsa tagged packets. > > "[PATCH] tag_mtk: add flow_dissect callback to the ops struct" > introduced the flow_dissect callback to get the right

Re: [PATCH v2] net: dsa: Implement flow_dissect callback for tag_dsa.

2019-02-16 Thread Andrew Lunn
On Sat, Feb 16, 2019 at 04:38:25PM +0800, Rundong Ge wrote: > Hi Andrew > > I have tested the L3 forwarding throughput performance of my box (with > an intel 4-core processor and each core’s frequency is 2.20GHz). > In my test scenario, I generated 200 UDP flows (frame size is 64 > bytes) with dif

phy speed setting issue: e1000: Add support for the CE4100 reference platform

2019-02-16 Thread Colin Ian King
Hi, Static analysis from CoverityScan has detected an issue with the speed setup with the control setting in the e1000 driver. Function e1000_config_mac_to_phy in /drivers/net/ethernet/intel/e1000/e1000_hw.c, CoverityScan reports: CID 140032 (#1 of 1): Operands don't affect result (CONSTANT_EXPR

-Wimplicit-fallthrough not working with ccache

2019-02-16 Thread Kalle Valo
(replying to an old thread but renaming it) Kalle Valo writes: > "Gustavo A. R. Silva" wrote: > >> In preparation to enabling -Wimplicit-fallthrough, mark switch cases >> where we are expecting to fall through. >> >> Notice that in this particular case, I replaced "pass through" with >> a prop

INFO: task hung in addrconf_dad_work

2019-02-16 Thread syzbot
Hello, syzbot found the following crash on: HEAD commit:5ded5871030e Merge tag 'scsi-fixes' of git://git.kernel.or.. git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=1577228f40 kernel config: https://syzkaller.appspot.com/x/.config?x=ee434566c893c7b1 da

[PATCH net-next] liquidio: using NULL instead of plain integer

2019-02-16 Thread YueHaibing
Fix following warning: drivers/net/ethernet/cavium/liquidio/cn23xx_pf_device.c:1453:35: warning: Using plain integer as NULL pointer drivers/net/ethernet/cavium/liquidio/lio_main.c:2910:23: warning: Using plain integer as NULL pointer Signed-off-by: YueHaibing --- drivers/net/ethernet/cavium/

Re: [PATCH net-next] netfilter: ipt_CLUSTERIP: make symbol 'cip_netdev_notifier' static

2019-02-16 Thread Pablo Neira Ayuso
On Sat, Feb 16, 2019 at 08:16:06AM +, Wei Yongjun wrote: > Fixes the following sparse warnings: > > net/ipv4/netfilter/ipt_CLUSTERIP.c:867:23: warning: > symbol 'cip_netdev_notifier' was not declared. Should it be static? Applied, thanks.

[PATCH net-next] cfg80211: pmsr: use eth_broadcast_addr() to assign broadcast address

2019-02-16 Thread Mao Wenan
This patch is to use eth_broadcast_addr() to assign broadcast address insetad of memset(). Signed-off-by: Mao Wenan --- net/wireless/pmsr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/net/wireless/pmsr.c b/net/wireless/pmsr.c index de9286703280..21139b82749f 100644 --- a/

[PATCH net-next] r8169: remove unneeded mmiowb barriers

2019-02-16 Thread Heiner Kallweit
writex() has implicit barriers, that's what makes it different from writex_relaxed(). Therefore these calls to mmiowb() can be removed. This patch was recently reverted due to a dependency with another problematic patch. But because it didn't contribute to the problem it was rebased and can be res

[PATCH] r8152: Add support for MAC address pass through on RTL8153-BD

2019-02-16 Thread David Chen
From: David Chen RTL8153-BD is used in Dell DA300 type-C dongle. It should be added to the whitelist of devices to activate MAC address pass through. Per confirming with Realtek all devices containing RTL8153-BD should activate MAC pass through and there won't use pass through bit on efuse like

Re: [PATCH v2] net: dsa: Implement flow_dissect callback for tag_dsa.

2019-02-16 Thread Rundong Ge
Hi Andrew I have tested the L3 forwarding throughput performance of my box (with an intel 4-core processor and each core’s frequency is 2.20GHz). In my test scenario, I generated 200 UDP flows (frame size is 64 bytes) with different src/dst pairs from eth1 to eth0. Eth1 is a slave DSA device from

[PATCH v2] net: dsa: Implement flow_dissect callback for tag_dsa.

2019-02-16 Thread Rundong Ge
RPS not work for DSA devices since the 'skb_get_hash' will always get the invalid hash for dsa tagged packets. "[PATCH] tag_mtk: add flow_dissect callback to the ops struct" introduced the flow_dissect callback to get the right hash for MTK tagged packet. Tag_dsa and tag_edsa also need to impleme

Re: [PATCH RFC] net: bridge: don't flood known multicast traffic when snooping is enabled

2019-02-16 Thread Nikolay Aleksandrov
On 16/02/2019 10:05, Nikolay Aleksandrov wrote: > On 15/02/2019 19:13, Linus Lüssing wrote: >> On Fri, Feb 15, 2019 at 03:04:27PM +0200, Nikolay Aleksandrov wrote: >>> Every user would expect to have traffic forwarded only to the configured >>> mdb destination when snooping is enabled, instead now

Re: [net-next] net: crypto set sk to NULL when af_alg_release.

2019-02-16 Thread maowenan
who can help review this patch? thank you. On 2019/2/15 22:24, Mao Wenan wrote: > KASAN has found use-after-free in sockfs_setattr. > The existed commit 6d8c50dcb029 ("socket: close race condition between > sock_close() > and sockfs_setattr()") is to fix this simillar issue, but it seems to ignor

Re: [PATCH] net: mv643xx_eth: disable clk on error path in mv643xx_eth_shared_probe()

2019-02-16 Thread Sergei Shtylyov
On 16.02.2019 0:20, Alexey Khoroshilov wrote: If mv643xx_eth_shared_of_probe() fails, mv643xx_eth_shared_probe() leaves clk undisabled. Enabled, that is? :-) Found by Linux Driver Verification project (linuxtesting.org). Signed-off-by: Alexey Khoroshilov [...] MBR, Sergei

[PATCH] net: sched: using kfree_rcu() to simplify the code

2019-02-16 Thread Wei Yongjun
The callback function of call_rcu() just calls a kfree(), so we can use kfree_rcu() instead of call_rcu() + callback function. Signed-off-by: Wei Yongjun --- net/sched/sch_api.c | 7 +-- 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/net/sched/sch_api.c b/net/sched/sch_api.c in

Re: [PATCH RFC] net: bridge: don't flood known multicast traffic when snooping is enabled

2019-02-16 Thread Nikolay Aleksandrov
On 15/02/2019 19:13, Linus Lüssing wrote: > On Fri, Feb 15, 2019 at 03:04:27PM +0200, Nikolay Aleksandrov wrote: >> Every user would expect to have traffic forwarded only to the configured >> mdb destination when snooping is enabled, instead now to get that one >> needs to enable both snooping and

[PATCH net-next] net: hns3: make function hclge_set_all_vf_rst() static

2019-02-16 Thread Wei Yongjun
Fixes the following sparse warning: drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c:2431:5: warning: symbol 'hclge_set_all_vf_rst' was not declared. Should it be static? Fixes: aa5c4f175be6 ("net: hns3: add reset handling for VF when doing PF reset") Signed-off-by: Wei Yongjun --- driv

[PATCH net-next] netfilter: ipt_CLUSTERIP: make symbol 'cip_netdev_notifier' static

2019-02-16 Thread Wei Yongjun
Fixes the following sparse warnings: net/ipv4/netfilter/ipt_CLUSTERIP.c:867:23: warning: symbol 'cip_netdev_notifier' was not declared. Should it be static? Fixes: 5a86d68bcf02 ("netfilter: ipt_CLUSTERIP: fix deadlock in netns exit routine") Signed-off-by: Wei Yongjun --- net/ipv4/netfilter/i