[PATCH] xen-netback: Fix logging message with spurious period after newline

2017-12-05 Thread Joe Perches
Using a period after a newline causes bad output. Signed-off-by: Joe Perches --- drivers/net/xen-netback/interface.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/xen-netback/interface.c b/drivers/net/xen-netback/interface.c index

[PATCH net-next v2 2/2] bpf/tracing: add a bpf test for new ioctl query interface

2017-12-05 Thread Yonghong Song
Added a subtest in test_progs. The tracepoint is sched/sched_switch. Multiple bpf programs are attached to this tracepoint and the query interface is exercised. Signed-off-by: Yonghong Song Acked-by: Alexei Starovoitov --- tools/include/uapi/linux/perf_event.h

[PATCH net-next v2 0/2] bpf/tracing: allow user space to query prog array on the same tp

2017-12-05 Thread Yonghong Song
Commit e87c6bc3852b ("bpf: permit multiple bpf attachments for a single perf event") added support to attach multiple bpf programs to a single perf event. Given a perf event (kprobe, uprobe, or kernel tracepoint), the perf ioctl interface is used to query bpf programs attached to the same trace

[PATCH net-next v2 1/2] bpf/tracing: allow user space to query prog array on the same tp

2017-12-05 Thread Yonghong Song
Commit e87c6bc3852b ("bpf: permit multiple bpf attachments for a single perf event") added support to attach multiple bpf programs to a single perf event. Commit 2541517c32be ("tracing, perf: Implement BPF programs attached to kprobes") utilized the existing perf ioctl interface and added the

Re: [PATCH v2 3/3] net: macb: change GFP_ATOMIC to GFP_KERNEL

2017-12-05 Thread Julia Lawall
On Tue, 5 Dec 2017, Julia Cartwright wrote: > Now that the rx_fs_lock is no longer held across allocation, it's safe > to use GFP_KERNEL for allocating new entries. > > This reverts commit 81da3bf6e3f88 ("net: macb: change GFP_KERNEL to > GFP_ATOMIC"). > > Cc: Julia Lawall

Re: [PATCH iproute2] iproute2: Fix undeclared __kernel_long_t type build error in RHEL 6.8

2017-12-05 Thread Leon Romanovsky
On Tue, Dec 05, 2017 at 05:33:25PM -0800, Stephen Hemminger wrote: > On Fri, 1 Dec 2017 13:04:51 +0200 > Leon Romanovsky wrote: > > > From: Leon Romanovsky > > > > Add asm/posix_types.h header file to the list of needed includes, > > because the headers

Re: Sending 802.1Q packets using AF_PACKET socket on filtered bridge forwards with wrong MAC addresses

2017-12-05 Thread Toshiaki Makita
Hi, (CC: Vlad) On 2017/11/30 7:01, Brandon Carpenter wrote: > I narrowed the search to a memmove() called from > skb_reorder_vlan_header() in net/core/skbuff.c. > >> memmove(skb->data - ETH_HLEN, skb->data - skb->mac_len - VLAN_HLEN, >>2 * ETH_ALEN); > > Calling skb_reset_mac_len()

Re: Transport mode xfrm_gro

2017-12-05 Thread Herbert Xu
On Wed, Dec 06, 2017 at 02:37:17PM +1100, Herbert Xu wrote: > > So why is xfrm_input in the xfrm_gro case trying to reinject the > skb into the network stack? Nevermind, I see now that transport_finish has code to skip xfrm_gro packets. Cheers, -- Email: Herbert Xu

Re: [PATCH net-next] tun: avoid unnecessary READ_ONCE in tun_net_xmit

2017-12-05 Thread Jason Wang
On 2017年12月06日 11:11, Willem de Bruijn wrote: From: Willem de Bruijn The statement no longer serves a purpose. Commit fa35864e0bb7 ("tuntap: Fix for a race in accessing numqueues") added the ACCESS_ONCE to avoid a race condition with skb_queue_len. Commit 436accebb530

Transport mode xfrm_gro

2017-12-05 Thread Herbert Xu
Hi Steffen: I'm looking at the function xfrm_input near the end where it deals with transport mode packets: err = x->inner_mode->afinfo->transport_finish(skb, xfrm_gro || async); if (xfrm_gro) { if (skb->sp)

Re: [PATCH] ptr_ring: add barriers

2017-12-05 Thread Jason Wang
On 2017年12月06日 10:53, Michael S. Tsirkin wrote: On Wed, Dec 06, 2017 at 10:31:39AM +0800, Jason Wang wrote: On 2017年12月06日 03:29, Michael S. Tsirkin wrote: Users of ptr_ring expect that it's safe to give the data structure a pointer and have it be available to consumers, but that actually

Re: [PATCH net-next 00/12] sctp: Implement Stream Interleave: The I-DATA Chunk Supporting User Message Interleaving

2017-12-05 Thread Xin Long
On Wed, Dec 6, 2017 at 1:30 AM, Marcelo Ricardo Leitner wrote: > On Tue, Dec 05, 2017 at 11:15:57PM +0800, Xin Long wrote: >> Stream Interleave would be Implemented in two Parts: >>1. The I-DATA Chunk Supporting User Message Interleaving >>2. Interaction with

Re: [PATCH] netlink: Add netns check on taps

2017-12-05 Thread Kevin Cernekee
On Tue, Dec 5, 2017 at 6:19 PM, David Ahern wrote: >> + if (!net_eq(dev_net(dev), sock_net(sk)) && >> + !net_eq(dev_net(dev), _net)) { > > Why is init_net special? Seems like snooping should be limited to the > namespace you are in. Depends how important it is to

[PATCH net-next] tun: avoid unnecessary READ_ONCE in tun_net_xmit

2017-12-05 Thread Willem de Bruijn
From: Willem de Bruijn The statement no longer serves a purpose. Commit fa35864e0bb7 ("tuntap: Fix for a race in accessing numqueues") added the ACCESS_ONCE to avoid a race condition with skb_queue_len. Commit 436accebb530 ("tuntap: remove unnecessary sk_receive_queue

Re: [PATCH] ptr_ring: add barriers

2017-12-05 Thread Michael S. Tsirkin
On Wed, Dec 06, 2017 at 10:31:39AM +0800, Jason Wang wrote: > > > On 2017年12月06日 03:29, Michael S. Tsirkin wrote: > > Users of ptr_ring expect that it's safe to give the > > data structure a pointer and have it be available > > to consumers, but that actually requires an smb_wmb > > or a

dsa: dsa_slave_port_obj_del calls multiple times with SWITCHDEV_OBJ_ID_HOST_MDB obj id

2017-12-05 Thread Tristram.Ha
I found the latest net-next kernel calls dsa_slave_port_obj_del() multiple times, one for each port, with host port as the parameter. As the base driver cannot find an entry with that host port, it returns an error and so users will see a lot of failures from the DSA switch. Is this a new

Re: [PATCH] ptr_ring: add barriers

2017-12-05 Thread Jason Wang
On 2017年12月06日 03:29, Michael S. Tsirkin wrote: Users of ptr_ring expect that it's safe to give the data structure a pointer and have it be available to consumers, but that actually requires an smb_wmb or a stronger barrier. In absence of such barriers and on architectures that reorder

Re: [PATCH net-next V3] tun: add eBPF based queue selection method

2017-12-05 Thread Jason Wang
On 2017年12月06日 01:02, David Miller wrote: From: Jason Wang Date: Mon, 4 Dec 2017 17:31:23 +0800 This patch introduces an eBPF based queue selection method. With this, the policy could be offloaded to userspace completely through a new ioctl TUNSETSTEERINGEBPF.

Re: [PATCH] netlink: Add netns check on taps

2017-12-05 Thread David Ahern
On 12/5/17 3:46 PM, Kevin Cernekee wrote: > Currently, a nlmon link inside a child namespace can observe systemwide > netlink activity. Filter the traffic so that in a non-init netns, > nlmon can only sniff netlink messages from its own netns. > > Test case: > > vpnns -- bash -c "ip link

[PATCH net] enic: add wq clean up budget

2017-12-05 Thread Govindarajulu Varadarajan
In case of tx clean up, we set '-1' as budget. This means clean up until wq is empty or till (1 << 32) pkts are cleaned. Under heavy load this will run for long time and cause "watchdog: BUG: soft lockup - CPU#25 stuck for 21s!" warning. This patch sets wq clean up budget to 256. Signed-off-by:

Re: [PATCH V11 4/5] vsprintf: add printk specifier %px

2017-12-05 Thread Sergey Senozhatsky
On (12/05/17 17:59), Linus Torvalds wrote: [..] > On Tue, Dec 5, 2017 at 5:36 PM, Sergey Senozhatsky > wrote: > > I see some %p-s being used in _supposedly_ important output, > > like arch/x86/mm/fault.c > > > > show_fault_oops(struct pt_regs *regs, unsigned

Re: [PATCH V11 4/5] vsprintf: add printk specifier %px

2017-12-05 Thread Linus Torvalds
On Tue, Dec 5, 2017 at 5:36 PM, Sergey Senozhatsky wrote: > I see some %p-s being used in _supposedly_ important output, > like arch/x86/mm/fault.c > > show_fault_oops(struct pt_regs *regs, unsigned long error_code, > unsigned long address) > ...

Re: [PATCH 2/2] veth: allow configuring GSO maximums

2017-12-05 Thread Solio Sarabia
On Tue, Dec 05, 2017 at 05:25:10PM -0800, Stephen Hemminger wrote: > On Tue, 5 Dec 2017 17:14:26 -0800 > Solio Sarabia wrote: > > > From: Stephen Hemminger > > > > Veth's can be used in environments (like Azure) where the underlying > >

[PATCH net-next] rds: debug: fix null check on static array

2017-12-05 Thread Prashant Bhole
t_name cannot be NULL since it is an array field of a struct. Replacing null check on static array with string length check using strnlen() Signed-off-by: Prashant Bhole --- net/rds/connection.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff

RE: [PATCH net-next v3 4/4] net: fec: add phy_reset_after_clk_enable() support

2017-12-05 Thread Andy Duan
From: Richard Leitner Sent: Tuesday, December 05, 2017 9:26 PM >Some PHYs (for example the SMSC LAN8710/LAN8720) doesn't allow turning >the refclk on and off again during operation (according to their datasheet). >Nonetheless exactly this behaviour was introduced for power saving

[PATCH v1 net-next 0/1] net: dsa: microchip: Add Microchip KSZ8895 DSA driver

2017-12-05 Thread Tristram.Ha
From: Tristram Ha This patch requires the previous patch for Microchip KSZ8795 DSA driver. v1 - For latest KSZ8795 v3 patch Tristram Ha (1): Add Microchip KSZ8895 DSA driver. drivers/net/dsa/microchip/Kconfig | 17 + drivers/net/dsa/microchip/Makefile

[PATCH v3 net-next] net: dsa: Modify tag_ksz.c so that tail tag code can be used by other KSZ switch drivers

2017-12-05 Thread Tristram.Ha
From: Tristram Ha Modify tag_ksz.c so that tail tag code can be used by other KSZ switch drivers. Signed-off-by: Tristram Ha Reviewed-by: Woojung Huh --- v3 - For latest KSZ9477 patch v2 - No new feature is

[PATCH v3 net-next 0/1] net: dsa: microchip: Add Microchip KSZ8795 DSA driver

2017-12-05 Thread Tristram.Ha
From: Tristram Ha This patch requires the previous patches for Microchip KSZ9477 DSA driver. v3 - For latest KSZ9477 v2 patch v2 - No new feature is introduced in tag_ksz.c v1 - Return error codes instead of numbers - Add more comments to clarify operation - Use

[PATCH v1 net-next 1/1] net: dsa: microchip: Add Microchip KSZ8895 DSA driver

2017-12-05 Thread Tristram.Ha
From: Tristram Ha Add Microchip KSZ8895 DSA driver. Signed-off-by: Tristram Ha Reviewed-by: Woojung Huh --- drivers/net/dsa/microchip/Kconfig | 17 + drivers/net/dsa/microchip/Makefile |2 +

[PATCH v3 net-next 1/1] net: dsa: microchip: Add Microchip KSZ8795 DSA driver

2017-12-05 Thread Tristram.Ha
From: Tristram Ha Add Microchip KSZ8795 DSA driver. Signed-off-by: Tristram Ha Reviewed-by: Woojung Huh --- drivers/net/dsa/microchip/Kconfig | 17 + drivers/net/dsa/microchip/Makefile |2 +

[PATCH v2 net-next 3/8] net: dsa: microchip: Initialize mutex before use

2017-12-05 Thread Tristram.Ha
From: Tristram Ha Initialize mutex before use. Signed-off-by: Tristram Ha --- drivers/net/dsa/microchip/ksz_common.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/net/dsa/microchip/ksz_common.c

[PATCH v2 net-next 1/8] net: dsa: microchip: Replace license with GPL

2017-12-05 Thread Tristram.Ha
From: Tristram Ha Replace license with GPL. Signed-off-by: Tristram Ha Reviewed-by: Woojung Huh Reviewed-by: Andrew Lunn --- drivers/net/dsa/microchip/ksz_9477_reg.h | 23 ---

[PATCH v2 net-next 0/8] net: dsa: microchip: Modify KSZ9477 DSA driver in preparation to add other KSZ switch drivers

2017-12-05 Thread Tristram.Ha
From: Tristram Ha This series of patches is to modify the original KSZ9477 DSA driver so that other KSZ switch drivers can be added and use the common code. There are several steps to accomplish this achievement. First is to rename some function names with a prefix

[PATCH v3 net-next] net: dsa: microchip: Add MIB counter reading support

2017-12-05 Thread Tristram.Ha
From: Tristram Ha Add MIB counter reading support. Signed-off-by: Tristram Ha Reviewed-by: Woojung Huh --- v3 - Use new timer_setup API v2 - Only MIB counter related code in patch v1 - Simplify MIB counter

[PATCH v2 net-next 6/8] net: dsa: microchip: Break KSZ9477 DSA driver into two files

2017-12-05 Thread Tristram.Ha
From: Tristram Ha Break KSZ9477 DSA driver into two files in preparation to add more KSZ switch drivers. Add common functions in ksz_common.h so that other KSZ switch drivers can access code in ksz_common.c. Add ksz_spi.h for common functions used by KSZ switch SPI

[PATCH v2 net-next 4/8] net: dsa: microchip: Rename some functions with ksz9477 prefix

2017-12-05 Thread Tristram.Ha
From: Tristram Ha Rename some functions with ksz9477 prefix to separate chip specific code from common code. Signed-off-by: Tristram Ha Reviewed-by: Woojung Huh Reviewed-by: Pavel Machek

[PATCH v2 net-next 8/8] net: dsa: microchip: Rename ksz_9477_reg.h to ksz9477_reg.h

2017-12-05 Thread Tristram.Ha
From: Tristram Ha Rename ksz_9477_reg.h to ksz9477_reg.h for consistency as the product name is always KSZ. Signed-off-by: Tristram Ha Reviewed-by: Woojung Huh Reviewed-by: Andrew Lunn ---

[PATCH v2 net-next 2/8] net: dsa: microchip: Clean up code according to patch check suggestions

2017-12-05 Thread Tristram.Ha
From: Tristram Ha Clean up code according to patch check suggestions. Signed-off-by: Tristram Ha Reviewed-by: Woojung Huh Reviewed-by: Pavel Machek Reviewed-by: Florian Fainelli

[PATCH v2 net-next 7/8] net: dsa: microchip: Prepare PHY for proper advertisement

2017-12-05 Thread Tristram.Ha
From: Tristram Ha Prepare PHY for proper advertisement and get link status for the port. Signed-off-by: Tristram Ha Reviewed-by: Woojung Huh --- drivers/net/dsa/microchip/ksz9477.c| 13 +

[PATCH v2 net-next 5/8] net: dsa: microchip: Rename ksz_spi.c to ksz9477_spi.c

2017-12-05 Thread Tristram.Ha
From: Tristram Ha Rename ksz_spi.c to ksz9477_spi.c and update Kconfig in preparation to add more KSZ switch drivers. Signed-off-by: Tristram Ha Reviewed-by: Woojung Huh Reviewed-by: Pavel Machek

Re: [PATCH iproute2] ip route: broken logic when using default word and family not specified

2017-12-05 Thread Stephen Hemminger
On Sat, 18 Nov 2017 17:56:32 +0100 Alexander Zubkov wrote: > I also opened earlier a ticket in bugzilla: > https://bugzilla.kernel.org/show_bug.cgi?id=197899 > And Stephen Hemminger had couple of comments there which I want to argue: > > > $ ip route list default > > Means

[PATCH iproute2] iplink: allow configuring GSO max values

2017-12-05 Thread Solio Sarabia
From: Stephen Hemminger This allows sending GSO maximum values when configuring a device. The values are advisory. Most devices will ignore them but for some pseudo devices such as veth pairs they can be set. Example: # ip link add dev vm1 type veth peer name

Re: [PATCH v2 iproute2 net-next] gre6: add collect metadata support

2017-12-05 Thread Daniel Borkmann
On 12/06/2017 02:07 AM, Stephen Hemminger wrote: > On Tue, 5 Dec 2017 15:10:37 -0800 > William Tu wrote: > >> diff --git a/man/man8/ip-link.8.in b/man/man8/ip-link.8.in >> index a6a10e577b1f..eb04f887c940 100644 >> --- a/man/man8/ip-link.8.in >> +++ b/man/man8/ip-link.8.in

Re: [PATCH V11 4/5] vsprintf: add printk specifier %px

2017-12-05 Thread Sergey Senozhatsky
Hello, On (12/05/17 13:22), Linus Torvalds wrote: [..] > It's not like those hex numbers were really helping people anyway. > We've turned off most of them on x86 oops reports long ago (and > entirely independently of the pointer hashing). Having stared at a lot > of oopses in my time, the only

Re: [PATCH iproute2] iproute2: Fix undeclared __kernel_long_t type build error in RHEL 6.8

2017-12-05 Thread Stephen Hemminger
On Fri, 1 Dec 2017 13:04:51 +0200 Leon Romanovsky wrote: > From: Leon Romanovsky > > Add asm/posix_types.h header file to the list of needed includes, > because the headers files in RHEL 6.8 are too old and doesn't > have declaration of __kernel_long_t. >

Re: [PATCH 2/2] veth: allow configuring GSO maximums

2017-12-05 Thread Stephen Hemminger
On Tue, 5 Dec 2017 17:14:26 -0800 Solio Sarabia wrote: > From: Stephen Hemminger > > Veth's can be used in environments (like Azure) where the underlying > network device is impacted by large GSO packets. This patch allows > gso maximum

[PATCH 0/2] Allow changing device gso maximums

2017-12-05 Thread Solio Sarabia
Docker uses bridge/veth for its bridged network. veth sends tcp packets as big as 65536 (its default gso value), even when lower physical or synthetic devices expose a lower limit. This causes tcp fragmentation in the host, spinning more cpu cycles. The proposed solution is to allow user to tune

[PATCH 2/2] veth: allow configuring GSO maximums

2017-12-05 Thread Solio Sarabia
From: Stephen Hemminger Veth's can be used in environments (like Azure) where the underlying network device is impacted by large GSO packets. This patch allows gso maximum values to be passed in when creating the device via netlink. In theory, other pseudo devices

Re: [PATCH v2 iproute2 net-next] gre6: add collect metadata support

2017-12-05 Thread Stephen Hemminger
On Tue, 5 Dec 2017 15:10:37 -0800 William Tu wrote: > diff --git a/man/man8/ip-link.8.in b/man/man8/ip-link.8.in > index a6a10e577b1f..eb04f887c940 100644 > --- a/man/man8/ip-link.8.in > +++ b/man/man8/ip-link.8.in > @@ -755,6 +755,8 @@ the following additional arguments are

Re: [PATCH v2 0/3] macb rx filter cleanups

2017-12-05 Thread David Miller
From: Julia Cartwright Date: Tue, 5 Dec 2017 18:02:47 -0600 > Here's a proper patchset based on net-next. > > v1 -> v2: > - Rebased on net-next > - Add Nicolas's Acks > - Reorder commits, putting the list_empty() cleanups prior to the > others. > - Added commit

Re: [PATCH iproute2] iproute2: Fix undeclared __kernel_long_t type build error in RHEL 6.8

2017-12-05 Thread Stephen Hemminger
On Sat, 2 Dec 2017 10:28:33 +0200 Leon Romanovsky wrote: > On Fri, Dec 01, 2017 at 08:48:07AM -0800, Stephen Hemminger wrote: > > On Fri, 1 Dec 2017 13:04:51 +0200 > > Leon Romanovsky wrote: > > > > > From: Leon Romanovsky > > > > > >

Re: [PATCH v2 3/3] ethtool: Add ETHTOOL_RESET support via --reset command

2017-12-05 Thread Scott Branden
Hi Michal, Thanks - one question below hopefully someone can help with. On 17-12-05 02:29 PM, Michal Kubecek wrote: On Tue, Dec 05, 2017 at 02:06:09PM -0800, Scott Branden wrote: On 17-12-05 01:30 PM, Michal Kubecek wrote: On Tue, Dec 05, 2017 at 12:53:23PM -0800, Scott Branden wrote: Add

[Patch net-next v2] act_mirred: get rid of mirred_list_lock spinlock

2017-12-05 Thread Cong Wang
TC actions are no longer freed in RCU callbacks and we should always have RTNL lock, so this spinlock is no longer needed. Cc: Eric Dumazet Cc: Jiri Pirko Cc: Jamal Hadi Salim Signed-off-by: Cong Wang ---

[Patch net-next v2] act_mirred: get rid of tcfm_ifindex from struct tcf_mirred

2017-12-05 Thread Cong Wang
tcfm_dev always points to the correct netdev and we already hold a refcnt, so no need to use tcfm_ifindex to lookup again. If we would support moving target netdev across netns, using pointer would be better than ifindex. This also fixes dumping obsolete ifindex, now after the target device is

[PATCH bpf-next 1/2] bpf, doc: add bpf trees and tps to maintainers entry

2017-12-05 Thread Daniel Borkmann
i) Add the bpf and bpf-next trees to the maintainers entry so they can be found easily and picked up by test bots etc that would integrate all trees from maintainers file. Suggested by Stephen while integrating the trees into linux-next. ii) Add the two headers defining BPF/XDP

[PATCH bpf-next 2/2] bpf, doc: add faq about bpf development process

2017-12-05 Thread Daniel Borkmann
In the same spirit of netdev FAQ, start a BPF FAQ as a collection of expectations and/or workflow details in the context of BPF patch processing. Signed-off-by: Daniel Borkmann Acked-by: Alexei Starovoitov --- Documentation/bpf/bpf_devel_QA.txt | 519

[PATCH bpf-next 0/2] Few BPF doc updates

2017-12-05 Thread Daniel Borkmann
Two changes, i) add BPF trees into maintainers file, and ii) add a BPF doc around the development process, similarly as we have with netdev FAQ, but just describing BPF specifics. Thanks! Daniel Borkmann (2): bpf, doc: add bpf trees and tps to maintainers entry bpf, doc: add faq about bpf

[PATCH net] net: thunderx: Fix TCP/UDP checksum offload for IPv4 pkts

2017-12-05 Thread Florian Westphal
Offload IP header checksum to NIC. This fixes a previous patch which disabled checksum offloading for both IPv4 and IPv6 packets. So L3 checksum offload was getting disabled for IPv4 pkts. And HW is dropping these pkts for some reason. Without this patch, IPv4 TSO appears to be broken:

[PATCH v2 0/3] macb rx filter cleanups

2017-12-05 Thread Julia Cartwright
Here's a proper patchset based on net-next. v1 -> v2: - Rebased on net-next - Add Nicolas's Acks - Reorder commits, putting the list_empty() cleanups prior to the others. - Added commit reverting the GFP_ATOMIC change. Julia Cartwright (3): net: macb: kill useless use of

[PATCH v2 2/3] net: macb: reduce scope of rx_fs_lock-protected regions

2017-12-05 Thread Julia Cartwright
Commit ae8223de3df5 ("net: macb: Added support for RX filtering") introduces a lock, rx_fs_lock which is intended to protect the list of rx_flow items and synchronize access to the hardware rx filtering registers. However, the region protected by this lock is overscoped, unnecessarily including

[PATCH v2 1/3] net: macb: kill useless use of list_empty()

2017-12-05 Thread Julia Cartwright
The list_for_each_entry() macro already handles the case where the list is empty (by not executing the loop body). It's not necessary to handle this case specially, so stop doing so. Cc: Rafal Ozieblo Acked-by: Nicolas Ferre Signed-off-by: Julia

[PATCH v2 3/3] net: macb: change GFP_ATOMIC to GFP_KERNEL

2017-12-05 Thread Julia Cartwright
Now that the rx_fs_lock is no longer held across allocation, it's safe to use GFP_KERNEL for allocating new entries. This reverts commit 81da3bf6e3f88 ("net: macb: change GFP_KERNEL to GFP_ATOMIC"). Cc: Julia Lawall Signed-off-by: Julia Cartwright ---

Re: [PATCH v2 0/6] bpf: correct broken uapi for BPF_PROG_TYPE_PERF_EVENT program type

2017-12-05 Thread Daniel Borkmann
On 12/05/2017 04:53 PM, Daniel Borkmann wrote: > On 12/04/2017 10:56 AM, Hendrik Brueckner wrote: >> Perf tool bpf selftests revealed a broken uapi for s390 and arm64. >> With the BPF_PROG_TYPE_PERF_EVENT program type the bpf_perf_event >> structure exports the pt_regs structure for all

Re: [PATCH tip/core/rcu 21/21] drivers/vhost: Remove now-redundant read_barrier_depends()

2017-12-05 Thread Paul E. McKenney
On Wed, Dec 06, 2017 at 12:09:36AM +0200, Michael S. Tsirkin wrote: > On Tue, Dec 05, 2017 at 10:57:00PM +0100, Peter Zijlstra wrote: > > On Tue, Dec 05, 2017 at 11:24:49PM +0200, Michael S. Tsirkin wrote: > > > READ_ONCE is really all over the place (some code literally replaced all > > > memory

Re: [PATCH 1/3] fix kcm_clone()

2017-12-05 Thread David Miller
From: Al Viro Date: Tue, 5 Dec 2017 23:27:57 + > 1) it's fput() or sock_release(), not both > 2) don't do fd_install() until the last failure exit. > 3) not a bug per se, but... don't attach socket to struct file >until it's set up. > > Take reserving descriptor

Re: [PATCH 2/3] socketpair(): allocate descriptors first

2017-12-05 Thread David Miller
From: Al Viro Date: Tue, 5 Dec 2017 23:28:38 + > simplifies failure exits considerably... > > Reviewed-by: Eric Dumazet > Signed-off-by: Al Viro Applied.

Re: [PATCH V11 3/5] printk: hash addresses printed with %p

2017-12-05 Thread Linus Torvalds
On Tue, Dec 5, 2017 at 2:57 PM, Geert Uytterhoeven wrote: > Lowest 3 is good enough for all natural types, up to long long. > We may still receive complaints from people who care about seeing if > a pointer is cacheline-aligned or not. Fixing that may need up to 7 bits, I'm

RE: [PATCH net-next 1/1] net: dsa: microchip: Add Microchip KSZ8895 DSA driver

2017-12-05 Thread Tristram.Ha
> > Sorry to be this late for the reply. I finally got hold of a KSZ8895 board > > that > > works with my SoC board to confirm the network communication. > > > > As expected the KSZ8895 board works correctly as the chip uses the same > > tail tagging feature in KSZ8795, and I did verify that

Re: [RFC][PATCHES] sock_alloc_file() cleanups and fixes

2017-12-05 Thread Al Viro
On Tue, Dec 05, 2017 at 02:44:43PM -0500, David Miller wrote: > From: Al Viro > Date: Mon, 4 Dec 2017 16:41:01 + > > > On Mon, Dec 04, 2017 at 10:35:24AM -0500, David Miller wrote: > >> From: Al Viro > >> Date: Fri, 1 Dec 2017 00:20:27 +

[PATCH 3/3] make sock_alloc_file() do sock_release() on failures

2017-12-05 Thread Al Viro
This changes calling conventions (and simplifies the hell out the callers). New rules: once struct socket had been passed to sock_alloc_file(), it's been consumed either by struct file or by sock_release() done by sock_alloc_file(). Either way the caller should not do sock_release() after that

[PATCH 1/3] fix kcm_clone()

2017-12-05 Thread Al Viro
1) it's fput() or sock_release(), not both 2) don't do fd_install() until the last failure exit. 3) not a bug per se, but... don't attach socket to struct file until it's set up. Take reserving descriptor into the caller, move fd_install() to the caller, sanitize failure exits and calling

[PATCH 2/3] socketpair(): allocate descriptors first

2017-12-05 Thread Al Viro
simplifies failure exits considerably... Reviewed-by: Eric Dumazet Signed-off-by: Al Viro --- net/socket.c | 89 ++-- 1 file changed, 38 insertions(+), 51 deletions(-) diff --git

[PATCH net-next 1/2] ip6_gre: add ip6 erspan collect_md mode

2017-12-05 Thread William Tu
Similar to ip6 gretap and ip4 gretap, the patch allows erspan tunnel to operate in collect metadata mode. bpf_skb_[gs]et_tunnel_key() helpers can make use of it right away. Signed-off-by: William Tu --- net/ipv6/ip6_gre.c | 110

[PATCH net-next 2/2] samples/bpf: add ip6erspan sample code

2017-12-05 Thread William Tu
Extend the existing tests for ip6erspan. Signed-off-by: William Tu --- samples/bpf/tcbpf2_kern.c | 58 ++ samples/bpf/test_tunnel_bpf.sh | 37 +++ 2 files changed, 95 insertions(+) diff --git

[PATCH net-next 0/2] add ip6erspan collect_md mode

2017-12-05 Thread William Tu
Similar to erspan collect_md mode in ipv4, the first patch adds support for ip6erspan collect metadata mode. The second patch adds the test case using bpf_skb_[gs]et_tunnel_key helpers. The corresponding iproute2 patch: https://marc.info/?l=linux-netdev=151251545410047=2 William Tu (2):

[PATCH v2 iproute2 net-next] gre6: add collect metadata support

2017-12-05 Thread William Tu
The patch adds 'external' option to support collect metadata gre6 tunnel. Example of L3 and L2 gre device: bash:~# ip link add dev ip6gre123 type ip6gre external bash:~# ip link add dev ip6gretap123 type ip6gretap external Signed-off-by: William Tu --- change in v2: -

Re: [PATCH] dccp: CVE-2017-8824: use-after-free in DCCP code

2017-12-05 Thread David Miller
From: simo.ghan...@gmail.com Date: Tue, 5 Dec 2017 20:58:35 + > From: Mohamed Ghannam > > Whenever the sock object is in DCCP_CLOSED state, > dccp_disconnect() must free dccps_hc_tx_ccid and > dccps_hc_rx_ccid and set to NULL. > > Signed-off-by: Mohamed Ghannam

Re: [Patch net-next] net_sched: remove unused parameter from act cleanup ops

2017-12-05 Thread David Miller
From: Cong Wang Date: Tue, 5 Dec 2017 12:53:07 -0800 > No one actually uses it. > > Cc: Jiri Pirko > Cc: Jamal Hadi Salim > Signed-off-by: Cong Wang Nice cleanup, applied, thanks Cong.

Re: [PATCH net 0/2] net: qualcomm: rmnet: Fix leaks in failure scenarios

2017-12-05 Thread David Miller
From: Subash Abhinov Kasiviswanathan Date: Tue, 5 Dec 2017 13:41:16 -0700 > Patch 1 fixes a leak in transmit path where a skb cannot be > transmitted due to insufficient headroom to stamp the map header. > Patch 2 fixes a leak in rmnet_newlink() failure because the >

Re: [PATCH net-next v2 0/5] net: dsa: use per-port upstream port

2017-12-05 Thread David Miller
From: Vivien Didelot Date: Tue, 5 Dec 2017 15:34:08 -0500 > An upstream port is a local switch port used to reach a CPU port. > > DSA still considers a unique CPU port in the whole switch fabric and > thus return a unique upstream port for a given switch.

Re: [PATCH 1/2] net: macb: reduce scope of rx_fs_lock-protected regions

2017-12-05 Thread David Miller
From: Julia Cartwright Date: Tue, 5 Dec 2017 14:17:11 -0600 > While Julia Lawall's cocci-generated patch fixes the problem, the right > solution is to obviate the problem altogether. I already applied Julia's patch. And I hope that if you generated this against current net-next

Re: [PATCH net] netlink: Relax attr validation for fixed length types

2017-12-05 Thread David Miller
From: David Ahern Date: Tue, 5 Dec 2017 12:55:40 -0700 > Commit 28033ae4e0f5 ("net: netlink: Update attr validation to require > exact length for some types") requires attributes using types NLA_U* and > NLA_S* to have an exact length. This change is exposing bugs in various

[PATCH] netlink: Add netns check on taps

2017-12-05 Thread Kevin Cernekee
Currently, a nlmon link inside a child namespace can observe systemwide netlink activity. Filter the traffic so that in a non-init netns, nlmon can only sniff netlink messages from its own netns. Test case: vpnns -- bash -c "ip link add nlmon0 type nlmon; \ ip link set

[PATCHv3 0/2] capability controlled user-namespaces

2017-12-05 Thread Mahesh Bandewar
From: Mahesh Bandewar TL;DR version - Creating a sandbox environment with namespaces is challenging considering what these sandboxed processes can engage into. e.g. CVE-2017-6074, CVE-2017-7184, CVE-2017-7308 etc. just to name few. Current form of user-namespaces,

[PATCHv3 1/2] capability: introduce sysctl for controlled user-ns capability whitelist

2017-12-05 Thread Mahesh Bandewar
From: Mahesh Bandewar Add a sysctl variable kernel.controlled_userns_caps_whitelist. This takes input as capability mask expressed as two comma separated hex u32 words. The mask, however, is stored in kernel as kernel_cap_t type. Any capabilities that are not part of this

Re: [PATCH v2 3/3] ethtool: Add ETHTOOL_RESET support via --reset command

2017-12-05 Thread Scott Branden
Hi Andrew, On 17-12-05 02:26 PM, Andrew Lunn wrote: On Tue, Dec 05, 2017 at 12:53:23PM -0800, Scott Branden wrote: Add ETHTOOL_RESET support via --reset command. ie. ethtool --reset DEVNAME flagnames currently match the ETH_RESET_xxx names:

Re: [RFC] virtio-net: help live migrate SR-IOV devices

2017-12-05 Thread Jakub Kicinski
On Tue, 5 Dec 2017 11:59:17 +0200, achiad shochat wrote: > I second Jacob - having a netdev of one device driver enslave a netdev > of another device driver is an awkward a-symmetric model. > Regardless of whether they share the same backend device. > Only I am not sure the

Re: [PATCH v2 3/3] ethtool: Add ETHTOOL_RESET support via --reset command

2017-12-05 Thread Michal Kubecek
On Tue, Dec 05, 2017 at 02:06:09PM -0800, Scott Branden wrote: > On 17-12-05 01:30 PM, Michal Kubecek wrote: > > On Tue, Dec 05, 2017 at 12:53:23PM -0800, Scott Branden wrote: > > > Add ETHTOOL_RESET support via --reset command. > > > > > > ie. ethtool --reset DEVNAME > > > > > >

Re: [PATCH v2 3/3] ethtool: Add ETHTOOL_RESET support via --reset command

2017-12-05 Thread Andrew Lunn
On Tue, Dec 05, 2017 at 12:53:23PM -0800, Scott Branden wrote: > Add ETHTOOL_RESET support via --reset command. > > ie. ethtool --reset DEVNAME > > flagnames currently match the ETH_RESET_xxx names: > mgmt,irq,dma,filter,offload,mac,phy,ram,dedicated,all [Snip] > +.B ethtool

RE: [PATCH net-next 1/1] net: dsa: microchip: Add Microchip KSZ8895 DSA driver

2017-12-05 Thread Tristram.Ha
> Thanks for patches. I installed whole series on top of net-next. > > Hardware is: > > root@miro:~# cat /proc/cpuinfo > model name : ARM926EJ-S rev 5 (v5l) > Hardware: Freescale MXS (Device Tree) > > I added devicetree chunks, and enabled DSA in the config. It seems > switch is

Re: [PATCH tip/core/rcu 21/21] drivers/vhost: Remove now-redundant read_barrier_depends()

2017-12-05 Thread Peter Zijlstra
On Tue, Dec 05, 2017 at 01:36:44PM -0800, Paul E. McKenney wrote: > What we do in some code is to comment the pairings, allowing the other > side of the pairing to be easily located. Would that work for you? I would say that that is mandatory for any memory ordering code ;-)

Re: [PATCH tip/core/rcu 21/21] drivers/vhost: Remove now-redundant read_barrier_depends()

2017-12-05 Thread Michael S. Tsirkin
On Tue, Dec 05, 2017 at 10:57:00PM +0100, Peter Zijlstra wrote: > On Tue, Dec 05, 2017 at 11:24:49PM +0200, Michael S. Tsirkin wrote: > > READ_ONCE is really all over the place (some code literally replaced all > > memory accesses with READ/WRITE ONCE). > > Yeah, so? Oh my point was I can't just

Re: [PATCH v2 3/3] ethtool: Add ETHTOOL_RESET support via --reset command

2017-12-05 Thread Scott Branden
Hi Michal, thanks for review - see comments On 17-12-05 01:30 PM, Michal Kubecek wrote: On Tue, Dec 05, 2017 at 12:53:23PM -0800, Scott Branden wrote: Add ETHTOOL_RESET support via --reset command. ie. ethtool --reset DEVNAME flagnames currently match the ETH_RESET_xxx names:

Re: [RFC] virtio-net: help live migrate SR-IOV devices

2017-12-05 Thread Michael S. Tsirkin
On Tue, Dec 05, 2017 at 01:52:26PM -0800, Jesse Brandeburg wrote: > On Tue, 5 Dec 2017 21:20:07 +0200 > "Michael S. Tsirkin" wrote: > > > On Tue, Dec 05, 2017 at 11:59:17AM +0200, achiad shochat wrote: > > > Then we'll have a single solution for both netvsc and virtio (and any >

Re: [PATCH tip/core/rcu 21/21] drivers/vhost: Remove now-redundant read_barrier_depends()

2017-12-05 Thread Peter Zijlstra
On Tue, Dec 05, 2017 at 11:24:49PM +0200, Michael S. Tsirkin wrote: > READ_ONCE is really all over the place (some code literally replaced all > memory accesses with READ/WRITE ONCE). Yeah, so? Complain to the compiler people for forcing us into that. > Would an API like

Re: [PATCHv2 2/2] userns: control capabilities of some user namespaces

2017-12-05 Thread महेश बंडेवार
On Wed, Nov 29, 2017 at 9:57 AM, Serge E. Hallyn wrote: > Quoting Mahesh Bandewar (महेश बंडेवार) (mahe...@google.com): >> On Tue, Nov 28, 2017 at 3:04 PM, Serge E. Hallyn wrote: >> > Quoting Mahesh Bandewar (महेश बंडेवार) (mahe...@google.com): >> > ... >> >>

Re: [PATCH tip/core/rcu 21/21] drivers/vhost: Remove now-redundant read_barrier_depends()

2017-12-05 Thread Michael S. Tsirkin
On Tue, Dec 05, 2017 at 01:36:44PM -0800, Paul E. McKenney wrote: > On Tue, Dec 05, 2017 at 11:24:49PM +0200, Michael S. Tsirkin wrote: > > On Tue, Dec 05, 2017 at 12:08:01PM -0800, Paul E. McKenney wrote: > > > On Tue, Dec 05, 2017 at 09:51:48PM +0200, Michael S. Tsirkin wrote: > > > > On Tue,

Re: [PATCH tip/core/rcu 21/21] drivers/vhost: Remove now-redundant read_barrier_depends()

2017-12-05 Thread Michael S. Tsirkin
On Tue, Dec 05, 2017 at 10:17:35PM +0100, Peter Zijlstra wrote: > On Tue, Dec 05, 2017 at 10:28:38PM +0200, Michael S. Tsirkin wrote: > > On Tue, Dec 05, 2017 at 08:57:52PM +0100, Peter Zijlstra wrote: > > > On Tue, Dec 05, 2017 at 09:51:48PM +0200, Michael S. Tsirkin wrote: > > > > > >

Re: [PATCH tip/core/rcu 21/21] drivers/vhost: Remove now-redundant read_barrier_depends()

2017-12-05 Thread Paul E. McKenney
On Tue, Dec 05, 2017 at 11:24:49PM +0200, Michael S. Tsirkin wrote: > On Tue, Dec 05, 2017 at 12:08:01PM -0800, Paul E. McKenney wrote: > > On Tue, Dec 05, 2017 at 09:51:48PM +0200, Michael S. Tsirkin wrote: > > > On Tue, Dec 05, 2017 at 11:33:39AM -0800, Paul E. McKenney wrote: > > > > On Tue,

Re: [PATCH v2 3/3] ethtool: Add ETHTOOL_RESET support via --reset command

2017-12-05 Thread Michal Kubecek
On Tue, Dec 05, 2017 at 12:53:23PM -0800, Scott Branden wrote: > Add ETHTOOL_RESET support via --reset command. > > ie. ethtool --reset DEVNAME > > flagnames currently match the ETH_RESET_xxx names: > mgmt,irq,dma,filter,offload,mac,phy,ram,dedicated,all > > Alternatively, you

  1   2   3   4   >