Re: [Nbd] [PATCH 3/4] treewide: convert PF_MEMALLOC manipulations to new helpers

2017-04-05 Thread Wouter Verhelst
On Wed, Apr 05, 2017 at 01:30:31PM +0200, Michal Hocko wrote: > On Wed 05-04-17 09:46:59, Vlastimil Babka wrote: > > We now have memalloc_noreclaim_{save,restore} helpers for robust setting and > > clearing of PF_MEMALLOC. Let's convert the code which was using the generic > > tsk_restore_flags().

[PATCH] net: i40evf: Use net_device_stats from struct net_device

2017-04-05 Thread Tobias Klauser
Instead of using a private copy of struct net_device_stats in struct i40evf_adapter, use stats from struct net_device. Also remove the now unnecessary .ndo_get_stats function. Signed-off-by: Tobias Klauser --- drivers/net/ethernet/intel/i40evf/i40evf.h | 1 - drivers/net/ethernet/intel/

[PATCH] net: igbvf: Use net_device_stats from struct net_device

2017-04-05 Thread Tobias Klauser
Instead of using a private copy of struct net_device_stats in struct igbvf_adapter, use stats from struct net_device. Also remove the now unnecessary .ndo_get_stats function. Signed-off-by: Tobias Klauser --- drivers/net/ethernet/intel/igbvf/igbvf.h | 1 - drivers/net/ethernet/intel/igbvf/netd

Re: [PATCH 4/4] mtd: nand: nandsim: convert to memalloc_noreclaim_*()

2017-04-05 Thread Adrian Hunter
On 05/04/17 14:39, Vlastimil Babka wrote: > On 04/05/2017 01:36 PM, Richard Weinberger wrote: >> Michal, >> >> Am 05.04.2017 um 13:31 schrieb Michal Hocko: >>> On Wed 05-04-17 09:47:00, Vlastimil Babka wrote: Nandsim has own functions set_memalloc() and clear_memalloc() for robust setting

[PATCH net] team: call netdev_change_features out of team lock

2017-04-05 Thread Xin Long
Commit f6988cb63a4e ("team: don't call netdev_change_features under team->lock") fixed the issue calling netdev_change_features under team->lock for team_compute_features. But there are still two places where it calls netdev_change_features under team->lock, team_port_add and team_port_del. It may

Re: [PATCH 2/4 v2 net-next] net: stmmac: adding multiple buffers for RX (fwd)

2017-04-05 Thread Julia Lawall
It looks like an infinite loop, if queue is unsigned. julia -- Forwarded message -- Date: Thu, 6 Apr 2017 11:49:01 +0800 From: kbuild test robot To: kbu...@01.org Cc: Julia Lawall Subject: Re: [PATCH 2/4 v2 net-next] net: stmmac: adding multiple buffers for RX [auto build test

Re: [PATCH net-next] macb: Add hardware PTP support.

2017-04-05 Thread Richard Cochran
On Wed, Apr 05, 2017 at 06:43:03AM -0700, David Miller wrote: > This patch does too many things at one time. Each entry in that list > of changes above should be a separate change, all posted together as > a group as a proper patch series. And please start a new thread with the next posting. Tha

[PATCH net] sctp: listen on the sock only when it's state is listening or closed

2017-04-05 Thread Xin Long
Now sctp doesn't check sock's state before listening on it. It could even cause changing a sock with any state to become a listening sock when doing sctp_listen. This patch is to fix it by checking sock's state in sctp_listen, so that it will listen on the sock with right state. Reported-by: Andr

Re: [PATCH] mwifiex: MAC randomization should not be persistent

2017-04-05 Thread Kalle Valo
Brian Norris writes: > nl80211 provides the NL80211_SCAN_FLAG_RANDOM_ADDR for every scan > request that should be randomized; the absence of such a flag means we > should not randomize. However, mwifiex was stashing the latest > randomization request and *always* using it for future scans, even t

Re: [RFC net-next] bpf: taint loading !is_gpl programs

2017-04-05 Thread Aaron Conole
Hi Daniel, Daniel Borkmann writes: > On 04/04/2017 08:33 PM, Aaron Conole wrote: >> The eBPF framework is used for more than just socket level filtering. It >> can also provide tracing, and even change the way packets coming into the >> system look. Most of the eBPF callable symbols are availa

[PATCH] netpoll: Check for skb->queue_mapping

2017-04-05 Thread Tushar Dave
Reducing real_num_tx_queues needs to be in sync with skb queue_mapping otherwise skbs with queue_mapping greater than real_num_tx_queues can be sent to the underlying driver and can result in kernel panic. One such event is running netconsole and enabling VF on the same device. Or running netconso

[PATCH net-next 2/2] Sample program using SO_COOKIE

2017-04-05 Thread Chenbo Feng
From: Chenbo Feng Added a per socket traffic monitoring option to illustrate the usage of new getsockopt SO_COOKIE. The program is based on the socket traffic monitoring program using xt_eBPF and in the new option the data entry can be directly accessed using socket cookie. The cookie retrieved a

[PATCH net-next 1/2] New getsockopt option to get socket cookie

2017-04-05 Thread Chenbo Feng
From: Chenbo Feng Introduce a new getsockopt operation to retrieve the socket cookie for a specific socket based on the socket fd. It returns a unique non-decreasing cookie for each socket. Tested: https://android-review.googlesource.com/#/c/358163/ Acked-by: Willem de Bruijn Signed-off-by: Ch

[PATCH net-next 0/2] New getsockopt option to retrieve socket cookie

2017-04-05 Thread Chenbo Feng
From: Chenbo Feng In the current kernel socket cookie implementation, there is no simple and direct way to retrieve the socket cookie based on file descriptor. A process mat need to get it from sock fd if it want to correlate with sock_diag output or use a bpf map with new socket cookie function

[GIT] Networking

2017-04-05 Thread David Miller
1) Reject invalid updates to netfilter expectation policies, from Pablo Neira Ayuso. 2) Fix memory leak in nfnl_cthelper, from Jeffy Chen. 3) Don't do stupid things if we get a neigh_probe() on a neigh entry whose ops lack a solicit method. From Eric Dumazet. 4) Don't transmit packets in

Re: [Patch net] net_sched: replace yield() with cond_resched()

2017-04-05 Thread Mike Galbraith
On Wed, 2017-04-05 at 16:42 -0700, Cong Wang wrote: > On Tue, Apr 4, 2017 at 10:56 PM, Mike Galbraith wrote: > > On Tue, 2017-04-04 at 22:19 -0700, Cong Wang wrote: > > > On Tue, Apr 4, 2017 at 8:55 PM, Mike Galbraith wrote: > > > > > > That won't help, cond_resched() has the same impact upon a

Re: [PATCH net] nfp: fix potential use after free on xdp prog

2017-04-05 Thread David Miller
From: Jakub Kicinski Date: Tue, 4 Apr 2017 15:56:55 -0700 > We should unregister the net_device first, before we give back > our reference on xdp_prog. Otherwise xdp_prog may be freed > before .ndo_stop() disabled the datapath. Found by code inspection. > > Fixes: ecd63a0217d5 ("nfp: add XDP

Re: [PATCH net-next] bonding: attempt to better support longer hw addresses

2017-04-05 Thread David Miller
From: Jarod Wilson Date: Tue, 4 Apr 2017 17:32:42 -0400 > People are using bonding over Infiniband IPoIB connections, and who knows > what else. Infiniband has a hardware address length of 20 octets > (INFINIBAND_ALEN), and the network core defines a MAX_ADDR_LEN of 32. > Various places in the b

[PATCH 07/10] ftgmac100: Directly receive into sk_buffs

2017-04-05 Thread Benjamin Herrenschmidt
The current driver receive path allocates pages and stashes them into SKB fragments. This is not particularly useful as we don't support jumbo frames (which wouldn't be great with the small FIFOs on all the known implementations) anyway. It also makes us flush the caches and allocate more memory f

Re: [PATCH net 2/2] tcp: fix reordering SNMP under-counting

2017-04-05 Thread David Miller
From: Yuchung Cheng Date: Tue, 4 Apr 2017 14:15:40 -0700 > Currently the reordering SNMP counters only increase if a connection > sees a higher degree then it has previously seen. It ignores if the > reordering degree is not greater than the default system threshold. > This significantly under-c

Re: [PATCH net 1/2] tcp: fix lost retransmit SNMP under-counting

2017-04-05 Thread David Miller
From: Yuchung Cheng Date: Tue, 4 Apr 2017 14:15:39 -0700 > The lost retransmit SNMP stat is under-counting retransmission > that uses segment offloading. This patch fixes that so all > retransmission related SNMP counters are consistent. > > Fixes: 10d3be569243 ("tcp-tso: do not split TSO packe

Re: [PATCH net-next] sfc: don't insert mc_list on low-latency firmware if it's too long

2017-04-05 Thread David Miller
From: Edward Cree Date: Tue, 4 Apr 2017 17:02:49 +0100 > If the mc_list is longer than 256 addresses, we enter mc_promisc mode. > If we're in mc_promisc mode and the firmware doesn't support cascaded > multicast, normally we also insert our mc_list, to prevent stealing by > another VI. However

Re: net/sched: latent livelock in dev_deactivate_many() due to yield() usage

2017-04-05 Thread Mike Galbraith
On Wed, 2017-04-05 at 17:31 -0700, Stephen Hemminger wrote: > On Sun, 02 Apr 2017 06:28:41 +0200 > Mike Galbraith wrote: > > > Livelock can be triggered by setting kworkers to SCHED_FIFO, then > > suspend/resume.. you come back from sleepy-land with a spinning > > kworker. For whatever reason, I

Re: net/sched: latent livelock in dev_deactivate_many() due to yield() usage

2017-04-05 Thread Mike Galbraith
On Wed, 2017-04-05 at 16:55 -0700, Cong Wang wrote: > On Tue, Apr 4, 2017 at 11:12 PM, Mike Galbraith wrote: > > On Tue, 2017-04-04 at 22:25 -0700, Cong Wang wrote: > > > On Tue, Apr 4, 2017 at 8:20 PM, Mike Galbraith wrote: > > > > - while (some_qdisc_is_busy(dev)) > > > > -

[PATCH 08/10] ftgmac100: Add missing barrier in ftgmac100_rx_packet()

2017-04-05 Thread Benjamin Herrenschmidt
Signed-off-by: Benjamin Herrenschmidt --- drivers/net/ethernet/faraday/ftgmac100.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/net/ethernet/faraday/ftgmac100.c b/drivers/net/ethernet/faraday/ftgmac100.c index 86bda0a..594af30 100644 --- a/drivers/net/ethernet/faraday/ftgmac100

[PATCH 05/10] ftgmac100: Simplify rx packets error handling

2017-04-05 Thread Benjamin Herrenschmidt
The fast path has a single unlikely() test for any error bit, calling into a helper that sets the appropriate statistics. The various netdev_info aren't particularly interesting. If we want to differentiate the various length errors later we can introduce driver specific stats using ethtool. Sign

[PATCH 06/10] ftgmac100: Simplify rx pointer handling in the rx path

2017-04-05 Thread Benjamin Herrenschmidt
We don't handle fragmented RX packets, so the "looping" helpers to locate the first segment of a packet or to drop a packet aren't actually helping. Take them out and simplify ftgmac100_rx_packet() further as a result. Signed-off-by: Benjamin Herrenschmidt --- drivers/net/ethernet/faraday/ftgma

[PATCH 09/10] ftgmac100: Remove rx descriptor accessors

2017-04-05 Thread Benjamin Herrenschmidt
Directly access the fields when needed. The accessors add clutter not clarity and in some cases cause unnecessary read-modify-write type access on the slow (uncached) descriptor memory. Signed-off-by: Benjamin Herrenschmidt --- drivers/net/ethernet/faraday/ftgmac100.c | 152 +

[PATCH 10/10] ftgmac100: Work around HW bug in runt frame detection

2017-04-05 Thread Benjamin Herrenschmidt
The HW incorrectly calculates the frame size without the vlan tag and compares that against 64. It will thus flag 64-bytes frames with a vlan tag as 60-bytes frames "runt" packets which we'll then drop. Thus we end up dropping ARP packets on vlan's ... It does that whether vlan tag stripping is en

[PATCH 04/10] ftgmac100: Cleanup rx checksum handling

2017-04-05 Thread Benjamin Herrenschmidt
Read the descriptor field only once and check for IP header checksum errors as well Signed-off-by: Benjamin Herrenschmidt --- drivers/net/ethernet/faraday/ftgmac100.c | 63 +--- 1 file changed, 25 insertions(+), 38 deletions(-) diff --git a/drivers/net/ethernet/farad

[PATCH 02/10] ftgmac100: Drop support for fragmented receive

2017-04-05 Thread Benjamin Herrenschmidt
We don't support jumbo frames, we will never receive a fragmented packet, the RX buffer is always big enough, if not then it's a runaway packet that can be dropped. So take out the loop that handles such things in ftgmac100_rx_packet() which will help with subsequent simplifications and improvemen

[PATCH 03/10] ftgmac100: Use a scratch buffer for failed RX allocations

2017-04-05 Thread Benjamin Herrenschmidt
We can occasionally fail to allocate new RX buffers at runtime or when starting the driver. At the moment the latter just fails to open which is fine but the former leaves stale DMA pointers in the ring. Instead, use a scratch page and have all RX ring descriptors point to it by default unless a p

[PATCH 01/10] ftgmac100: Move ftgmac100_alloc_rx_page() before its users

2017-04-05 Thread Benjamin Herrenschmidt
Avoids a forward declaration Signed-off-by: Benjamin Herrenschmidt --- drivers/net/ethernet/faraday/ftgmac100.c | 59 +++- 1 file changed, 28 insertions(+), 31 deletions(-) diff --git a/drivers/net/ethernet/faraday/ftgmac100.c b/drivers/net/ethernet/faraday/ftgmac10

[PATCH 00/10] ftgmac: Rework batch 2 - RX path

2017-04-05 Thread Benjamin Herrenschmidt
This is the second batch of updates to the ftgmac100 driver. This one tackles the RX path of the driver, simplifying it greatly to match common practice while significantly increasing the performance. (The bulk of the performance gains of my series will be provided by the TX path improvements, no

Re: [PATCH iproute2] man: fix man page warnings

2017-04-05 Thread Alexander Alemayhu
On Wed, Apr 05, 2017 at 04:56:23PM +0200, Phil Sutter wrote: > > People using '.R' try to force "normal" font, like for every second > parameter to '.IR' but in fact they could just leave the macro away > since lines starting without any macro will get normal font settings > anyway. > I will keep

Re: net/sched: latent livelock in dev_deactivate_many() due to yield() usage

2017-04-05 Thread Stephen Hemminger
On Sun, 02 Apr 2017 06:28:41 +0200 Mike Galbraith wrote: > Livelock can be triggered by setting kworkers to SCHED_FIFO, then > suspend/resume.. you come back from sleepy-land with a spinning > kworker. For whatever reason, I can only do that with an enterprise > like config, my standard config r

[PATCH net-next v5 0/2] L2TP:Adjust intf MTU, add underlay L3, L2 hdrs.

2017-04-05 Thread R. Parameswaran
Existing L2TP kernel code does not derive the optimal MTU for Ethernet pseudowires and instead leaves this to a userspace L2TP daemon or operator. If an MTU is not specified, the existing kernel code chooses an MTU that does not take account of all tunnel header overheads, which can lead to unwant

[PATCH net-next v5 2/2] L2TP:Adjust intf MTU, add underlay L3, L2 hdrs.

2017-04-05 Thread R. Parameswaran
Existing L2TP kernel code does not derive the optimal MTU for Ethernet pseudowires and instead leaves this to a userspace L2TP daemon or operator. If an MTU is not specified, the existing kernel code chooses an MTU that does not take account of all tunnel header overheads, which can lead to unwant

Re: net/sched: latent livelock in dev_deactivate_many() due to yield() usage

2017-04-05 Thread Cong Wang
On Tue, Apr 4, 2017 at 11:12 PM, Mike Galbraith wrote: > On Tue, 2017-04-04 at 22:25 -0700, Cong Wang wrote: >> On Tue, Apr 4, 2017 at 8:20 PM, Mike Galbraith wrote: >> > - while (some_qdisc_is_busy(dev)) >> > - yield(); >> > + swait_event_timeout

[PATCH net-next v5 1/2] New kernel function to get IP overhead on a socket.

2017-04-05 Thread R. Parameswaran
A new function, kernel_sock_ip_overhead(), is provided to calculate the cumulative overhead imposed by the IP Header and IP options, if any, on a socket's payload. The new function returns an overhead of zero for sockets that do not belong to the IPv4 or IPv6 address families. This is used in the

Re: [Patch net] net_sched: replace yield() with cond_resched()

2017-04-05 Thread Cong Wang
On Tue, Apr 4, 2017 at 10:56 PM, Mike Galbraith wrote: > On Tue, 2017-04-04 at 22:19 -0700, Cong Wang wrote: >> On Tue, Apr 4, 2017 at 8:55 PM, Mike Galbraith wrote: > >> > That won't help, cond_resched() has the same impact upon a lone >> > SCHED_FIFO task as yield() does.. none. >> >> Hmm? In t

Re: net/ipv4: use-after-free in ipv4_mtu

2017-04-05 Thread Cong Wang
On Tue, Apr 4, 2017 at 7:45 PM, Eric Dumazet wrote: > On Tue, 2017-04-04 at 18:11 -0700, Cong Wang wrote: >> On Tue, Apr 4, 2017 at 11:51 AM, Eric Dumazet wrote: >> > Looking at fib->fib_metrics, I fail to understand how the following can >> > work : >> > >> > dst_init_metrics(&rt->dst, fi->fib_

[PATCH] mwifiex: MAC randomization should not be persistent

2017-04-05 Thread Brian Norris
nl80211 provides the NL80211_SCAN_FLAG_RANDOM_ADDR for every scan request that should be randomized; the absence of such a flag means we should not randomize. However, mwifiex was stashing the latest randomization request and *always* using it for future scans, even those that didn't set the flag.

[PATCH] qlge: avoid format string exposure in workqueue

2017-04-05 Thread Kees Cook
While unlikely, this makes sure the workqueue name won't be processed as a format string. Signed-off-by: Kees Cook --- drivers/net/ethernet/qlogic/qlge/qlge_main.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/net/ethernet/qlogic/qlge/qlge_main.c b/drivers/net/et

[PATCH] net: ethernet: wiznet: avoid format string exposure

2017-04-05 Thread Kees Cook
While unlikely, this makes sure any format strings in the device name can't exposure information via the resulting workqueue name. Signed-off-by: Kees Cook --- drivers/net/ethernet/wiznet/w5100.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/net/ethernet/wiznet/w5

[PATCH 20/24] bpf: Restrict kernel image access functions when the kernel is locked down

2017-04-05 Thread David Howells
From: Chun-Yi Lee There are some bpf functions can be used to read kernel memory: bpf_probe_read, bpf_probe_write_user and bpf_trace_printk. These allow private keys in kernel memory (e.g. the hibernation image signing key) to be read by an eBPF program. Prohibit those functions when the kernel

tcpprobe display format for snd_nxt and snd_una

2017-04-05 Thread hiren panchasara
(New to linux and first-time poster so please guide me if needed.) Upon using tcpprobe I realized that it prints snd_nxt and snd_una as hex which makes it harder to read and compare with tcpdump for example. Not sure if that is intentional. If not, a simple patch like this would print them as d

Re: [PATCH 4/4] net: dsa: LAN9303: add MDIO managed mode support

2017-04-05 Thread Andrew Lunn
> +static const struct of_device_id lan9303_mdio_of_match[] = { > + { .compatible = "smsc,lan9303" }, > + { /* sentinel */ }, > +}; > +MODULE_DEVICE_TABLE(of, lan9303_mdio_of_match); If i'm reading this right, i think you have the same compatible string for both the i2c and the mdio driver

Re: net/ipv4: use-after-free in ipv4_mtu

2017-04-05 Thread Subash Abhinov Kasiviswanathan
Interesting. I might had too many beers tonight, but ... refcount was removed in 2860583fe840 many months later -static void rt_init_metrics(struct rtable *rt, struct fib_info *fi) -{ - if (fi->fib_metrics != (u32 *) dst_default_metrics) { - rt->fi = fi; - atom

[PATCH 3/4] bluetooth: hci_uart: add LL protocol serdev driver support

2017-04-05 Thread Rob Herring
Turns out that the LL protocol and the TI-ST are the same thing AFAICT. The TI-ST adds firmware loading, GPIO control, and shared access for NFC, FM radio, etc. For now, we're only implementing what is needed for BT. This mirrors other drivers like BCM and Intel, but uses the new serdev bus. The f

[PATCH 4/4] arm64: dts: hikey: add WL1835 Bluetooth device node

2017-04-05 Thread Rob Herring
This adds the serial slave device for the WL1835 Bluetooth interface. Signed-off-by: Rob Herring Cc: Wei Xu Cc: Mark Rutland --- arch/arm64/boot/dts/hisilicon/hi6220-hikey.dts | 5 + 1 file changed, 5 insertions(+) diff --git a/arch/arm64/boot/dts/hisilicon/hi6220-hikey.dts b/arch/arm64/

[PATCH 1/4] dt-bindings: net: Add TI WiLink shared transport binding

2017-04-05 Thread Rob Herring
Add serial slave device binding for the TI WiLink series of Bluetooth/FM/GPS devices. Signed-off-by: Rob Herring Cc: Mark Rutland Cc: netdev@vger.kernel.org Cc: devicet...@vger.kernel.org --- .../devicetree/bindings/net/ti,wilink-st.txt | 35 ++ 1 file changed, 35 inse

[PATCH 2/4] bluetooth: hci_uart: remove unused hci_uart_init_tty

2017-04-05 Thread Rob Herring
There are no users of hci_uart_init_tty, so remove it. Signed-off-by: Rob Herring Cc: Marcel Holtmann Cc: Gustavo Padovan Cc: Johan Hedberg Cc: linux-blueto...@vger.kernel.org --- drivers/bluetooth/hci_ldisc.c | 19 --- drivers/bluetooth/hci_uart.h | 1 - 2 files changed, 20

[PATCH 0/4] TI Bluetooth serdev support

2017-04-05 Thread Rob Herring
This series adds serdev support to the HCI LL protocol used on TI BT modules and enables support on HiKey board with with the WL1835 module. With this the custom TI UIM daemon and btattach are no longer needed. The series is available on this git branch[1]. Patch 2 is just clean-up and can be appl

Re: [PATCH 3/4] net: dsa: LAN9303: add I2C managed mode support

2017-04-05 Thread Andrew Lunn
On Wed, Apr 05, 2017 at 11:20:23AM +0200, Juergen Borleis wrote: > In this mode the switch device and the internal phys will be managed via > I2C interface. The MDIO interface is still supported, but for the > (emulated) CPU port only. > > Signed-off-by: Juergen Borleis > --- > .../devicetree/bi

[PATCH net] qed: Correct MSI-x for storage

2017-04-05 Thread Yuval Mintz
When qedr is enabled, qed would try dividing the msi-x vectors between L2 and RoCE, starting with L2 and providing it with sufficient vectors for its queues. Problem is qed would also do that for storage partitions, and as those don't need queues it would lead qed to award those partitions with 0

[PATCH net-next 0/2] net: dsa: Mock-up driver couple fixes

2017-04-05 Thread Florian Fainelli
Thanks to Dan's static checker, a bunch of small issues were found in the code. Florian Fainelli (2): net: dsa: loop: Fix uninitialized pvid variable net: dsa: loop: Initialize err in dsa_loop_vlan_dump drivers/net/dsa/dsa_loop.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) --

[PATCH net-next 1/2] net: dsa: loop: Fix uninitialized pvid variable

2017-04-05 Thread Florian Fainelli
Dan's static analyzer reported the following: drivers/net/dsa/dsa_loop.c:181 dsa_loop_port_vlan_del() error: XXX uninitialized symbol 'pvid'. we were missing the assignment of pvid to ps->vid, so add that. Reported-by: Dan Carpenter Fixes: 98cd1552ea27 ("net: dsa: Mock-up driver

[PATCH net-next 2/2] net: dsa: loop: Initialize err in dsa_loop_vlan_dump

2017-04-05 Thread Florian Fainelli
Dan's static checker reported the following: drivers/net/dsa/dsa_loop.c:223 dsa_loop_port_vlan_dump() error: uninitialized symbol 'err'. which could happen if we do hit the continue statement for each iteration of the loop. Initialize err to 0 here. Reported-by: Dan Carpenter Fi

Re: [PATCH 2/4] net: dsa: add new DSA switch driver for the SMSC-LAN9303

2017-04-05 Thread Andrew Lunn
On Wed, Apr 05, 2017 at 11:20:22AM +0200, Juergen Borleis wrote: > The SMSC/Microchip LAN9303 is an ethernet switch device with one CPU port > and two external ethernet ports with built-in phys. > > This driver uses the DSA framework, but is currently only capable of > separating the two external

Re: [PATCH 1/2] bpf: remove struct bpf_prog_type_list

2017-04-05 Thread Alexei Starovoitov
On Tue, Apr 04, 2017 at 07:27:10PM +0200, Johannes Berg wrote: > From: Johannes Berg > > There's no need to have struct bpf_prog_type_list since > it just contains a list_head, the type, and the ops > pointer. Since the types are densely packed and not > actually dynamically registered, it's much

Re: pull-request: can 2017-04-04

2017-04-05 Thread Uwe Kleine-König
On Wed, Apr 05, 2017 at 10:37:34AM -0700, David Miller wrote: > From: Marc Kleine-Budde > Date: Tue, 4 Apr 2017 17:59:47 +0200 > > > this is a pull request of two patches for net/master. > ... > > The following changes since commit 0b9aefea860063bb39e36bd7fe6c7087fed0ba87: > > > > tcp: minimi

Re: [PATCH] ebpf: verify the output of the JIT

2017-04-05 Thread kbuild test robot
Hi Tycho, [auto build test WARNING on net/master] [also build test WARNING on v4.11-rc5 next-20170405] [cannot apply to tip/x86/core] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system] url: https://github.com/0day-ci/linux/commits/Tycho

Re: pull-request: can 2017-04-04

2017-04-05 Thread David Miller
From: Marc Kleine-Budde Date: Tue, 4 Apr 2017 17:59:47 +0200 > this is a pull request of two patches for net/master. ... > The following changes since commit 0b9aefea860063bb39e36bd7fe6c7087fed0ba87: > > tcp: minimize false-positives on TCP/GRO check (2017-04-03 18:43:41 -0700) > > are avail

Re: pull-request: can-next 2017-03-03,pull-request: can-next 2017-03-03

2017-04-05 Thread David Miller
From: Marc Kleine-Budde Date: Tue, 4 Apr 2017 17:47:28 +0200 > this is a pull request of 5 patches for net-next/master. > > There are two patches by Yegor Yefremov which convert the ti_hecc > driver into a DT only driver, as there is no in-tree user of the old > platform driver interface anymore

[PATCH 17/38] Annotate hardware config module parameters in drivers/net/arcnet/

2017-04-05 Thread David Howells
When the kernel is running in secure boot mode, we lock down the kernel to prevent userspace from modifying the running kernel image. Whilst this includes prohibiting access to things like /dev/mem, it must also prevent access by means of configuring driver modules in such a way as to cause a devi

Re: [PATCH 0/4 v2 net-next] net: stmmac: adding multiple buffers

2017-04-05 Thread Corentin Labbe
On Wed, Apr 05, 2017 at 05:43:00PM +0100, Joao Pinto wrote: > This patch adds multiple buffers to stmmac in a more fragmented > way, in order to make problem debug easier. > > I would kindly request to people to test this patch in their HWs in > order to check if everything's functional. Thank you

[PATCH 18/38] Annotate hardware config module parameters in drivers/net/can/

2017-04-05 Thread David Howells
When the kernel is running in secure boot mode, we lock down the kernel to prevent userspace from modifying the running kernel image. Whilst this includes prohibiting access to things like /dev/mem, it must also prevent access by means of configuring driver modules in such a way as to cause a devi

Re: [PATCH net-next 3/3] vxlan: allow multiple VXLANs with same VNI for IPv6 link-local addresses

2017-04-05 Thread Matthias Schiffer
On 03/15/2017 04:22 PM, Jiri Benc wrote: > On Wed, 15 Mar 2017 15:29:29 +0100, Matthias Schiffer wrote: >> While ensuring that the destination address is link-local iff the source >> address is would also be an option, it didn't seem too useful as the >> destination address will be a multicast addr

[PATCH 16/38] Annotate hardware config module parameters in drivers/net/appletalk/

2017-04-05 Thread David Howells
When the kernel is running in secure boot mode, we lock down the kernel to prevent userspace from modifying the running kernel image. Whilst this includes prohibiting access to things like /dev/mem, it must also prevent access by means of configuring driver modules in such a way as to cause a devi

[PATCH 19/38] Annotate hardware config module parameters in drivers/net/ethernet/

2017-04-05 Thread David Howells
When the kernel is running in secure boot mode, we lock down the kernel to prevent userspace from modifying the running kernel image. Whilst this includes prohibiting access to things like /dev/mem, it must also prevent access by means of configuring driver modules in such a way as to cause a devi

Re: [PATCH 1/4] net: dsa: add support for the SMSC-LAN9303 tagging format

2017-04-05 Thread Andrew Lunn
On Wed, Apr 05, 2017 at 11:20:21AM +0200, Juergen Borleis wrote: > To define the outgoing port and to discover the incoming port a regular > VLAN tag is used by the LAN9303. But its VID meaning is 'special'. > > This tag handler/filter depends on some hardware features which must be > enabled in t

[iproute PATCH] ip-route: Prevent some other double spaces in output

2017-04-05 Thread Timothy Redaelli
Print spaces only after text. CC: Phil Sutter Signed-off-by: Timothy Redaelli --- ip/iproute.c | 77 ++-- 1 file changed, 39 insertions(+), 38 deletions(-) Fixed all the problems reported in V2 Tested with improved script https://da.gd/t

[PATCH 22/38] Annotate hardware config module parameters in drivers/net/wan/

2017-04-05 Thread David Howells
When the kernel is running in secure boot mode, we lock down the kernel to prevent userspace from modifying the running kernel image. Whilst this includes prohibiting access to things like /dev/mem, it must also prevent access by means of configuring driver modules in such a way as to cause a devi

[PATCH 23/38] Annotate hardware config module parameters in drivers/net/wireless/

2017-04-05 Thread David Howells
When the kernel is running in secure boot mode, we lock down the kernel to prevent userspace from modifying the running kernel image. Whilst this includes prohibiting access to things like /dev/mem, it must also prevent access by means of configuring driver modules in such a way as to cause a devi

[PATCH 21/38] Annotate hardware config module parameters in drivers/net/irda/

2017-04-05 Thread David Howells
When the kernel is running in secure boot mode, we lock down the kernel to prevent userspace from modifying the running kernel image. Whilst this includes prohibiting access to things like /dev/mem, it must also prevent access by means of configuring driver modules in such a way as to cause a devi

[PATCH 20/38] Annotate hardware config module parameters in drivers/net/hamradio/

2017-04-05 Thread David Howells
When the kernel is running in secure boot mode, we lock down the kernel to prevent userspace from modifying the running kernel image. Whilst this includes prohibiting access to things like /dev/mem, it must also prevent access by means of configuring driver modules in such a way as to cause a devi

[PATCH 12/38] Annotate hardware config module parameters in drivers/isdn/

2017-04-05 Thread David Howells
When the kernel is running in secure boot mode, we lock down the kernel to prevent userspace from modifying the running kernel image. Whilst this includes prohibiting access to things like /dev/mem, it must also prevent access by means of configuring driver modules in such a way as to cause a devi

[PATCH 2/4 v2 net-next] net: stmmac: adding multiple buffers for RX

2017-04-05 Thread Joao Pinto
This patch adds the structure stmmac_rx_queue which contains rx queues specific data (previously in stmmac_priv). Signed-off-by: Joao Pinto --- changes v1->v2: - %d replaced by %u when printing unsigned - err_init_rx_buffers treatment fixed drivers/net/ethernet/stmicro/stmmac/chain_mode.c |

[PATCH 1/4 v2 net-next] net: stmmac: break some functions into RX and TX scopes

2017-04-05 Thread Joao Pinto
This patch breaks several functions into RX and TX scopes, which will be useful when adding multiple buffers mechanism. Signed-off-by: Joao Pinto --- changes v1->v2: - RX and TX inconsistency - stmmac_free_rx_buffers renamed to stmmac_free_rx_buffer - stmmac_free_tx_buffers renamed to stmmac_free

[PATCH 4/4 v2 net-next] net: stmmac: adding multiple napi mechanism

2017-04-05 Thread Joao Pinto
This patch adds the napi variable to the stmmac_rx_queue structure and forces that operations like netif_queue_stopped, netif_wake_queue, netif_stop_queue, netdev_reset_queue and netdev_sent_queue be made by queue. Signed-off-by: Joao Pinto --- changes v1->v2: - init_dma_desc_rings() and alloc_dm

[PATCH 3/4 v2 net-next] net: stmmac: adding multiple buffers for TX

2017-04-05 Thread Joao Pinto
This patch adds the structure stmmac_tx_queue which contains tx queues specific data (previously in stmmac_priv). Signed-off-by: Joao Pinto --- changes v1->v2: - just to keep up with patch-set version drivers/net/ethernet/stmicro/stmmac/chain_mode.c | 38 +- drivers/net/ethernet/stmicro/stmma

[PATCH 0/4 v2 net-next] net: stmmac: adding multiple buffers

2017-04-05 Thread Joao Pinto
This patch adds multiple buffers to stmmac in a more fragmented way, in order to make problem debug easier. I would kindly request to people to test this patch in their HWs in order to check if everything's functional. Thank you. Joao Pinto (4): net: stmmac: break some functions into RX and TX

[PATCH net-next] net/sched: Removed unused vlan actions definition

2017-04-05 Thread Or Gerlitz
Commit c7e2b9689ef "sched: introduce vlan action" added both the UAPI values for the vlan actions (TCA_VLAN_ACT_) and these two in-kernel ones which are not used, remove them. Signed-off-by: Or Gerlitz Acked-by: Jiri Pirko --- include/net/tc_act/tc_vlan.h | 3 --- 1 file changed, 3 deletions(-)

Re: in_irq_or_nmi() and RFC patch

2017-04-05 Thread Mel Gorman
On Mon, Apr 03, 2017 at 01:05:06PM +0100, Mel Gorman wrote: > > Started performance benchmarking: > > 163 cycles = current state > > 183 cycles = with BH disable + in_irq > > 218 cycles = with BH disable + in_irq + irqs_disabled > > > > Thus, the performance numbers unfortunately looks bad, onc

Re: [PATCH net-next] mlx4: trust shinfo->gso_segs

2017-04-05 Thread Saeed Mahameed
On Wed, Apr 5, 2017 at 11:49 AM, Eric Dumazet wrote: > From: Eric Dumazet > > mlx4 is the only driver in the tree making a point to recompute > shinfo->gso_segs. > > Lets remove superfluous code. > > Signed-off-by: Eric Dumazet > Cc: Tariq Toukan > Cc: Saeed Mahameed > --- > drivers/net/ether

[PATCH net-next] mlx4: trust shinfo->gso_segs

2017-04-05 Thread Eric Dumazet
From: Eric Dumazet mlx4 is the only driver in the tree making a point to recompute shinfo->gso_segs. Lets remove superfluous code. Signed-off-by: Eric Dumazet Cc: Tariq Toukan Cc: Saeed Mahameed --- drivers/net/ethernet/mellanox/mlx4/en_tx.c |3 +-- 1 file changed, 1 insertion(+), 2 del

RE: [PATCH] soreuseport: use "unsigned int" in __reuseport_alloc()

2017-04-05 Thread David Laight
From: Alexey Dobriyan > Sent: 04 April 2017 12:36 > On Mon, Apr 3, 2017 at 4:56 PM, Craig Gallek wrote: > > On Sun, Apr 2, 2017 at 6:18 PM, Alexey Dobriyan wrote: > >> Number of sockets is limited by 16-bit, so 64-bit allocation will never > >> happen. > >> > >> 16-bit ops are the worst code dens

Re: [PATCH v2] selftests: add a generic testsuite for ethernet device

2017-04-05 Thread David Miller
From: Corentin Labbe Date: Tue, 4 Apr 2017 15:32:47 +0200 > This patch add a generic testsuite for testing ethernet network device driver. > > Signed-off-by: Corentin Labbe > --- > > Changes since v1: > - Test for starting master interface > - Changed printing format to "RESULT: $netdev: line

Re: [PATCH v2 net-next 0/2] rtnetlink: Updates to rtnetlink_event()

2017-04-05 Thread David Miller
From: Vladislav Yasevich Date: Tue, 4 Apr 2017 09:23:40 -0400 > This series came out of the conversation that started as a result > my first attempt to add netdevice event info to netlink messages. > > This series converts event processing to a 'white list', where > we explicitely permit events

Re: [PATCH] net: davinci_mdio: add GPIO reset logic

2017-04-05 Thread Andrew Lunn
On Wed, Apr 05, 2017 at 11:33:57AM +0300, Roger Quadros wrote: > Some boards [1] leave the PHYs at an invalid state > during system power-up or reset thus causing unreliability > issues with the PHY like not being detected by the mdio bus > or link not functional. To work around these boards have >

Re: [PATCH v2 10/13] ftgmac100: Add a reset task and use it for link changes

2017-04-05 Thread Andrew Lunn
On Wed, Apr 05, 2017 at 12:28:50PM +1000, Benjamin Herrenschmidt wrote: > Link speed changes require a full HW reset. This isn't done > properly at the moment. It will involve delays and thus isn't > suitable to do from the link poll callback. > > So let's create a reset_task that we can queue up

Re: [PATCH v2 05/13] ftgmac100: Cleanup speed/duplex tracking and fix duplex config

2017-04-05 Thread Andrew Lunn
On Wed, Apr 05, 2017 at 12:28:45PM +1000, Benjamin Herrenschmidt wrote: > Keep track of both the current speed and duplex settings > instead of only speed and properly apply the duplex setting > to the HW. > > This reworks the adjust_link() function to also avoid trying > to reconfigure the HW whe

Re: [PATCH net-next] net/mlx5e: fix build error without CONFIG_SYSFS

2017-04-05 Thread Saeed Mahameed
On Wed, Apr 5, 2017 at 5:11 AM, Tobias Regnery wrote: > Commit 9008ae074885 ("net/mlx5e: Minimize mlx5e_{open/close}_locked") > copied the calls to netif_set_real_num_{tx,rx}_queues from > mlx5e_open_locked to mlx5e_activate_priv_channels and wraps them in an > if condition to test for netdev->rea

Re: [PATCH iproute2] man: fix man page warnings

2017-04-05 Thread Phil Sutter
On Sun, Mar 26, 2017 at 09:11:14PM +0200, Alexander Alemayhu wrote: > While generating PDFs from the man pages, I saw the warning below from > several files. Compared the tc-matchall.8 with bridge.8 and used .RI > instead of .R. It should have no effect on the man page rendering. > > `R' is a

Re: [PATCH net-next] net: stmmac: allow changing the MTU while the interface is running

2017-04-05 Thread David Miller
From: Niklas Cassel Date: Tue, 4 Apr 2017 14:18:54 +0200 > From: Niklas Cassel > > Setting ethtool ops for stmmac is only allowed when the interface is up. > Setting MTU (a netdev op) for stmmac is only allowed when the interface > is down. > > It seems that the only reason why MTU cannot be c

Re: [PATCH net-next v2 1/1] net: tcp: Define the TCP_MAX_WSCALE instead of literal number 14

2017-04-05 Thread David Miller
From: gfree.w...@foxmail.com Date: Tue, 4 Apr 2017 21:09:48 +0800 > From: Gao Feng > > Define one new macro TCP_MAX_WSCALE instead of literal number '14', > and use U16_MAX instead of 65535 as the max value of TCP window. > There is another minor change, use rounddown(space, mss) instead of > (

[PATCH net] l2tp: define SOL_PPPOL2TP in uapi

2017-04-05 Thread Guillaume Nault
Userspace needs SOL_PPPOL2TP to be defined for using PPPOL2TP_SO_* socket options. Signed-off-by: Guillaume Nault --- include/uapi/linux/if_pppol2tp.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/uapi/linux/if_pppol2tp.h b/include/uapi/linux/if_pppol2tp.h index 6418c4d10241..90c

Re: [PATCH] net: ibm: emac: remove unused sysrq handler for 'c' key

2017-04-05 Thread David Miller
From: Eric Biggers Date: Mon, 3 Apr 2017 22:50:20 -0700 > From: Eric Biggers > > Since commit d6580a9f1523 ("kexec: sysrq: simplify sysrq-c handler"), > the sysrq handler for the 'c' key has been sysrq_crash_op. Debugging > code in the ibm_emac driver also tries to register a handler for the

Re: net/sctp: list double add warning in sctp_endpoint_add_asoc

2017-04-05 Thread Marcelo Ricardo Leitner
On Wed, Apr 05, 2017 at 04:02:44PM +0200, Andrey Konovalov wrote: > On Tue, Apr 4, 2017 at 11:14 PM, Marcelo Ricardo Leitner > wrote: > > On Wed, Apr 05, 2017 at 01:29:19AM +0800, Xin Long wrote: > >> On Tue, Apr 4, 2017 at 9:28 PM, Andrey Konovalov > >> wrote: > >> > Hi, > >> > > >> > I've got

  1   2   >