deliverable/linux.git
7 years agoMerge remote-tracking branch 'usb-serial-fixes/usb-linus'
Stephen Rothwell [Mon, 12 Sep 2016 21:58:36 +0000 (07:58 +1000)] 
Merge remote-tracking branch 'usb-serial-fixes/usb-linus'

7 years agoMerge remote-tracking branch 'pci-current/for-linus'
Stephen Rothwell [Mon, 12 Sep 2016 21:58:34 +0000 (07:58 +1000)] 
Merge remote-tracking branch 'pci-current/for-linus'

7 years agoMerge remote-tracking branch 'sound-current/for-linus'
Stephen Rothwell [Mon, 12 Sep 2016 21:58:33 +0000 (07:58 +1000)] 
Merge remote-tracking branch 'sound-current/for-linus'

7 years agoMerge remote-tracking branch 'mac80211/master'
Stephen Rothwell [Mon, 12 Sep 2016 21:58:32 +0000 (07:58 +1000)] 
Merge remote-tracking branch 'mac80211/master'

7 years agoMerge remote-tracking branch 'netfilter/master'
Stephen Rothwell [Mon, 12 Sep 2016 21:58:30 +0000 (07:58 +1000)] 
Merge remote-tracking branch 'netfilter/master'

7 years agoMerge remote-tracking branch 'ipsec/master'
Stephen Rothwell [Mon, 12 Sep 2016 21:58:30 +0000 (07:58 +1000)] 
Merge remote-tracking branch 'ipsec/master'

7 years agoMerge remote-tracking branch 'arm-current/fixes'
Stephen Rothwell [Mon, 12 Sep 2016 21:58:27 +0000 (07:58 +1000)] 
Merge remote-tracking branch 'arm-current/fixes'

7 years agodrm/fence: allow fence waiting to be interrupted by userspace
Gustavo Padovan [Mon, 12 Sep 2016 19:08:11 +0000 (16:08 -0300)] 
drm/fence: allow fence waiting to be interrupted by userspace

If userspace is running an synchronously atomic commit and interrupts the
atomic operation during fence_wait() it will hang until the timer expires,
so here we change the wait to be interruptible so it stop immediately when
userspace wants to quit.

Also adds the necessary error checking for fence_wait().

v2: Comment by Daniel Vetter
- Add error checking for fence_wait()

v3: Rebase on top of new atomic noblocking support

v4: Comment by Maarten Lankhorst
- remove 'swapped' bitfield as it was duplicating information

v5: Comments by Maarten Lankhorst
- assign plane->state to plane_state if !intr
- squash previous patch into this one

v6: Comment by Sean Paul
- rename intr to pre_swap

Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk>
Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
[seanpaul fixed a couple checkpatch warnings and moved the preswap comment]
Signed-off-by: Sean Paul <seanpaul@chromium.org>
Link: http://patchwork.freedesktop.org/patch/msgid/1473707291-14781-1-git-send-email-gustavo@padovan.org
7 years agonfsd: randomize SETCLIENTID reply to help distinguish servers
J. Bruce Fields [Mon, 12 Sep 2016 20:00:47 +0000 (16:00 -0400)] 
nfsd: randomize SETCLIENTID reply to help distinguish servers

NFSv4.1 has built-in trunking support that allows a client to determine
whether two connections to two different IP addresses are actually to
the same server.  NFSv4.0 does not, but RFC 7931 attempts to provide
clients a means to do this by suggesting that they perform SETCLIENTIDs
to the two servers and comparing the clientids and verifiers.

Linux clients since 05f4c350ee02 "NFS: Discover NFSv4 server trunking
when mounting" implement this suggestion.  It is possible that other
clients do to.

knfsd generates the 64-bit clientid by concatenating the 32-bit boot
time (in seconds) and a counter.  This makes collisions between
clientids generated by the same server extremely unlikely.  But
collisions are very likely between clientids generated by servers that
boot at the same time, and it's quite common for multiple servers to
boot at the same time.  The verifier is generated in the same way, so
has the same problem.

Therefore recent NFSv4.0 clients may decide two different servers are
really the same, and mount a filesystem from the wrong server.

The fault is really with RFC 7931, and needs a client fix, but it's not
clear what that fix will be.  In the meantime, mitigate the chance of
these collisions by randomizing the starting value of the counters used
to generate clientids and verifiers.

Signed-off-by: J. Bruce Fields <bfields@redhat.com>
7 years agoMerge remote-tracking branches 'asoc/topic/ux500' and 'asoc/topic/wm8962' into asoc...
Mark Brown [Mon, 12 Sep 2016 19:09:29 +0000 (20:09 +0100)] 
Merge remote-tracking branches 'asoc/topic/ux500' and 'asoc/topic/wm8962' into asoc-next

7 years agoMerge remote-tracking branches 'asoc/topic/simple', 'asoc/topic/sunxi', 'asoc/topic...
Mark Brown [Mon, 12 Sep 2016 19:09:26 +0000 (20:09 +0100)] 
Merge remote-tracking branches 'asoc/topic/simple', 'asoc/topic/sunxi', 'asoc/topic/tas5086', 'asoc/topic/tegra' and 'asoc/topic/topology' into asoc-next

7 years agoMerge remote-tracking branches 'asoc/topic/rockchip', 'asoc/topic/rt5659', 'asoc...
Mark Brown [Mon, 12 Sep 2016 19:09:23 +0000 (20:09 +0100)] 
Merge remote-tracking branches 'asoc/topic/rockchip', 'asoc/topic/rt5659', 'asoc/topic/samsung' and 'asoc/topic/sgtl5000' into asoc-next

7 years agoMerge remote-tracking branches 'asoc/topic/omap', 'asoc/topic/platform-drvdata' and...
Mark Brown [Mon, 12 Sep 2016 19:09:22 +0000 (20:09 +0100)] 
Merge remote-tracking branches 'asoc/topic/omap', 'asoc/topic/platform-drvdata' and 'asoc/topic/qcom' into asoc-next

7 years agoMerge remote-tracking branches 'asoc/topic/max98371', 'asoc/topic/mtk', 'asoc/topic...
Mark Brown [Mon, 12 Sep 2016 19:09:20 +0000 (20:09 +0100)] 
Merge remote-tracking branches 'asoc/topic/max98371', 'asoc/topic/mtk', 'asoc/topic/nau8810' and 'asoc/topic/of-bool' into asoc-next

7 years agoMerge remote-tracking branches 'asoc/topic/dwc', 'asoc/topic/fsl', 'asoc/topic/gpio...
Mark Brown [Mon, 12 Sep 2016 19:09:17 +0000 (20:09 +0100)] 
Merge remote-tracking branches 'asoc/topic/dwc', 'asoc/topic/fsl', 'asoc/topic/gpio-chip' and 'asoc/topic/hdmi' into asoc-next

7 years agoMerge remote-tracking branches 'asoc/topic/cs42l73', 'asoc/topic/cs53l30', 'asoc...
Mark Brown [Mon, 12 Sep 2016 19:09:14 +0000 (20:09 +0100)] 
Merge remote-tracking branches 'asoc/topic/cs42l73', 'asoc/topic/cs53l30', 'asoc/topic/da7213', 'asoc/topic/da7218' and 'asoc/topic/da7219' into asoc-next

7 years agoMerge remote-tracking branches 'asoc/topic/ac97', 'asoc/topic/arizona', 'asoc/topic...
Mark Brown [Mon, 12 Sep 2016 19:09:10 +0000 (20:09 +0100)] 
Merge remote-tracking branches 'asoc/topic/ac97', 'asoc/topic/arizona', 'asoc/topic/atmel', 'asoc/topic/codec-component' and 'asoc/topic/cs35l30' into asoc-next

7 years agoMerge remote-tracking branch 'asoc/topic/rcar' into asoc-next
Mark Brown [Mon, 12 Sep 2016 19:09:09 +0000 (20:09 +0100)] 
Merge remote-tracking branch 'asoc/topic/rcar' into asoc-next

7 years agoMerge remote-tracking branch 'asoc/topic/pcm' into asoc-next
Mark Brown [Mon, 12 Sep 2016 19:09:08 +0000 (20:09 +0100)] 
Merge remote-tracking branch 'asoc/topic/pcm' into asoc-next

7 years agoMerge remote-tracking branch 'asoc/topic/intel' into asoc-next
Mark Brown [Mon, 12 Sep 2016 19:09:08 +0000 (20:09 +0100)] 
Merge remote-tracking branch 'asoc/topic/intel' into asoc-next

7 years agoMerge remote-tracking branch 'asoc/topic/dapm' into asoc-next
Mark Brown [Mon, 12 Sep 2016 19:09:07 +0000 (20:09 +0100)] 
Merge remote-tracking branch 'asoc/topic/dapm' into asoc-next

7 years agoMerge remote-tracking branches 'asoc/fix/arizona', 'asoc/fix/rt5514' and 'asoc/fix...
Mark Brown [Mon, 12 Sep 2016 19:09:04 +0000 (20:09 +0100)] 
Merge remote-tracking branches 'asoc/fix/arizona', 'asoc/fix/rt5514' and 'asoc/fix/shift' into asoc-linus

7 years agoMerge remote-tracking branch 'asoc/fix/intel' into asoc-linus
Mark Brown [Mon, 12 Sep 2016 19:09:03 +0000 (20:09 +0100)] 
Merge remote-tracking branch 'asoc/fix/intel' into asoc-linus

7 years agoMerge remote-tracking branch 'asoc/fix/dapm' into asoc-linus
Mark Brown [Mon, 12 Sep 2016 19:09:02 +0000 (20:09 +0100)] 
Merge remote-tracking branch 'asoc/fix/dapm' into asoc-linus

7 years agoASoC: constify gpio_chip structures
Julia Lawall [Sun, 11 Sep 2016 12:14:42 +0000 (14:14 +0200)] 
ASoC: constify gpio_chip structures

These structures are only used to copy into other structures, so declare
them as const.

The semantic patch that makes this change is as follows:
(http://coccinelle.lip6.fr/)

// <smpl>
@r disable optional_qualifier@
identifier i;
position p;
@@
static struct gpio_chip i@p = { ... };

@ok@
identifier r.i;
expression e;
position p;
@@
e = i@p;

@bad@
position p != {r.p,ok.p};
identifier r.i;
struct gpio_chip e;
@@
e@i@p

@depends on !bad disable optional_qualifier@
identifier r.i;
@@
static
+const
 struct gpio_chip i = { ... };
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Mark Brown <broonie@kernel.org>
7 years agoASoC: ac97: constify gpio_chip structures
Julia Lawall [Sun, 11 Sep 2016 12:14:41 +0000 (14:14 +0200)] 
ASoC: ac97: constify gpio_chip structures

These structures are only used to copy into other structures, so declare
them as const.

The semantic patch that makes this change is as follows:
(http://coccinelle.lip6.fr/)

// <smpl>
@r disable optional_qualifier@
identifier i;
position p;
@@
static struct gpio_chip i@p = { ... };

@ok@
identifier r.i;
expression e;
position p;
@@
e = i@p;

@bad@
position p != {r.p,ok.p};
identifier r.i;
struct gpio_chip e;
@@
e@i@p

@depends on !bad disable optional_qualifier@
identifier r.i;
@@
static
+const
 struct gpio_chip i = { ... };
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Mark Brown <broonie@kernel.org>
7 years agoASoC: constify snd_pcm_ops structures
Julia Lawall [Thu, 8 Sep 2016 00:35:23 +0000 (02:35 +0200)] 
ASoC: constify snd_pcm_ops structures

Check for snd_pcm_ops structures that are only stored in the ops field of a
snd_soc_platform_driver structure or passed as the third argument to
snd_pcm_set_ops.  The corresponding field or parameter is declared const,
so snd_pcm_ops structures that have this property can be declared as const
also.

The semantic patch that makes this change is as follows:
(http://coccinelle.lip6.fr/)

// <smpl>
@r disable optional_qualifier@
identifier i;
position p;
@@
static struct snd_pcm_ops i@p = { ... };

@ok1@
identifier r.i;
struct snd_soc_platform_driver e;
position p;
@@
e.ops = &i@p;

@ok2@
identifier r.i;
expression e1, e2;
position p;
@@
snd_pcm_set_ops(e1, e2, &i@p)

@bad@
position p != {r.p,ok1.p,ok2.p};
identifier r.i;
struct snd_pcm_ops e;
@@
e@i@p

@depends on !bad disable optional_qualifier@
identifier r.i;
@@
static
+const
 struct snd_pcm_ops i = { ... };
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Mark Brown <broonie@kernel.org>
7 years agoASoC: rockchip: spdif: restore register during runtime_suspend/resume cycle
Sugar Zhang [Wed, 7 Sep 2016 06:30:21 +0000 (14:30 +0800)] 
ASoC: rockchip: spdif: restore register during runtime_suspend/resume cycle

when step into runtime_suspend, spdif pd will be disabled and loss state.
so need to restore register when runtime_resume.

Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
7 years agoASoC: rockchip: i2s: restore register during runtime_suspend/resume cycle
Sugar Zhang [Wed, 7 Sep 2016 06:27:33 +0000 (14:27 +0800)] 
ASoC: rockchip: i2s: restore register during runtime_suspend/resume cycle

when step into runtime_suspend, i2s pd will be disabled and loss state.
so need to restore register when runtime_resume.

Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
7 years agoASoC: rt5514: make the volume TLV to match the units 0.01dB
Oder Chiou [Wed, 7 Sep 2016 03:07:49 +0000 (11:07 +0800)] 
ASoC: rt5514: make the volume TLV to match the units 0.01dB

The volume have a step of 0.375dB, but TLV uses the units 0.01dB. It should
be changed to a step of 0.75dB to match the units of TLV.

Signed-off-by: Oder Chiou <oder_chiou@realtek.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
7 years agonetfilter: nf_nat: handle NF_DROP from nfnetlink_parse_nat_setup()
Pablo Neira Ayuso [Fri, 9 Sep 2016 13:38:12 +0000 (15:38 +0200)] 
netfilter: nf_nat: handle NF_DROP from nfnetlink_parse_nat_setup()

nf_nat_setup_info() returns NF_* verdicts, so convert them to error
codes that is what ctnelink expects. This has passed overlook without
having any impact since this nf_nat_setup_info() has always returned
NF_ACCEPT so far. Since 870190a9ec90 ("netfilter: nat: convert nat bysrc
hash to rhashtable"), this is problem.

Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
7 years agonetfilter: nft_numgen: fix race between num generate and store it
Liping Zhang [Mon, 12 Sep 2016 14:21:36 +0000 (22:21 +0800)] 
netfilter: nft_numgen: fix race between num generate and store it

After we generate a new number, we still use the priv->counter and
store it to the dreg. This is not correct, another cpu may already
change it to a new number. So we must use the generated number, not
the priv->counter itself.

Fixes: 91dbc6be0a62 ("netfilter: nf_tables: add number generator expression")
Signed-off-by: Liping Zhang <liping.zhang@spreadtrum.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
7 years agonetfilter: conntrack: remove packet hotpath stats
Florian Westphal [Sun, 11 Sep 2016 20:55:53 +0000 (22:55 +0200)] 
netfilter: conntrack: remove packet hotpath stats

These counters sit in hot path and do show up in perf, this is especially
true for 'found' and 'searched' which get incremented for every packet
processed.

Information like

searched=212030105
new=623431
found=333613
delete=623327

does not seem too helpful nowadays:

- on busy systems found and searched will overflow every few hours
(these are 32bit integers), other more busy ones every few days.

- for debugging there are better methods, such as iptables' trace target,
the conntrack log sysctls.  Nowadays we also have perf tool.

This removes packet path stat counters except those that
are expected to be 0 (or close to 0) on a normal system, e.g.
'insert_failed' (race happened) or 'invalid' (proto tracker rejects).

The insert stat is retained for the ctnetlink case.
The found stat is retained for the tuple-is-taken check when NAT has to
determine if it needs to pick a different source address.

Signed-off-by: Florian Westphal <fw@strlen.de>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
7 years agonetfilter: nf_queue: get rid of dependency on IP6_NF_IPTABLES
Liping Zhang [Sun, 11 Sep 2016 14:05:27 +0000 (22:05 +0800)] 
netfilter: nf_queue: get rid of dependency on IP6_NF_IPTABLES

hash_v6 is used by both nftables and ip6tables, so depend on
IP6_NF_IPTABLES is not properly.

Actually, it only parses ipv6hdr and computes a hash value, so
even if IPV6 is disabled, there's no side effect too, remove it.

Signed-off-by: Liping Zhang <liping.zhang@spreadtrum.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
7 years agonetfilter: Add the missed return value check of nft_register_chain_type
Gao Feng [Sat, 10 Sep 2016 02:04:30 +0000 (10:04 +0800)] 
netfilter: Add the missed return value check of nft_register_chain_type

There are some codes of netfilter module which did not check the return
value of nft_register_chain_type. Add the checks now.

Signed-off-by: Gao Feng <fgao@ikuai8.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
7 years agonetfilter: Add the missed return value check of register_netdevice_notifier
Gao Feng [Fri, 9 Sep 2016 15:25:09 +0000 (23:25 +0800)] 
netfilter: Add the missed return value check of register_netdevice_notifier

There are some codes of netfilter module which did not check the return
value of register_netdevice_notifier. Add the checks now.

Signed-off-by: Gao Feng <fgao@ikuai8.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
7 years agonetfilter: nf_conntrack: simplify __nf_ct_try_assign_helper() return logic
Pablo Neira [Fri, 9 Sep 2016 12:01:26 +0000 (14:01 +0200)] 
netfilter: nf_conntrack: simplify __nf_ct_try_assign_helper() return logic

Instead of several goto's just to return the result, simply return it.

Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
7 years agonetfilter: nf_tables: don't drop IPv6 packets that cannot parse transport
Pablo Neira Ayuso [Fri, 9 Sep 2016 10:42:53 +0000 (12:42 +0200)] 
netfilter: nf_tables: don't drop IPv6 packets that cannot parse transport

This is overly conservative and not flexible at all, so better let them
go through and let the filtering policy decide what to do with them. We
use skb_header_pointer() all over the place so we would just fail to
match when trying to access fields from malformed traffic.

Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
7 years agonetfilter: nf_tables_bridge: use nft_set_pktinfo_ipv{4, 6}_validate
Pablo Neira Ayuso [Fri, 9 Sep 2016 10:42:52 +0000 (12:42 +0200)] 
netfilter: nf_tables_bridge: use nft_set_pktinfo_ipv{4, 6}_validate

Consolidate pktinfo setup and validation by using the new generic
functions so we converge to the netdev family codebase.

We only need a linear IPv4 and IPv6 header from the reject expression,
so move nft_bridge_iphdr_validate() and nft_bridge_ip6hdr_validate()
to net/bridge/netfilter/nft_reject_bridge.c.

Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
7 years agonetfilter: introduce nft_set_pktinfo_{ipv4, ipv6}_validate()
Pablo Neira Ayuso [Fri, 9 Sep 2016 10:42:51 +0000 (12:42 +0200)] 
netfilter: introduce nft_set_pktinfo_{ipv4, ipv6}_validate()

These functions are extracted from the netdev family, they initialize
the pktinfo structure and validate that the IPv4 and IPv6 headers are
well-formed given that these functions are called from a path where
layer 3 sanitization did not happen yet.

These functions are placed in include/net/netfilter/nf_tables_ipv{4,6}.h
so they can be reused by a follow up patch to use them from the bridge
family too.

Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
7 years agonetfilter: nf_tables_ipv6: setup pktinfo transport field on failure to parse
Pablo Neira Ayuso [Fri, 9 Sep 2016 10:42:50 +0000 (12:42 +0200)] 
netfilter: nf_tables_ipv6: setup pktinfo transport field on failure to parse

Make sure the pktinfo protocol fields are initialized if this fails to
parse the transport header.

Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
7 years agonetfilter: nf_tables: ensure proper initialization of nft_pktinfo fields
Pablo Neira Ayuso [Fri, 9 Sep 2016 10:42:49 +0000 (12:42 +0200)] 
netfilter: nf_tables: ensure proper initialization of nft_pktinfo fields

This patch introduces nft_set_pktinfo_unspec() that ensures proper
initialization all of pktinfo fields for non-IP traffic. This is used
by the bridge, netdev and arp families.

This new function relies on nft_set_pktinfo_proto_unspec() to set a new
tprot_set field that indicates if transport protocol information is
available. Remain fields are zeroed.

The meta expression has been also updated to check to tprot_set in first
place given that zero is a valid tprot value. Even a handcrafted packet
may come with the IPPROTO_RAW (255) protocol number so we can't rely on
this value as tprot unset.

Reported-by: Florian Westphal <fw@strlen.de>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
7 years agonetfilter: nft_dynset: allow to invert match criteria
Pablo Neira Ayuso [Wed, 7 Sep 2016 10:22:18 +0000 (12:22 +0200)] 
netfilter: nft_dynset: allow to invert match criteria

The dynset expression matches if we can fit a new entry into the set.
If there is no room for it, then it breaks the rule evaluation.

This patch introduces the inversion flag so you can add rules to
explicitly drop packets that don't fit into the set. For example:

 # nft filter input flow table xyz size 4 { ip saddr timeout 120s counter } overflow drop

This is useful to provide a replacement for connlimit.

For the rule above, every new entry uses the IPv4 address as key in the
set, this entry gets a timeout of 120 seconds that gets refresh on every
packet seen. If we get new flow and our set already contains 4 entries
already, then this packet is dropped.

You can already express this in positive logic, assuming default policy
to drop:

 # nft filter input flow table xyz size 4 { ip saddr timeout 10s counter } accept

Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
7 years agonetfilter: nft_hash: Add hash offset value
Laura Garcia Liebana [Tue, 6 Sep 2016 06:44:19 +0000 (08:44 +0200)] 
netfilter: nft_hash: Add hash offset value

Add support to pass through an offset to the hash value. With this
feature, the sysadmin is able to generate a hash with a given
offset value.

Example:

meta mark set jhash ip saddr mod 2 seed 0xabcd offset 100

This option generates marks according to the source address from 100 to
101.

Signed-off-by: Laura Garcia Liebana <nevola@gmail.com>
7 years agoMerge branch 'devel-stable' into for-next
Russell King [Mon, 12 Sep 2016 15:03:06 +0000 (16:03 +0100)] 
Merge branch 'devel-stable' into for-next

7 years agoMerge branches 'fixes' and 'misc' into for-next
Russell King [Mon, 12 Sep 2016 15:03:01 +0000 (16:03 +0100)] 
Merge branches 'fixes' and 'misc' into for-next

7 years agoMerge tag 'arm-plt-optimizations-for-v4.9' of git://git.linaro.org/people/ard.biesheu...
Russell King [Wed, 7 Sep 2016 16:15:23 +0000 (17:15 +0100)] 
Merge tag 'arm-plt-optimizations-for-v4.9' of git://git.linaro.org/people/ard.biesheuvel/linux-arm into devel-stable

This series of 4 patches optimizes the ARM PLT generation code that
is invoked at module load time, to get rid of the O(n^2) algorithm
that results in pathological load times of 10 seconds or more for
large modules on certain STB platforms

7 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
Linus Torvalds [Mon, 12 Sep 2016 14:56:06 +0000 (07:56 -0700)] 
Merge git://git./linux/kernel/git/davem/net

Pull networking fixes from David Miller:
 "Mostly small sets of driver fixes scattered all over the place.

   1) Mediatek driver fixes from Sean Wang.  Forward port not written
      correctly during TX map, missed handling of EPROBE_DEFER, and
      mistaken use of put_page() instead of skb_free_frag().

   2) Fix socket double-free in KCM code, from WANG Cong.

   3) QED driver fixes from Sudarsana Reddy Kalluru, including a fix for
      using the dcbx buffers before initializing them.

   4) Mellanox Switch driver fixes from Jiri Pirko, including a fix for
      double fib removals and an error handling fix in
      mlxsw_sp_module_init().

   5) Fix kernel panic when enabling LLDP in i40e driver, from Dave
      Ertman.

   6) Fix padding of TSO packets in thunderx driver, from Sunil Goutham.

   7) TCP's rcv_wup not initialized properly when using fastopen, from
      Neal Cardwell.

   8) Don't use uninitialized flow keys in flow dissector, from Gao
      Feng.

   9) Use after free in l2tp module unload, from Sabrina Dubroca.

  10) Fix interrupt registry ordering issues in smsc911x driver, from
      Jeremy Linton.

  11) Fix crashes in bonding having to do with enslaving and rx_handler,
      from Mahesh Bandewar.

  12) AF_UNIX deadlock fixes from Linus.

  13) In mlx5 driver, don't read skb->xmit_mode after it might have been
      freed from the TX reclaim path.  From Tariq Toukan.

  14) Fix a bug from 2015 in TCP Yeah where the congestion window does
      not increase, from Artem Germanov.

  15) Don't pad frames on receive in NFP driver, from Jakub Kicinski.

  16) Fix chunk fragmenting in SCTP wrt. GSO, from Marcelo Ricardo
      Leitner.

  17) Fix deletion of VRF routes, from Mark Tomlinson.

  18) Fix device refcount leak when DAD fails in ipv6, from Wei Yongjun"

* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net: (101 commits)
  net/mlx4_en: Fix panic on xmit while port is down
  net/mlx4_en: Fixes for DCBX
  net/mlx4_en: Fix the return value of mlx4_en_dcbnl_set_state()
  net/mlx4_en: Fix the return value of mlx4_en_dcbnl_set_all()
  net: ethernet: renesas: sh_eth: add POST registers for rz
  drivers: net: phy: mdio-xgene: Add hardware dependency
  dwc_eth_qos: do not register semi-initialized device
  sctp: identify chunks that need to be fragmented at IP level
  mlxsw: spectrum: Set port type before setting its address
  mlxsw: spectrum_router: Fix error path in mlxsw_sp_router_init
  nfp: don't pad frames on receive
  nfp: drop support for old firmware ABIs
  nfp: remove linux/version.h includes
  tcp: cwnd does not increase in TCP YeAH
  net/mlx5e: Fix parsing of vlan packets when updating lro header
  net/mlx5e: Fix global PFC counters replication
  net/mlx5e: Prevent casting overflow
  net/mlx5e: Move an_disable_cap bit to a new position
  net/mlx5e: Fix xmit_more counter race issue
  tcp: fastopen: avoid negative sk_forward_alloc
  ...

7 years agodrm: Move property validation to a helper, v2.
Maarten Lankhorst [Thu, 8 Sep 2016 10:30:01 +0000 (12:30 +0200)] 
drm: Move property validation to a helper, v2.

Property lifetimes are equal to the device lifetime, so the separate
drm_property_find is not needed. The pointer can be retrieved from
the properties member, which saves us some locking and a extra lookup.
The lifetime for properties is until the device is destroyed, which
happens late in the device unload path.

kms_atomic is also testing for invalid properties which returns -ENOENT,
to be consistent return -ENOENT for valid properties that don't appear
on the object property list.

Changes since v1:
- Return -ENOENT for invalid properties to make kms_atomic pass.
- Change commit message slightly to take this into account.

Testcase: kms_atomic
Testcase: kms_properties
Fixes: 4e9951d96093 ("drm/atomic: Reject properties not part of the object.")
Suggested-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Signed-off-by: Sean Paul <seanpaul@chromium.org>
Link: http://patchwork.freedesktop.org/patch/msgid/599c7fa8-b6fd-a42b-c619-a9e4a9c5c244@linux.intel.com
7 years agoMerge branch 'for-4.9/block' into for-next
Jens Axboe [Mon, 12 Sep 2016 14:26:30 +0000 (08:26 -0600)] 
Merge branch 'for-4.9/block' into for-next

7 years agoMerge branches 'pnp' and 'device-properties' into linux-next
Rafael J. Wysocki [Mon, 12 Sep 2016 12:51:30 +0000 (14:51 +0200)] 
Merge branches 'pnp' and 'device-properties' into linux-next

* pnp:
  PNP: isapnp: make core more explicitly non-modular

* device-properties:
  serial: 8250_dw: Add quirk for APM X-Gene SoC
  ACPI / LPSS: Provide build-in properties of the UART
  ACPI / APD: Provide build-in properties of the UART
  driver core: Don't leak secondary fwnode on device removal

7 years agoMerge branches 'pm-cpufreq' and 'pm-cpufreq-sched' into linux-next
Rafael J. Wysocki [Mon, 12 Sep 2016 12:50:30 +0000 (14:50 +0200)] 
Merge branches 'pm-cpufreq' and 'pm-cpufreq-sched' into linux-next

* pm-cpufreq:
  cpufreq: Drop unnecessary check from cpufreq_policy_alloc()
  cpufreq-SCPI: Delete unnecessary assignment for the field "owner"
  cpufreq: dt: Add exynos5433 compatible to use generic cpufreq driver

* pm-cpufreq-sched:
  cpufreq / sched: ignore SMT when determining max cpu capacity
  cpufreq / sched: Pass runqueue pointer to cpufreq_update_util()
  cpufreq / sched: Pass flags to cpufreq_update_util()

7 years agoMerge back earlier cpufreq material for v4.9.
Rafael J. Wysocki [Mon, 12 Sep 2016 12:49:29 +0000 (14:49 +0200)] 
Merge back earlier cpufreq material for v4.9.

7 years agoMerge branches 'pm-domains' and 'pm-cpuidle' into linux-next
Rafael J. Wysocki [Mon, 12 Sep 2016 12:49:03 +0000 (14:49 +0200)] 
Merge branches 'pm-domains' and 'pm-cpuidle' into linux-next

* pm-domains:
  PM / Domains: Always enable debugfs support if available

* pm-cpuidle:
  ARM: cpuidle: Fix error return code

7 years agoMerge branches 'acpi-button', 'acpi-tables' and 'acpi-battery' into linux-next
Rafael J. Wysocki [Mon, 12 Sep 2016 12:48:35 +0000 (14:48 +0200)] 
Merge branches 'acpi-button', 'acpi-tables' and 'acpi-battery' into linux-next

* acpi-button:
  ACPI / button: Add document for ACPI control method lid device restrictions
  ACPI / button: Fix an issue in button.lid_init_state=ignore mode

* acpi-tables:
  ACPI / tables: do not report the number of entries ignored by acpi_parse_entries()
  ACPI / tables: fix acpi_parse_entries_array() so it traverses all subtables
  ACPI / tables: fix incorrect counts returned by acpi_parse_entries_array()

* acpi-battery:
  ACPI / battery: Add sysfs representation after checking _BST

7 years agoMerge branches 'acpi-ec' and 'acpi-cppc' into linux-next
Rafael J. Wysocki [Mon, 12 Sep 2016 12:48:13 +0000 (14:48 +0200)] 
Merge branches 'acpi-ec' and 'acpi-cppc' into linux-next

* acpi-ec:
  ACPI / EC: Fix issues related to boot_ec
  ACPI / EC: Fix a gap that ECDT EC cannot handle EC events
  ACPI / EC: Fix a memory leakage issue in acpi_ec_add()
  ACPI / EC: Cleanup first_ec/boot_ec code
  ACPI / EC: Enable event freeze mode to improve event handling for suspend process
  ACPI / EC: Add PM operations to improve event handling for suspend process
  ACPI / EC: Add PM operations to improve event handling for resume process
  ACPI / EC: Fix an issue that SCI_EVT cannot be detected after event is enabled
  ACPI / EC: Add EC_FLAGS_QUERY_ENABLED to reveal a hidden logic
  ACPI / EC: Add PM operations for suspend/resume noirq stage

* acpi-cppc:
  ACPI / CPPC: Add prefix cppc to cpudata structure name
  ACPI / CPPC: Add support for functional fixed hardware address
  ACPI / CPPC: Don't return on CPPC probe failure
  ACPI / CPPC: Allow build with ACPI_CPU_FREQ_PSS config
  ACPI / CPPC: check for error bit in PCC status field
  ACPI / CPPC: move all PCC related information into pcc_data
  ACPI / CPPC: add sysfs support to compute delivered performance
  ACPI / CPPC: set a non-zero value for transition_latency
  ACPI / CPPC: support for batching CPPC requests
  ACPI / CPPC: acquire pcc_lock only while accessing PCC subspace
  ACPI / CPPC: restructure read/writes for efficient sys mapped reg ops
  mailbox: pcc: Support HW-Reduced Communication Subspace type 2

7 years agoMerge branches 'acpi-sysfs', 'acpi-pci', 'acpi-soc' and 'acpi-bus' into linux-next
Rafael J. Wysocki [Mon, 12 Sep 2016 12:47:33 +0000 (14:47 +0200)] 
Merge branches 'acpi-sysfs', 'acpi-pci', 'acpi-soc' and 'acpi-bus' into linux-next

* acpi-sysfs:
  ACPI / sysfs: Use new GPE masking mechanism in GPE interface

* acpi-pci:
  ACPI / PCI: fix GIC irq model default PCI IRQ polarity

* acpi-soc:
  ACPI / APD: Add device HID for Vulcan SPI controller

* acpi-bus:
  ACPI / bus: Make acpi_get_first_physical_node() public

7 years agoMerge branch 'acpica' into linux-next
Rafael J. Wysocki [Mon, 12 Sep 2016 12:47:04 +0000 (14:47 +0200)] 
Merge branch 'acpica' into linux-next

* acpica: (42 commits)
  ACPICA: Update version to 20160831
  ACPICA: Tables: Tune table mutex to be a leaf lock
  ACPICA: Dispatcher: Fix a mutex issue for method auto serialization
  ACPICA: Namespace: Fix dynamic table loading issues
  ACPICA: Namespace: Add acpi_ns_get_node_unlocked()
  ACPICA: Interpreter: Fix MLC issues by switching to new term_list grammar for table loading
  ACPICA: Update return value for intenal _OSI method
  ACPICA: Tables: Override all 64-bit GAS fields when acpi_gbl_use32_bit_fadt_addresses is TRUE
  ACPICA: Tables: Add new table events indicating table installation/uninstallation
  ACPICA: Tables: Remove wrong table event macros
  ACPICA: Tables: Remove acpi_tb_install_fixed_table()
  ACPICA: Add a couple of casts to uthex.c
  ACPICA: Cleanup for all string-to-integer conversions
  ACPICA: Debugger: Add subcommand for predefined name execution
  ACPICA: Update version to 20160729
  ACPICA: OSL: Fix a regression that old GCC requires a workaround for strchr()
  ACPICA: OSL: Cleanup the inclusion order of the compiler-specific headers
  ACPICA: EFI: Port acpidump to EDK2 environment
  ACPICA: Applications: Fix a potential issue that help messages may be dumped to acpi_gbl_debug_file
  ACPICA: Clib: Eliminate acpi_os_XXXFile()/acpi_log_error and link clibrary fxxx()/errno/perror() instead
  ...

7 years agommc: sdhci-acpi: Set MMC_CAP_CMD_DURING_TFR for Intel eMMC controllers
Adrian Hunter [Tue, 16 Aug 2016 10:44:15 +0000 (13:44 +0300)] 
mmc: sdhci-acpi: Set MMC_CAP_CMD_DURING_TFR for Intel eMMC controllers

Set MMC_CAP_CMD_DURING_TFR for Intel BYT and related eMMC host controllers.

Signed-off-by: Adrian Hunter <adrian.hunter@intel.com>
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
7 years agommc: sdhci-pci: Set MMC_CAP_CMD_DURING_TFR for Intel eMMC controllers
Adrian Hunter [Tue, 16 Aug 2016 10:44:14 +0000 (13:44 +0300)] 
mmc: sdhci-pci: Set MMC_CAP_CMD_DURING_TFR for Intel eMMC controllers

Set MMC_CAP_CMD_DURING_TFR for Intel BYT and related eMMC host controllers.

Signed-off-by: Adrian Hunter <adrian.hunter@intel.com>
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
7 years agommc: sdhci: Support cap_cmd_during_tfr requests
Adrian Hunter [Tue, 16 Aug 2016 10:44:13 +0000 (13:44 +0300)] 
mmc: sdhci: Support cap_cmd_during_tfr requests

Now SDHCI supports commands during transfer, enable support for the core
API.

There are 3 small changes needed:

First, auto-CMD12 cannot be used with a cap_cmd_during_tfr request because
the host controller cannot expect the command line to be available.

Secondly, a cap_cmd_during_tfr request must not send a stop command, again
because the host controller cannot expect the command line to be available.

Thirdly, when a cap_cmd_during_tfr command completes, use
mmc_command_complete() to notify the upper layers that the command line is
now available for further commands.

Signed-off-by: Adrian Hunter <adrian.hunter@intel.com>
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
7 years agommc: mmc_test: Add tests for sending commands during transfer
Adrian Hunter [Tue, 16 Aug 2016 10:44:12 +0000 (13:44 +0300)] 
mmc: mmc_test: Add tests for sending commands during transfer

Add 6 tests for sending commands during transfer. The tests are:
 * Commands during read - no Set Block Count (CMD23).
 * Commands during write - no Set Block Count (CMD23).
 * Commands during read - use Set Block Count (CMD23).
 * Commands during write - use Set Block Count (CMD23).
 * Commands during non-blocking read - use Set Block Count (CMD23).
 * Commands during non-blocking write - use Set Block Count (CMD23).

For a range of transfer sizes, the tests start an ongoing data transfer and
then repeatedly send the status command (CMD13) while the transfer
continues. The tests pass if all requests complete with no errors. The host
controller driver must support MMC_CAP_CMD_DURING_TFR.

Signed-off-by: Adrian Hunter <adrian.hunter@intel.com>
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
7 years agommc: core: Add support for sending commands during data transfer
Adrian Hunter [Tue, 16 Aug 2016 10:44:11 +0000 (13:44 +0300)] 
mmc: core: Add support for sending commands during data transfer

A host controller driver exposes its capability using caps flag
MMC_CAP_CMD_DURING_TFR. A driver with that capability can accept requests
that are marked mrq->cap_cmd_during_tfr = true. Then the driver informs the
upper layers when the command line is available for further commands by
calling mmc_command_done(). Because of that, the driver will not then
automatically send STOP commands, and it is the responsibility of the upper
layer to send a STOP command if it is required.

For requests submitted through the mmc_wait_for_req() interface, the caller
sets mrq->cap_cmd_during_tfr = true which causes mmc_wait_for_req() in fact
not to wait. The caller can then send commands that do not use the data
lines. Finally the caller can wait for the transfer to complete by calling
mmc_wait_for_req_done() which is now exported.

For requests submitted through the mmc_start_req() interface, the caller
again sets mrq->cap_cmd_during_tfr = true, but mmc_start_req() anyway does
not wait. The caller can then send commands that do not use the data
lines. Finally the caller can wait for the transfer to complete in the
normal way i.e. calling mmc_start_req() again.

Irrespective of how a cap_cmd_during_tfr request is started,
mmc_is_req_done() can be called if the upper layer needs to determine if
the request is done. However the appropriate waiting function (either
mmc_wait_for_req_done() or mmc_start_req()) must still be called.

The implementation consists primarily of a new completion
mrq->cmd_completion which notifies when the command line is available for
further commands. That completion is completed by mmc_command_done().
When there is an ongoing data transfer, calls to mmc_wait_for_req() will
automatically wait on that completion, so the caller does not have to do
anything special.

Note, in the case of errors, the driver may call mmc_request_done() without
calling mmc_command_done() because mmc_request_done() always calls
mmc_command_done().

Signed-off-by: Adrian Hunter <adrian.hunter@intel.com>
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
7 years agommc: sdhci-brcmstb: Fix incorrect capability
Jaedon Shin [Fri, 9 Sep 2016 02:08:40 +0000 (11:08 +0900)] 
mmc: sdhci-brcmstb: Fix incorrect capability

Clear incorrect SDHCI_CAN_64BIT capability on Broadcom MIPS based SoCs.
The MIPS based SoCs are using ADMA only, but the several SoCs have the
incorrect capability bit about ADMA 64-bit. The "brcm,bcm7425-sdhci" is
compatible string for MIPS based SoC.

Signed-off-by: Jaedon Shin <jaedon.shin@gmail.com>
Acked-by: Adrian Hunter <adrian.hunter@intel.com>
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
7 years agommc: DT: sdhci-brcmstb: Bindings document for common sdhci-brcmstb
Jaedon Shin [Fri, 9 Sep 2016 02:08:39 +0000 (11:08 +0900)] 
mmc: DT: sdhci-brcmstb: Bindings document for common sdhci-brcmstb

Changes to the DT binding document to separate the BCM7425 and the
BCM7445.

A compatible string "brcm,bcm7425-sdhci" was representing the BCM7425
SDHCI host controller with all BRCMSTB SoCs including the BCM7445. Now
it should be separated because vary a bit in initialize each host
controller.

- Renames the DT binding document to common name.
- Adds a compatible string "brcm,bcm7445-sdhci" that is representing the
  BCM7445 with thereafter 28nm generation ARM based SoCs.

Signed-off-by: Jaedon Shin <jaedon.shin@gmail.com>
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
7 years agoARM: pxa/lubbock: add pcmcia clock
Russell King [Sun, 4 Sep 2016 20:45:56 +0000 (21:45 +0100)] 
ARM: pxa/lubbock: add pcmcia clock

Add the required PCMCIA clock for the SA1111 "1800" device.  This clock
is used to compute timing information for the PCMCIA interface in the
SoC device, rather than the SA1111.  Hence, the provision of this clock
is a convenience for the driver and does not reflect the hardware, so
this must not be copied into DT.

Acked-by: Robert Jarzmik <robert.jarzmik@free.fr>
Tested-by: Robert Jarzmik <robert.jarzmik@free.fr>
Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
7 years agoARM: locomo: fix locomo irq handling
Russell King [Fri, 2 Sep 2016 21:08:45 +0000 (22:08 +0100)] 
ARM: locomo: fix locomo irq handling

Accidentally booting Collie on Assabet reveals that the locomo driver
incorrectly overwrites gpio-sa1100's chip data for its parent interrupt,
leading to oops in sa1100_gpio_unmask() and sa1100_update_edge_regs()
when "gpio: sa1100: convert to use IO accessors" is applied.  Fix locomo
to use the handler data rather than chip data for its parent interrupt.

Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
7 years agoARM: 8612/1: LPAE: initialize cache policy correctly
Stefan Agner [Wed, 7 Sep 2016 20:56:09 +0000 (21:56 +0100)] 
ARM: 8612/1: LPAE: initialize cache policy correctly

The cachepolicy variable gets initialized using a masked pmd
value. So far, the pmd has been masked with flags valid for the
2-page table format, but the 3-page table format requires a
different mask. On LPAE, this lead to a wrong assumption of what
initial cache policy has been used. Later a check forces the
cache policy to writealloc and prints the following warning:
Forcing write-allocate cache policy for SMP

This patch introduces a new definition PMD_SECT_CACHE_MASK for
both page table formats which masks in all cache flags in both
cases.

Signed-off-by: Stefan Agner <stefan@agner.ch>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
7 years agomac80211: make mpath path fixing more robust
Pedersen, Thomas [Tue, 6 Sep 2016 18:59:00 +0000 (11:59 -0700)] 
mac80211: make mpath path fixing more robust

A fixed mpath was not quite being treated as such:

1) if a PERR frame was received, a fixed mpath was
   deactivated.

2) queued path discovery for fixed mpath was potentially
   being considered, changing mpath state.

3) other mpath flags were potentially being inherited when
   fixing the mpath. Just assign PATH_FIXED and SN_VALID.

This solves several issues when fixing a mesh path in one
direction. The reverse direction mpath should probably
also be fixed, or root announcements at least be enabled.

Signed-off-by: Thomas Pedersen <twp@qca.qualcomm.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
7 years agoMerge branches 'fixes-pcmcia' and 'fixes-sa1111' into fixes
Russell King [Mon, 12 Sep 2016 10:19:04 +0000 (11:19 +0100)] 
Merge branches 'fixes-pcmcia' and 'fixes-sa1111' into fixes

7 years agoARM: sa1111: fix missing clk_disable()
Russell King [Tue, 6 Sep 2016 15:09:17 +0000 (16:09 +0100)] 
ARM: sa1111: fix missing clk_disable()

SA1111 forgets to call clk_disable() in the probe error cleanup path.
Add the necessary call.

Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
7 years agoARM: sa1111: fix pcmcia suspend/resume
Russell King [Tue, 6 Sep 2016 13:34:05 +0000 (14:34 +0100)] 
ARM: sa1111: fix pcmcia suspend/resume

SA1111 PCMCIA was broken when PCMCIA switched to using dev_pm_ops for
the PCMCIA socket class.  PCMCIA used to handle suspend/resume via the
socket hosting device, which happened at normal device suspend/resume
time.

However, the referenced commit changed this: much of the resume now
happens much earlier, in the noirq resume handler of dev_pm_ops.

However, on SA1111, the PCMCIA device is not accessible as the SA1111
has not been resumed at _noirq time.  It's slightly worse than that,
because the SA1111 has already been put to sleep at _noirq time, so
suspend doesn't work properly.

Fix this by converting the core SA1111 code to use dev_pm_ops as well,
and performing its own suspend/resume at noirq time.

This fixes these errors in the kernel log:

pcmcia_socket pcmcia_socket0: time out after reset
pcmcia_socket pcmcia_socket1: time out after reset

and the resulting lack of PCMCIA cards after a S2RAM cycle.

Fixes: d7646f7632549 ("pcmcia: use dev_pm_ops for class pcmcia_socket_class")
Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
7 years agoARM: sa1111: fix pcmcia interrupt mask polarity
Russell King [Tue, 6 Sep 2016 13:21:46 +0000 (14:21 +0100)] 
ARM: sa1111: fix pcmcia interrupt mask polarity

The polarity of the high IRQs was being calculated using
SA1111_IRQMASK_HI(), but this assumes a Linux interrupt number, not a
hardware interrupt number.  Hence, the resulting mask was incorrect.
Fix this.

Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
7 years agoARM: sa1111: fix error code propagation in sa1111_probe()
Russell King [Sat, 3 Sep 2016 09:21:51 +0000 (10:21 +0100)] 
ARM: sa1111: fix error code propagation in sa1111_probe()

Ensure that we propagate the platform_get_irq() error code out of the
probe function.  This allows probe deferrals to work correctly should
platform_get_irq() not be able to resolve the interrupt in a DT
environment at probe time.

Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
7 years agoMAINTAINERS: Add MFD's DT bindings directory to MFD entry
Lee Jones [Thu, 8 Sep 2016 07:02:36 +0000 (08:02 +0100)] 
MAINTAINERS: Add MFD's DT bindings directory to MFD entry

Reviewed-by: Andrew Jeffery <andrew@aj.id.au>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
7 years agopcmcia: lubbock: fix sockets configuration
Robert Jarzmik [Thu, 1 Sep 2016 06:31:08 +0000 (08:31 +0200)] 
pcmcia: lubbock: fix sockets configuration

On lubbock board, the probe of the driver crashes by dereferencing very
early a platform_data structure which is not set, in
pxa2xx_configure_sockets().

The stack fixed is :
[    0.244353] SA1111 Microprocessor Companion Chip: silicon revision 1, metal revision 1
[    0.256321] sa1111 sa1111: Providing IRQ336-390
[    0.340899] clocksource: Switched to clocksource oscr0
[    0.472263] Unable to handle kernel NULL pointer dereference at virtual address 00000004
[    0.480469] pgd = c0004000
[    0.483432] [00000004] *pgd=00000000
[    0.487105] Internal error: Oops: f5 [#1] ARM
[    0.491497] Modules linked in:
[    0.494650] CPU: 0 PID: 1 Comm: swapper Not tainted 4.8.0-rc3-00080-g1aaa68426f0c-dirty #2068
[    0.503229] Hardware name: Intel DBPXA250 Development Platform (aka Lubbock)
[    0.510344] task: c3e42000 task.stack: c3e44000
[    0.514984] PC is at pxa2xx_configure_sockets+0x4/0x24 (drivers/pcmcia/pxa2xx_base.c:227)
[    0.520193] LR is at pcmcia_lubbock_init+0x1c/0x38
[    0.525079] pc : [<c0247c30>]    lr : [<c02479b0>]    psr: a0000053
[    0.525079] sp : c3e45e70  ip : 100019ff  fp : 00000000
[    0.536651] r10: c0828900  r9 : c0434838  r8 : 00000000
[    0.541953] r7 : c0820700  r6 : c0857b30  r5 : c3ec1400  r4 : c0820758
[    0.548549] r3 : 00000000  r2 : 0000000c  r1 : c3c09c40  r0 : c3ec1400
[    0.555154] Flags: NzCv  IRQs on  FIQs off  Mode SVC_32  ISA ARM  Segment none
[    0.562450] Control: 0000397f  Table: a0004000  DAC: 00000053
[    0.568257] Process swapper (pid: 1, stack limit = 0xc3e44190)
[    0.574154] Stack: (0xc3e45e70 to 0xc3e46000)
[    0.578610] 5e60:                                     c4849800 00000000 c3ec1400 c024769c
[    0.586928] 5e80: 00000000 c3ec140c c3c0ee0c c3ec1400 c3ec1434 c020c410 c3ec1400 c3ec1434
[    0.595244] 5ea0: c0820700 c080b408 c0828900 c020c5f8 00000000 c0820700 c020c578 c020ac5c
[    0.603560] 5ec0: c3e687cc c3e71e10 c0820700 00000000 c3c02de0 c020bae4 c03c62f7 c03c62f7
[    0.611872] 5ee0: c3e68780 c0820700 c042e034 00000000 c043c440 c020cdec c080b408 00000005
[    0.620188] 5f00: c042e034 c00096c0 c0034440 c01c730c 20000053 ffffffff 00000000 00000000
[    0.628502] 5f20: 00000000 c3ffcb87 c3ffcb90 c00346ac c3e66ba0 c03f7914 00000092 00000005
[    0.636811] 5f40: 00000005 c03f847c 00000091 c03f847c 00000000 00000005 c0434828 00000005
[    0.645125] 5f60: c043482c 00000092 c043c440 c0828900 c0434838 c0418d2c 00000005 00000005
[    0.653430] 5f80: 00000000 c041858c 00000000 c032e9f0 00000000 00000000 00000000 00000000
[    0.661729] 5fa0: 00000000 c032e9f8 00000000 c000f0f0 00000000 00000000 00000000 00000000
[    0.670020] 5fc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
[    0.678311] 5fe0: 00000000 00000000 00000000 00000000 00000013 00000000 00000000 00000000
[    0.686673] (pxa2xx_configure_sockets) from pcmcia_lubbock_init (/drivers/pcmcia/sa1111_lubbock.c:161)
[    0.696026] (pcmcia_lubbock_init) from pcmcia_probe (/drivers/pcmcia/sa1111_generic.c:213)
[    0.704358] (pcmcia_probe) from driver_probe_device (/drivers/base/dd.c:378 /drivers/base/dd.c:499)
[    0.712848] (driver_probe_device) from __driver_attach (/./include/linux/device.h:983 /drivers/base/dd.c:733)
[    0.721414] (__driver_attach) from bus_for_each_dev (/drivers/base/bus.c:313)
[    0.729723] (bus_for_each_dev) from bus_add_driver (/drivers/base/bus.c:708)
[    0.738036] (bus_add_driver) from driver_register (/drivers/base/driver.c:169)
[    0.746185] (driver_register) from do_one_initcall (/init/main.c:778)
[    0.754561] (do_one_initcall) from kernel_init_freeable (/init/main.c:843 /init/main.c:851 /init/main.c:869 /init/main.c:1016)
[    0.763409] (kernel_init_freeable) from kernel_init (/init/main.c:944)
[    0.771660] (kernel_init) from ret_from_fork (/arch/arm/kernel/entry-common.S:119)
[ 0.779347] Code: c03c6305 c03c631e c03c632e e5903048 (e993000c)
All code
========
   0: c03c6305  eorsgt r6, ip, r5, lsl #6
   4: c03c631e  eorsgt r6, ip, lr, lsl r3
   8: c03c632e  eorsgt r6, ip, lr, lsr #6
   c: e5903048  ldr r3, [r0, #72] ; 0x48
  10:* e993000c  ldmib r3, {r2, r3} <-- trapping instruction

Signed-off-by: Robert Jarzmik <robert.jarzmik@free.fr>
Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
7 years agopcmcia: sa1111: fix propagation of lowlevel board init return code
Russell King [Fri, 2 Sep 2016 09:14:20 +0000 (10:14 +0100)] 
pcmcia: sa1111: fix propagation of lowlevel board init return code

When testing Lubbock, it was noticed that the sa1111 pcmcia driver bound
but was not functional due to no sockets being registered.  This is
because the return code from the lowlevel board initialisation was not
being propagated out of the probe function.  Fix this.

Tested-by: Robert Jarzmik <robert.jarzmik@free.fr>
Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
7 years agopcmcia: soc_common: fix SS_STSCHG polarity
Russell King [Wed, 31 Aug 2016 07:49:43 +0000 (08:49 +0100)] 
pcmcia: soc_common: fix SS_STSCHG polarity

SS_STSCHG should be set for an IO card when the BVD1 signal is asserted
low, not high.

Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
7 years agopcmcia: sa11xx_base: add units to the timing information
Russell King [Wed, 31 Aug 2016 07:49:43 +0000 (08:49 +0100)] 
pcmcia: sa11xx_base: add units to the timing information

Add units to the timing information, so we know that the numbers are
nanoseconds.  The output changes from:

I/O      : 165 (172)
attribute: 300 (316)
common   : 300 (316)

to:

I/O      : 165ns (172ns)
attribute: 300ns (316ns)
common   : 300ns (316ns)

Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
7 years agopcmcia: sa11xx_base: fix reporting of timing information
Russell King [Wed, 31 Aug 2016 07:49:43 +0000 (08:49 +0100)] 
pcmcia: sa11xx_base: fix reporting of timing information

Fix the reporting of the currently programmed timing information.  These
entries have been showing zero due to the clock rate being a factor of
1000 too big.  With this change, we go from:

I/O      : 165 (0)
attribute: 300 (0)
common   : 300 (0)

to:

I/O      : 165 (172)
attribute: 300 (316)
common   : 300 (316)

Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
7 years agopcmcia: ds: fix suspend/resume
Russell King [Wed, 31 Aug 2016 07:49:43 +0000 (08:49 +0100)] 
pcmcia: ds: fix suspend/resume

PCMCIA suspend/resume no longer works since the commit mentioned below,
as the callbacks are no longer made.  Convert the driver to the new
dev_pm_ops, which restores the suspend/resume functionality.  Tested on
the arm arch Assabet platform.

Fixes: aa8e54b559479 ("PM / sleep: Go direct_complete if driver has no callbacks")
Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
7 years agomac80211: fix sequence number assignment for PS response frames
Felix Fietkau [Sun, 4 Sep 2016 16:00:59 +0000 (18:00 +0200)] 
mac80211: fix sequence number assignment for PS response frames

When using intermediate queues, sequence number allocation is deferred
until dequeue. This doesn't work for PS response frames, which bypass
those queues.

Signed-off-by: Felix Fietkau <nbd@nbd.name>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
7 years agomac80211: fix tim recalculation after PS response
Felix Fietkau [Sun, 28 Aug 2016 11:10:37 +0000 (13:10 +0200)] 
mac80211: fix tim recalculation after PS response

Handle the case where the mac80211 intermediate queues are empty and the
driver has buffered frames

Fixes: ba8c3d6f16a1 ("mac80211: add an intermediate software queue implementation")
Signed-off-by: Felix Fietkau <nbd@nbd.name>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
7 years agomac80211: send delBA on unexpected BlockAck Request
Johannes Berg [Mon, 29 Aug 2016 20:25:19 +0000 (23:25 +0300)] 
mac80211: send delBA on unexpected BlockAck Request

If we don't have a BA session, send delBA, as requested by the
IEEE 802.11 spec. Apply the same limit of sending such a delBA
only once as in the previous patch.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
7 years agomac80211: send delBA on unexpected BlockAck data frames
Johannes Berg [Mon, 29 Aug 2016 20:25:18 +0000 (23:25 +0300)] 
mac80211: send delBA on unexpected BlockAck data frames

When we receive data frames with ACK policy BlockAck, send
delBA as requested by the 802.11 spec. Since this would be
happening for every frame inside an A-MPDU if it's really
received outside a session, limit it to a single attempt.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
7 years agoarm64/kvm: use alternative auto-nop
Mark Rutland [Wed, 7 Sep 2016 10:07:10 +0000 (11:07 +0100)] 
arm64/kvm: use alternative auto-nop

Make use of the new alternative_if and alternative_else_nop_endif and
get rid of our open-coded NOP sleds, making the code simpler to read.

Note that for __kvm_call_hyp the branch to __vhe_hyp_call has been moved
out of the alternative sequence, and in the default case there will be
four additional NOPs executed.

Cc: Marc Zyngier <marc.zyngier@arm.com>
Cc: kvmarm@lists.cs.columbia.edu
Acked-by: Christoffer Dall <christoffer.dall@linaro.org>
Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Signed-off-by: Will Deacon <will.deacon@arm.com>
7 years agoarm64: use alternative auto-nop
Mark Rutland [Wed, 7 Sep 2016 10:07:09 +0000 (11:07 +0100)] 
arm64: use alternative auto-nop

Make use of the new alternative_if and alternative_else_nop_endif and
get rid of our homebew NOP sleds, making the code simpler to read.

Note that for cpu_do_switch_mm the ret has been moved out of the
alternative sequence, and in the default case there will be three
additional NOPs executed.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: James Morse <james.morse@arm.com>
Cc: Will Deacon <will.deacon@arm.com>
Signed-off-by: Will Deacon <will.deacon@arm.com>
7 years agomac80211: add support for radiotap timestamp field
Johannes Berg [Mon, 29 Aug 2016 20:25:17 +0000 (23:25 +0300)] 
mac80211: add support for radiotap timestamp field

Use the existing device timestamp from the RX status information
to add support for the new radiotap timestamp field. Currently
only 32-bit counters are supported, but we also add the radiotap
mactime where applicable. This new field allows more flexibility
in where the timestamp is taken etc. The non-timestamp data in
the field is taken from a new field in the hw struct.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
7 years agoarm64: alternative: add auto-nop infrastructure
Mark Rutland [Wed, 7 Sep 2016 10:07:08 +0000 (11:07 +0100)] 
arm64: alternative: add auto-nop infrastructure

In some cases, one side of an alternative sequence is simply a number of
NOPs used to balance the other side. Keeping track of this manually is
tedious, and the presence of large chains of NOPs makes the code more
painful to read than necessary.

To ameliorate matters, this patch adds a new alternative_else_nop_endif,
which automatically balances an alternative sequence with a trivial NOP
sled.

In many cases, we would like a NOP-sled in the default case, and
instructions patched in in the presence of a feature. To enable the NOPs
to be generated automatically for this case, this patch also adds a new
alternative_if, and updates alternative_else and alternative_endif to
work with either alternative_if or alternative_endif.

Cc: Andre Przywara <andre.przywara@arm.com>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: Dave Martin <dave.martin@arm.com>
Cc: James Morse <james.morse@arm.com>
Signed-off-by: Mark Rutland <mark.rutland@arm.com>
[will: use new nops macro to generate nop sequences]
Signed-off-by: Will Deacon <will.deacon@arm.com>
7 years agomac80211: add support for MU-MIMO air sniffer
Aviya Erenfeld [Mon, 29 Aug 2016 20:25:16 +0000 (23:25 +0300)] 
mac80211: add support for MU-MIMO air sniffer

add support to MU-MIMO air sniffer according groupID:
in monitor mode, use a given MU-MIMO groupID to monitor stations
that belongs to that group using MU-MIMO.

add support for following a station according to its MAC address
using VHT MU-MIMO sniffer:
the monitors wait until they get an action MU-MIMO notification
frame, then parses it in order to find the groupID that corresponds
to the given MAC address and monitors packets destined to that
groupID using VHT MU-MIMO.

Signed-off-by: Aviya Erenfeld <aviya.erenfeld@intel.com>
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
7 years agoMerge branch 'patchwork' into to_next
Mauro Carvalho Chehab [Mon, 12 Sep 2016 09:43:13 +0000 (06:43 -0300)] 
Merge branch 'patchwork' into to_next

* patchwork:
  [media] pulse8-cec: fix compiler warning
  [media] pxa_camera: merge soc_mediabus.c into pxa_camera.c

7 years ago[media] pulse8-cec: fix compiler warning
Hans Verkuil [Sun, 11 Sep 2016 08:57:30 +0000 (05:57 -0300)] 
[media] pulse8-cec: fix compiler warning

pulse8-cec.c: In function 'pulse8_connect':
pulse8-cec.c:447:2: warning: 'pa' may be used uninitialized in this function [-Wmaybe-uninitialized]
  cec_s_phys_addr(pulse8->adap, pa, false);
  ^
pulse8-cec.c:609:6: note: 'pa' was declared here
  u16 pa;
      ^

As far as I can tell, this can't actually happen. Still, it is better to just
initialize it.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
7 years ago[media] pxa_camera: merge soc_mediabus.c into pxa_camera.c
Hans Verkuil [Sun, 11 Sep 2016 08:51:54 +0000 (05:51 -0300)] 
[media] pxa_camera: merge soc_mediabus.c into pxa_camera.c

Linking soc_mediabus into this driver causes multiple definition linker warnings
if soc_camera is also enabled:

   drivers/media/platform/soc_camera/built-in.o:(___ksymtab+soc_mbus_image_size+0x0): multiple definition of `__ksymtab_soc_mbus_image_size'
   drivers/media/platform/soc_camera/soc_mediabus.o:(___ksymtab+soc_mbus_image_size+0x0): first defined here
>> drivers/media/platform/soc_camera/built-in.o:(___ksymtab+soc_mbus_samples_per_pixel+0x0): multiple definition of `__ksymtab_soc_mbus_samples_per_pixel'
   drivers/media/platform/soc_camera/soc_mediabus.o:(___ksymtab+soc_mbus_samples_per_pixel+0x0): first defined here
   drivers/media/platform/soc_camera/built-in.o: In function `soc_mbus_config_compatible':
   (.text+0x3840): multiple definition of `soc_mbus_config_compatible'
   drivers/media/platform/soc_camera/soc_mediabus.o:(.text+0x134): first defined here

Since we really don't want to have to use any of the soc-camera code this patch
copies the relevant code and data structures from soc_mediabus and renames it to pxa_mbus_*.

The large table of formats has been culled a bit, removing formats that are not supported
by this driver.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Cc: Robert Jarzmik <robert.jarzmik@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
7 years agomac80211: RX BA support for sta max_rx_aggregation_subframes
Maxim Altshul [Mon, 22 Aug 2016 14:14:04 +0000 (17:14 +0300)] 
mac80211: RX BA support for sta max_rx_aggregation_subframes

The ability to change the max_rx_aggregation frames is useful
in cases of IOP.

There exist some devices (latest mobile phones and some AP's)
that tend to not respect a BA sessions maximum size (in Kbps).
These devices won't respect the AMPDU size that was negotiated during
association (even though they do respect the maximal number of packets).

This violation is characterized by a valid number of packets in
a single AMPDU. Even so, the total size will exceed the size negotiated
during association.

Eventually, this will cause some undefined behavior, which in turn
causes the hw to drop packets, causing the throughput to plummet.

This patch will make the subframe limitation to be held by each station,
instead of being held only by hw.

Signed-off-by: Maxim Altshul <maxim.altshul@ti.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
7 years agocfg80211: Remove deprecated create_singlethread_workqueue
Bhaktipriya Shridhar [Tue, 30 Aug 2016 19:05:07 +0000 (00:35 +0530)] 
cfg80211: Remove deprecated create_singlethread_workqueue

The workqueue "cfg80211_wq" is involved in cleanup, scan and event related
works. It queues multiple work items &rdev->event_work,
&rdev->dfs_update_channels_wk,
&wiphy_to_rdev(request->wiphy)->scan_done_wk,
&wiphy_to_rdev(wiphy)->sched_scan_results_wk, which require strict
execution ordering.
Hence, an ordered dedicated workqueue has been used.

Since it's a wireless driver, WQ_MEM_RECLAIM has been set to ensure
forward progress under memory pressure.

Signed-off-by: Bhaktipriya Shridhar <bhaktipriya96@gmail.com>
Acked-by: Tejun Heo <tj@kernel.org>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
7 years agomac80211: refactor monitor representation in sdata
Aviya Erenfeld [Mon, 29 Aug 2016 20:25:15 +0000 (23:25 +0300)] 
mac80211: refactor monitor representation in sdata

Insert the u32 monitor flags variable in a new structure
that represents a monitor interface.
This will allow to add more configuration variables to
that structure which will happen in an upcoming change.

Signed-off-by: Aviya Erenfeld <aviya.erenfeld@intel.com>
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
7 years agocfg80211: clarify the requirements of .disconnect()
Emmanuel Grumbach [Mon, 29 Aug 2016 20:25:14 +0000 (23:25 +0300)] 
cfg80211: clarify the requirements of .disconnect()

cfg80211 expects the .disconnect() handler to call
cfg80211_disconnect() when done. Make this requirement
more explicit.

Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
7 years agonl80211: Allow GET_INTERFACE dumps to be filtered
Denis Kenzior [Wed, 3 Aug 2016 22:02:15 +0000 (17:02 -0500)] 
nl80211: Allow GET_INTERFACE dumps to be filtered

This patch allows GET_INTERFACE dumps to be filtered based on
NL80211_ATTR_WIPHY or NL80211_ATTR_WDEV.  The documentation for
GET_INTERFACE mentions that this is possible:
"Request an interface's configuration; either a dump request on
a %NL80211_ATTR_WIPHY or ..."

However, this behavior has not been implemented until now.

Johannes: rewrite most of the patch:
 * use nl80211_dump_wiphy_parse() to also allow passing an interface
   to be able to dump its siblings
 * fix locking (must hold rtnl around using nl80211_fam.attrbuf)
 * make init self-contained instead of relying on other cb->args

Signed-off-by: Denis Kenzior <denkenz@gmail.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
7 years agomfd: ucb1x00: Remove NO_IRQ check
Arnd Bergmann [Tue, 6 Sep 2016 13:53:29 +0000 (15:53 +0200)] 
mfd: ucb1x00: Remove NO_IRQ check

probe_irq_off() returns '0' on failure, not NO_IRQ, so the check
in this driver is clearly wrong. This replaces it with the
regular '!irq' check used in other drivers.

The sa1100 platform that this driver is used on originally numbered
all its interrupts starting at '0', which would have conflicted with
this change, but as of commit 18f3aec ("ARM: 8230/1: sa1100: shift
IRQs by one"), this is not a problem any more.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
7 years agodoc: bindings: mfd: act8945a: Update the example
Wenyou Yang [Thu, 1 Sep 2016 09:30:00 +0000 (17:30 +0800)] 
doc: bindings: mfd: act8945a: Update the example

Since the act8945a-charger is regarded as a sub-device and it using
"interrupts" property, update the examples section.

Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com>
Acked-by: Rob Herring <robh@kernel.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
This page took 0.055246 seconds and 5 git commands to generate.