Re: Fw: [Bug 204903] New: unable to create vrf interface when ipv6.disable=1

2019-09-24 Thread Michal Kubecek
On Tue, Sep 24, 2019 at 08:28:52PM -0600, David Ahern wrote: > On 9/19/19 2:46 AM, Stephen Hemminger wrote: > > > > > > Begin forwarded message: > > > > Date: Wed, 18 Sep 2019 15:15:42 + > > From: bugzilla-dae...@bugzilla.kernel.org > > To: step...@networkplumber.org > > Subject: [Bug 204903

Re: [PATCH bpf-next v11 3/4] tools: Added bpf_get_ns_current_pid_tgid helper

2019-09-24 Thread Yonghong Song
On 9/24/19 8:20 AM, Carlos Neira wrote: > Signed-off-by: Carlos Neira Please do add some commit message. A couple of examples, commit 0fc2e0b84ba725c5e6ee66059936638389e67c80 Author: Alexei Starovoitov Date: Thu Aug 22 22:52:13 2019 -0700 tools/bpf: sync bpf.h sync bpf.h from ke

RE: [PATCH v2] r8152: Use guard clause and fix comment typos

2019-09-24 Thread Hayes Wang
Prashant Malani [mailto:pmal...@chromium.org] > Sent: Tuesday, September 24, 2019 12:01 PM > To: Hayes Wang > Cc: grund...@chromium.org; netdev@vger.kernel.org; nic_swsd; Prashant > Malani > Subject: [PATCH v2] r8152: Use guard clause and fix comment typos > > Use a guard clause in tx_bottom() to

[PATCH] net: use unlikely for dql_avail case

2019-09-24 Thread xiaolinkui
This is an unlikely case, use unlikely() on it seems logical. Signed-off-by: xiaolinkui --- include/linux/netdevice.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h index 88292953aa6f..005f3da1b13d 100644 --- a/include/li

Re: Fw: [Bug 204903] New: unable to create vrf interface when ipv6.disable=1

2019-09-24 Thread David Ahern
On 9/19/19 2:46 AM, Stephen Hemminger wrote: > > > Begin forwarded message: > > Date: Wed, 18 Sep 2019 15:15:42 + > From: bugzilla-dae...@bugzilla.kernel.org > To: step...@networkplumber.org > Subject: [Bug 204903] New: unable to create vrf interface when ipv6.disable=1 > > > https://bugzi

[PATCH net] net: dsa: qca8k: Fix port enable for CPU port

2019-09-24 Thread Andrew Lunn
The CPU port does not have a PHY connected to it. So calling phy_support_asym_pause() results in an Opps. As with other DSA drivers, add a guard that the port is a user port. Reported-by: Michal Vokáč Fixes: 0394a63acfe2 ("net: dsa: enable and disable all ports") Signed-off-by: Andrew Lunn ---

Re: [BUG] Unable to handle kernel NULL pointer dereference in phy_support_asym_pause

2019-09-24 Thread Andrew Lunn
On Tue, Sep 24, 2019 at 03:10:44PM +0200, Michal Vokáč wrote: > On 24. 09. 19 14:31, Andrew Lunn wrote: > I added the printk and the above fix and can confirm that it is the CPU > port and the phy is NULL pointer: > > [6.976366] qca8k 2188000.ethernet-1:0a: Using legacy PHYLIB callbacks. > Pl

Re: Fwd: [PATCH] bonding/802.3ad: fix slave initialization states race

2019-09-24 Thread Jay Vosburgh
Алексей Захаров wrote: [...] >Right after reboot one of the slaves hangs with actor port state 71 >and partner port state 1. >It doesn't send lacpdu and seems to be broken. >Setting link down and up again fixes slave state. [...] I think I see what failed in the first patch, could you test

Re: [PATCH] r8152: Use guard clause and fix comment typos

2019-09-24 Thread Grant Grundler
On Tue, Sep 24, 2019 at 4:47 PM Grant Grundler wrote: > > On Mon, Sep 23, 2019 at 7:47 PM Hayes Wang wrote: > > > > Prashant Malani [mailto:pmal...@chromium.org] > > > Sent: Tuesday, September 24, 2019 6:27 AM > > > To: Hayes Wang > > [...] > > > - do { > > > + while (1) { > > >

Re: [PATCH] r8152: Use guard clause and fix comment typos

2019-09-24 Thread Grant Grundler
On Mon, Sep 23, 2019 at 7:47 PM Hayes Wang wrote: > > Prashant Malani [mailto:pmal...@chromium.org] > > Sent: Tuesday, September 24, 2019 6:27 AM > > To: Hayes Wang > [...] > > - do { > > + while (1) { > > struct tx_agg *agg; > > + struct net_device *netdev = tp->

[PATCH iproute2(-next) 1/1] ip: fix ip route show json output for multipath nexthops

2019-09-24 Thread Julien Fortin
From: Julien Fortin print_rta_multipath doesn't support JSON output: { "dst":"27.0.0.13", "protocol":"bgp", "metric":20, "flags":[], "gateway":"169.254.0.1"dev uplink-1 weight 1 , "flags":["onlink"], "gateway":"169.254.0.1"dev uplink-2 weight 1 , "flags":["onlink"

[PATCH net] sch_netem: fix rcu splat in netem_enqueue()

2019-09-24 Thread Eric Dumazet
qdisc_root() use from netem_enqueue() triggers a lockdep warning. __dev_queue_xmit() uses rcu_read_lock_bh() which is not equivalent to rcu_read_lock() + local_bh_disable_bh as far as lockdep is concerned. WARNING: suspicious RCU usage 5.3.0-rc7+ #0 Not tainted - inclu

Re: Linux 5.4 - bpf test build fails

2019-09-24 Thread Shuah Khan
On 9/24/19 1:19 PM, Daniel Borkmann wrote: On Tue, Sep 24, 2019 at 12:56:53PM -0600, Shuah Khan wrote: On 9/24/19 12:49 PM, Daniel Borkmann wrote: On Tue, Sep 24, 2019 at 09:48:35AM -0600, Shuah Khan wrote: On 9/24/19 9:43 AM, Yonghong Song wrote: On 9/24/19 8:26 AM, Shuah Khan wrote: Hi Ale

Re: [PATCH v3 0/2] net: stmmac: Enhanced addressing mode for DWMAC 4.10

2019-09-24 Thread David Miller
From: Thierry Reding Date: Fri, 20 Sep 2019 19:00:34 +0200 > From: Thierry Reding > > The DWMAC 4.10 supports the same enhanced addressing mode as later > generations. Parse this capability from the hardware feature registers > and set the EAME (Enhanced Addressing Mode Enable) bit when necessa

[ANNOUNCE] iproute2 5.3 release

2019-09-24 Thread Stephen Hemminger
The 5.3 kernel has been released, and the last patches have been applied to iproute2. This update includes usual ammount of minor fixes and to tools and documentation. More to the newer tools like devlink and rdma. Download: https://www.kernel.org/pub/linux/utils/net/iproute2/iproute2-5.3.0.t

Re: [PATCH] net-icmp: remove ping_group_range sysctl

2019-09-24 Thread David Miller
From: Maciej Żenczykowski Date: Tue, 24 Sep 2019 16:47:00 +0200 >> Removing this is going to break things, you can't just remove a sysctl >> because "oh it was a bad idea to add this, sorry." > > Yeah, I know... but do you have any other suggestions? > > Would you take an alternative to make th

Re: [PATCHv2 iproute2 master] bpf: Fix race condition with map pinning

2019-09-24 Thread Stephen Hemminger
On Thu, 19 Sep 2019 19:04:47 -0700 Joe Stringer wrote: > If two processes attempt to invoke bpf_map_attach() at the same time, > then they will both create maps, then the first will successfully pin > the map to the filesystem and the second will not pin the map, but will > continue operating wit

Re: [PATCH net] bpf/xskmap: Return ERR_PTR for failure case instead of NULL.

2019-09-24 Thread Björn Töpel
On 2019-09-24 18:25, Jonathan Lemon wrote: When kzalloc() failed, NULL was returned to the caller, which tested the pointer with IS_ERR(), which didn't match, so the pointer was used later, resulting in a NULL dereference. Return ERR_PTR(-ENOMEM) instead of NULL. Reported-by: syzbot+491c1b7565b

[PATCH net] kcm: disable preemption in kcm_parse_func_strparser()

2019-09-24 Thread Eric Dumazet
After commit a2c11b034142 ("kcm: use BPF_PROG_RUN") syzbot easily triggers the warning in cant_sleep(). As explained in commit 6cab5e90ab2b ("bpf: run bpf programs with preemption disabled") we need to disable preemption before running bpf programs. BUG: assuming atomic context at net/kcm/kcmsock

Re: Linux 5.4 - bpf test build fails

2019-09-24 Thread Daniel Borkmann
On Tue, Sep 24, 2019 at 12:56:53PM -0600, Shuah Khan wrote: > On 9/24/19 12:49 PM, Daniel Borkmann wrote: > > On Tue, Sep 24, 2019 at 09:48:35AM -0600, Shuah Khan wrote: > > > On 9/24/19 9:43 AM, Yonghong Song wrote: > > > > On 9/24/19 8:26 AM, Shuah Khan wrote: > > > > > Hi Alexei and Daniel, > >

Re: Linux 5.4 - bpf test build fails

2019-09-24 Thread Shuah Khan
On 9/24/19 12:49 PM, Daniel Borkmann wrote: On Tue, Sep 24, 2019 at 09:48:35AM -0600, Shuah Khan wrote: On 9/24/19 9:43 AM, Yonghong Song wrote: On 9/24/19 8:26 AM, Shuah Khan wrote: Hi Alexei and Daniel, bpf test doesn't build on Linux 5.4 mainline. Do you know what's happening here. make -

Re: Linux 5.4 - bpf test build fails

2019-09-24 Thread Daniel Borkmann
On Tue, Sep 24, 2019 at 09:48:35AM -0600, Shuah Khan wrote: > On 9/24/19 9:43 AM, Yonghong Song wrote: > > On 9/24/19 8:26 AM, Shuah Khan wrote: > > > Hi Alexei and Daniel, > > > > > > bpf test doesn't build on Linux 5.4 mainline. Do you know what's > > > happening here. > > > > > > make -C tools

Re: Linux 5.4 - bpf test build fails

2019-09-24 Thread Shuah Khan
On 9/24/19 12:07 PM, tim.b...@sony.com wrote: -Original Message- From: Cristian Marussi on Tuesday, September 24, 2019 7:30 AM Hi Shuah On 24/09/2019 17:39, Shuah Khan wrote: On 9/24/19 10:03 AM, Shuah Khan wrote: On 9/24/19 9:52 AM, Cristian Marussi wrote: Hi Shuah On 24/09/2019

Re: [PATCH V11 0/4] BPF: New helper to obtain namespace data from current task

2019-09-24 Thread Carlos Antonio Neira Bustos
On Tue, Sep 24, 2019 at 08:01:17PM +0200, Daniel Borkmann wrote: > On Tue, Sep 24, 2019 at 12:20:01PM -0300, Carlos Neira wrote: > > Currently bpf_get_current_pid_tgid(), is used to do pid filtering in bcc's > > scripts but this helper returns the pid as seen by the root namespace which > > is > >

Re: [PATCH net v3] net/sched: cbs: Fix not adding cbs instance to list

2019-09-24 Thread Guedes, Andre
Hi Vinicius, > On Sep 23, 2019, at 10:04 PM, Vinicius Costa Gomes > wrote: > > The problem happens because that when offloading is enabled, the cbs > instance is not added to the list. > > Also, the current code doesn't handle correctly the case when offload > is disabled without removing the

RE: Linux 5.4 - bpf test build fails

2019-09-24 Thread Tim.Bird
> -Original Message- > From: Cristian Marussi on Tuesday, September 24, 2019 7:30 AM > > Hi Shuah > > On 24/09/2019 17:39, Shuah Khan wrote: > > On 9/24/19 10:03 AM, Shuah Khan wrote: > >> On 9/24/19 9:52 AM, Cristian Marussi wrote: > >>> Hi Shuah > >>> > >>> On 24/09/2019 16:26, Shuah

Re: [PATCH V11 0/4] BPF: New helper to obtain namespace data from current task

2019-09-24 Thread Daniel Borkmann
On Tue, Sep 24, 2019 at 12:20:01PM -0300, Carlos Neira wrote: > Currently bpf_get_current_pid_tgid(), is used to do pid filtering in bcc's > scripts but this helper returns the pid as seen by the root namespace which is > fine when a bcc script is not executed inside a container. > When the process

Re: Linux 5.4 - bpf test build fails

2019-09-24 Thread Cristian Marussi
Hi Shuah On 24/09/2019 17:39, Shuah Khan wrote: > On 9/24/19 10:03 AM, Shuah Khan wrote: >> On 9/24/19 9:52 AM, Cristian Marussi wrote: >>> Hi Shuah >>> >>> On 24/09/2019 16:26, Shuah Khan wrote: Hi Alexei and Daniel, bpf test doesn't build on Linux 5.4 mainline. Do you know what's

Re: [PATCH V2 net 1/1] net/tls(TLS_SW): Fix list_del double free caused by a race condition in tls_tx_records

2019-09-24 Thread Pooja Trivedi
On Mon, Sep 23, 2019 at 8:28 PM Jakub Kicinski wrote: > > On Sat, 21 Sep 2019 23:19:20 -0400, Pooja Trivedi wrote: > > On Wed, Sep 18, 2019 at 5:45 PM Jakub Kicinski wrote: > > > On Wed, 18 Sep 2019 17:37:44 -0400, Pooja Trivedi wrote: > > > > Hi Jakub, > > > > > > > > I have explained one potenti

Re: [PATCH net] skge: fix checksum byte order

2019-09-24 Thread Florian Fainelli
On 9/20/19 9:18 AM, Stephen Hemminger wrote: > From: Stephen Hemminger > > Running old skge driver on PowerPC causes checksum errors > because hardware reported 1's complement checksum is in little-endian > byte order. > > Reported-by: Benoit > Signed-off-by: Stephen Hemminger Fixes: 383181ac

Re: [PATCH net v3 0/3] Fix Qdisc destroy issues caused by adding fine-grained locking to filter API

2019-09-24 Thread Cong Wang
On Tue, Sep 24, 2019 at 8:51 AM Vlad Buslov wrote: > > TC filter API unlocking introduced several new fine-grained locks. The > change caused sleeping-while-atomic BUGs in several Qdiscs that call cls > APIs which need to obtain new mutex while holding sch tree spinlock. This > series fixes affect

Re: Linux 5.4 - bpf test build fails

2019-09-24 Thread Shuah Khan
On 9/24/19 10:03 AM, Shuah Khan wrote: On 9/24/19 9:52 AM, Cristian Marussi wrote: Hi Shuah On 24/09/2019 16:26, Shuah Khan wrote: Hi Alexei and Daniel, bpf test doesn't build on Linux 5.4 mainline. Do you know what's happening here. make -C tools/testing/selftests/bpf/ side question, sin

Re: [RFC PATCH bpf-next v2 1/2] bpf: adding map batch processing support

2019-09-24 Thread Yonghong Song
On 9/23/19 4:20 PM, Brian Vazquez wrote: > Hi Yonghong, thanks for working on this! > > I have some concerns about this implementation but overall I think > this might work for our use case too! Thanks for reviewing the patch. I will get back to this very soon. > > On Sun, Sep 8, 2019 at 1:11

Re: [PATCH 4.19-stable 0/7] mlx5 checksum fixes for 4.19

2019-09-24 Thread Greg KH
On Mon, Sep 23, 2019 at 05:51:06PM +0200, David Miller wrote: > From: Saeed Mahameed > Date: Mon, 23 Sep 2019 12:39:57 + > > > This series includes some upstream patches aimed to fix multiple checksum > > issues with mlx5 driver in 4.19-stable kernels. > > > > Since the patches didn't apply

[PATCH net] bpf/xskmap: Return ERR_PTR for failure case instead of NULL.

2019-09-24 Thread Jonathan Lemon
When kzalloc() failed, NULL was returned to the caller, which tested the pointer with IS_ERR(), which didn't match, so the pointer was used later, resulting in a NULL dereference. Return ERR_PTR(-ENOMEM) instead of NULL. Reported-by: syzbot+491c1b7565ba9069e...@syzkaller.appspotmail.com Fixes: 04

[PATCH net] bpf/xskmap: Return ERR_PTR for failure case instead of NULL.

2019-09-24 Thread Jonathan Lemon
When kzalloc() failed, NULL was returned to the caller, which tested the pointer with IS_ERR(), which didn't match, so the pointer was used later, resulting in a NULL dereference. Return ERR_PTR(-ENOMEM) instead of NULL. Reported-by: syzbot+491c1b7565ba9069e...@syzkaller.appspotmail.com Fixes: 04

Re: Linux 5.4 - bpf test build fails

2019-09-24 Thread Shuah Khan
On 9/24/19 9:52 AM, Cristian Marussi wrote: Hi Shuah On 24/09/2019 16:26, Shuah Khan wrote: Hi Alexei and Daniel, bpf test doesn't build on Linux 5.4 mainline. Do you know what's happening here. make -C tools/testing/selftests/bpf/ side question, since I'm writing arm64/ tests. my "build-

[PATCH v2] dimlib: make DIMLIB a hidden symbol

2019-09-24 Thread Uwe Kleine-König
According to Tal Gilboa the only benefit from DIM comes from a driver that uses it. So it doesn't make sense to make this symbol user visible, instead all drivers that use it should select it (as is already the case AFAICT). Signed-off-by: Uwe Kleine-König --- Hello David, On Tue, Sep 24, 2019 a

Re: [PATCH net] net/rds: Check laddr_check before calling it

2019-09-24 Thread Ka-Cheong Poon
On 9/21/19 9:09 AM, Jakub Kicinski wrote: On Tue, 17 Sep 2019 08:29:18 -0700, Ka-Cheong Poon wrote: In rds_bind(), laddr_check is called without checking if it is NULL or not. And rs_transport should be reset if rds_add_bound() fails. Reported-by: syzbot+fae39afd2101a17ec...@syzkaller.appspotm

Re: Linux 5.4 - bpf test build fails

2019-09-24 Thread Cristian Marussi
Hi Shuah On 24/09/2019 16:26, Shuah Khan wrote: > Hi Alexei and Daniel, > > bpf test doesn't build on Linux 5.4 mainline. Do you know what's > happening here. > > > make -C tools/testing/selftests/bpf/ side question, since I'm writing arm64/ tests. my "build-testcases" following the KSFT docs

[PATCH net v3 3/3] net: sched: sch_sfb: don't call qdisc_put() while holding tree lock

2019-09-24 Thread Vlad Buslov
Recent changes that removed rtnl dependency from rules update path of tc also made tcf_block_put() function sleeping. This function is called from ops->destroy() of several Qdisc implementations, which in turn is called by qdisc_put(). Some Qdiscs call qdisc_put() while holding sch tree spinlock, w

[PATCH net v3 2/3] net: sched: multiq: don't call qdisc_put() while holding tree lock

2019-09-24 Thread Vlad Buslov
Recent changes that removed rtnl dependency from rules update path of tc also made tcf_block_put() function sleeping. This function is called from ops->destroy() of several Qdisc implementations, which in turn is called by qdisc_put(). Some Qdiscs call qdisc_put() while holding sch tree spinlock, w

[PATCH net v3 0/3] Fix Qdisc destroy issues caused by adding fine-grained locking to filter API

2019-09-24 Thread Vlad Buslov
TC filter API unlocking introduced several new fine-grained locks. The change caused sleeping-while-atomic BUGs in several Qdiscs that call cls APIs which need to obtain new mutex while holding sch tree spinlock. This series fixes affected Qdiscs by ensuring that cls API that became sleeping is onl

[PATCH net v3 1/3] net: sched: sch_htb: don't call qdisc_put() while holding tree lock

2019-09-24 Thread Vlad Buslov
Recent changes that removed rtnl dependency from rules update path of tc also made tcf_block_put() function sleeping. This function is called from ops->destroy() of several Qdisc implementations, which in turn is called by qdisc_put(). Some Qdiscs call qdisc_put() while holding sch tree spinlock, w

[PATCH net] net/rds: Check laddr_check before calling it

2019-09-24 Thread Ka-Cheong Poon
In rds_bind(), laddr_check is called without checking if it is NULL or not. And rs_transport should be reset if rds_add_bound() fails. Fixes: c5c1a030a7db ("net/rds: An rds_sock is added too early to the hash table") Reported-by: syzbot+fae39afd2101a17ec...@syzkaller.appspotmail.com Signed-off-b

Re: Linux 5.4 - bpf test build fails

2019-09-24 Thread Shuah Khan
On 9/24/19 9:43 AM, Yonghong Song wrote: On 9/24/19 8:26 AM, Shuah Khan wrote: Hi Alexei and Daniel, bpf test doesn't build on Linux 5.4 mainline. Do you know what's happening here. make -C tools/testing/selftests/bpf/ -c progs/test_core_reloc_ptr_as_arr.c -o - || echo "clang failed") | \

Re: Linux 5.4 - bpf test build fails

2019-09-24 Thread Yonghong Song
On 9/24/19 8:26 AM, Shuah Khan wrote: > Hi Alexei and Daniel, > > bpf test doesn't build on Linux 5.4 mainline. Do you know what's > happening here. > > > make -C tools/testing/selftests/bpf/ > > -c progs/test_core_reloc_ptr_as_arr.c -o - || echo "clang failed") | \ > llc -march=bpf -mcpu=gen

Re: [PATCH net-next] net/rds: Check laddr_check before calling it

2019-09-24 Thread Ka-Cheong Poon
On 9/24/19 11:27 PM, Ka-Cheong Poon wrote: In rds_bind(), laddr_check is called without checking if it is NULL or not. And rs_transport should be reset if rds_add_bound() fails. Fixes: c5c1a030a7db ("net/rds: Check laddr_check before calling it") Oops, wrong Subject. Will re-submit. Sorry

[PATCH net-next] net/rds: Check laddr_check before calling it

2019-09-24 Thread Ka-Cheong Poon
In rds_bind(), laddr_check is called without checking if it is NULL or not. And rs_transport should be reset if rds_add_bound() fails. Fixes: c5c1a030a7db ("net/rds: Check laddr_check before calling it") Reported-by: syzbot+fae39afd2101a17ec...@syzkaller.appspotmail.com Signed-off-by: Ka-Cheong P

Linux 5.4 - bpf test build fails

2019-09-24 Thread Shuah Khan
Hi Alexei and Daniel, bpf test doesn't build on Linux 5.4 mainline. Do you know what's happening here. make -C tools/testing/selftests/bpf/ -c progs/test_core_reloc_ptr_as_arr.c -o - || echo "clang failed") | \ llc -march=bpf -mcpu=generic -filetype=obj -o /mnt/data/lkml/linux_5.4/tools/test

[PATCH bpf-next v11 4/4] tools/testing/selftests/bpf: Add self-tests for new helper.

2019-09-24 Thread Carlos Neira
Self tests added for new helper Signed-off-by: Carlos Neira --- tools/testing/selftests/bpf/Makefile | 2 +- tools/testing/selftests/bpf/bpf_helpers.h | 3 + .../selftests/bpf/progs/test_pidns_kern.c | 71 tools/testing/selftests/bpf/test_pidns.c | 152 +++

[PATCH bpf-next v11 1/4] fs/nsfs.c: added ns_match

2019-09-24 Thread Carlos Neira
ns_match returns true if the namespace inode and dev_t matches the ones provided by the caller. Signed-off-by: Carlos Neira --- fs/nsfs.c | 8 include/linux/proc_ns.h | 2 ++ 2 files changed, 10 insertions(+) diff --git a/fs/nsfs.c b/fs/nsfs.c index a0431642c6b5..256f6295

[PATCH bpf-next v11 3/4] tools: Added bpf_get_ns_current_pid_tgid helper

2019-09-24 Thread Carlos Neira
Signed-off-by: Carlos Neira --- tools/include/uapi/linux/bpf.h | 18 +- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/tools/include/uapi/linux/bpf.h b/tools/include/uapi/linux/bpf.h index 77c6be96d676..9272dc8fb08c 100644 --- a/tools/include/uapi/linux/bpf.h +++ b/

[PATCH V11 0/4] BPF: New helper to obtain namespace data from current task

2019-09-24 Thread Carlos Neira
Currently bpf_get_current_pid_tgid(), is used to do pid filtering in bcc's scripts but this helper returns the pid as seen by the root namespace which is fine when a bcc script is not executed inside a container. When the process of interest is inside a container, pid filtering will not work if bpf

[PATCH bpf-next v11 2/4] bpf: added new helper bpf_get_ns_current_pid_tgid

2019-09-24 Thread Carlos Neira
New bpf helper bpf_get_ns_current_pid_tgid, This helper will return pid and tgid from current task which namespace matches dev_t and inode number provided, this will allows us to instrument a process inside a container. Signed-off-by: Carlos Neira --- include/linux/bpf.h | 1 + include/uap

Re: [PATCH net] ppp: Fix memory leak in ppp_write

2019-09-24 Thread Guillaume Nault
On Sun, Sep 22, 2019 at 04:45:31PM +0900, Takeshi Misawa wrote: > When ppp is closing, __ppp_xmit_process() failed to enqueue skb > and skb allocated in ppp_write() is leaked. > > syzbot reported : > BUG: memory leak > unreferenced object 0x88812a17bc00 (size 224): > comm "syz-executor673",

[PATCH net 0/3] tcp: provide correct skb->priority

2019-09-24 Thread Eric Dumazet
SO_PRIORITY socket option requests TCP egress packets to contain a user provided value. TCP manages to send most packets with the requested values, notably for TCP_ESTABLISHED state, but fails to do so for few packets. These packets are control packets sent on behalf of SYN_RECV or TIME_WAIT stat

[PATCH net 2/3] ipv6: tcp: provide sk->sk_priority to ctl packets

2019-09-24 Thread Eric Dumazet
We can populate skb->priority for some ctl packets instead of always using zero. Signed-off-by: Eric Dumazet --- net/ipv6/tcp_ipv6.c | 16 +--- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/net/ipv6/tcp_ipv6.c b/net/ipv6/tcp_ipv6.c index 806064c2886777ad37a1f0b8406aa

[PATCH net 1/3] ipv6: add priority parameter to ip6_xmit()

2019-09-24 Thread Eric Dumazet
Currently, ip6_xmit() sets skb->priority based on sk->sk_priority This is not desirable for TCP since TCP shares the same ctl socket for a given netns. We want to be able to send RST or ACK packets with a non zero skb->priority. This patch has no functional change. Signed-off-by: Eric Dumazet -

[PATCH net 3/3] tcp: honor SO_PRIORITY in TIME_WAIT state

2019-09-24 Thread Eric Dumazet
ctl packets sent on behalf of TIME_WAIT sockets currently have a zero skb->priority, which can cause various problems. In this patch we : - add a tw_priority field in struct inet_timewait_sock. - populate it from sk->sk_priority when a TIME_WAIT is created. - For IPv4, change ip_send_unicast_re

Re: [PATCH net] skge: fix checksum byte order

2019-09-24 Thread David Miller
From: Stephen Hemminger Date: Fri, 20 Sep 2019 18:18:26 +0200 > From: Stephen Hemminger > > Running old skge driver on PowerPC causes checksum errors > because hardware reported 1's complement checksum is in little-endian > byte order. > > Reported-by: Benoit > Signed-off-by: Stephen Hemminge

Re: atlantic: weird hwmon temperature readings with AQC107 NIC (kernel 5.2/5.3)

2019-09-24 Thread Holger Hoffstätte
On 9/24/19 4:32 PM, Igor Russkikh wrote: We've recently found out that as well, could you try applying the following patch: diff --git a/drivers/net/ethernet/aquantia/atlantic/hw_atl/hw_atl_utils_fw2x.c b/drivers/net/ethernet/aquantia/atlantic/hw_atl/hw_atl_utils_fw2x.c index da726489e3c8..08b0

Re: [PATCH] arcnet: provide a buffer big enough to actually receive packets

2019-09-24 Thread David Miller
From: Uwe Kleine-König Date: Fri, 20 Sep 2019 16:08:21 +0200 > struct archdr is only big enough to hold the header of various types of > arcnet packets. So to provide enough space to hold the data read from > hardware provide a buffer large enough to hold a packet with maximal > size. > > The pr

Re: [PATCH] net-icmp: remove ping_group_range sysctl

2019-09-24 Thread Maciej Żenczykowski
> Removing this is going to break things, you can't just remove a sysctl > because "oh it was a bad idea to add this, sorry." Yeah, I know... but do you have any other suggestions? Would you take an alternative to make the default wide opened? The current sysctl just doesn't work. It can even p

Re: [PATCH] net-icmp: remove ping_group_range sysctl

2019-09-24 Thread David Miller
Removing this is going to break things, you can't just remove a sysctl because "oh it was a bad idea to add this, sorry."

Re: [PATCH 0/5] Raw socket cleanups

2019-09-24 Thread David Miller
From: Greg Kroah-Hartman Date: Fri, 20 Sep 2019 09:35:44 +0200 > Ori Nimron pointed out that there are a number of places in the kernel > where you can create a raw socket, without having to have the > CAP_NET_RAW permission. > > To resolve this, here's a short patch series to test these odd and

Re: [PATCH net] net: sched: fix possible crash in tcf_action_destroy()

2019-09-24 Thread David Miller
From: Eric Dumazet Date: Wed, 18 Sep 2019 12:57:04 -0700 > If the allocation done in tcf_exts_init() failed, > we end up with a NULL pointer in exts->actions. ... > Fixes: 90b73b77d08e ("net: sched: change action API to use array of pointers > to actions") > Signed-off-by: Eric Dumazet > Repor

Re: atlantic: weird hwmon temperature readings with AQC107 NIC (kernel 5.2/5.3)

2019-09-24 Thread Igor Russkikh
On 24.09.2019 17:30, Holger Hoffstätte wrote: > On 9/24/19 4:16 PM, Holger Hoffstätte wrote: >> Hi, >> >> I recently upgraded my home network with two AQ107-based NICs and a >> multi-speed switch. Everything works great, but I couldn't help but notice >> very weird hwmon temperature output (which

Re: atlantic: weird hwmon temperature readings with AQC107 NIC (kernel 5.2/5.3)

2019-09-24 Thread Holger Hoffstätte
On 9/24/19 4:16 PM, Holger Hoffstätte wrote: Hi, I recently upgraded my home network with two AQ107-based NICs and a multi-speed switch. Everything works great, but I couldn't help but notice very weird hwmon temperature output (which I wanted to use for monitoring and alerting). Both cards ide

atlantic: weird hwmon temperature readings with AQC107 NIC (kernel 5.2/5.3)

2019-09-24 Thread Holger Hoffstätte
Hi, I recently upgraded my home network with two AQ107-based NICs and a multi-speed switch. Everything works great, but I couldn't help but notice very weird hwmon temperature output (which I wanted to use for monitoring and alerting). Both cards identify as: $lspci -v -s 06:00.0 06:00.0 Ethern

Re: [PATCH] bonding/802.3ad: fix slave initialization states race

2019-09-24 Thread David Miller
From: Aleksei Zakharov Date: Wed, 18 Sep 2019 16:05:45 +0300 > Once a while, one of 802.3ad slaves fails to initialize and hangs in > BOND_LINK_FAIL state. Commit 334031219a84 ("bonding/802.3ad: fix slave > link initialization transition states") checks slave->last_link_up. But > link can still h

Re: [BUG] Unable to handle kernel NULL pointer dereference in phy_support_asym_pause

2019-09-24 Thread Michal Vokáč
On 24. 09. 19 14:31, Andrew Lunn wrote: On Tue, Sep 24, 2019 at 01:27:24PM +0200, Michal Vokáč wrote: Hi, just tried booting latest next-20190920 on our imx6dl-yapp4-hydra platform with QCA8334 switch and got this: [7.424620] [<806840e0>] (phy_support_asym_pause) from [<80686724>] (qca8k_

Re: [BUG] Unable to handle kernel NULL pointer dereference in phy_support_asym_pause

2019-09-24 Thread Andrew Lunn
On Tue, Sep 24, 2019 at 01:27:24PM +0200, Michal Vokáč wrote: > Hi, > > just tried booting latest next-20190920 on our imx6dl-yapp4-hydra platform > with QCA8334 switch and got this: > > [7.424620] [<806840e0>] (phy_support_asym_pause) from [<80686724>] > (qca8k_port_enable+0x40/0x48) > [

Hello

2019-09-24 Thread Edith Brown
-- Hello dear how are you? my name is Edith Brown i am a U.S military woman is my pleasure meeting you here best regards

Re: CONFIG_NET_TC_SKB_EXT

2019-09-24 Thread Paul Blakey
On 9/23/2019 8:17 PM, Edward Cree wrote: > On 23/09/2019 17:56, Paul Blakey wrote: >> Even following this approach in tc only is challenging for some >> scenarios, consider the following tc rules: >> >> tc filter add dev1 ... chain 0 flower action goto chain 1 >> tc filter add dev1 ... chain 0 fl

[BUG] Unable to handle kernel NULL pointer dereference in phy_support_asym_pause

2019-09-24 Thread Michal Vokáč
Hi, just tried booting latest next-20190920 on our imx6dl-yapp4-hydra platform with QCA8334 switch and got this: [6.957822] 8<--- cut here --- [6.963550] Unable to handle kernel NULL pointer dereference at virtual address 0264 [6.974342] pgd = (ptrval) [6.979751] [0264]

[PATCH] openvswitch: change type of UPCALL_PID attribute to NLA_UNSPEC

2019-09-24 Thread Li RongQing
userspace openvswitch patch "(dpif-linux: Implement the API functions to allow multiple handler threads read upcall)" changes its type from U32 to UNSPEC, but leave the kernel unchanged and after kernel 6e237d099fac "(netlink: Relax attr validation for fixed length types)", this bug is exposed by

Re: [PATCH net v3] net/sched: cls_api: Fix nooffloaddevcnt counter when indr block call success

2019-09-24 Thread Or Gerlitz
On Mon, Sep 23, 2019 at 5:21 PM wenxu wrote: > 在 2019/9/23 17:42, John Hurley 写道: > > On Mon, Sep 23, 2019 at 5:20 AM wenxu wrote: > >> Hi John & Jakub > >> > >> There are some limitations for indirect tc callback work with skip_sw ? > >> > > Hi Wenxu, > > This is not really a limitation. > > As

Re: [pull request][net 0/7] Mellanox, mlx5 fixes 2019-09-24

2019-09-24 Thread Saeed Mahameed
On Tue, 2019-09-24 at 09:41 +, Saeed Mahameed wrote: > Hi Dave, > > This series introduces some fixes to mlx5 driver. > For more information please see tag log below. > > Please pull and let me know if there is any problem. > > For -stable v4.10: correction: 4.20, NOT 4.10. > ('net/mlx5e:

[net 4/7] net/mlx5: DR, Allow matching on vport based on vhca_id

2019-09-24 Thread Saeed Mahameed
From: Alaa Hleihel In case source_eswitch_owner_vhca_id is given as a match, the source_vport (vhca_id) will be set in case vhca_id_valid. This will allow matching on peer vports, vports that belong to the other pf. Fixes: 26d688e33f88 ("net/mlx5: DR, Add Steering entry (STE) utilities") Signed

[net 3/7] net/mlx5: DR, Fix getting incorrect prev node in ste_free

2019-09-24 Thread Saeed Mahameed
From: Alex Vesker When we free an STE and the STE is in the middle of collision list, the prev_ste was obtained incorrectly from the list. To avoid such issues list_entry calls replaced with standard list API. Fixes: 26d688e33f88 ("net/mlx5: DR, Add Steering entry (STE) utilities") Signed-off-by

[net 6/7] net/mlx5e: Fix traffic duplication in ethtool steering

2019-09-24 Thread Saeed Mahameed
Before this patch, when adding multiple ethtool steering rules with identical classification, the driver used to append the new destination to the already existing hw rule, which caused the hw to forward the traffic to all destinations (rx queues). Here we avoid this by setting the "no append" mlx

[net 1/7] net/mlx5: DR, Fix SW steering HW bits and definitions

2019-09-24 Thread Saeed Mahameed
From: Yevgeny Kliteynik Fix wrong reserved bits offsets. Fixes: 97b5484ed608 ("net/mlx5: Add HW bits and definitions required for SW steering") Signed-off-by: Yevgeny Kliteynik Reviewed-by: Alex Vesker Signed-off-by: Saeed Mahameed --- include/linux/mlx5/mlx5_ifc.h | 28 ++--

[net 5/7] net/mlx5: Add device ID of upcoming BlueField-2

2019-09-24 Thread Saeed Mahameed
From: Bodong Wang Add the device ID of upcoming BlueField-2 integrated ConnectX-6 Dx network controller. Its VFs will be using the generic VF device ID: 0x101e "ConnectX Family mlx5Gen Virtual Function". Fixes: 2e9d3e83ab82 ("net/mlx5: Update the list of the PCI supported devices") Signed-off-by

[net 7/7] net/mlx5e: Fix matching on tunnel addresses type

2019-09-24 Thread Saeed Mahameed
From: Dmytro Linkin In mlx5 parse_tunnel_attr() function dispatch on encap IP address type is performed by directly checking flow_rule_match_key() on FLOW_DISSECTOR_KEY_ENC_IPV4_ADDRS, and then on FLOW_DISSECTOR_KEY_ENC_IPV6_ADDRS. However, since those are stored in union, first check is always t

[net 2/7] net/mlx5: DR, Remove redundant vport number from action

2019-09-24 Thread Saeed Mahameed
From: Alex Vesker The vport number is part of the vport_cap, there is no reason to store in a separate variable on the vport. Fixes: 9db810ed2d37 ("net/mlx5: DR, Expose steering action functionality") Signed-off-by: Alex Vesker Reviewed-by: Maor Gottlieb Signed-off-by: Saeed Mahameed --- dri

[pull request][net 0/7] Mellanox, mlx5 fixes 2019-09-24

2019-09-24 Thread Saeed Mahameed
Hi Dave, This series introduces some fixes to mlx5 driver. For more information please see tag log below. Please pull and let me know if there is any problem. For -stable v4.10: ('net/mlx5e: Fix traffic duplication in ethtool steering') For -stable v4.19: ('net/mlx5: Add device ID of upcoming

Re: [PATCH] IB/mlx5: add checking for "vf" from do_setvfinfo()

2019-09-24 Thread Dan Carpenter
On Thu, Apr 25, 2019 at 06:15:13AM +, Parav Pandit wrote: > > > > -Original Message- > > From: Dan Carpenter > > Sent: Wednesday, April 24, 2019 9:08 AM > > To: Parav Pandit ; netdev@vger.kernel.org > > Cc: Leon Romanovsky ; Eli Cohen ; > > Doug Ledford ; Jason Gunthorpe ; > > linux-

ethtool 5.2 qsfp.c heap buffer overflow

2019-09-24 Thread Qiwei Wen
Hi, The function "sff8636_dom_parse", called from "sff8636_show_dom", disregards the module eeprom size returned from the driver and assumes the existence of upper pages, e.g. sd->sfp_temp[HALRM] = SFF8636_OFFSET_TO_TEMP(SFF8636_TEMP_HALRM); To reproduce: return ETH_MODULE_SFF_8636_LEN (256) for