Re: [PATCH v7 net-next 01/16] gso: Remove arbitrary checks for unsupported GSO

2016-05-20 Thread Alexander Duyck
On Fri, May 20, 2016 at 6:02 PM, Hannes Frederic Sowa wrote: > Hello, > > On 18.05.2016 18:06, Tom Herbert wrote: >> In several gso_segment functions there are checks of gso_type against >> a seemingly arbitrary list of SKB_GSO_* flags. This seems like an >> attempt to identify unsupported GSO typ

Re: [PATCH 2/2] ip6_gre: Set flowi6_proto as IPPROTO_GRE in xmit path.

2016-05-20 Thread 严海双
> On May 21, 2016, at 1:48 AM, David Miller wrote: > > From: Haishuang Yan > Date: Wed, 18 May 2016 18:05:52 +0800 > >> In gre6 xmit path, we are sending a GRE packet, so set fl6 proto >> to IPPROTO_GRE properly. >> >> Signed-off-by: Haishuang Yan > > I think it would be a lot better to ini

Re: IPv6 extension header privileges

2016-05-20 Thread Sowmini Varadhan
On (05/21/16 02:20), Hannes Frederic Sowa wrote: > > There are some options inherently protocol depending like the jumbo > payload option, which should be under control of the kernel, or the > router alert option for igmp, which causes packets to be steered towards > the slow/software path of rout

Re: [PATCH v7 net-next 01/16] gso: Remove arbitrary checks for unsupported GSO

2016-05-20 Thread Hannes Frederic Sowa
Hello, On 18.05.2016 18:06, Tom Herbert wrote: > In several gso_segment functions there are checks of gso_type against > a seemingly arbitrary list of SKB_GSO_* flags. This seems like an > attempt to identify unsupported GSO types, but since the stack is > the one that set these GSO types in the f

Re: off-by-one in DecodeQ931

2016-05-20 Thread Toby DiPasquale
I'm a bit new to this; is this patch OK? On Tue, May 3, 2016 at 1:12 AM, Toby DiPasquale wrote: > On Mon, Apr 25, 2016 at 11:29 AM, Florian Westphal wrote: >> -> sz (size_t) will underflow here >> >> I'd suggest to change the if (sz < 1) to if (sz < 2) to >> resolve this, the while loop below ha

Re: IPv6 extension header privileges

2016-05-20 Thread Hannes Frederic Sowa
On 21.05.2016 00:37, Tom Herbert wrote: > Hi, > > In ipv6_sockglue.c I noticed: > > /* hop-by-hop / destination options are privileged option */ > retv = -EPERM; > if (optname != IPV6_RTHDR && !ns_capable(net->user_ns, CAP_NET_RAW)) >break; > > Can anyone provide that rationale as to

[GIT] Networking

2016-05-20 Thread David Miller
1) Tunneling fixes from Tom Herbert and Alexander Duyck. 2) AF_UNIX updates some struct sock bit fields with the socket lock, whereas setsockopt() sets overlapping ones with locking. Seperate out the synchronized vs. the AF_UNIX unsynchronized ones to avoid corruption. From Andrey Ryab

Re: [PATCHv2] net: suppress warnings on dev_alloc_skb

2016-05-20 Thread David Miller
From: Neil Horman Date: Thu, 19 May 2016 11:30:54 -0400 > Noticed an allocation failure in a network driver the other day on a 32 bit > system: ... > Thought that perhaps the big splat in the logs wasn't really necessecary, as > all call sites for dev_alloc_skb: > > a) check the return code for

Re: [PATCH net] udp: prevent skbs lingering in tunnel socket queues

2016-05-20 Thread David Miller
From: Hannes Frederic Sowa Date: Thu, 19 May 2016 15:58:33 +0200 > In case we find a socket with encapsulation enabled we should call > the encap_recv function even if just a udp header without payload is > available. The callbacks are responsible for correctly verifying and > dropping the packet

Re: [PATCH net-next 0/2] bpf: verifier fixes

2016-05-20 Thread David Miller
From: Alexei Starovoitov Date: Thu, 19 May 2016 18:17:12 -0700 > Further testing of 'direct packet access' uncovered > several usability issues. Fix them. Series applied, thanks Alexei.

Re: [PATCH] net:liquidio: use kmemdup

2016-05-20 Thread David Miller
From: Muhammad Falak R Wani Date: Thu, 19 May 2016 19:22:49 +0530 > Use kmemdup when some other buffer is immediately copied into allocated > region. It replaces call to allocation followed by memcpy, by a single > call to kmemdup. > > Signed-off-by: Muhammad Falak R Wani Applied.

Re: [PATCH] net: usb: ch9200: use kmemdup

2016-05-20 Thread David Miller
From: Muhammad Falak R Wani Date: Thu, 19 May 2016 19:26:50 +0530 > Use kmemdup when some other buffer is immediately copied into allocated > region. It replaces call to allocation followed by memcpy, by a single > call to kmemdup. > > Signed-off-by: Muhammad Falak R Wani Applied.

Re: [PATCH] ps3_gelic: use kmemdup

2016-05-20 Thread David Miller
From: Muhammad Falak R Wani Date: Thu, 19 May 2016 19:24:41 +0530 > Use kmemdup when some other buffer is immediately copied into allocated > region. It replaces call to allocation followed by memcpy, by a single > call to kmemdup. > > Signed-off-by: Muhammad Falak R Wani Applied.

Re: [PATCH net] bpf: Use mount_nodev not mount_ns to mount the bpf filesystem

2016-05-20 Thread David Miller
From: ebied...@xmission.com (Eric W. Biederman) Date: Fri, 20 May 2016 17:22:48 -0500 > > While reviewing the filesystems that set FS_USERNS_MOUNT I spotted the > bpf filesystem. Looking at the code I saw a broken usage of mount_ns > with current->nsproxy->mnt_ns. As the code does not acquire a

Re: pull-request: wireless-drivers-next 2016-05-13 (take two)

2016-05-20 Thread David Miller
From: Kalle Valo Date: Thu, 19 May 2016 15:45:08 +0300 > this the second version of the last pull request to net-next for 4.7, > which got postponed due to the recent iwlwifi merge conflict. Now that > Linus fixed the merge problem in his tree I actually didn't have to fix > anything in my tree a

Re: [RFC net-next] net: sched: do not acquire qdisc spinlock in qdisc/class stats dump

2016-05-20 Thread David Miller
From: Eric Dumazet Date: Thu, 19 May 2016 05:35:20 -0700 > From: Eric Dumazet > > Large tc dumps (tc -s {qdisc|class} sh dev ethX) done by Google BwE host > agent [1] are problematic at scale : > > For each qdisc/class found in the dump, we currently lock the root qdisc > spinlock in order

Re: [PATCH net V2] tuntap: correctly wake up process during uninit

2016-05-20 Thread David Miller
From: Jason Wang Date: Thu, 19 May 2016 13:36:51 +0800 > We used to check dev->reg_state against NETREG_REGISTERED after each > time we are woke up. But after commit 9e641bdcfa4e ("net-tun: > restructure tun_do_read for better sleep/wakeup efficiency"), it uses > skb_recv_datagram() which does no

Re: [PATCH net,stable v2] net: cdc_ncm: update datagram size after changing mtu

2016-05-20 Thread David Miller
From: Robert Dobrowolski Date: Thu, 19 May 2016 11:56:09 +0200 > From: Rafal Redzimski > > Current implementation updates the mtu size and notify cdc_ncm > device using USB_CDC_SET_MAX_DATAGRAM_SIZE request about datagram > size change instead of changing rx_urb_size. > > Whenever mtu is being

Re: [PATCH net] bpf: Use mount_nodev not mount_ns to mount the bpf filesystem

2016-05-20 Thread Hannes Frederic Sowa
On 21.05.2016 00:22, Eric W. Biederman wrote: > > While reviewing the filesystems that set FS_USERNS_MOUNT I spotted the > bpf filesystem. Looking at the code I saw a broken usage of mount_ns > with current->nsproxy->mnt_ns. As the code does not acquire a > reference to the mount namespace it can

Re: [net-next PATCH 0/2] Follow-ups for GUEoIPv6 patches

2016-05-20 Thread David Miller
From: Alexander Duyck Date: Wed, 18 May 2016 10:44:40 -0700 > This patch series is meant to be applied after: > [PATCH v7 net-next 00/16] ipv6: Enable GUEoIPv6 and more fixes for v6 > tunneling > > The first patch addresses an issue we already resolved in the GREv4 and is > now present in GREv6

Re: [PATCH net 0/2] RDS: TCP: connection spamming fixes

2016-05-20 Thread David Miller
From: Sowmini Varadhan Date: Wed, 18 May 2016 10:06:22 -0700 > We have been testing the RDS-TCP code with a connection spammer > that sends incoming SYNs to the RDS listen port well after > an rds-tcp connection has been established, and found a few > race-windows that are fixed by this patch s

Re: [RFC][PATCH net] bpf: Use mount_nodev not mount_ns to mount the bpf filesystem

2016-05-20 Thread Eric W. Biederman
Hannes Frederic Sowa writes: > On 18.05.2016 22:43, Daniel Borkmann wrote: >> Eric, please send the patch officially and feel free to add my Ack. Done. >> Given >> the circumstances, moving to mount_nodev() seems the best way forward. To >> also address above mentioned concern from Hannes, we n

IPv6 extension header privileges

2016-05-20 Thread Tom Herbert
Hi, In ipv6_sockglue.c I noticed: /* hop-by-hop / destination options are privileged option */ retv = -EPERM; if (optname != IPV6_RTHDR && !ns_capable(net->user_ns, CAP_NET_RAW)) break; Can anyone provide that rationale as to why these are privileged ops? Thanks, Tom

[PATCH net] bpf: Use mount_nodev not mount_ns to mount the bpf filesystem

2016-05-20 Thread Eric W. Biederman
While reviewing the filesystems that set FS_USERNS_MOUNT I spotted the bpf filesystem. Looking at the code I saw a broken usage of mount_ns with current->nsproxy->mnt_ns. As the code does not acquire a reference to the mount namespace it can not possibly be correct to store the mount namespace on

Re: [PATCH v4] net: sock: move ->sk_shutdown out of bitfields.

2016-05-20 Thread David Miller
From: Andrey Ryabinin Date: Wed, 18 May 2016 19:19:27 +0300 > ->sk_shutdown bits share one bitfield with some other bits in sock struct, > such as ->sk_no_check_[r,t]x, ->sk_userlocks ... > sock_setsockopt() may write to these bits, while holding the socket lock. > > In case of AF_UNIX sockets,

Re: [PATCH v7 net-next 00/16] ipv6: Enable GUEoIPv6 and more fixes for v6 tunneling

2016-05-20 Thread David Miller
From: Tom Herbert Date: Wed, 18 May 2016 09:06:08 -0700 > This patch set: > - Fixes GRE6 to process translate flags correctly from configuration > - Adds support for GSO and GRO for ip6ip6 and ip4ip6 > - Add support for FOU and GUE in IPv6 > - Support GRE, ip6ip6 and ip4ip6 over FOU/GUE >

Re: [PATCH] Revert "phy: add support for a reset-gpio specification"

2016-05-20 Thread David Miller
From: Fabio Estevam Date: Wed, 18 May 2016 13:05:00 -0300 > Commit da47b4572056 ("phy: add support for a reset-gpio specification") > causes the following xtensa qemu crash according to Guenter Roeck: ... > This reverts commit da47b4572056487fd7941c26f73b3e8815ff712a. > > Reported-by: Guenter R

Re: [PATCH net-next] xen-netback: only deinitialized hash if it was initialized

2016-05-20 Thread David Miller
From: Paul Durrant Date: Wed, 18 May 2016 15:55:42 +0100 > A domain with a frontend that does not implement a control ring has been > seen to cause a crash during domain save. This was apparently because > the call to xenvif_deinit_hash() in xenvif_disconnect_ctrl() is made > regardless of whethe

Re: [RFC] net: remove busylock

2016-05-20 Thread Eric Dumazet
On Fri, 2016-05-20 at 19:49 +0200, Jesper Dangaard Brouer wrote: > On Fri, 20 May 2016 07:16:55 -0700 > Eric Dumazet wrote: > > > Since bonding pretends to be multiqueue, TCQ_F_ONETXQUEUE is not set > > on sch->flags when HTB is installed at the bonding device root. > > If would be cool if you c

Re: [PATCH 1/3] netfilter: ipset: use setup_timer() and mod_timer().

2016-05-20 Thread Jozsef Kadlecsik
On Sat, 14 May 2016, Muhammad Falak R Wani wrote: > Use setup_timer() and instead of init_timer(), being the preferred way > of setting up a timer. > > Also, quoting the mod_timer() function comment: > -> mod_timer() is a more efficient way to update the expire field of an >active timer (if t

Re: [PATCH net-next 5/7] Driver: Vmxnet3: Add support for get_coalesce, set_coalesce ethtool operations

2016-05-20 Thread Shrikrishna Khare
On Sun, 8 May 2016, Ben Hutchings wrote: > > Would a patch that maps 0 to 'no coalescing' be acceptable? That is: > > > > rx-usecs = 0 -> coalescing disabled. > > rx-usecs = 1 -> default (chosen by the device). > > rx-usecs = 2 -> adaptive coalescing. > > rx-usecs = 3 -> static coalescing. > >

Re: [PATCH] net: alx: use custom skb allocator

2016-05-20 Thread Jarod Wilson
On Fri, May 20, 2016 at 03:56:23PM +0800, Feng Tang wrote: > Hi, > > Please ignore this patch. > > I found the problem and made the patch with kernel 4.4 with Ubuntu 12.04 > on Lenovo Y580. > > After submitting the patch, I tried to google the datasheet for > Atheros 8161 dev, and found there

Re: [PATCH] mlx5: avoid unused variable warning

2016-05-20 Thread David Miller
From: Arnd Bergmann Date: Wed, 18 May 2016 16:21:07 +0200 > When CONFIG_NET_CLS_ACT is disabled, we get a new warning in the mlx5 > ethernet driver because the tc_for_each_action() loop never references > the iterator: > > mellanox/mlx5/core/en_tc.c: In function 'mlx5e_stats_flower': > mellanox/

Re: [PATCH net] bpf: rather use get_random_int for randomizations

2016-05-20 Thread David Miller
From: Daniel Borkmann Date: Wed, 18 May 2016 14:14:28 +0200 > Start address randomization and blinding in BPF currently use > prandom_u32(). prandom_u32() values are not exposed to unpriviledged > user space to my knowledge, but given other kernel facilities such as > ASLR, stack canaries, etc ma

Re: [PATCH net 1/1] qede: Fix DMA address APIs usage

2016-05-20 Thread David Miller
From: Manish Chopra Date: Wed, 18 May 2016 07:43:57 -0400 > Driver incorrectly uses dma_unmap_addr_set() to set > a variable which is in truth a dma_addr_t > [i.e not defined using DEFINE_DMA_UNMAP_ADDR()] and is > being used by the driver flows other than unmapping > physical addresses. This pat

Re: [PATCH net] macsec: fix netlink attribute for key id

2016-05-20 Thread David Miller
From: Sabrina Dubroca Date: Wed, 18 May 2016 13:34:40 +0200 > In my last commit I replaced MACSEC_SA_ATTR_KEYID by > MACSEC_SA_ATTR_KEY. > > Fixes: 8acca6acebd0 ("macsec: key identifier is 128 bits, not 64") > Signed-off-by: Sabrina Dubroca Applied and queued up for -stable, thanks.

Re: [PATCH net-next] xen-netback: correct length checks on hash copy_ops

2016-05-20 Thread David Miller
From: Paul Durrant Date: Wed, 18 May 2016 08:53:01 +0100 > The length checks on the grant table copy_ops for setting hash key and > hash mapping are checking the local 'len' value which is correct in > the case of the former but not the latter. This was picked up by > static analysis checks. > >

Re: [PATCHv3] phy: fix crash in fixed_phy_add()

2016-05-20 Thread David Miller
From: Rabin Vincent Date: Wed, 18 May 2016 12:47:31 +0200 > From: Rabin Vincent > > Since e7f4dc3536a ("mdio: Move allocation of interrupts into core"), > platforms which call fixed_phy_add() before fixed_mdio_bus_init() is > called (for example, because the platform code and the fixed_phy driv

Re: [RFC] net: remove busylock

2016-05-20 Thread Jesper Dangaard Brouer
On Fri, 20 May 2016 07:16:55 -0700 Eric Dumazet wrote: > Since bonding pretends to be multiqueue, TCQ_F_ONETXQUEUE is not set > on sch->flags when HTB is installed at the bonding device root. If would be cool if you could run a test with removed busylock and allow HTB to bulk dequeue. -- Best

Re: [PATCH 2/2] ip6_gre: Set flowi6_proto as IPPROTO_GRE in xmit path.

2016-05-20 Thread David Miller
From: Haishuang Yan Date: Wed, 18 May 2016 18:05:52 +0800 > In gre6 xmit path, we are sending a GRE packet, so set fl6 proto > to IPPROTO_GRE properly. > > Signed-off-by: Haishuang Yan I think it would be a lot better to initialize the flow protocol field properly in ip6gre_tnl_link_config() i

Re: [PATCH 1/2] ip6_gre: Fix MTU setting for ip6gretap

2016-05-20 Thread David Miller
From: Haishuang Yan Date: Wed, 18 May 2016 18:05:51 +0800 > When creat an ip6gretap interface with an unreachable route, > the MTU is about 14 bytes larger than what was needed. > > If the remote address is reachable: > ping6 2001:0:130::1 -c 2 > PING 2001:0:130::1(2001:0:130::1) 56 data bytes >

Re: [PATCH] net: sock: Add option for memory optimized hints.

2016-05-20 Thread Eric Dumazet
On Fri, 2016-05-20 at 15:36 +0200, peter enderborg wrote: > From: Peter Enderborg > > When sending data the socket allocates memory for > payload on a cache or a page alloc. The page alloc > then might trigger compation that takes long time. > This can be avoided with smaller chunks. But > usersp

[PATCH][3.13.y-ckt][PATCH 1/1] bridge: Fix the way to find old local fdb entries in br_fdb_changeaddr

2016-05-20 Thread Joseph Salisbury
From: Toshiaki Makita BugLink: http://bugs.launchpad.net/bugs/1581585 br_fdb_changeaddr() assumes that there is at most one local entry per port per vlan. It used to be true, but since commit 36fd2b63e3b4 ("bridge: allow creating/deleting fdb entries via netlink"), it has not been so. Therefore,

[PATCH][v3.13.y-ckt][PATCH 0/1] bridge: notify user space after fdb update

2016-05-20 Thread Joseph Salisbury
BugLink: http://bugs.launchpad.net/bugs/1581585 Hello, Please consider including upstream commit c65c7a306610ee7c13669a8f5601b472c19dc6f1 in the next v3.13.y-ckt release. It was included in the mainline tree as of v3.14-rc3. It has been tested and confirmed to resolve http://bugs.launchpad.ne

Re: [PATCH net v2] fou: avoid using sk_user_data before it is initialised

2016-05-20 Thread Cong Wang
On Thu, May 19, 2016 at 10:57 PM, Simon Horman wrote: > During initialisation sk->sk_user_data should not be used before > it is initialised. > > Found by bisection after noticing the following: > > $ ip fou add port ipproto 47 > [0.383417] BUG: unable to handle kernel NULL pointer derefe

Re: [PATCH] net: sock: Add option for memory optimized hints.

2016-05-20 Thread David Miller
It is not appropriate to submit new features at this time as we are in the merge window and we are only bug fixes. Please resubmit this when the net-next tree opens back up.

Re: [PATCH 1/1] net: pegasus: remove dead coding

2016-05-20 Thread David Miller
From: Petko Manolov Date: Fri, 20 May 2016 10:33:47 +0300 > On 16-05-19 11:35:42, David Miller wrote: >> From: Heinrich Schuchardt >> Date: Wed, 18 May 2016 02:13:30 +0200 >> >> > (!count || count < 4) is always true. >> > So let's remove the coding which is dead at least since 2005. >> > >> >

Re: [PATCH] net: pegasus: remove unused variables and labels

2016-05-20 Thread David Miller
From: Arnd Bergmann Date: Fri, 20 May 2016 10:22:30 +0200 > The latest dead-code removal was slightly incomplete and > left a few things behind that we now get compiler warnings > for: > > drivers/net/usb/pegasus.c: In function 'read_bulk_callback': > drivers/net/usb/pegasus.c:475:1: error: labe

ip rule duplicates

2016-05-20 Thread Mateusz Bajorski
Hi, When we add the same rule again with flag NLM_F_EXCL we expect that we receive error: RTNETLINK answers: File exists This behaviour is already in ip routing part. I have noticed that iproute2 when adds new rule it attach flag NLM_F_EXCL to call. (see http://git.kernel.org/cgit/linux/kern

[PATCH] ipv4: Fix non-initialized TTL when CONFIG_SYSCTL=n

2016-05-20 Thread Ezequiel Garcia
Commit fa50d974d104 ("ipv4: Namespaceify ip_default_ttl sysctl knob") moves the default TTL assignment, and as side-effect IPv4 TTL now has a default value only if sysctl support is enabled (CONFIG_SYSCTL=y). The sysctl_ip_default_ttl is fundamental for IP to work properly, as it provides the TTL

Re: [RFC] net: remove busylock

2016-05-20 Thread John Fastabend
On 16-05-20 06:11 AM, Eric Dumazet wrote: > On Fri, 2016-05-20 at 09:29 +0200, Jesper Dangaard Brouer wrote: > > >> The hole idea behind allowing bulk qdisc dequeue, was to mitigate this, >> by allowing dequeue to do more work, while holding the lock. >> >> You mention HTB. Notice HTB does not t

[PATCH] Added NLM_F_EXCL support to fib_nl_newrule

2016-05-20 Thread Mateusz Bajorski
When adding rule with NLM_F_EXCL flag then check if the same rule exist. If yes then exit with -EEXIST. This is already implemented in iproute2: if (cmd == RTM_NEWRULE) { req.n.nlmsg_flags |= NLM_F_CREATE|NLM_F_EXCL; req.r.rtm_type = RTN_UNICAST; }

Re: [RFC] net: remove busylock

2016-05-20 Thread Eric Dumazet
On Fri, 2016-05-20 at 06:47 -0700, Eric Dumazet wrote: > On Fri, 2016-05-20 at 06:11 -0700, Eric Dumazet wrote: > > On Fri, 2016-05-20 at 09:29 +0200, Jesper Dangaard Brouer wrote: > > > > > > > The hole idea behind allowing bulk qdisc dequeue, was to mitigate this, > > > by allowing dequeue to d

Re: [RFC] net: remove busylock

2016-05-20 Thread Eric Dumazet
On Fri, 2016-05-20 at 06:11 -0700, Eric Dumazet wrote: > On Fri, 2016-05-20 at 09:29 +0200, Jesper Dangaard Brouer wrote: > > > > The hole idea behind allowing bulk qdisc dequeue, was to mitigate this, > > by allowing dequeue to do more work, while holding the lock. > > > > You mention HTB. Not

[PATCH] net: sock: Add option for memory optimized hints.

2016-05-20 Thread peter enderborg
From: Peter Enderborg When sending data the socket allocates memory for payload on a cache or a page alloc. The page alloc then might trigger compation that takes long time. This can be avoided with smaller chunks. But userspace can not know what is the right size for the smaller sends. For this

Re: [RFC] net: remove busylock

2016-05-20 Thread Eric Dumazet
On Fri, 2016-05-20 at 09:29 +0200, Jesper Dangaard Brouer wrote: > The hole idea behind allowing bulk qdisc dequeue, was to mitigate this, > by allowing dequeue to do more work, while holding the lock. > > You mention HTB. Notice HTB does not take advantage of bulk dequeue. > Have you tried to

Re: [RFC net-next] net: sched: do not acquire qdisc spinlock in qdisc/class stats dump

2016-05-20 Thread Eric Dumazet
On Fri, 2016-05-20 at 06:01 -0700, Eric Dumazet wrote: > Tricky, since sch_direct_xmit() releases the qdisc spinlock and grabs it > again, while owning the ' running seqcount' > > Needs more LOCKDEP tricks ;) > That would be : @@ -137,10 +137,10 @@ int sch_direct_xmit(struct sk_buff *skb, stru

Re: [RFC net-next] net: sched: do not acquire qdisc spinlock in qdisc/class stats dump

2016-05-20 Thread Eric Dumazet
On Fri, 2016-05-20 at 05:44 -0700, Eric Dumazet wrote: > On Thu, 2016-05-19 at 19:45 -0700, Eric Dumazet wrote: > > On Thu, 2016-05-19 at 18:50 -0700, Cong Wang wrote: > > > On Thu, May 19, 2016 at 5:35 AM, Eric Dumazet > > > wrote: > > > > > > > > These stats are using u64 or u32 fields, so read

Re: [PATCH] ptp: use memdup_user().

2016-05-20 Thread Richard Cochran
On Fri, May 20, 2016 at 05:51:02PM +0530, Muhammad Falak R Wani wrote: > Use memdup_user to duplicate a memory region from user-space to > kernel-space, instead of open coding using kmalloc & copy_from_user. > > Signed-off-by: Muhammad Falak R Wani Acked-by: Richard Cochran

Re: [RFC net-next] net: sched: do not acquire qdisc spinlock in qdisc/class stats dump

2016-05-20 Thread Eric Dumazet
On Thu, 2016-05-19 at 19:45 -0700, Eric Dumazet wrote: > On Thu, 2016-05-19 at 18:50 -0700, Cong Wang wrote: > > On Thu, May 19, 2016 at 5:35 AM, Eric Dumazet > > wrote: > > > > > > These stats are using u64 or u32 fields, so reading integral values > > > should not prevent writers from doing con

rxrpc: Simplify connect() implementation and simplify sendmsg() op

2016-05-20 Thread David Howells
Hi Dave, Are you okay with taking this into net-next? I no longer take away the ability to do connect(), but now it does nothing more than specify a default address and mark the socket as being client only. As before, the default address is overridden if sendmsg() is given an address. The other

[PATCH] ptp: use memdup_user().

2016-05-20 Thread Muhammad Falak R Wani
Use memdup_user to duplicate a memory region from user-space to kernel-space, instead of open coding using kmalloc & copy_from_user. Signed-off-by: Muhammad Falak R Wani --- drivers/ptp/ptp_chardev.c | 11 +++ 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/drivers/ptp/ptp_

[PATCH] wan: cosa: use memdup_user().

2016-05-20 Thread Muhammad Falak R Wani
Use memdup_user to duplicate a memory region from user-space to kernel-space, instead of open coding using kmalloc & copy_from_user. Signed-off-by: Muhammad Falak R Wani --- drivers/net/wan/cosa.c | 11 +++ 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/drivers/net/wan/cos

[PATCH V2 4.8 1/2] brcmutil: add field storing control channel to the struct brcmu_chan

2016-05-20 Thread Rafał Miłecki
Our d11 code supports encoding/decoding channel info into/from chanspec format used by firmware. Current implementation is quite misleading because of the way "chnum" field is used. When encoding channel info, "chnum" has to be filled by a caller with *center* channel number. However when decoding

[PATCH V2 4.8 2/2] brcmfmac: support get_channel cfg80211 callback

2016-05-20 Thread Rafał Miłecki
This is important for brcmfmac as some of released firmwares (e.g. brcmfmac4366b-pcie.bin) may pick different channel than requested. This has been tested with BCM4366B1 in D-Link DIR-885L. Signed-off-by: Rafał Miłecki --- V2: Check if ndev isn't NULL, update description. --- .../broadcom/brcm80

Re: [PATCH 4.8 2/2] brcmfmac: support get_channel cfg80211 callback

2016-05-20 Thread Rafał Miłecki
On 20 May 2016 at 09:42, Arend Van Spriel wrote: > On 19-5-2016 13:02, Rafał Miłecki wrote: >> This is important for brcmfmac as the firmware may pick different >> channel than requested. This has been tested with BCM4366B1 (in D-Link >> DIR-885L). > > Can you elaborate? Is this for AP or STA mode

Re: 4.5.0 on sun7i-a20-olinuxino-lime2: libphy: PHY stmmac-0:ffffffff not found (regression from rc7)

2016-05-20 Thread Andre Heider
Hi, On Fri, May 20, 2016 at 12:36 PM, Marc Zyngier wrote: > On 20/05/16 11:30, Andre Heider wrote: >> Hi, >> >> On Fri, May 20, 2016 at 10:14 AM, Giuseppe CAVALLARO >> wrote: >>> On 5/20/2016 9:56 AM, Marc Zyngier wrote: On 20/05/16 06:44, Andre Heider wrote: > > Giuseppe, Alex

Re: 4.5.0 on sun7i-a20-olinuxino-lime2: libphy: PHY stmmac-0:ffffffff not found (regression from rc7)

2016-05-20 Thread Marc Zyngier
On 20/05/16 11:30, Andre Heider wrote: > Hi, > > On Fri, May 20, 2016 at 10:14 AM, Giuseppe CAVALLARO > wrote: >> On 5/20/2016 9:56 AM, Marc Zyngier wrote: >>> >>> On 20/05/16 06:44, Andre Heider wrote: Giuseppe, Alexandre, et al., On Thu, Mar 17, 2016 at 8:52 AM, Marc Zyngier

Re: 4.5.0 on sun7i-a20-olinuxino-lime2: libphy: PHY stmmac-0:ffffffff not found (regression from rc7)

2016-05-20 Thread Andre Heider
Hi, On Fri, May 20, 2016 at 10:14 AM, Giuseppe CAVALLARO wrote: > On 5/20/2016 9:56 AM, Marc Zyngier wrote: >> >> On 20/05/16 06:44, Andre Heider wrote: >>> >>> Giuseppe, Alexandre, et al., >>> >>> On Thu, Mar 17, 2016 at 8:52 AM, Marc Zyngier >>> wrote: On Thu, 17 Mar 2016 00:56:40 +0

Re: [PATCH v9 net-next 4/7] openvswitch: add layer 3 flow/port support

2016-05-20 Thread Simon Horman
On Fri, May 20, 2016 at 11:20:04AM +0200, Jiri Benc wrote: > On Fri, 20 May 2016 18:12:05 +0900, Simon Horman wrote: [...] > > 3. With regards to the mirroring part of your question, I need to check > >on that and possibly its broken. But my thinking is that a mirroring > >vport would reg

Re: [PATCH] net: pegasus: remove unused variables and labels

2016-05-20 Thread Arnd Bergmann
On Friday 20 May 2016 12:32:23 Petko Manolov wrote: > Guys, come on. This code is not dead. This code is executed every time an > ethernet packet is received. It takes care of various error statistics. More > importantly, it sends the actual (reported by the adapter) packet length to > the >

RE: [v10, 7/7] mmc: sdhci-of-esdhc: fix host version for T4240-R1.0-R2.0

2016-05-20 Thread Yangbo Lu
Hi Arnd, Any comments? Please reply when you see the email since we want this eSDHC issue to be fixed soon. All the patches are Freescale-specific and is to fix the eSDHC driver. Could we let them merged first if you were talking about a new way of abstracting getting SoC version. Thanks :)

Re: [PATCH] net: pegasus: remove unused variables and labels

2016-05-20 Thread Petko Manolov
Guys, come on. This code is not dead. This code is executed every time an ethernet packet is received. It takes care of various error statistics. More importantly, it sends the actual (reported by the adapter) packet length to the network layer along with the packet. This patch removes skb_p

Re: [PATCH v9 net-next 4/7] openvswitch: add layer 3 flow/port support

2016-05-20 Thread Jiri Benc
On Fri, 20 May 2016 18:12:05 +0900, Simon Horman wrote: > 1. push_eth adds an Ethernet header with all-zero addresses and >the Ethernet type as determined from skb->protocol which is in >turn determined by the tunnel header (we have discussed that >bit before). > >In principle it i

Re: [PATCH v9 net-next 4/7] openvswitch: add layer 3 flow/port support

2016-05-20 Thread Simon Horman
On Fri, May 20, 2016 at 10:39:39AM +0200, Jiri Benc wrote: > On Fri, 20 May 2016 17:16:13 +0900, Simon Horman wrote: > > My understanding is that currently OvS handles access ports using a > > push_vlan action. > > When needed (i.e. when the packet goes to a non-access port), yes. > > > And that

Re: [PATCH v9 net-next 4/7] openvswitch: add layer 3 flow/port support

2016-05-20 Thread Jiri Benc
On Fri, 20 May 2016 17:16:13 +0900, Simon Horman wrote: > My understanding is that currently OvS handles access ports using a > push_vlan action. When needed (i.e. when the packet goes to a non-access port), yes. > And that this patch set in conjunction with its > user-space counterpart should en

[PATCH] net: pegasus: remove unused variables and labels

2016-05-20 Thread Arnd Bergmann
The latest dead-code removal was slightly incomplete and left a few things behind that we now get compiler warnings for: drivers/net/usb/pegasus.c: In function 'read_bulk_callback': drivers/net/usb/pegasus.c:475:1: error: label 'goon' defined but not used [-Werror=unused-label] drivers/net/usb/pe

Re: [PATCH v9 net-next 4/7] openvswitch: add layer 3 flow/port support

2016-05-20 Thread Simon Horman
On Fri, May 20, 2016 at 05:11:23PM +0900, Simon Horman wrote: > On Fri, May 20, 2016 at 10:00:28AM +0200, Jiri Benc wrote: > > On Fri, 20 May 2016 14:29:01 +0900, Simon Horman wrote: > > > The second option does seem rather tempting although I'm not sure > > > that it actually plays out in the acce

Re: 4.5.0 on sun7i-a20-olinuxino-lime2: libphy: PHY stmmac-0:ffffffff not found (regression from rc7)

2016-05-20 Thread Giuseppe CAVALLARO
Hello On 5/20/2016 9:56 AM, Marc Zyngier wrote: On 20/05/16 06:44, Andre Heider wrote: Giuseppe, Alexandre, et al., On Thu, Mar 17, 2016 at 8:52 AM, Marc Zyngier wrote: On Thu, 17 Mar 2016 00:56:40 +0100 Bert Lindner wrote: On 2016-03-16 18:42, Marc Zyngier wrote: On 16/03/16 15:10, Bert

Re: [net-next PATCH V1 0/3] net: enable use of kmem_cache_alloc_bulk in network stack

2016-05-20 Thread Jesper Dangaard Brouer
On Mon, 09 May 2016 15:44:24 +0200 Jesper Dangaard Brouer wrote: > This patchset enables use of the slab/kmem_cache bulk alloc API, and > completes the use the slab/kmem_cache bulking API in the network stack. > > I've not included the patches that introduce a SKB bulk hint, which > would benefi

Re: [PATCH v9 net-next 4/7] openvswitch: add layer 3 flow/port support

2016-05-20 Thread Simon Horman
On Fri, May 20, 2016 at 10:00:28AM +0200, Jiri Benc wrote: > On Fri, 20 May 2016 14:29:01 +0900, Simon Horman wrote: > > The second option does seem rather tempting although I'm not sure > > that it actually plays out in the access-port scenario at this time. > > We support gre ports to be access

Re: [PATCH v9 net-next 4/7] openvswitch: add layer 3 flow/port support

2016-05-20 Thread Jiri Benc
On Fri, 20 May 2016 14:29:01 +0900, Simon Horman wrote: > The second option does seem rather tempting although I'm not sure > that it actually plays out in the access-port scenario at this time. We support gre ports to be access ports currently. With conversion to ipgre, this needs to continue wor

Re: 4.5.0 on sun7i-a20-olinuxino-lime2: libphy: PHY stmmac-0:ffffffff not found (regression from rc7)

2016-05-20 Thread Marc Zyngier
On 20/05/16 06:44, Andre Heider wrote: > Giuseppe, Alexandre, et al., > > On Thu, Mar 17, 2016 at 8:52 AM, Marc Zyngier wrote: >> On Thu, 17 Mar 2016 00:56:40 +0100 >> Bert Lindner wrote: >>> On 2016-03-16 18:42, Marc Zyngier wrote: On 16/03/16 15:10, Bert Lindner wrote: > On 2016-03-16

Re: [PATCH] net: alx: use custom skb allocator

2016-05-20 Thread Feng Tang
Hi, Please ignore this patch. I found the problem and made the patch with kernel 4.4 with Ubuntu 12.04 on Lenovo Y580. After submitting the patch, I tried to google the datasheet for Atheros 8161 dev, and found there was already a kernel bugzilla https://bugzilla.kernel.org/show_bug.cgi?id=70

Re: [PATCH] brcmfmac: use kmemdup

2016-05-20 Thread Arend Van Spriel
On 19-5-2016 15:59, Muhammad Falak R Wani wrote: > Use kmemdup when some other buffer is immediately copied into allocated > region. It replaces call to allocation followed by memcpy, by a single > call to kmemdup. Acked-by: Arend van Spriel > Signed-off-by: Muhammad Falak R Wani > --- > driver

Re: [PATCH 4.8 1/2] brcmutil: add field storing control channel to the struct brcmu_chan

2016-05-20 Thread Arend Van Spriel
On 19-5-2016 13:02, Rafał Miłecki wrote: > Our d11 code supports encoding/decoding channel info into/from chanspec > format used by firmware. Current implementation is quite misleading > because of the way "chnum" field is used. > When encoding channel info, "chnum" has to be filled by a caller wit

Re: [PATCH 4.8 2/2] brcmfmac: support get_channel cfg80211 callback

2016-05-20 Thread Arend Van Spriel
On 19-5-2016 13:02, Rafał Miłecki wrote: > This is important for brcmfmac as the firmware may pick different > channel than requested. This has been tested with BCM4366B1 (in D-Link > DIR-885L). Can you elaborate? Is this for AP or STA mode? > Signed-off-by: Rafał Miłecki > --- > .../broadcom/b

Re: [PATCH 1/1] net: pegasus: remove dead coding

2016-05-20 Thread Petko Manolov
On 16-05-19 11:35:42, David Miller wrote: > From: Heinrich Schuchardt > Date: Wed, 18 May 2016 02:13:30 +0200 > > > (!count || count < 4) is always true. > > So let's remove the coding which is dead at least since 2005. > > > > Signed-off-by: Heinrich Schuchardt > > Applied. David, the patch

Re: [RFC] net: remove busylock

2016-05-20 Thread Jesper Dangaard Brouer
On Thu, 19 May 2016 11:03:32 -0700 Alexander Duyck wrote: > On Thu, May 19, 2016 at 10:08 AM, Eric Dumazet wrote: > > busylock was added at the time we had expensive ticket spinlocks > > > > (commit 79640a4ca6955e3ebdb7038508fa7a0cd7fa5527 ("net: add additional > > lock to qdisc to increase thro