Re: [PATCH net-next 1/8] net/ncsi: Avoid unused-value build warning from ia64-linux-gcc

2016-09-28 Thread David Miller
From: Gavin Shan Date: Thu, 29 Sep 2016 15:03:08 +1000 > This replaces the atomic access to NCSI channel's state with READ_ONCE() > and WRITE_ONCE() to avoid the above build warning. We needn't hold the > channel's lock when updating its state as well. No logical

Re: [PATCH 0/3] [v2] Add basic ACPI support to the Qualcomm Technologies EMAC driver

2016-09-28 Thread David Miller
From: Timur Tabi Date: Wed, 28 Sep 2016 11:58:41 -0500 > This patch series adds support to the EMAC driver for extracting addresses, > interrupts, and some _DSDs (properties) from ACPI. The first two patches > clean up the code, and the third patch adds ACPI-specific

Re: [PATCH net-next v5] bpf: allow access into map value arrays

2016-09-28 Thread David Miller
From: Josef Bacik Date: Wed, 28 Sep 2016 10:54:32 -0400 > Suppose you have a map array value that is something like this > > struct foo { > unsigned iter; > int array[SOME_CONSTANT]; > }; > > You can easily insert this into an array, but you cannot modify the

[PATCH kernel v2] PCI: Enable access to custom VPD for Chelsio devices (cxgb3)

2016-09-28 Thread Alexey Kardashevskiy
There is at least one Chelsio 10Gb card which uses VPD area to store some custom blocks (example below). However pci_vpd_size() returns the length of the first block only assuming that there can be only one VPD "End Tag" and VFIO blocks access beyond that offset (since 4e1a63555) which leads to

[PATCH net-next 7/8] net/ncsi: Introduce ncsi_stop_dev()

2016-09-28 Thread Gavin Shan
This introduces ncsi_stop_dev(), as counterpart to ncsi_start_dev(), to stop the NCSI device so that it can be reenabled in future. This API should be called when the network device driver is going to shutdown the device. There are 3 things done in the function: Stop the channel monitoring; Reset

[PATCH net-next 8/8] net/faraday: Stop NCSI device on shutdown

2016-09-28 Thread Gavin Shan
This stops NCSI device when closing the network device so that the NCSI device can be reenabled later. Signed-off-by: Gavin Shan Reviewed-by: Joel Stanley --- drivers/net/ethernet/faraday/ftgmac100.c | 2 ++ 1 file changed, 2 insertions(+) diff --git

[PATCH net-next 0/8] net/ncsi: NCSI Improvment and bug fixes

2016-09-28 Thread Gavin Shan
This series of patches improves NCSI stack according to the comments I received after the NCSI code was merged to 4.8.rc1: * PATCH[1/8] fixes the build warning caused by xchg() with ia64-linux-gcc. The atomic operations are replaced with {READ, WRITE}_ONCE(). * Channel ID (0x1f) is the

[PATCH net-next 1/8] net/ncsi: Avoid unused-value build warning from ia64-linux-gcc

2016-09-28 Thread Gavin Shan
xchg() is used to set NCSI channel's state in order for consistent access to the state. xchg()'s return value should be used. Otherwise, one build warning will be raised (with -Wunused-value) as below message indicates. It is reported by ia64-linux-gcc (GCC) 4.9.0. net/ncsi/ncsi-manage.c: In

[PATCH net-next 6/8] net/ncsi: Rework the channel monitoring

2016-09-28 Thread Gavin Shan
The original NCSI channel monitoring was implemented based on a backoff algorithm: the GLS response should be received in the specified interval. Otherwise, the channel is regarded as dead and failover should be taken if current channel is an active one. There are several problems in the

[PATCH net-next 5/8] net/ncsi: Allow to extend NCSI request properties

2016-09-28 Thread Gavin Shan
There is only one NCSI request property for now: the response for the sent command need drive the workqueue or not. So we had one field (@driven) for the purpose. We lost the flexibility to extend NCSI request properties. This replaces @driven with @flags and @req_flags in NCSI request and NCSI

[PATCH net-next 4/8] net/ncsi: Rework request index allocation

2016-09-28 Thread Gavin Shan
The NCSI request index (struct ncsi_request::id) is put into instance ID (IID) field while sending NCSI command packet. It was designed the available IDs are given in round-robin fashion. @ndp->request_id was introduced to represent the next available ID, but it has been used as number of

[PATCH net-next 3/8] net/ncsi: Don't probe on the reserved channel ID (0x1f)

2016-09-28 Thread Gavin Shan
We needn't send CIS (Clear Initial State) command to the NCSI reserved channel (0x1f) in the enumeration. We shouldn't receive a valid response from CIS on NCSI channel 0x1f. Signed-off-by: Gavin Shan Reviewed-by: Joel Stanley ---

[PATCH net-next 2/8] net/ncsi: Introduce NCSI_RESERVED_CHANNEL

2016-09-28 Thread Gavin Shan
This defines NCSI_RESERVED_CHANNEL as the reserved NCSI channel ID (0x1f). No logical changes introduced. Signed-off-by: Gavin Shan Reviewed-by: Joel Stanley --- net/ncsi/internal.h| 1 + net/ncsi/ncsi-manage.c | 14 +++--- 2 files

Re: [PATCH v2 net-next 4/5] xps_flows: XPS for packets that don't have a socket

2016-09-28 Thread Eric Dumazet
On Wed, 2016-09-28 at 20:54 -0700, Tom Herbert wrote: > xps_flows maintains a per device flow table that is indexed by the > skbuff hash. The table is only consulted when there is no queue saved in > a transmit socket for an skbuff. > > Each entry in the flow table contains a queue index and a

[PATCH v2 net-next] mlx5: Add ndo_poll_controller() implementation

2016-09-28 Thread Calvin Owens
This implements ndo_poll_controller in net_device_ops callbacks for mlx5, which is necessary to use netconsole with this driver. Acked-By: Saeed Mahameed Signed-off-by: Calvin Owens --- Changes in v2: * Only iterate channels to avoid redundant

Re: Explaining RX-stages for XDP

2016-09-28 Thread Alexei Starovoitov
On Wed, Sep 28, 2016 at 12:44:31PM +0200, Jesper Dangaard Brouer wrote: > > The idea is quite different. It has nothing to do with Edward's > proposal[3]. The RX packet-vector is simply an array, either of pointers > or index numbers (into the RX-ring). The needed changes are completely >

[PATCH v2 net-next 5/5] xps: Documentation for transmit socketles flow steering

2016-09-28 Thread Tom Herbert
Signed-off-by: Tom Herbert --- Documentation/ABI/testing/sysfs-class-net | 8 Documentation/networking/scaling.txt | 26 ++ 2 files changed, 34 insertions(+) diff --git a/Documentation/ABI/testing/sysfs-class-net

[PATCH v2 net-next 4/5] xps_flows: XPS for packets that don't have a socket

2016-09-28 Thread Tom Herbert
xps_flows maintains a per device flow table that is indexed by the skbuff hash. The table is only consulted when there is no queue saved in a transmit socket for an skbuff. Each entry in the flow table contains a queue index and a queue pointer. The queue pointer is set when a queue is chosen

[PATCH v2 net-next 1/5] net: Set SW hash in skb_set_hash_from_sk

2016-09-28 Thread Tom Herbert
Use the __skb_set_sw_hash to set the hash in an skbuff from the socket txhash. Signed-off-by: Tom Herbert --- include/net/sock.h | 6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/include/net/sock.h b/include/net/sock.h index ebf75db..17d379a 100644

[PATCH v2 net-next 2/5] dql: Add counters for number of queuing and completion operations

2016-09-28 Thread Tom Herbert
Add two new counters to struct dql that are num_enqueue_ops and num_completed_ops. num_enqueue_ops is incremented by one in each call to dql_queued. num_enqueue_ops is incremented in dql_completed which takes an argument indicating number of operations completed. These counters are only intended

[PATCH v2 net-next 3/5] net: Add xps_dev_flow_table_cnt

2016-09-28 Thread Tom Herbert
Add infrastructure and definitions to create XFS flow tables. This creates the new sys entry /sys/class/net/eth*/xps_dev_flow_table_cnt Signed-off-by: Tom Herbert --- include/linux/netdevice.h | 24 + net/core/net-sysfs.c | 89

[PATCH v2 net-next 0/5] xps_flows: XPS flow steering when there is no socket

2016-09-28 Thread Tom Herbert
This patch set introduces transmit flow steering for socketless packets. The idea is that we record the transmit queues in a flow table that is indexed by skbuff hash. The flow table entries have two values: the queue_index and the head cnt of packets from the TX queue. We only allow a queue to

Re: [PATCH net v2] L2TP:Adjust intf MTU,factor underlay L3,overlay L2

2016-09-28 Thread R. Parameswaran
Hi David, Please see inline: On Wed, 28 Sep 2016, David Miller wrote: > From: "R. Parameswaran" > Date: Tue, 27 Sep 2016 12:17:21 -0700 (PDT) > > > Later, in vxlan_dev_configure(), called from vxlan_dev_create(), it gets > > adjusted to account for the headers: >

Re: [PATCH] netfilter: bridge: clarify bridge/netfilter message

2016-09-28 Thread Florian Westphal
Stefan Agner wrote: > When using bridge without bridge netfilter enabled the message > displayed is rather confusing and leads to belive that a deprecated > feature is in use. Use IS_MODULE to be explicit that the message only > affects users which use bridge netfilter as module

Re: UDP wierdness around skb_copy_and_csum_datagram_msg()

2016-09-28 Thread Jay Smith
Actually, on a little more searching of this list's archives, I think that this discussion: https://patchwork.kernel.org/patch/9260733/ is about exactly the same issue I've found, except from the TCP side. I'm cc'ing a few of the participants from that discussion. So is the patch proposed there

Re: [PATCH net-next v3 2/3] udp: implement memory accounting helpers

2016-09-28 Thread Eric Dumazet
On Wed, 2016-09-28 at 12:52 +0200, Paolo Abeni wrote: > +static void udp_rmem_release(struct sock *sk, int partial) > +{ > + struct udp_sock *up = udp_sk(sk); > + int fwd, amt; > + > + if (partial && !udp_under_memory_pressure(sk)) > + return; > + > + /* we can have

Re: UDP wierdness around skb_copy_and_csum_datagram_msg()

2016-09-28 Thread Eric Dumazet
On Wed, 2016-09-28 at 17:18 -0700, Jay Smith wrote: > I've spent the last week or so trying to track down a recurring > problem I'm seeing with UDP datagram handling. I'm new to the > internals of the Linux network stack, but it appears to me that > there's a substantial error in recent kernels'

Re: linux-next: manual merge of the netfilter-next tree with the net tree

2016-09-28 Thread Stephen Rothwell
Hi all, On Tue, 13 Sep 2016 10:12:50 +1000 Stephen Rothwell wrote: > > Today's linux-next merge of the netfilter-next tree got a conflict in: > > net/netfilter/nf_tables_netdev.c > > between commit: > > c73c24849011 ("netfilter: nf_tables_netdev: remove redundant

Re: [PATCH net-next] net: do not export sk_stream_write_space

2016-09-28 Thread David Miller
From: Eric Dumazet Date: Wed, 28 Sep 2016 08:41:16 -0700 > From: Eric Dumazet > > Since commit 900f65d361d3 ("tcp: move duplicate code from > tcp_v4_init_sock()/tcp_v6_init_sock()") we no longer need > to export sk_stream_write_space() > > From:

UDP wierdness around skb_copy_and_csum_datagram_msg()

2016-09-28 Thread Jay Smith
I've spent the last week or so trying to track down a recurring problem I'm seeing with UDP datagram handling. I'm new to the internals of the Linux network stack, but it appears to me that there's a substantial error in recent kernels' handling of UDP checksum errors. The behavior I'm seeing:

Re: mv643xxx_eth driver, failed to linearize skb with tiny unaligned fragment

2016-09-28 Thread Eric Dumazet
On Wed, 2016-09-28 at 22:37 +0200, Frans van de Wiel wrote: > We compiled kernel 4.6.6 for our nas devices running on ARM kirkwood cpu’s. > These nas devices have only 256 MB of RAM so limited memory resources > When we fully load the cpu and are copying files via the interface we get >

How to submit potential patch in linux kernel

2016-09-28 Thread Shyam Saini
Hi everyone, I'm Shyam, final year undergraduate student. I wanted to know how one can submit potential linux kernel patch in networking subsystem. Thanks, Shyam

[PATCH net-next] nfp: bpf: zero extend 4 byte context loads

2016-09-28 Thread Jakub Kicinski
Set upper 32 bits of destination register to zeros after load from the context structure. Signed-off-by: Jakub Kicinski --- drivers/net/ethernet/netronome/nfp/nfp_bpf_jit.c | 2 ++ 1 file changed, 2 insertions(+) diff --git

Re: [PATCH] Add netdev all_adj_list refcnt propagation to fix panic

2016-09-28 Thread Andrew Collins
On 09/28/2016 12:06 PM, David Ahern wrote: Andrew Collins posted this patch as RFC in March: http://patchwork.ozlabs.org/patch/603101/ It has apparently fallen through the cracks and never applied. It solves a refcnt problem (thanks Nik for pointing out this patch) I have been running

[PATCH v2 net-next 2/2] net: deprecate eth_change_mtu, remove usage

2016-09-28 Thread Jarod Wilson
With centralized MTU checking, there's nothing productive done by eth_change_mtu that isn't already done in dev_set_mtu, so mark it as deprecated and remove all usage of it in the kernel. All callers have been audited for calls to alloc_etherdev* or ether_setup directly, which means they all have

[PATCH v2 net-next 0/2] net: centralize net_device MTU bounds checking

2016-09-28 Thread Jarod Wilson
While looking into an MTU issue with sfc, I started noticing that almost every NIC driver with an ndo_change_mtu function implemented almost exactly the same range checks, and in many cases, that was the only practical thing their ndo_change_mtu function was doing. Quite a few drivers have either

[PATCH v2 net-next 1/2] net: centralize net_device min/max MTU checking

2016-09-28 Thread Jarod Wilson
While looking into an MTU issue with sfc, I started noticing that almost every NIC driver with an ndo_change_mtu function implemented almost exactly the same range checks, and in many cases, that was the only practical thing their ndo_change_mtu function was doing. Quite a few drivers have either

[PATCH] netfilter: bridge: clarify bridge/netfilter message

2016-09-28 Thread Stefan Agner
When using bridge without bridge netfilter enabled the message displayed is rather confusing and leads to belive that a deprecated feature is in use. Use IS_MODULE to be explicit that the message only affects users which use bridge netfilter as module and reword the message. Signed-off-by: Stefan

Re: [PATCH RFC 5/6] net: phy: Trigger state machine on state change and not polling.

2016-09-28 Thread Florian Fainelli
On 09/28/2016 01:32 AM, Andrew Lunn wrote: > The phy_start() is used to indicate the PHY is now ready to do its > work. The state is changed, normally to PHY_UP which means that both > the MAC and the PHY are ready. > > If the phy driver is using polling, when the next poll happens, the > state

[PATCH v2 net-next 0/2] net: centralize net_device MTU bounds checking

2016-09-28 Thread Jarod Wilson
While looking into an MTU issue with sfc, I started noticing that almost every NIC driver with an ndo_change_mtu function implemented almost exactly the same range checks, and in many cases, that was the only practical thing their ndo_change_mtu function was doing. Quite a few drivers have either

Re: [PATCH RFC 2/6] net: phy: Use threaded IRQ, to allow IRQ from sleeping devices

2016-09-28 Thread Andrew Lunn
On Wed, Sep 28, 2016 at 02:38:03PM +0300, Sergei Shtylyov wrote: > Hello. > > On 9/28/2016 11:32 AM, Andrew Lunn wrote: > > >The interrupt lines from PHYs maybe connected to I2C bus expanders, or > >from switches on MDIO busses. Such interrupts are sourced from devices > >which sleep, so use

mv643xxx_eth driver, failed to linearize skb with tiny unaligned fragment

2016-09-28 Thread Frans van de Wiel
We compiled kernel 4.6.6 for our nas devices running on ARM kirkwood cpu’s. These nas devices have only 256 MB of RAM so limited memory resources When we fully load the cpu and are copying files via the interface we get frequently this “ error” message in dmesg log [ 1978.149929]

Re: [PATCH net-next 2/2] net: phy: Add PHY Auto/Mdi/Mdix set driver for Microsemi PHYs.

2016-09-28 Thread Andrew Lunn
> + reg_val = phy_read(phydev, MSCC_PHY_BYPASS_CONTROL); > + if ((mdix == ETH_TP_MDI) || (mdix == ETH_TP_MDI_X)) { > + reg_val |= (DISABLE_PAIR_SWAP_CORR_MASK | > + DISABLE_POLARITY_CORR_MASK | > + DISABLE_HP_AUTO_MDIX_MASK); > +

Re: [PATCH] fs/select: add vmalloc fallback for select(2)

2016-09-28 Thread Vlastimil Babka
On 09/28/2016 06:30 PM, David Laight wrote: > From: Vlastimil Babka >> Sent: 27 September 2016 12:51 > ... >> Process name suggests it's part of db2 database. It seems it has to implement >> its own interface to select() syscall, because glibc itself seems to have a >> FD_SETSIZE limit of 1024,

Re: [PATCH net-next] net/vxlan: Avoid unaligned access in vxlan_build_skb()

2016-09-28 Thread Sowmini Varadhan
On (09/28/16 11:08), Alexander Duyck wrote: > > - then udp_gro_receive -> vxlan_gro_receive pulls up vxlan header > > into linear part, and then.. > > This is the point where we need to stop, drop the existing headers, > call skb_reserve(NET_IP_ALIGN), and then pick back up where we left > off.

[PATCH net] sctp: fix the issue sctp_diag uses lock_sock in rcu_read_lock

2016-09-28 Thread Xin Long
When sctp dumps all the ep->assocs, it needs to lock_sock first, but now it locks sock in rcu_read_lock, and lock_sock may sleep, which would break rcu_read_lock. This patch is to get and hold one sock when traversing the list. After that and get out of rcu_read_lock, lock and dump it. Then it

[PATCHv3 net 0/3] sctp: a bunch of fixes for prsctp polices

2016-09-28 Thread Xin Long
This patchset is to fix 2 issues for prsctp polices: 1. patch 1 and 2 fix "netperf-Throughput_Mbps -37.2% regression" issue when overloading the CPU. 2. patch 3 fix "prsctp polices should check both sides' prsctp_capable, instead of only local side". Xin Long (3): sctp: move

[PATCHv3 net 3/3] sctp: change to check peer prsctp_capable when using prsctp polices

2016-09-28 Thread Xin Long
Now before using prsctp polices, sctp uses asoc->prsctp_enable to check if prsctp is enabled. However asoc->prsctp_enable is set only means local host support prsctp, sctp should not abandon packet if peer host doesn't enable prsctp. So this patch is to use asoc->peer.prsctp_capable to check if

[PATCHv3 net 1/3] sctp: move sent_count to the memory hole in sctp_chunk

2016-09-28 Thread Xin Long
Now pahole sctp_chunk, it has 2 memory holes: struct sctp_chunk { struct list_head list; atomic_t refcnt; /* XXX 4 bytes hole, try to pack */ ... long unsigned int prsctp_param; int

[PATCHv3 net 2/3] sctp: remove prsctp_param from sctp_chunk

2016-09-28 Thread Xin Long
Now sctp uses chunk->prsctp_param to save the prsctp param for all the prsctp polices, we didn't need to introduce prsctp_param to sctp_chunk. We can just use chunk->sinfo.sinfo_timetolive for RTX and BUF polices, and reuse msg->expires_at for TTL policy, as the prsctp polices and old expires

[PATCH] tc: f_u32: Fill in 'linkid' provided by user

2016-09-28 Thread Sushma Sitaram
Currently, 'linkid' input by the user is parsed but 'handle' is appended to the netlink message. # tc filter add dev enp1s0f1 protocol ip parent : prio 99 u32 ht 800: \ order 1 link 1: offset at 0 mask 0f00 shift 6 plus 0 eat match ip \ protocol 6 ff resulted in: filter

Re: [PATCH v1] mlx4: remove unused fields

2016-09-28 Thread Eric Dumazet
On Wed, 2016-09-28 at 11:00 -0700, David Decotigny wrote: > From: David Decotigny > > This also can address following UBSAN warnings: > [ 36.640343] > > [ 36.648772] UBSAN: Undefined

Re: [PATCH net-next] net/vxlan: Avoid unaligned access in vxlan_build_skb()

2016-09-28 Thread Alexander Duyck
On Wed, Sep 28, 2016 at 10:03 AM, Sowmini Varadhan wrote: > On (09/23/16 17:43), Alexander Duyck wrote: >> > On (09/23/16 10:38), Alexander Duyck wrote: > ; >> >> almost think of it as us doing something like the inverse of >> >> pskb_pull_tail. The general

[PATCH] Add netdev all_adj_list refcnt propagation to fix panic

2016-09-28 Thread David Ahern
Andrew Collins posted this patch as RFC in March: http://patchwork.ozlabs.org/patch/603101/ It has apparently fallen through the cracks and never applied. It solves a refcnt problem (thanks Nik for pointing out this patch) with stacked devices that involves macvlan on a bridge, a bond into

Re: [PATCH 3/3] net: fec: align IP header in hardware

2016-09-28 Thread Eric Nelson
Thanks Russell, On 09/28/2016 10:25 AM, Russell King - ARM Linux wrote: > On Wed, Sep 28, 2016 at 10:14:52AM -0700, Eric Nelson wrote: >> Thanks David, >> >> On 09/28/2016 09:42 AM, David Laight wrote: >>> From reading this it seems that the effect of FEC_RACC_SHIFT16 is to >>> add two bytes of

[PATCH v1] mlx4: remove unused fields

2016-09-28 Thread David Decotigny
From: David Decotigny This also can address following UBSAN warnings: [ 36.640343] [ 36.648772] UBSAN: Undefined behaviour in drivers/net/ethernet/mellanox/mlx4/fw.c:857:26 [ 36.656853]

Re: ISDN-Gigaset: Fine-tuning for three function implementations

2016-09-28 Thread Paul Bolle
On Wed, 2016-09-28 at 18:50 +0200, SF Markus Elfring wrote: > Would you like to look once more into an improved patch series for this > software module a bit later? I'm afraid I'm not looking forward to receiving an update of this series, sorry. Thanks, Paul Bolle

Re: [PATCH 1/5] ISDN-Gigaset: Use kmalloc_array() in two functions

2016-09-28 Thread Paul Bolle
On Wed, 2016-09-28 at 18:38 +0200, SF Markus Elfring wrote: > > I'm not going to change code just because some checker suggests to > > do so. > > The script "checkpatch.pl" can point information out like the > following. > > WARNING: Prefer kmalloc_array over kmalloc with multiply Am I being

Re: [PATCH v2 net] net: skbuff: skb_vlan_push: Fix wrong unwinding of skb->data after __vlan_insert_tag call

2016-09-28 Thread Shmulik Ladkani
On Wed, 28 Sep 2016 16:43:38 +0200 Daniel Borkmann wrote: > Couldn't we end up with 1) for the act_vlan case when we'd have the > offset-adjusted skb_vlan_push() fix from here, where we'd then redirect > to ingress where skb_vlan_pop() would be called? If I'm not missing >

Re: [PATCH net-next 1/2] net: phy: Add Wake-on-LAN driver for Microsemi PHYs.

2016-09-28 Thread Florian Fainelli
On 09/28/2016 05:01 AM, Raju Lakkaraju wrote: > From: Raju Lakkaraju > > Wake-on-LAN (WoL) is an Ethernet networking standard that allows > a computer/device to be turned on or awakened by a network message. > VSC8531 PHY can support this feature configure by driver

Re: [PATCH 3/3] net: fec: align IP header in hardware

2016-09-28 Thread Russell King - ARM Linux
On Wed, Sep 28, 2016 at 10:14:52AM -0700, Eric Nelson wrote: > Thanks David, > > On 09/28/2016 09:42 AM, David Laight wrote: > > From reading this it seems that the effect of FEC_RACC_SHIFT16 is to > > add two bytes of 'junk' to the start of every receive frame. > > That's right. Two bytes of

Re: [PATCH RFC 4/6] net: phy: Use phy name when requesting the interrupt

2016-09-28 Thread Florian Fainelli
On 09/28/2016 01:32 AM, Andrew Lunn wrote: > Using the fixed name "phy_interrupt" is not very informative in > /proc/interrupts when there are a lot of phys, e.g. a device with an > Ethernet switch. So when requesting the interrupt, use the name of the > phy. > > Signed-off-by: Andrew Lunn

Re: [PATCH 3/3] net: fec: align IP header in hardware

2016-09-28 Thread Eric Nelson
Thanks David, On 09/28/2016 09:42 AM, David Laight wrote: > From: Eric Nelson >> Sent: 26 September 2016 19:40 >> Hi David, >> >> On 09/26/2016 02:26 AM, David Laight wrote: >>> From: Eric Nelson Sent: 24 September 2016 15:42 The FEC receive accelerator (RACC) supports shifting the data

Re: [PATCH RFC 3/6] net: phy: Threaded interrupts allow some simplification

2016-09-28 Thread Florian Fainelli
On 09/28/2016 06:38 AM, Sergei Shtylyov wrote: > On 09/28/2016 03:28 PM, Andrew Lunn wrote: > > The PHY interrupts are now handled in a threaded interrupt handler, > which can sleep. The work queue is no longer needed, phy_change() can > be called directly. Additionally, none of the

Re: [PATCH v2 net] net: skbuff: skb_vlan_push: Fix wrong unwinding of skb->data after __vlan_insert_tag call

2016-09-28 Thread Shmulik Ladkani
On Wed, 28 Sep 2016 16:43:38 +0200 Daniel Borkmann wrote: > > (1) suppose upon entry we have > > > > DA,SA,0x8100,TCI,0x0800, > > ^^ > > mac_hdr data > > > > initial offset is 18, and after current unwinding code we'll get > > You

Re: [PATCH net-next] net/vxlan: Avoid unaligned access in vxlan_build_skb()

2016-09-28 Thread Sowmini Varadhan
On (09/23/16 17:43), Alexander Duyck wrote: > > On (09/23/16 10:38), Alexander Duyck wrote: ; > >> almost think of it as us doing something like the inverse of > >> pskb_pull_tail. The general idea here is we want to actually leave > >> the data in skb->data, but just reference it from

[PATCH 0/3] [v2] Add basic ACPI support to the Qualcomm Technologies EMAC driver

2016-09-28 Thread Timur Tabi
This patch series adds support to the EMAC driver for extracting addresses, interrupts, and some _DSDs (properties) from ACPI. The first two patches clean up the code, and the third patch adds ACPI-specific functionality. The first patch fixes a bug with handling the platform_device for the

[PATCH 2/3] [v2] net: qcom/emac: use device_get_mac_address

2016-09-28 Thread Timur Tabi
Replace the DT-specific of_get_mac_address() function with device_get_mac_address, which works on both DT and ACPI platforms. This change makes it easier to add ACPI support. Signed-off-by: Timur Tabi --- drivers/net/ethernet/qualcomm/emac/emac.c | 10 -- 1 file

[PATCH 1/3] [v2] net: qcom/emac: do not use devm on internal phy pdev

2016-09-28 Thread Timur Tabi
The platform_device returned by of_find_device_by_node() is not automatically released when the driver unprobes. Therefore, managed calls like devm_ioremap_resource() should not be used. Instead, we manually allocate the resources and then free them on driver release. Signed-off-by: Timur Tabi

[PATCH 3/3] [v2] net: qcom/emac: initial ACPI support

2016-09-28 Thread Timur Tabi
Add support for reading addresses, interrupts, and _DSD properties from ACPI tables, just like with device tree. The HID for the EMAC device itself is QCOM8070. The internal PHY is represented by a child node with a HID of QCOM8071. The EMAC also has some complex clock initialization

Re: ISDN-Gigaset: Fine-tuning for three function implementations

2016-09-28 Thread SF Markus Elfring
> Two of the five patches introduced bugs. The rest of the series isn't > free of various nits either. Of course, I was in no mood to be lenient > when I looked at those three patches. > > I won't take any of these patches, sorry. Would you like to look once more into an improved patch series

Re: [PATCHv2 net 0/5] sctp: some fixes of prsctp polices

2016-09-28 Thread Xin Long
> > That doesn't matter. This happens all the time. > > The way you handle this is you submit patch #1 targetting 'net' and > wait for it to get into 'net' and propagate into 'net-next'. When > that happens you can submit patches #2-5 as a second patch series > targetting 'net-next'. Thanks,

RE: [PATCH 3/3] net: fec: align IP header in hardware

2016-09-28 Thread David Laight
From: Eric Nelson > Sent: 26 September 2016 19:40 > Hi David, > > On 09/26/2016 02:26 AM, David Laight wrote: > > From: Eric Nelson > >> Sent: 24 September 2016 15:42 > >> The FEC receive accelerator (RACC) supports shifting the data payload of > >> received packets by 16-bits, which aligns the

Re: [PATCH 1/5] ISDN-Gigaset: Use kmalloc_array() in two functions

2016-09-28 Thread SF Markus Elfring
>> * Multiplications for the size determination of memory allocations >> indicated that array data structures should be processed. >> Thus use the corresponding function "kmalloc_array". > > Was the current code incorrect? I suggest to use a safer interface for array allocations. > What

RE: [PATCH] fs/select: add vmalloc fallback for select(2)

2016-09-28 Thread David Laight
From: Vlastimil Babka > Sent: 27 September 2016 12:51 ... > Process name suggests it's part of db2 database. It seems it has to implement > its own interface to select() syscall, because glibc itself seems to have a > FD_SETSIZE limit of 1024, which is probably why this wasn't an issue for all >

Re: [PATCH net-next 1/2] net: phy: Add Wake-on-LAN driver for Microsemi PHYs.

2016-09-28 Thread Andrew Lunn
> +#define MSCC_PHY_WOL_MAC_CONTROL 27 > +#define EDGE_RATE_CNTL_POS 5 > +#define EDGE_RATE_CNTL_MASK0x00E0 This patch does not require these two #defines. Please indicate in the cover note if the patches depends on other patches in order to cleanly apply. Or if

Re: [net-next 5/5] PCI: disable FLR for 82579 device

2016-09-28 Thread Bjorn Helgaas
On Wed, Sep 28, 2016 at 03:33:52PM +, Neftin, Sasha wrote: > > Since I worked with Sasha on this I will provide a bit of information from > what I understand of this bug as well. > > On Tue, Sep 27, 2016 at 12:13 PM, Alex Williamson > wrote: > > On Tue, 27 Sep

Re: [PATCH v4 net-next] net: phy: Add Edge-rate driver for Microsemi PHYs.

2016-09-28 Thread Andrew Lunn
> +Optional properties: > +- vsc8531,vddmac : The vddmac in mV. > +- vsc8531,edge-slowdown : % the edge should be slowed down relative to > + the fastest possible edge time. Native sign > + need not enter. > + Edge rate

Local variable ordering (was Re: [PATCH v5 0/7] Reduce cache miss for snmp_fold_field)

2016-09-28 Thread Edward Cree
On 28/09/16 14:45, hejianet wrote: > > > On 9/28/16 5:08 PM, David Miller wrote: >> From: Jia He >> Date: Wed, 28 Sep 2016 14:22:21 +0800 >> >>> v5: >>> - order local variables from longest to shortest line >> I still see many cases where this problem still exists. Please >>

Re: [PATCHv2 net 0/5] sctp: some fixes of prsctp polices

2016-09-28 Thread marcelo . leitner
On Wed, Sep 28, 2016 at 11:17:16AM -0400, David Miller wrote: > From: Xin Long > Date: Wed, 28 Sep 2016 20:35:40 +0800 > > >> > >>> This patchset is to improve some codes about prsctp polices, and also > >>> to fix some issues. > >>> > >>> v1->v2: > >>> - wrap the check

[PATCH net-next] net: do not export sk_stream_write_space

2016-09-28 Thread Eric Dumazet
From: Eric Dumazet Since commit 900f65d361d3 ("tcp: move duplicate code from tcp_v4_init_sock()/tcp_v6_init_sock()") we no longer need to export sk_stream_write_space() From: Eric Dumazet Cc: Neal Cardwell --- net/core/stream.c

[PATCH nf-next v4 0/2] fixes for recent nf_compact hooks

2016-09-28 Thread Aaron Conole
Two possible error conditions were caught during an extended testing session, and by a build robot. These patches fix the two issues (a missing handler when config is changed, and a potential NULL dereference). Aaron Conole (2): netfilter: Fix potential null pointer dereference

[PATCH nf-next v4 1/2] netfilter: Fix potential null pointer dereference

2016-09-28 Thread Aaron Conole
It's possible for nf_hook_entry_head to return NULL. If two nf_unregister_net_hook calls happen simultaneously with a single hook entry in the list, both will enter the nf_hook_mutex critical section. The first will successfully delete the head, but the second will see this NULL pointer and

Re: [PATCH nf-next v3 1/2] netfilter: Fix potential null pointer dereference

2016-09-28 Thread Aaron Conole
Eric Dumazet writes: > On Wed, 2016-09-28 at 10:56 -0400, Aaron Conole wrote: >> Eric Dumazet writes: >> >> > On Wed, 2016-09-28 at 09:12 -0400, Aaron Conole wrote: >> >> It's possible for nf_hook_entry_head to return NULL. If two >> >>

[PATCH nf-next v4 2/2] nf_set_hooks_head: accommodate different kconfig

2016-09-28 Thread Aaron Conole
When CONFIG_NETFILTER_INGRESS is unset (or no), we need to handle the request for registration properly by dropping the hook. This releases the entry during the set. Fixes: e3b37f11e6e4 ("netfilter: replace list_head with single linked list") Signed-off-by: Aaron Conole ---

RE: [net-next 5/5] PCI: disable FLR for 82579 device

2016-09-28 Thread Neftin, Sasha
Since I worked with Sasha on this I will provide a bit of information from what I understand of this bug as well. On Tue, Sep 27, 2016 at 12:13 PM, Alex Williamson wrote: > On Tue, 27 Sep 2016 13:17:02 -0500 > Bjorn Helgaas wrote: > >> On Sun,

Re: [PATCH nf-next v3 1/2] netfilter: Fix potential null pointer dereference

2016-09-28 Thread Eric Dumazet
On Wed, 2016-09-28 at 10:56 -0400, Aaron Conole wrote: > Eric Dumazet writes: > > > On Wed, 2016-09-28 at 09:12 -0400, Aaron Conole wrote: > >> It's possible for nf_hook_entry_head to return NULL. If two > >> nf_unregister_net_hook calls happen simultaneously with a

Re: [PATCH] ipv6 addrconf: enable use of proc_dointvec_minmax in addrconf_sysctl

2016-09-28 Thread David Miller
From: Maciej Żenczykowski Date: Wed, 28 Sep 2016 22:23:10 +0900 > Anyway, enough, I give up, this isn't worth my time, and it's also not > worth your time. > I removed the dependency from the other patches and squashed them all into > 1 to make reviewing easier.

Re: [PATCHv2 net 0/5] sctp: some fixes of prsctp polices

2016-09-28 Thread David Miller
From: Xin Long Date: Wed, 28 Sep 2016 20:35:40 +0800 >> >>> This patchset is to improve some codes about prsctp polices, and also >>> to fix some issues. >>> >>> v1->v2: >>> - wrap the check of chunk->sent_count in a macro: >>> sctp_chunk_retransmitted in patch 2/5.

Re: [PATCH RFC 0/4] xfs: Transmit flow steering

2016-09-28 Thread Rick Jones
Here is a quick look at performance tests for the result of trying the prototype fix for the packet reordering problem with VMs sending over an XPS-configured NIC. In particular, the Emulex/Avago/Broadcom Skyhawk. The fix was applied to a 4.4 kernel. Before: 3884 Mbit/s After: 8897 Mbit/s

Re: [RFC PATCH net-next 2/2] sfc: report 4-tuple UDP hashing to ethtool, if it's enabled

2016-09-28 Thread Edward Cree
On 28/09/16 10:12, David Laight wrote: > If you invert the above and add a goto... > if (!efx->rx_hash_udp_4tuple) > goto set_ip; I don't mind gotos... >> case SCTP_V4_FLOW: >> case AH_ESP_V4_FLOW: >> case

Re: [PATCH nf-next v3 1/2] netfilter: Fix potential null pointer dereference

2016-09-28 Thread Aaron Conole
Eric Dumazet writes: > On Wed, 2016-09-28 at 09:12 -0400, Aaron Conole wrote: >> It's possible for nf_hook_entry_head to return NULL. If two >> nf_unregister_net_hook calls happen simultaneously with a single hook >> entry in the list, both will enter the nf_hook_mutex

Re: [PATCH v5] net: ip, diag -- Add diag interface for raw sockets

2016-09-28 Thread Cyrill Gorcunov
On Wed, Sep 28, 2016 at 06:49:51AM -0700, Eric Dumazet wrote: > > > > 4.7 is pretty widespread, so I've to think... > > Sorry, 4.4.7 it was > > https://www.mail-archive.com/netdev@vger.kernel.org/msg128714.html Ah, thanks for info!

[PATCH net-next v5] bpf: allow access into map value arrays

2016-09-28 Thread Josef Bacik
Suppose you have a map array value that is something like this struct foo { unsigned iter; int array[SOME_CONSTANT]; }; You can easily insert this into an array, but you cannot modify the contents of foo->array[] after the fact. This is because we have no way to verify we won't

[PATCH v8 1/8] thunderbolt: Macro rename

2016-09-28 Thread Amir Levy
This first patch updates the NHI Thunderbolt controller registers file to reflect that it is not only for Cactus Ridge. No functional change intended. Signed-off-by: Amir Levy Signed-off-by: Andreas Noever --- drivers/thunderbolt/nhi_regs.h |

[PATCH v8 4/8] thunderbolt: Networking state machine

2016-09-28 Thread Amir Levy
This patch builds the peer to peer communication path. Communication is established by a negotiation process whereby messages are sent back and forth between the peers until a connection is established. This includes the Thunderbolt Network driver communication with the second peer via Intel

[PATCH v8 6/8] thunderbolt: Kconfig for Thunderbolt Networking

2016-09-28 Thread Amir Levy
Update to the Kconfig Thunderbolt description to add Thunderbolt networking as an option. The menu item "Thunderbolt support" now offers: "Apple Hardware Support" (existing) and/or "Thunderbolt Networking" (new) You can choose the driver for your platform or build both drivers - each

[PATCH v8 7/8] thunderbolt: Networking doc

2016-09-28 Thread Amir Levy
Adding Thunderbolt(TM) networking documentation. Signed-off-by: Amir Levy --- Documentation/00-INDEX | 2 + Documentation/thunderbolt/networking.txt | 132 +++ 2 files changed, 134 insertions(+) create mode 100644

[PATCH v8 3/8] thunderbolt: Communication with the ICM (firmware)

2016-09-28 Thread Amir Levy
This patch provides the communication protocol between the Intel Connection Manager(ICM) firmware that is operational in the Thunderbolt controller in non-Apple hardware. The ICM firmware-based controller is used for establishing and maintaining the Thunderbolt Networking connection - we need to

[PATCH v8 8/8] thunderbolt: Adding maintainer entry

2016-09-28 Thread Amir Levy
Add Amir Levy as maintainer for Thunderbolt(TM) ICM driver Signed-off-by: Amir Levy --- MAINTAINERS | 8 +++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/MAINTAINERS b/MAINTAINERS index 01bff8e..a4a4614 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@

  1   2   3   >