]> Git Repo - linux.git/log
linux.git
9 years agozswap: dynamic pool creation
Dan Streetman [Wed, 9 Sep 2015 22:35:19 +0000 (15:35 -0700)]
zswap: dynamic pool creation

Add dynamic creation of pools.  Move the static crypto compression per-cpu
transforms into each pool.  Add a pointer to zswap_entry to the pool it's
in.

This is required by the following patch which enables changing the zswap
zpool and compressor params at runtime.

[[email protected]: fix merge snafus]
Signed-off-by: Dan Streetman <[email protected]>
Acked-by: Seth Jennings <[email protected]>
Cc: Sergey Senozhatsky <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
9 years agozpool: add zpool_has_pool()
Dan Streetman [Wed, 9 Sep 2015 22:35:16 +0000 (15:35 -0700)]
zpool: add zpool_has_pool()

This series makes creation of the zpool and compressor dynamic, so that
they can be changed at runtime.  This makes using/configuring zswap
easier, as before this zswap had to be configured at boot time, using boot
params.

This uses a single list to track both the zpool and compressor together,
although Seth had mentioned an alternative which is to track the zpools
and compressors using separate lists.  In the most common case, only a
single zpool and single compressor, using one list is slightly simpler
than using two lists, and for the uncommon case of multiple zpools and/or
compressors, using one list is slightly less simple (and uses slightly
more memory, probably) than using two lists.

This patch (of 4):

Add zpool_has_pool() function, indicating if the specified type of zpool
is available (i.e.  zsmalloc or zbud).  This allows checking if a pool is
available, without actually trying to allocate it, similar to
crypto_has_alg().

This is used by a following patch to zswap that enables the dynamic
runtime creation of zswap zpools.

Signed-off-by: Dan Streetman <[email protected]>
Acked-by: Seth Jennings <[email protected]>
Cc: Sergey Senozhatsky <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
9 years agotcp_cubic: better follow cubic curve after idle period
Eric Dumazet [Thu, 10 Sep 2015 04:55:07 +0000 (21:55 -0700)]
tcp_cubic: better follow cubic curve after idle period

Jana Iyengar found an interesting issue on CUBIC :

The epoch is only updated/reset initially and when experiencing losses.
The delta "t" of now - epoch_start can be arbitrary large after app idle
as well as the bic_target. Consequentially the slope (inverse of
ca->cnt) would be really large, and eventually ca->cnt would be
lower-bounded in the end to 2 to have delayed-ACK slow-start behavior.

This particularly shows up when slow_start_after_idle is disabled
as a dangerous cwnd inflation (1.5 x RTT) after few seconds of idle
time.

Jana initial fix was to reset epoch_start if app limited,
but Neal pointed out it would ask the CUBIC algorithm to recalculate the
curve so that we again start growing steeply upward from where cwnd is
now (as CUBIC does just after a loss). Ideally we'd want the cwnd growth
curve to be the same shape, just shifted later in time by the amount of
the idle period.

Reported-by: Jana Iyengar <[email protected]>
Signed-off-by: Eric Dumazet <[email protected]>
Signed-off-by: Yuchung Cheng <[email protected]>
Signed-off-by: Neal Cardwell <[email protected]>
Cc: Stephen Hemminger <[email protected]>
Cc: Sangtae Ha <[email protected]>
Cc: Lawrence Brakmo <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
9 years agotcp: generate CA_EVENT_TX_START on data frames
Neal Cardwell [Thu, 10 Sep 2015 04:54:37 +0000 (21:54 -0700)]
tcp: generate CA_EVENT_TX_START on data frames

Issuing a CC TX_START event on control frames like pure ACK
is a waste of time, as a CC should not care.

Following patch needs this change, as we want CUBIC to properly track
idle time at a low cost, with a single TX_START being generated.

Yuchung might slightly refine the condition triggering TX_START
on a followup patch.

Signed-off-by: Neal Cardwell <[email protected]>
Signed-off-by: Eric Dumazet <[email protected]>
Signed-off-by: Yuchung Cheng <[email protected]>
Cc: Jana Iyengar <[email protected]>
Cc: Stephen Hemminger <[email protected]>
Cc: Sangtae Ha <[email protected]>
Cc: Lawrence Brakmo <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
9 years agoxen-netfront: respect user provided max_queues
Wei Liu [Thu, 10 Sep 2015 10:18:58 +0000 (11:18 +0100)]
xen-netfront: respect user provided max_queues

Originally that parameter was always reset to num_online_cpus during
module initialisation, which renders it useless.

The fix is to only set max_queues to num_online_cpus when user has not
provided a value.

Signed-off-by: Wei Liu <[email protected]>
Cc: David Vrabel <[email protected]>
Reviewed-by: David Vrabel <[email protected]>
Tested-by: David Vrabel <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
9 years agoxen-netback: respect user provided max_queues
Wei Liu [Thu, 10 Sep 2015 10:18:57 +0000 (11:18 +0100)]
xen-netback: respect user provided max_queues

Originally that parameter was always reset to num_online_cpus during
module initialisation, which renders it useless.

The fix is to only set max_queues to num_online_cpus when user has not
provided a value.

Reported-by: Johnny Strom <[email protected]>
Signed-off-by: Wei Liu <[email protected]>
Reviewed-by: David Vrabel <[email protected]>
Acked-by: Ian Campbell <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
9 years agor8169: Fix sleeping function called during get_stats64, v2
Corinna Vinschen [Thu, 10 Sep 2015 08:47:35 +0000 (10:47 +0200)]
r8169: Fix sleeping function called during get_stats64, v2

Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=104031
Fixes: 6e85d5ad36a26debc23a9a865c029cbe242b2dc8
Based on the discussion starting at
http://www.spinics.net/lists/netdev/msg342193.html

Tested locally on RTL8168evl/8111evl with various concurrent processes
accessing /proc/net/dev while changing the link state as well as
removing/reloading the r8169 module.

Signed-off-by: Corinna Vinschen <[email protected]>
Tested-by: poma <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
9 years agodrm/i915: Allow DSI dual link to be configured on any pipe
Gaurav K Singh [Mon, 3 Aug 2015 10:15:32 +0000 (15:45 +0530)]
drm/i915: Allow DSI dual link to be configured on any pipe

Just like single link MIPI panels, similarly for dual link panels, pipe
to be configured is based on the DVO port from VBT Block 2. In hardware,
Port A is mapped with Pipe A and Port C is mapped with Pipe B.

This issue got introduced in -

commit 7e9804fdcffc650515c60f524b8b2076ee59e710
Author: Jani Nikula <[email protected]>
Date:   Fri Jan 16 14:27:23 2015 +0200

    drm/i915/dsi: add drm mipi dsi host support

Cc: [email protected] # v4.0
Signed-off-by: Gaurav K Singh <[email protected]>
Reviewed-by: Ville Syrjälä <[email protected]>
Signed-off-by: Jani Nikula <[email protected]>
9 years agodrm/i915: Don't try to use DDR DVFS on CHV when disabled in the BIOS
Ville Syrjälä [Tue, 8 Sep 2015 18:05:12 +0000 (21:05 +0300)]
drm/i915: Don't try to use DDR DVFS on CHV when disabled in the BIOS

If one disables DDR DVFS in the BIOS, Punit will apparently ignores
all DDR DVFS request. Currently we assume that DDR DVFS is always
operational, which leads to errors in dmesg when the DDR DVFS requests
time out.

Fix the problem by gently prodding Punit during driver load to find out
whether it will respond to DDR DVFS requests. If the request times out,
we assume that DDR DVFS has been permanenly disabled in the BIOS and
no longer perster the Punit about it.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=91629
Signed-off-by: Ville Syrjälä <[email protected]>
Reviewed-by: Clint Taylor <[email protected]>
Tested-by: Clint Taylor <[email protected]>
Signed-off-by: Jani Nikula <[email protected]>
9 years agodrm/i915: Fix CSR MMIO address check
Takashi Iwai [Wed, 9 Sep 2015 14:52:09 +0000 (16:52 +0200)]
drm/i915: Fix CSR MMIO address check

Fix a wrong logical AND (&&) used for the range check of CSR MMIO.

Spotted nicely by gcc -Wlogical-op flag:
  drivers/gpu/drm/i915/intel_csr.c: In function ‘finish_csr_load’:
  drivers/gpu/drm/i915/intel_csr.c:353:41: warning: logical ‘and’ of mutually exclusive tests is always false [-Wlogical-op]

Fixes: eb805623d8b1 ('drm/i915/skl: Add support to load SKL CSR firmware.')
Cc: <[email protected]> # v4.2
Signed-off-by: Takashi Iwai <[email protected]>
Reviewed-by: Daniel Vetter <[email protected]>
Reviewed-by: Animesh Manna <[email protected]>
Signed-off-by: Jani Nikula <[email protected]>
9 years agoether: add IEEE 1722 ethertype - TSN
Henrik Austad [Wed, 9 Sep 2015 10:25:17 +0000 (12:25 +0200)]
ether: add IEEE 1722 ethertype - TSN

IEEE 1722 describes AVB (later renamed to TSN - Time Sensitive
Networking), a protocol, encapsualtion and synchronization to utilize
standard networks for audio/video (and later other time-sensitive)
streams.

This standard uses ethertype 0x22F0.

http://standards.ieee.org/develop/regauth/ethertype/eth.txt

This is a respin of a previous patch ("ether: add AVB frame type
ETH_P_AVB")

CC: "David S. Miller" <[email protected]>
CC: [email protected]
CC: [email protected]
CC: [email protected]
Signed-off-by: Henrik Austad <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
9 years agoelf-em.h: move EM_MICROBLAZE to the common header
Mike Frysinger [Tue, 18 Aug 2015 07:28:01 +0000 (03:28 -0400)]
elf-em.h: move EM_MICROBLAZE to the common header

The linux/audit.h header uses EM_MICROBLAZE in order to define
AUDIT_ARCH_MICROBLAZE, but it's only available in the microblaze
asm headers.  Move it to the common elf-em.h header so that the
define can be used on non-microblaze systems.  Otherwise we get
build errors that EM_MICROBLAZE isn't defined when we try to use
the AUDIT_ARCH_MICROBLAZE symbol.

Signed-off-by: Mike Frysinger <[email protected]>
Signed-off-by: Michal Simek <[email protected]>
9 years agonetlink, mmap: fix edge-case leakages in nf queue zero-copy
Daniel Borkmann [Thu, 10 Sep 2015 00:10:57 +0000 (02:10 +0200)]
netlink, mmap: fix edge-case leakages in nf queue zero-copy

When netlink mmap on receive side is the consumer of nf queue data,
it can happen that in some edge cases, we write skb shared info into
the user space mmap buffer:

Assume a possible rx ring frame size of only 4096, and the network skb,
which is being zero-copied into the netlink skb, contains page frags
with an overall skb->len larger than the linear part of the netlink
skb.

skb_zerocopy(), which is generic and thus not aware of the fact that
shared info cannot be accessed for such skbs then tries to write and
fill frags, thus leaking kernel data/pointers and in some corner cases
possibly writing out of bounds of the mmap area (when filling the
last slot in the ring buffer this way).

I.e. the ring buffer slot is then of status NL_MMAP_STATUS_VALID, has
an advertised length larger than 4096, where the linear part is visible
at the slot beginning, and the leaked sizeof(struct skb_shared_info)
has been written to the beginning of the next slot (also corrupting
the struct nl_mmap_hdr slot header incl. status etc), since skb->end
points to skb->data + ring->frame_size - NL_MMAP_HDRLEN.

The fix adds and lets __netlink_alloc_skb() take the actual needed
linear room for the network skb + meta data into account. It's completely
irrelevant for non-mmaped netlink sockets, but in case mmap sockets
are used, it can be decided whether the available skb_tailroom() is
really large enough for the buffer, or whether it needs to internally
fallback to a normal alloc_skb().

>From nf queue side, the information whether the destination port is
an mmap RX ring is not really available without extra port-to-socket
lookup, thus it can only be determined in lower layers i.e. when
__netlink_alloc_skb() is called that checks internally for this. I
chose to add the extra ldiff parameter as mmap will then still work:
We have data_len and hlen in nfqnl_build_packet_message(), data_len
is the full length (capped at queue->copy_range) for skb_zerocopy()
and hlen some possible part of data_len that needs to be copied; the
rem_len variable indicates the needed remaining linear mmap space.

The only other workaround in nf queue internally would be after
allocation time by f.e. cap'ing the data_len to the skb_tailroom()
iff we deal with an mmap skb, but that would 1) expose the fact that
we use a mmap skb to upper layers, and 2) trim the skb where we
otherwise could just have moved the full skb into the normal receive
queue.

After the patch, in my test case the ring slot doesn't fit and therefore
shows NL_MMAP_STATUS_COPY, where a full skb carries all the data and
thus needs to be picked up via recv().

Fixes: 3ab1f683bf8b ("nfnetlink: add support for memory mapped netlink")
Signed-off-by: Daniel Borkmann <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
9 years agonetlink, mmap: don't walk rx ring on poll if receive queue non-empty
Daniel Borkmann [Wed, 9 Sep 2015 23:20:46 +0000 (01:20 +0200)]
netlink, mmap: don't walk rx ring on poll if receive queue non-empty

In case of netlink mmap, there can be situations where received frames
have to be placed into the normal receive queue. The ring buffer indicates
this through NL_MMAP_STATUS_COPY, so the user is asked to pick them up
via recvmsg(2) syscall, and to put the slot back to NL_MMAP_STATUS_UNUSED.

Commit 0ef707700f1c ("netlink: rx mmap: fix POLLIN condition") changed
polling, so that we walk in the worst case the whole ring through the
new netlink_has_valid_frame(), for example, when the ring would have no
NL_MMAP_STATUS_VALID, but at least one NL_MMAP_STATUS_COPY frame.

Since we do a datagram_poll() already earlier to pick up a mask that could
possibly contain POLLIN | POLLRDNORM already (due to NL_MMAP_STATUS_COPY),
we can skip checking the rx ring entirely.

In case the kernel is compiled with !CONFIG_NETLINK_MMAP, then all this is
irrelevant anyway as netlink_poll() is just defined as datagram_poll().

Signed-off-by: Daniel Borkmann <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
9 years agocxgb4: changes for new firmware 1.14.4.0
Hariprasad Shenai [Thu, 10 Sep 2015 04:25:13 +0000 (09:55 +0530)]
cxgb4: changes for new firmware 1.14.4.0

Incorporate fw_ldst_cmd structure change for new firmware and also
update version string for the same

Signed-off-by: Hariprasad Shenai <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
9 years agonet: fec: add netif status check before set mac address
Nimrod Andy [Thu, 10 Sep 2015 01:35:39 +0000 (09:35 +0800)]
net: fec: add netif status check before set mac address

There exist one issue by below case that case system hang:
ifconfig eth0 down
ifconfig eth0 hw ether 00:10:19:19:81:19

After eth0 down, all fec clocks are gated off. In the .fec_set_mac_address()
function, it will set new MAC address to registers, which causes system hang.

So it needs to add netif status check to avoid registers access when clocks are
gated off. Until eth0 up the new MAC address are wrote into related registers.

V2:
As Lucas Stach's suggestion, add a comment in the code to explain why it needed.

CC: Lucas Stach <[email protected]>
CC: Florian Fainelli <[email protected]>
Signed-off-by: Fugang Duan <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
9 years agoMerge branch 'r8152-autoresume'
David S. Miller [Thu, 10 Sep 2015 03:27:54 +0000 (20:27 -0700)]
Merge branch 'r8152-autoresume'

Hayes Wang says:

====================
r8152: fix the autoresume may fail

Fix the autosuspend issues which occur about linking change.
====================

Signed-off-by: David S. Miller <[email protected]>
9 years agor8152: fix the runtime suspend issues
hayeswang [Mon, 7 Sep 2015 03:57:44 +0000 (11:57 +0800)]
r8152: fix the runtime suspend issues

Fix the runtime suspend issues result from the linking change.

Case 1:
a) link down occurs.
b) driver disable tx/rx.
c) autosuspend occurs.
d) hw linking up.
e) device suspends without enabling tx/rx.
f) couldn't wake up when receiving packets.

Case 2:
a) Nway results in linking down.
b) autosuspend occurs.
c) device suspends.
d) device may not wake up when linking up.

Signed-off-by: Hayes Wang <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
9 years agor8152: split DRIVER_VERSION
hayeswang [Mon, 7 Sep 2015 03:57:43 +0000 (11:57 +0800)]
r8152: split DRIVER_VERSION

Split DRIVER_VERSION into NETNEXT_VERSION and NET_VERSION. Then,
according to the value of DRIVER_VERSION, we could know which
patches are used generally without comparing the source code.

Signed-off-by: Hayes Wang <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
9 years agoipv6: fix ifnullfree.cocci warnings
Wu Fengguang [Wed, 9 Sep 2015 22:57:12 +0000 (06:57 +0800)]
ipv6: fix ifnullfree.cocci warnings

net/ipv6/route.c:2946:3-8: WARNING: NULL check before freeing functions like kfree, debugfs_remove, debugfs_remove_recursive or usb_free_urb is not needed. Maybe consider reorganizing relevant code to avoid passing NULL values.

 NULL check before some freeing functions is not needed.

 Based on checkpatch warning
 "kfree(NULL) is safe this check is probably not required"
 and kfreeaddr.cocci by Julia Lawall.

Generated by: scripts/coccinelle/free/ifnullfree.cocci

CC: Roopa Prabhu <[email protected]>
Signed-off-by: Fengguang Wu <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
9 years agoadd microchip LAN88xx phy driver
[email protected] [Wed, 9 Sep 2015 20:49:53 +0000 (20:49 +0000)]
add microchip LAN88xx phy driver

Add Microchip LAN88XX phy driver for phylib.

Signed-off-by: Woojung Huh <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
9 years agostmmac: fix check for phydev being open
Alexey Brodkin [Wed, 9 Sep 2015 15:01:08 +0000 (18:01 +0300)]
stmmac: fix check for phydev being open

Current check of phydev with IS_ERR(phydev) may make not much sense
because of_phy_connect() returns NULL on failure instead of error value.

Still for checking result of phy_connect() IS_ERR() makes perfect sense.

So let's use combined check IS_ERR_OR_NULL() that covers both cases.

Cc: Sergei Shtylyov <[email protected]>
Cc: Giuseppe Cavallaro <[email protected]>
Cc: [email protected]
Cc: [email protected]
Cc: David Miller <[email protected]>
Signed-off-by: Alexey Brodkin <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
9 years agonet: qlcnic: delete redundant memsets
Rasmus Villemoes [Wed, 9 Sep 2015 08:38:05 +0000 (10:38 +0200)]
net: qlcnic: delete redundant memsets

In all cases, mbx->req.arg and mbx->rsp.arg have just been allocated
using kcalloc(), so these six memsets are redundant.

Signed-off-by: Rasmus Villemoes <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
9 years agonet: mv643xx_eth: use kzalloc
Rasmus Villemoes [Wed, 9 Sep 2015 08:38:04 +0000 (10:38 +0200)]
net: mv643xx_eth: use kzalloc

The double memset is a little ugly; using kzalloc avoids it altogether.

Signed-off-by: Rasmus Villemoes <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
9 years agonet: jme: use kzalloc() instead of kmalloc+memset
Rasmus Villemoes [Wed, 9 Sep 2015 08:38:03 +0000 (10:38 +0200)]
net: jme: use kzalloc() instead of kmalloc+memset

Using kzalloc saves a tiny bit on .text.

Signed-off-by: Rasmus Villemoes <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
9 years agonet: cavium: liquidio: use kzalloc in setup_glist()
Rasmus Villemoes [Wed, 9 Sep 2015 08:38:02 +0000 (10:38 +0200)]
net: cavium: liquidio: use kzalloc in setup_glist()

We save a little .text and get rid of the sizeof(...) style
inconsistency.

Signed-off-by: Rasmus Villemoes <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
9 years agoMerge MTD 4.3-rc1 updates into -next
Brian Norris [Wed, 9 Sep 2015 23:57:39 +0000 (16:57 -0700)]
Merge MTD 4.3-rc1 updates into -next

9 years agomtd: sunxi_nand: Select the chip in sunxi_nand_chip_init_timings()
Stefan Roese [Fri, 28 Aug 2015 12:45:21 +0000 (14:45 +0200)]
mtd: sunxi_nand: Select the chip in sunxi_nand_chip_init_timings()

nand_scan_ident() leaves the chip deselected. So just issuing some commands
from the sunxi driver does not work. We need to select the chip before
writing the commands to the NAND device. This patch takes care of this.

Set the new timing on all dies implemented as suggested by Boris.

This was detected on the in-circuit ICnova-A20 SoM equipped with the
Micron MT29F32G08CBACAWP (4GiB) ONFI NAND device.

Signed-off-by: Stefan Roese <[email protected]>
Cc: Hans de Goede <[email protected]>
Cc: Maxime Ripard <[email protected]>
Cc: Roy Spliet <[email protected]>
Acked-by: Boris Brezillon <[email protected]>
[Brian: fixup whitespace]
Signed-off-by: Brian Norris <[email protected]>
9 years agoMerge tag 'qcom-soc-for-4.3-rc2' of git://codeaurora.org/quic/kernel/agross-msm into...
Kevin Hilman [Wed, 9 Sep 2015 23:15:34 +0000 (16:15 -0700)]
Merge tag 'qcom-soc-for-4.3-rc2' of git://codeaurora.org/quic/kernel/agross-msm into next/late

Qualcomm ARM Based SoC Updates for 4.3-rc2

* Fix errant private access in SMEM
* Fix use of correct remote processor ID in SMD transactions
* Correct SMD fBLOCKREADINTR handling

* tag 'qcom-soc-for-4.3-rc2' of git://codeaurora.org/quic/kernel/agross-msm:
  soc: qcom: smd: Correct fBLOCKREADINTR handling
  soc: qcom: smd: Use correct remote processor ID
  soc: qcom: smem: Fix errant private access
  devicetree: soc: Add Qualcomm SMD based RPM DT binding
  soc: qcom: Driver for the Qualcomm RPM over SMD
  soc: qcom: Add Shared Memory Driver
  soc: qcom: Add device tree binding for Shared Memory Device
  drivers: qcom: Select QCOM_SCM unconditionally for QCOM_PM
  soc: qcom: Add Shared Memory Manager driver

9 years agoMerge tag 'qcom-dt-for-4.3-rc2' of git://codeaurora.org/quic/kernel/agross-msm into...
Kevin Hilman [Wed, 9 Sep 2015 23:15:19 +0000 (16:15 -0700)]
Merge tag 'qcom-dt-for-4.3-rc2' of git://codeaurora.org/quic/kernel/agross-msm into next/late

Qualcomm ARM Based Device Tree Updates for v4.3-rc2

* Add labels for serial nodes to be used for aliasing and stdout-path
* Add stdout-path for APQ8064 Compulab QS600
* Add stdout-path for APQ8064 Inforce 6410
* Add stdout-path for APQ8074 Dragonboard
* Add stdout-path for APQ8084 Inforce 6540
* Add stdout-path for APQ8084 MTP
* Add stdout-path for IPQ8064 AP148
* Add stdout-path for MSM8660 Surf
* Add stdout-path for MSM8960 CDP
* Add stdout-path for MSM8974 Xperia Honami

* tag 'qcom-dt-for-4.3-rc2' of git://codeaurora.org/quic/kernel/agross-msm: (24 commits)
  ARM: dts: qcom: msm8974-sony-xperia-honami: Use stdout-path
  ARM: dts: qcom: msm8960-cdp: Use stdout-path
  ARM: dts: qcom: msm8660-surf: Use stdout-path
  ARM: dts: qcom: ipq8064-ap148: Use stdout-path
  ARM: dts: qcom: apq8084-mtp: Use stdout-path
  ARM: dts: qcom: apq8084-ifc6540: Use stdout-path
  ARM: dts: qcom: apq8074-dragonboard: Use stdout-path
  ARM: dts: qcom: apq8064-ifc6410: Use stdout-path
  ARM: dts: qcom: apq8064-cm-qs600: Use stdout-path
  ARM: dts: qcom: Label serial nodes for aliasing and stdout-path
  ARM: dts: qs600: Add real regulators to sdcc
  ARM: dts: ifc6410: add real regulators for sdcc nodes.
  ARM: dts: apq8064: remove temporary fixed regulator for mmc
  ARM: dts: apq8064: fix missing gsbi cell-index
  ARM: dts: apq8064: Add DT support for GSBI6 and for UART pin mux
  ARM: dts: apq8064: add pm8921 mpp support
  ARM: dts: apq8064: Add pm8921 mfd and its gpio node
  ARM: dts: msm8974: Add smem reservation and node
  ARM: dts: msm8974: Add tcsr mutex node
  ARM: dts: qcom: Add ks8851 node for wired ethernet
  ...

9 years agoMerge branch 'next/defconfig' into next/late
Kevin Hilman [Wed, 9 Sep 2015 23:07:41 +0000 (16:07 -0700)]
Merge branch 'next/defconfig' into next/late

* next/defconfig: (45 commits)
  ARM: multi_v7_defconfig: Enable PBIAS regulator
  ARM: add TC2 PM support to multi_v7_defconfig
  ARM: tegra: Update multi_v7_defconfig
  ARM: tegra: Update default configuration
  ARM: at91/defconfig: at91_dt: remove ARM_AT91_ETHER
  ARM: at91/defconfig: at91_dt: enable DRM hlcdc support
  ARM: at91: at91_dt_defconfig: enable ISI and ov2640 support
  ARM: multi_v7_defconfig: Enable Allwinner P2WI, PWM, DMA_SUN6I, cryptodev
  ARM: sunxi_defconfig: Enable DMA_SUN6I, P2WI, PWM, cryptodev, EXTCON, FHANDLE
  ARM: shmobile: Enable fixed voltage regulator in shmobile_defconfig
  ARM: multi_v7_defconfig: Select MX6UL and MX7D
  ARM: prima2_defconfig: enable build for hwspinlock
  ARM: prima2_defconfig: enable build for RTC
  ARM: prima2_defconfig: enable build for misc input
  ARM: prima2_defconfig: enable build for SiRFSoC SDHC host
  ARM: prima2_defconfig: fix the outdated defconfig
  ARM: imx_v6_v7_defconfig: Select CONFIG_IKCONFIG_PROC
  ARM: defconfig: orion5x: add DT support
  ARM: qcom_defconfig: Enable options for KS8851 ethernet
  ARM: multi_v7_defconfig: Enable support for PWM Regulators
  ...

9 years agoARM: multi_v7_defconfig: Enable PBIAS regulator
Kishon Vijay Abraham I [Fri, 4 Sep 2015 12:13:15 +0000 (17:43 +0530)]
ARM: multi_v7_defconfig: Enable PBIAS regulator

PBIAS regulator is required for MMC module in OMAP2, OMAP3, OMAP4,
OMAP5 and DRA7 SoCs. Enable it here.

Signed-off-by: Kishon Vijay Abraham I <[email protected]>
Signed-off-by: Kevin Hilman <[email protected]>
9 years agoMerge branch 'drivers/reset' into next/late
Kevin Hilman [Wed, 9 Sep 2015 22:42:45 +0000 (15:42 -0700)]
Merge branch 'drivers/reset' into next/late

* drivers/reset:
  reset: ath79: Fix missing spin_lock_init
  reset: Add (devm_)reset_control_get stub functions
  reset: reset-zynq: Adding support for Xilinx Zynq reset controller.
  docs: dts: Added documentation for Xilinx Zynq Reset Controller bindings.
  MIPS: ath79: Add the reset controller to the AR9132 dtsi
  reset: Add a driver for the reset controller on the AR71XX/AR9XXX
  devicetree: Add bindings for the ATH79 reset controller
  reset: socfpga: Update reset-socfpga to read the altr,modrst-offset property
  doc: dt: add documentation for lpc1850-rgu reset driver
  reset: add driver for lpc18xx rgu
  reset: sti: constify of_device_id array
  ARM: STi: DT: Move reset controller constants into common location
  MAINTAINERS: add include/dt-bindings/reset path to reset controller entry

9 years agoMerge tag 'reset-for-4.3-fixes' of git://git.pengutronix.de/git/pza/linux into driver...
Kevin Hilman [Wed, 9 Sep 2015 22:41:42 +0000 (15:41 -0700)]
Merge tag 'reset-for-4.3-fixes' of git://git.pengutronix.de/git/pza/linux into drivers/reset

Merge "Reset controller fixes for v4.3" from Philipp Zabel:

Reset controller fixes for v4.3

- added stubs to avoid build breakage in COMPILE_TEST
  configurations with RESET_CONTROLLER disabled
- fixed missing spinlock initialization in ath79 driver

* tag 'reset-for-4.3-fixes' of git://git.pengutronix.de/git/pza/linux:
  reset: ath79: Fix missing spin_lock_init
  reset: Add (devm_)reset_control_get stub functions

9 years agonet: ipv6: use common fib_default_rule_pref
Phil Sutter [Wed, 9 Sep 2015 12:20:56 +0000 (14:20 +0200)]
net: ipv6: use common fib_default_rule_pref

This switches IPv6 policy routing to use the shared
fib_default_rule_pref() function of IPv4 and DECnet. It is also used in
multicast routing for IPv4 as well as IPv6.

The motivation for this patch is a complaint about iproute2 behaving
inconsistent between IPv4 and IPv6 when adding policy rules: Formerly,
IPv6 rules were assigned a fixed priority of 0x3FFF whereas for IPv4 the
assigned priority value was decreased with each rule added.

Since then all users of the default_pref field have been converted to
assign the generic function fib_default_rule_pref(), fib_nl_newrule()
may just use it directly instead. Therefore get rid of the function
pointer altogether and make fib_default_rule_pref() static, as it's not
used outside fib_rules.c anymore.

Signed-off-by: Phil Sutter <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
9 years agonet: ethoc: Remove unnecessary #ifdef CONFIG_OF
Tobias Klauser [Wed, 9 Sep 2015 09:24:29 +0000 (11:24 +0200)]
net: ethoc: Remove unnecessary #ifdef CONFIG_OF

For !CONFIG_OF of_get_property() is defined to always return NULL. Thus
there's no need to protect the call to of_get_property() with #ifdef
CONFIG_OF.

Signed-off-by: Tobias Klauser <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
9 years agonet: dsa: bcm_sf2: Fix 64-bits register writes
Florian Fainelli [Wed, 9 Sep 2015 03:06:41 +0000 (20:06 -0700)]
net: dsa: bcm_sf2: Fix 64-bits register writes

The macro to write 64-bits quantities to the 32-bits register swapped
the value and offsets arguments, we want to preserve the ordering of the
arguments with respect to how writel() is implemented for instance:
value first, offset/base second.

Fixes: 246d7f773c13 ("net: dsa: add Broadcom SF2 switch driver")
Signed-off-by: Florian Fainelli <[email protected]>
Reviewed-by: Vivien Didelot <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
9 years agobpf: fix out of bounds access in verifier log
Alexei Starovoitov [Tue, 8 Sep 2015 20:40:01 +0000 (13:40 -0700)]
bpf: fix out of bounds access in verifier log

when the verifier log is enabled the print_bpf_insn() is doing
bpf_alu_string[BPF_OP(insn->code) >> 4]
and
bpf_jmp_string[BPF_OP(insn->code) >> 4]
where BPF_OP is a 4-bit instruction opcode.
Malformed insns can cause out of bounds access.
Fix it by sizing arrays appropriately.

The bug was found by clang address sanitizer with libfuzzer.

Reported-by: Yonghong Song <[email protected]>
Signed-off-by: Alexei Starovoitov <[email protected]>
Acked-by: Daniel Borkmann <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
9 years agoipv6: fix multipath route replace error recovery
Roopa Prabhu [Tue, 8 Sep 2015 17:53:04 +0000 (10:53 -0700)]
ipv6: fix multipath route replace error recovery

Problem:
The ecmp route replace support for ipv6 in the kernel, deletes the
existing ecmp route too early, ie when it installs the first nexthop.
If there is an error in installing the subsequent nexthops, its too late
to recover the already deleted existing route leaving the fib
in an inconsistent state.

This patch reduces the possibility of this by doing the following:
a) Changes the existing multipath route add code to a two stage process:
  build rt6_infos + insert them
ip6_route_add rt6_info creation code is moved into
ip6_route_info_create.
b) This ensures that most errors are caught during building rt6_infos
  and we fail early
c) Separates multipath add and del code. Because add needs the special
  two stage mode in a) and delete essentially does not care.
d) In any event if the code fails during inserting a route again, a
  warning is printed (This should be unlikely)

Before the patch:
$ip -6 route show
3000:1000:1000:1000::2 via fe80::202:ff:fe00:b dev swp49s0 metric 1024
3000:1000:1000:1000::2 via fe80::202:ff:fe00:d dev swp49s1 metric 1024
3000:1000:1000:1000::2 via fe80::202:ff:fe00:f dev swp49s2 metric 1024

/* Try replacing the route with a duplicate nexthop */
$ip -6 route change 3000:1000:1000:1000::2/128 nexthop via
fe80::202:ff:fe00:b dev swp49s0 nexthop via fe80::202:ff:fe00:d dev
swp49s1 nexthop via fe80::202:ff:fe00:d dev swp49s1
RTNETLINK answers: File exists

$ip -6 route show
/* previously added ecmp route 3000:1000:1000:1000::2 dissappears from
 * kernel */

After the patch:
$ip -6 route show
3000:1000:1000:1000::2 via fe80::202:ff:fe00:b dev swp49s0 metric 1024
3000:1000:1000:1000::2 via fe80::202:ff:fe00:d dev swp49s1 metric 1024
3000:1000:1000:1000::2 via fe80::202:ff:fe00:f dev swp49s2 metric 1024

/* Try replacing the route with a duplicate nexthop */
$ip -6 route change 3000:1000:1000:1000::2/128 nexthop via
fe80::202:ff:fe00:b dev swp49s0 nexthop via fe80::202:ff:fe00:d dev
swp49s1 nexthop via fe80::202:ff:fe00:d dev swp49s1
RTNETLINK answers: File exists

$ip -6 route show
3000:1000:1000:1000::2 via fe80::202:ff:fe00:b dev swp49s0 metric 1024
3000:1000:1000:1000::2 via fe80::202:ff:fe00:d dev swp49s1 metric 1024
3000:1000:1000:1000::2 via fe80::202:ff:fe00:f dev swp49s2 metric 1024

Fixes: 27596472473a ("ipv6: fix ECMP route replacement")
Signed-off-by: Roopa Prabhu <[email protected]>
Reviewed-by: Nikolay Aleksandrov <[email protected]>
Acked-by: Nicolas Dichtel <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
9 years agosoc: qcom: smd: Correct fBLOCKREADINTR handling
Bjorn Andersson [Mon, 24 Aug 2015 20:38:46 +0000 (13:38 -0700)]
soc: qcom: smd: Correct fBLOCKREADINTR handling

fBLOCKREADINTR is masking the notification from the remote and should
hence be cleared while we're waiting the tx fifo to drain. Also change
the reset state to mask the notification, as send is the only use case
where we're interested in it.

Signed-off-by: Bjorn Andersson <[email protected]>
Signed-off-by: Andy Gross <[email protected]>
9 years agosoc: qcom: smd: Use correct remote processor ID
Andy Gross [Wed, 26 Aug 2015 19:42:45 +0000 (14:42 -0500)]
soc: qcom: smd: Use correct remote processor ID

This patch fixes SMEM addressing issues when remote processors need to use
secure SMEM partitions.

Signed-off-by: Andy Gross <[email protected]>
Reviewed-by: Bjorn Andersson <[email protected]>
9 years agosoc: qcom: smem: Fix errant private access
Andy Gross [Wed, 12 Aug 2015 04:48:15 +0000 (23:48 -0500)]
soc: qcom: smem: Fix errant private access

This patch corrects private partition item access.  Instead of falling back to
global for instances where we have an actual host and remote partition existing,
return the results of the private lookup.

Signed-off-by: Andy Gross <[email protected]>
9 years agoMerge tag 'qcom-soc-for-4.3' into v4.2-rc2
Andy Gross [Wed, 9 Sep 2015 20:56:35 +0000 (15:56 -0500)]
Merge tag 'qcom-soc-for-4.3' into v4.2-rc2

Qualcomm ARM Based SoC Updates for 4.3

* Add SMEM driver
* Add SMD driver
* Add RPM over SMD driver
* Select QCOM_SCM by default

9 years agointel_pstate: fix PCT_TO_HWP macro
Kristen Carlson Accardi [Wed, 9 Sep 2015 18:41:22 +0000 (11:41 -0700)]
intel_pstate: fix PCT_TO_HWP macro

PCT_TO_HWP does not take the actual range of pstates exported
by HWP_CAPABILITIES in account, and is broken on most platforms.
Remove the macro and set the min and max pstate for hwp by
determining the range and adjusting by the min and max percent
limits values.

Signed-off-by: Kristen Carlson Accardi <[email protected]>
Signed-off-by: Rafael J. Wysocki <[email protected]>
9 years agointel_pstate: Fix user input of min/max to legal policy region
Chen Yu [Wed, 9 Sep 2015 10:27:31 +0000 (18:27 +0800)]
intel_pstate: Fix user input of min/max to legal policy region

In current code, max_perf_pct might be smaller than min_perf_pct
by improper user input:

$ grep . /sys/devices/system/cpu/intel_pstate/m*_perf_pct
/sys/devices/system/cpu/intel_pstate/max_perf_pct:100
/sys/devices/system/cpu/intel_pstate/min_perf_pct:100

$ echo 80 > /sys/devices/system/cpu/intel_pstate/max_perf_pct

$ grep . /sys/devices/system/cpu/intel_pstate/m*_perf_pct
/sys/devices/system/cpu/intel_pstate/max_perf_pct:80
/sys/devices/system/cpu/intel_pstate/min_perf_pct:100

Fix this problem by 2 steps:
 1. Normalize the user input to [min_policy, max_policy].
 2. Make sure max_perf_pct>=min_perf_pct, suggested by Seiichi Ikarashi.

Signed-off-by: Chen Yu <[email protected]>
Acked-by: Kristen Carlson Accardi <[email protected]>
Signed-off-by: Rafael J. Wysocki <[email protected]>
9 years agoPM / OPP: Return suspend_opp only if it is enabled
Viresh Kumar [Wed, 9 Sep 2015 11:28:22 +0000 (16:58 +0530)]
PM / OPP: Return suspend_opp only if it is enabled

There is no point returning suspend_opp, if it is disabled by the core.
As we can't use it at all. Fix it.

Fixes: 4eafbd15b6c8 ("PM / OPP: add dev_pm_opp_get_suspend_opp() helper")
Signed-off-by: Viresh Kumar <[email protected]>
Signed-off-by: Rafael J. Wysocki <[email protected]>
9 years agoARM: dts: qcom: msm8974-sony-xperia-honami: Use stdout-path
Stephen Boyd [Tue, 16 Jun 2015 21:31:53 +0000 (14:31 -0700)]
ARM: dts: qcom: msm8974-sony-xperia-honami: Use stdout-path

Use stdout-path so that we don't have to put the console on the
kernel command line.

Cc: Tim Bird <[email protected]>
Cc: Bjorn Andersson <[email protected]>
Signed-off-by: Stephen Boyd <[email protected]>
9 years agoARM: dts: qcom: msm8960-cdp: Use stdout-path
Stephen Boyd [Tue, 16 Jun 2015 21:31:52 +0000 (14:31 -0700)]
ARM: dts: qcom: msm8960-cdp: Use stdout-path

Use stdout-path so that we don't have to put the console on the
kernel command line.

Signed-off-by: Stephen Boyd <[email protected]>
9 years agoARM: dts: qcom: msm8660-surf: Use stdout-path
Stephen Boyd [Tue, 16 Jun 2015 21:31:51 +0000 (14:31 -0700)]
ARM: dts: qcom: msm8660-surf: Use stdout-path

Use stdout-path so that we don't have to put the console on the
kernel command line.

Signed-off-by: Stephen Boyd <[email protected]>
9 years agoARM: dts: qcom: ipq8064-ap148: Use stdout-path
Stephen Boyd [Tue, 16 Jun 2015 21:31:50 +0000 (14:31 -0700)]
ARM: dts: qcom: ipq8064-ap148: Use stdout-path

Use stdout-path so that we don't have to put the console on the
kernel command line.

Cc: Mathieu Olivari <[email protected]>
Signed-off-by: Stephen Boyd <[email protected]>
9 years agoARM: dts: qcom: apq8084-mtp: Use stdout-path
Stephen Boyd [Tue, 16 Jun 2015 21:31:49 +0000 (14:31 -0700)]
ARM: dts: qcom: apq8084-mtp: Use stdout-path

Use stdout-path so that we don't have to put the console on the
kernel command line.

Signed-off-by: Stephen Boyd <[email protected]>
9 years agoARM: dts: qcom: apq8084-ifc6540: Use stdout-path
Stephen Boyd [Tue, 16 Jun 2015 21:31:48 +0000 (14:31 -0700)]
ARM: dts: qcom: apq8084-ifc6540: Use stdout-path

Use stdout-path so that we don't have to put the console on the
kernel command line.

Signed-off-by: Stephen Boyd <[email protected]>
9 years agoARM: dts: qcom: apq8074-dragonboard: Use stdout-path
Stephen Boyd [Tue, 16 Jun 2015 21:31:47 +0000 (14:31 -0700)]
ARM: dts: qcom: apq8074-dragonboard: Use stdout-path

Use stdout-path so that we don't have to put the console on the
kernel command line.

Signed-off-by: Stephen Boyd <[email protected]>
9 years agoARM: dts: qcom: apq8064-ifc6410: Use stdout-path
Stephen Boyd [Tue, 16 Jun 2015 21:31:46 +0000 (14:31 -0700)]
ARM: dts: qcom: apq8064-ifc6410: Use stdout-path

Use stdout-path so that we don't have to put the console on the
kernel command line.

Signed-off-by: Stephen Boyd <[email protected]>
9 years agoARM: dts: qcom: apq8064-cm-qs600: Use stdout-path
Stephen Boyd [Tue, 16 Jun 2015 21:31:45 +0000 (14:31 -0700)]
ARM: dts: qcom: apq8064-cm-qs600: Use stdout-path

Use stdout-path so that we don't have to put the console on the
kernel command line.

Cc: Mike Rapoport <[email protected]>
Cc: Igor Grinberg <[email protected]>
Signed-off-by: Stephen Boyd <[email protected]>
9 years agoARM: dts: qcom: Label serial nodes for aliasing and stdout-path
Stephen Boyd [Tue, 16 Jun 2015 21:31:44 +0000 (14:31 -0700)]
ARM: dts: qcom: Label serial nodes for aliasing and stdout-path

Add a label to the serial nodes that are being used for the
console.

Signed-off-by: Stephen Boyd <[email protected]>
9 years agoMerge tag 'qcom-dt-for-4.3' into v4.2-rc2
Andy Gross [Wed, 9 Sep 2015 19:56:32 +0000 (14:56 -0500)]
Merge tag 'qcom-dt-for-4.3' into v4.2-rc2

Qualcomm ARM Based Device Tree Updates for v4.3

* Switch to use pinctrl compatible for GPIOs
* Add RPM regulators for MSM8960
* Add SPI Ethernet support on MSM8960 CDP
* Add SMEM support along with dependencies
* Add PM8921 support for GPIO and MPP
* Fix GSBI cell index
* Switch to use real regulators on APQ8064 w/ SDCC

9 years agoebpf: fix fd refcount leaks related to maps in bpf syscall
Daniel Borkmann [Tue, 8 Sep 2015 16:00:09 +0000 (18:00 +0200)]
ebpf: fix fd refcount leaks related to maps in bpf syscall

We may already have gotten a proper fd struct through fdget(), so
whenever we return at the end of an map operation, we need to call
fdput(). However, each map operation from syscall side first probes
CHECK_ATTR() to verify that unused fields in the bpf_attr union are
zero.

In case of malformed input, we return with error, but the lookup to
the map_fd was already performed at that time, so that we return
without an corresponding fdput(). Fix it by performing an fdget()
only right before bpf_map_get(). The fdget() invocation on maps in
the verifier is not affected.

Fixes: db20fd2b0108 ("bpf: add lookup/update/delete/iterate methods to BPF maps")
Signed-off-by: Daniel Borkmann <[email protected]>
Acked-by: Alexei Starovoitov <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
9 years agoWatchdog: Fix parent of watchdog_devices
Pratyush Anand [Thu, 20 Aug 2015 08:35:01 +0000 (14:05 +0530)]
Watchdog: Fix parent of watchdog_devices

/sys/class/watchdog/watchdogn/device/modalias can help to identify the
driver/module for a given watchdog node. However, many wdt devices do not
set their parent and so, we do not see an entry for device in sysfs for
such devices.

This patch fixes parent of watchdog_device so that
/sys/class/watchdog/watchdogn/device is populated.

Exceptions: booke, diag288, octeon, softdog and w83627hf -- They do not
have any parent. Not sure, how we can identify driver for these devices.

Signed-off-by: Pratyush Anand <[email protected]>
Reviewed-by: Johannes Thumshirn <[email protected]>
Acked-by: Guenter Roeck <[email protected]>
Acked-by: H Hartley Sweeten <[email protected]>
Acked-by: Lee Jones <[email protected]>
Acked-by: Lubomir Rintel <[email protected]>
Acked-by: Maxime Coquelin <[email protected]>
Acked-by: Thierry Reding <[email protected]>
Acked-by: Viresh Kumar <[email protected]>
Acked-by: Linus Walleij <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
9 years agowatchdog: at91rm9200: Correct check for syscon_node_to_regmap() errors
Bjorn Andersson [Mon, 17 Aug 2015 16:19:03 +0000 (09:19 -0700)]
watchdog: at91rm9200: Correct check for syscon_node_to_regmap() errors

syscon_node_to_regmap() returns a regmap or an ERR_PTR().

Signed-off-by: Bjorn Andersson <[email protected]>
Acked-by: Guenter Roeck <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
9 years agowatchdog: at91sam9: get and use slow clock
Alexandre Belloni [Sun, 16 Aug 2015 09:23:43 +0000 (11:23 +0200)]
watchdog: at91sam9: get and use slow clock

Commit dca1a4b5ff6e ("clk: at91: keep slow clk enabled to prevent system
hang") added a workaround for the slow clock as it is not properly handled
by its users.

Get and use the slow clock as it is necessary for the at91sam9 watchdog.

Signed-off-by: Alexandre Belloni <[email protected]>
Reviewed-by: Guenter Roeck <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
9 years agoDocumentation: dt: binding: atmel-sama5d4-wdt: for SAMA5D4 watchdog driver
Wenyou Yang [Thu, 6 Aug 2015 10:17:05 +0000 (18:17 +0800)]
Documentation: dt: binding: atmel-sama5d4-wdt: for SAMA5D4 watchdog driver

The compatible "atmel,sama5d4-wdt" supports the SAMA5D4 watchdog driver
and the watchdog's WDT_MR register can be written more than once.

Signed-off-by: Wenyou Yang <[email protected]>
Reviewed-by: Guenter Roeck <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
9 years agoRDS: verify the underlying transport exists before creating a connection
Sasha Levin [Tue, 8 Sep 2015 14:53:40 +0000 (10:53 -0400)]
RDS: verify the underlying transport exists before creating a connection

There was no verification that an underlying transport exists when creating
a connection, this would cause dereferencing a NULL ptr.

It might happen on sockets that weren't properly bound before attempting to
send a message, which will cause a NULL ptr deref:

[135546.047719] kasan: GPF could be caused by NULL-ptr deref or user memory accessgeneral protection fault: 0000 [#1] PREEMPT SMP DEBUG_PAGEALLOC KASAN
[135546.051270] Modules linked in:
[135546.051781] CPU: 4 PID: 15650 Comm: trinity-c4 Not tainted 4.2.0-next-20150902-sasha-00041-gbaa1222-dirty #2527
[135546.053217] task: ffff8800835bc000 ti: ffff8800bc708000 task.ti: ffff8800bc708000
[135546.054291] RIP: __rds_conn_create (net/rds/connection.c:194)
[135546.055666] RSP: 0018:ffff8800bc70fab0  EFLAGS: 00010202
[135546.056457] RAX: dffffc0000000000 RBX: 0000000000000f2c RCX: ffff8800835bc000
[135546.057494] RDX: 0000000000000007 RSI: ffff8800835bccd8 RDI: 0000000000000038
[135546.058530] RBP: ffff8800bc70fb18 R08: 0000000000000001 R09: 0000000000000000
[135546.059556] R10: ffffed014d7a3a23 R11: ffffed014d7a3a21 R12: 0000000000000000
[135546.060614] R13: 0000000000000001 R14: ffff8801ec3d0000 R15: 0000000000000000
[135546.061668] FS:  00007faad4ffb700(0000) GS:ffff880252000000(0000) knlGS:0000000000000000
[135546.062836] CS:  0010 DS: 0000 ES: 0000 CR0: 000000008005003b
[135546.063682] CR2: 000000000000846a CR3: 000000009d137000 CR4: 00000000000006a0
[135546.064723] Stack:
[135546.065048]  ffffffffafe2055c ffffffffafe23fc1 ffffed00493097bf ffff8801ec3d0008
[135546.066247]  0000000000000000 00000000000000d0 0000000000000000 ac194a24c0586342
[135546.067438]  1ffff100178e1f78 ffff880320581b00 ffff8800bc70fdd0 ffff880320581b00
[135546.068629] Call Trace:
[135546.069028] ? __rds_conn_create (include/linux/rcupdate.h:856 net/rds/connection.c:134)
[135546.069989] ? rds_message_copy_from_user (net/rds/message.c:298)
[135546.071021] rds_conn_create_outgoing (net/rds/connection.c:278)
[135546.071981] rds_sendmsg (net/rds/send.c:1058)
[135546.072858] ? perf_trace_lock (include/trace/events/lock.h:38)
[135546.073744] ? lockdep_init (kernel/locking/lockdep.c:3298)
[135546.074577] ? rds_send_drop_to (net/rds/send.c:976)
[135546.075508] ? __might_fault (./arch/x86/include/asm/current.h:14 mm/memory.c:3795)
[135546.076349] ? __might_fault (mm/memory.c:3795)
[135546.077179] ? rds_send_drop_to (net/rds/send.c:976)
[135546.078114] sock_sendmsg (net/socket.c:611 net/socket.c:620)
[135546.078856] SYSC_sendto (net/socket.c:1657)
[135546.079596] ? SYSC_connect (net/socket.c:1628)
[135546.080510] ? trace_dump_stack (kernel/trace/trace.c:1926)
[135546.081397] ? ring_buffer_unlock_commit (kernel/trace/ring_buffer.c:2479 kernel/trace/ring_buffer.c:2558 kernel/trace/ring_buffer.c:2674)
[135546.082390] ? trace_buffer_unlock_commit (kernel/trace/trace.c:1749)
[135546.083410] ? trace_event_raw_event_sys_enter (include/trace/events/syscalls.h:16)
[135546.084481] ? do_audit_syscall_entry (include/trace/events/syscalls.h:16)
[135546.085438] ? trace_buffer_unlock_commit (kernel/trace/trace.c:1749)
[135546.085515] rds_ib_laddr_check(): addr 36.74.25.172 ret -99 node type -1

Acked-by: Santosh Shilimkar <[email protected]>
Signed-off-by: Sasha Levin <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
9 years agowatchdog: add a driver to support SAMA5D4 watchdog timer
Wenyou Yang [Thu, 6 Aug 2015 10:16:46 +0000 (18:16 +0800)]
watchdog: add a driver to support SAMA5D4 watchdog timer

From SAMA5D4, the watchdog timer is upgrated with a new feature,
which is describled as in the datasheet, "WDT_MR can be written
until a LOCKMR command is issued in WDT_CR".
That is to say, as long as the bootstrap and u-boot don't issue
a LOCKMR command, WDT_MR can be written more than once in the driver.

So the SAMA5D4 watchdog driver's implementation is different from
the at91sam9260 watchdog driver implemented in file at91sam9_wdt.c.
The user application open the device file to enable the watchdog timer
hardware, and close to disable it, and set the watchdog timer timeout
by seting WDV and WDD fields of WDT_MR register, and ping the watchdog
by issuing WDRSTT command to WDT_CR register with hard-coded key.

Signed-off-by: Wenyou Yang <[email protected]>
Reviewed-by: Guenter Roeck <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
9 years agowatchdog: mpc8xxx: allow to compile for MPC512x
Uwe Kleine-König [Wed, 12 Aug 2015 08:15:58 +0000 (10:15 +0200)]
watchdog: mpc8xxx: allow to compile for MPC512x

The MPC5125 processor features a watchdog device that is identical to
the MPC8610 one. So allow to enable the driver for MPC512x kernel
configurations.

Signed-off-by: Uwe Kleine-König <[email protected]>
Reviewed-by: Guenter Roeck <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
9 years agowatchdog: mpc8xxx: use better error code when watchdog cannot be enabled
Uwe Kleine-König [Wed, 12 Aug 2015 08:15:57 +0000 (10:15 +0200)]
watchdog: mpc8xxx: use better error code when watchdog cannot be enabled

checkpatch warns about ENOSYS, telling "ENOSYS means 'invalid syscall
nr' and nothing else". So use ENODEV instead.

Signed-off-by: Uwe Kleine-König <[email protected]>
Reviewed-by: Guenter Roeck <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
9 years agowatchdog: mpc8xxx: use dynamic memory for device specific data
Uwe Kleine-König [Wed, 12 Aug 2015 08:15:56 +0000 (10:15 +0200)]
watchdog: mpc8xxx: use dynamic memory for device specific data

Instead of relying on global static memory dynamically allocate the
needed data. This has the benefit of some saved bytes if the driver is
not in use and making it possible to bind more than one device (even
though this has no known use case).

Signed-off-by: Uwe Kleine-König <[email protected]>
Reviewed-by: Guenter Roeck <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
9 years agowatchdog: mpc8xxx: use devm_ioremap_resource to map memory
Uwe Kleine-König [Wed, 12 Aug 2015 08:15:55 +0000 (10:15 +0200)]
watchdog: mpc8xxx: use devm_ioremap_resource to map memory

This simplifies the error paths and device unbinding.

Signed-off-by: Uwe Kleine-König <[email protected]>
Reviewed-by: Guenter Roeck <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
9 years agowatchdog: mpc8xxx: make use of of_device_get_match_data
Uwe Kleine-König [Wed, 12 Aug 2015 08:15:54 +0000 (10:15 +0200)]
watchdog: mpc8xxx: make use of of_device_get_match_data

This function is new in v4.2-rc1 and makes a forward declaration of the
match table superfluous which can so be removed.

Signed-off-by: Uwe Kleine-König <[email protected]>
Reviewed-by: Guenter Roeck <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
9 years agowatchdog: mpc8xxx: simplify registration
Uwe Kleine-König [Wed, 12 Aug 2015 08:15:53 +0000 (10:15 +0200)]
watchdog: mpc8xxx: simplify registration

Since commit ef90174f8210 ("watchdog: watchdog_core: Add watchdog
registration deferral mechanism") there is no need to delay the call to
watchdog_register_device any more. So simplify the registration code
accordingly.

Resetting wd_base to NULL can the also be dropped because nothing
depends on it being NULL to signal probe failure any more. (The matching
wd_base = NULL in .remove was missing, too.)

Signed-off-by: Uwe Kleine-König <[email protected]>
Reviewed-by: Guenter Roeck <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
9 years agowatchdog: mpc8xxx: remove dead code
Uwe Kleine-König [Wed, 12 Aug 2015 08:15:52 +0000 (10:15 +0200)]
watchdog: mpc8xxx: remove dead code

Signed-off-by: Uwe Kleine-König <[email protected]>
Reviewed-by: Guenter Roeck <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
9 years agowatchdog: lpc18xx_wdt_get_timeleft() can be static
Fengguang Wu [Fri, 7 Aug 2015 17:28:40 +0000 (10:28 -0700)]
watchdog: lpc18xx_wdt_get_timeleft() can be static

Signed-off-by: Fengguang Wu <[email protected]>
Reviewed-by: Guenter Roeck <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
9 years agoDT: watchdog: Add NXP LPC18xx Watchdog Timer binding documentation
Ariel D'Alessandro [Sat, 1 Aug 2015 18:37:17 +0000 (15:37 -0300)]
DT: watchdog: Add NXP LPC18xx Watchdog Timer binding documentation

Add the devicetree binding document for NXP LPC18xx Watchdog Timer.

Signed-off-by: Ariel D'Alessandro <[email protected]>
Reviewed-by: Guenter Roeck <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
9 years agowatchdog: NXP LPC18xx Watchdog Timer Driver
Ariel D'Alessandro [Sat, 1 Aug 2015 18:37:16 +0000 (15:37 -0300)]
watchdog: NXP LPC18xx Watchdog Timer Driver

This commit adds support for the watchdog timer found in NXP LPC SoCs
family, which includes LPC18xx/LPC43xx. Other SoCs in that family may
share the same watchdog hardware.

Watchdog driver registers a restart handler that will restart the system
by performing an incorrect feed after ensuring the watchdog is enabled in
reset mode.

As watchdog cannot be disabled in hardware, driver's stop routine will
regularly send a keepalive ping using a timer.

Signed-off-by: Ariel D'Alessandro <[email protected]>
Reviewed-by: Guenter Roeck <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
9 years agowatchdog: gpio-wdt: ping already at startup for always running devices
Uwe Kleine-König [Fri, 31 Jul 2015 07:21:36 +0000 (09:21 +0200)]
watchdog: gpio-wdt: ping already at startup for always running devices

During probe for an always-running watchdog a timer is setup to
constantly ping the watchdog while the device is not open. The gpio to
ping the watchdog is setup to inactive.

For a watchdog with hw_algo = "toggle" this results in a ping depending
on the initial state of the gpio, for hw_algo = "level" no ping is
generated.

Make sure that the first automatic ping is sent immediately and not only
when the timer expires the first time. This makes the machine survive in
case more than half of the watchdog timeout is already elapsed. (Which
is very probable for the chip I'm faced with that has a timeout of one
second.)

Signed-off-by: Uwe Kleine-König <[email protected]>
Reviewed-by: Guenter Roeck <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
9 years agowatchdog: gpio-wdt: be more strict about hw_algo matching
Uwe Kleine-König [Thu, 30 Jul 2015 09:32:23 +0000 (11:32 +0200)]
watchdog: gpio-wdt: be more strict about hw_algo matching

strncmp(algo, "toggle", 6) doesn't compare the trailing '\0' byte, so
using

hw_algo = "toggleboggle"

is recognized the same way as

hw_algo = "toggle"

. While this doesn't introduce any problems for a device tree that
sticks to the documented settings it's still ugly.

Fix this by using strcmp to only match on "toggle" and "level".

Signed-off-by: Uwe Kleine-König <[email protected]>
Reviewed-by: Guenter Roeck <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
9 years agoDocumentation: watchdog: at91sam9_wdt: add clocks property
Alexandre Belloni [Fri, 31 Jul 2015 09:39:39 +0000 (11:39 +0200)]
Documentation: watchdog: at91sam9_wdt: add clocks property

The watchdog has an input clock, the slow clock. It is required as it will
not function without it.

Signed-off-by: Alexandre Belloni <[email protected]>
Reviewed-by: Guenter Roeck <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
9 years agoxen-netback: require fewer guest Rx slots when not using GSO
David Vrabel [Tue, 8 Sep 2015 13:25:14 +0000 (14:25 +0100)]
xen-netback: require fewer guest Rx slots when not using GSO

Commit f48da8b14d04ca87ffcffe68829afd45f926ec6a (xen-netback: fix
unlimited guest Rx internal queue and carrier flapping) introduced a
regression.

The PV frontend in IPXE only places 4 requests on the guest Rx ring.
Since netback required at least (MAX_SKB_FRAGS + 1) slots, IPXE could
not receive any packets.

a) If GSO is not enabled on the VIF, fewer guest Rx slots are required
   for the largest possible packet.  Calculate the required slots
   based on the maximum GSO size or the MTU.

   This calculation of the number of required slots relies on
   1650d5455bd2 (xen-netback: always fully coalesce guest Rx packets)
   which present in 4.0-rc1 and later.

b) Reduce the Rx stall detection to checking for at least one
   available Rx request.  This is fine since we're predominately
   concerned with detecting interfaces which are down and thus have
   zero available Rx requests.

Signed-off-by: David Vrabel <[email protected]>
Reviewed-by: Wei Liu <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
9 years agowatchdog: booke_wdt: Use infrastructure to check timeout limits
Guenter Roeck [Wed, 29 Jul 2015 16:45:36 +0000 (09:45 -0700)]
watchdog: booke_wdt: Use infrastructure to check timeout limits

The watchdog infrastructure checks the maximum timeout for us.
Use it.

Signed-off-by: Guenter Roeck <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
9 years agowatchdog: (nv_tco) add support for MCP79
Vivien Didelot [Mon, 27 Jul 2015 16:03:30 +0000 (12:03 -0400)]
watchdog: (nv_tco) add support for MCP79

Tested on the Nvidia chipset with an SMBus controller PCI ID 0x0AA2
(as shown in the PCI listing during the boot sequence).

Signed-off-by: Vivien Didelot <[email protected]>
Reviewed-by: Guenter Roeck <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
9 years agowatchdog: sunxi: fix activation of system reset
Francesco Lavra [Sat, 25 Jul 2015 06:25:18 +0000 (08:25 +0200)]
watchdog: sunxi: fix activation of system reset

Commit f2147de33470 ("watchdog: sunxi: support parameterized compatible
strings") introduced a regression in sunxi_wdt_start(), by which
the system reset function of the watchdog is not enabled upon
starting the watchdog. As a result, the system is not reset when the
watchdog expires. Fix it.

Fixes: f2147de33470 ("watchdog: sunxi: support parameterized compatible strings")
Signed-off-by: Francesco Lavra <[email protected]>
Acked-by: Maxime Ripard <[email protected]>
Reviewed-by: Guenter Roeck <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
Cc: [email protected]
9 years agowatchdog: mtk_wdt: add wdt shutdown callback to disable wdt if enabled
Greta Zhang [Fri, 24 Jul 2015 07:28:46 +0000 (15:28 +0800)]
watchdog: mtk_wdt: add wdt shutdown callback to disable wdt if enabled

Without .shutdown(), watchdog might reset the system during power off.
For example, if watchdog's timeout is set to 30s, then it is reset to
zero by mtk_wdt_ping(). During power off, no app will ping watchdog,
but watchdog is still running and may trigger reset.

Signed-off-by: Greta Zhang <[email protected]>
Signed-off-by: Eddie Huang <[email protected]>
Acked-by: Matthias Brugger <[email protected]>
Reviewed-by: Guenter Roeck <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
9 years agowatchdog: mtk_wdt: add suspend/resume support
Greta Zhang [Fri, 24 Jul 2015 07:28:45 +0000 (15:28 +0800)]
watchdog: mtk_wdt: add suspend/resume support

add mediatek watchdog driver suspend/resume support

Signed-off-by: Greta Zhang <[email protected]>
Signed-off-by: Roger Lu <[email protected]>
Signed-off-by: Eddie Huang <[email protected]>
Acked-by: Matthias Brugger <[email protected]>
Reviewed-by: Guenter Roeck <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
9 years agowatchdog: imgpdc: Unregister restart handler on remove
Ezequiel Garcia [Thu, 23 Jul 2015 20:21:16 +0000 (17:21 -0300)]
watchdog: imgpdc: Unregister restart handler on remove

Commit c631f20068 ("watchdog: imgpdc: Add reboot support") introduced
a restart handler but forgot to unregister it on driver removal. Fix it.

Fixes: c631f20068 ("watchdog: imgpdc: Add reboot support")
Reported-by: Ariel D'Alessandro <[email protected]>
Signed-off-by: Ezequiel Garcia <[email protected]>
Reviewed-by: Guenter Roeck <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
9 years agoDocumentation/watchdog: add timeout and ping rate control to watchdog-test.c
Timur Tabi [Mon, 29 Jun 2015 16:46:17 +0000 (11:46 -0500)]
Documentation/watchdog: add timeout and ping rate control to watchdog-test.c

The watchdog test program is much more useful if it can configure the
timeout value and ping rate.  This will allow you to test actual timeouts.

Adds the -t parameter to set the timeout value (in seconds), and -p to set
the ping rate (number of seconds between pings).

Signed-off-by: Timur Tabi <[email protected]>
Reviewed-by: Guenter Roeck <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
9 years agoMerge branch 'cxgb4-fixes'
David S. Miller [Wed, 9 Sep 2015 19:29:26 +0000 (12:29 -0700)]
Merge branch 'cxgb4-fixes'

Hariprasad Shenai says:

====================
cxgb4: Fix tx flit calculation and wc stat configuration

This patch series fixes the following:
Patch 1/2 fixes tx flit calculation, which if wrong can lead to
stall, hang, data corrpution, write combining failure. Patch 2/2 fixes
PCI-E write combining stats configuration.

This patch series has been created against net tree and includes
patches on cxgb4 driver.

We have included all the maintainers of respective drivers. Kindly review
the change and let us know in case of any review comments.
====================

Signed-off-by: David S. Miller <[email protected]>
9 years agocxgb4: Fix for write-combining stats configuration
Hariprasad Shenai [Tue, 8 Sep 2015 10:55:40 +0000 (16:25 +0530)]
cxgb4: Fix for write-combining stats configuration

The write-combining configuration register SGE_STAT_CFG_A needs to
be configured after FW initializes the adapter, else FW will reset
the configuration

Signed-off-by: Hariprasad Shenai <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
9 years agocxgb4: Fix tx flit calculation
Hariprasad Shenai [Tue, 8 Sep 2015 10:55:39 +0000 (16:25 +0530)]
cxgb4: Fix tx flit calculation

In commit 0aac3f56d4a63f04 ("cxgb4: Add comment for calculate tx flits
and sge length code") introduced a regression where tx flit calculation
is going wrong, which can lead to data corruption, hang, stall and
write-combining failure. Fixing it.

Signed-off-by: Hariprasad Shenai <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
9 years agonet: eth: altera: Fix the initial device operstate
Atsushi Nemoto [Tue, 8 Sep 2015 09:15:41 +0000 (18:15 +0900)]
net: eth: altera: Fix the initial device operstate

Call netif_carrier_off() prior to register_netdev(), otherwise
userspace can see incorrect link state.

Signed-off-by: Atsushi Nemoto <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
9 years agoMerge tag 'tty-4.3-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty
Linus Torvalds [Wed, 9 Sep 2015 18:27:01 +0000 (11:27 -0700)]
Merge tag 'tty-4.3-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty

Pull tty driver reverts from Greg KH:
 "Here are some reverts for some tty patches (specifically the pl011
  driver) that ended up breaking a bunch of machines (i.e. almost all
  of the ones with this chip).

  People are working on a fix for this, but in the meantime, it's best
  to just revert all 5 patches to restore people's serial consoles.

  These reverts have been in linux-next for many days now"

* tag 'tty-4.3-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty:
  Revert "uart: pl011: Rename regs with enumeration"
  Revert "uart: pl011: Introduce register accessor"
  Revert "uart: pl011: Introduce register look up table"
  Revert "uart: pl011: Improve LCRH register access decision"
  Revert "uart: pl011: Add support to ZTE ZX296702 uart"

9 years agoMerge tag 'for-linus-20150909' of git://git.infradead.org/linux-mtd
Linus Torvalds [Wed, 9 Sep 2015 18:17:33 +0000 (11:17 -0700)]
Merge tag 'for-linus-20150909' of git://git.infradead.org/linux-mtd

Pull more MTD updates from Brian Norris:
 "There was one significant bug in my first pull request, fixed here.  I
  also threw in a few trivial ID additions and a small module rename.

  Details:

   - SPI NOR: bug fix for a "end of table" check that resulted in a NULL
     dereference in some cases

   - SPI NOR: a few new IDs / feature flags

   - OMAP2 NAND: rename module so it doesn't conflict with onenand
     omap2.ko"

* tag 'for-linus-20150909' of git://git.infradead.org/linux-mtd:
  mtd: spi-nor: fix NULL dereference when no match found in spi_nor_ids[]
  mtd: spi-nor: s25sl064p supports both dual and quad I/O
  mtd: spi-nor: allow dual/quad reads on S25FL129P
  mtd: nand: omap2: Rename shippable module to omap2_nand
  mtd: spi-nor: Add support for sst25wf020a
  mtd: spi-nor: Add support for Micron n25q064a serial flash

9 years agoMerge tag 'pwm/for-4.3-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/thierry...
Linus Torvalds [Wed, 9 Sep 2015 17:55:32 +0000 (10:55 -0700)]
Merge tag 'pwm/for-4.3-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/thierry.reding/linux-pwm

Pull pwm updates from Thierry Reding:
 "This set of changes introduces the beginnings of a new API that's
  based around the concept of states that can be atomically applied.
  Drivers go to various lengths to implement something similar, which
  indicates that the core should really be providing the necessary
  framework.

  On top of that, there is a bit of cleanup as well as improved
  kerneldoc and integration into the device-drivers DocBook.

  Regarding drivers there is a new one for the NXP LPC18xx family of
  SoCs and a couple of fixes for existing drivers (pca9685, Broadcom
  Kona and Atmel HLCDC)"

* tag 'pwm/for-4.3-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/thierry.reding/linux-pwm:
  ARM: at91: pwm: atmel-hlcdc: Add at91sam9n12 errata
  pwm: Add NXP LPC18xx PWM/SCT DT binding documentation
  pwm: NXP LPC18xx PWM/SCT driver
  pwm-pca9685: Support changing the output frequency
  pwm-pca9685: Fix several driver bugs
  pwm: kona: Modify settings application sequence
  pwm: pca9685: Drop owner assignment
  pwm: Add to device-drivers documentation
  pwm: Clean up kerneldoc
  pwm: Remove useless whitespace
  pwm: sysfs: Remove unnecessary padding
  pwm: sysfs: Properly convert from enum to string
  pwm: Make use of pwm_get_xxx() helpers where appropriate
  pwm: Add pwm_get_polarity() helper function
  pwm: Constify PWM device where possible
  pwm: Add the pwm_is_enabled() helper

9 years agofix ufs write vs readpage race when writing into a hole
Al Viro [Wed, 9 Sep 2015 09:16:39 +0000 (10:16 +0100)]
fix ufs write vs readpage race when writing into a hole

Followup to the UFS series - with the way we clear the new blocks (via
buffer cache, possibly on more than a page worth of file) we really
should not insert a reference to new block into inode block tree until
after we'd cleared it.

Signed-off-by: Al Viro <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
9 years agoMerge tag 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost
Linus Torvalds [Wed, 9 Sep 2015 17:37:41 +0000 (10:37 -0700)]
Merge tag 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost

Pull virtio updates from Michael Tsirkin:
 "Virtio fixes and features for 4.3:

   - virtio-mmio can now be auto-loaded through acpi.
   - virtio blk supports extended partitions.
   - total memory is better reported when using virtio balloon with
     auto-deflate.
   - cache control is re-enabled when using virtio-blk in modern mode"

* tag 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost:
  virtio_balloon: do not change memory amount visible via /proc/meminfo
  virtio_ballon: change stub of release_pages_by_pfn
  virtio-blk: Allow extended partitions
  virtio_mmio: add ACPI probing
  virtio-blk: use VIRTIO_BLK_F_WCE and VIRTIO_BLK_F_CONFIG_WCE in virtio1

9 years agoMerge tag 'metag-for-v4.3' of git://git.kernel.org/pub/scm/linux/kernel/git/jhogan...
Linus Torvalds [Wed, 9 Sep 2015 17:27:59 +0000 (10:27 -0700)]
Merge tag 'metag-for-v4.3' of git://git.kernel.org/pub/scm/linux/kernel/git/jhogan/metag

Pull metag updates from James Hogan:
 "Metag architecture changes for v4.3.

  Just a couple of changes for v4.3-rc1.  A preparatory IRQ patch to
  prepare for moving irq_data struct members, and a tweak to
  Documentation/features since Meta2 could support THP"

* tag 'metag-for-v4.3' of git://git.kernel.org/pub/scm/linux/kernel/git/jhogan/metag:
  Documentation/features/vm: Meta2 is capable of THP
  metag/irq: Use access helper irq_data_get_affinity_mask()

9 years agoMerge tag 'nios2-v4.3-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/lftan...
Linus Torvalds [Wed, 9 Sep 2015 17:07:32 +0000 (10:07 -0700)]
Merge tag 'nios2-v4.3-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/lftan/nios2

Pull nios2 updates from Ley Foon Tan:

 - add defconfig and device tree for max 10 support
 - migrate to new 'set-state' interface for timer
 - fix unaligned handler
 - MAINTAINERS: update nios2 git repo

* tag 'nios2-v4.3-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/lftan/nios2:
  nios2: add Max10 defconfig
  nios2: Add Max10 device tree
  MAINTAINERS: update nios2 git repo
  nios2: remove unused statistic counters
  nios2: fixed variable imm16 to s16
  nios2/time: Migrate to new 'set-state' interface

9 years agoMerge branch 'for-next' of git://git.samba.org/sfrench/cifs-2.6
Linus Torvalds [Wed, 9 Sep 2015 16:59:35 +0000 (09:59 -0700)]
Merge branch 'for-next' of git://git.samba.org/sfrench/cifs-2.6

Pull cifs updates from Steve French:
 "Small cifs fix and a patch for improved debugging"

* 'for-next' of git://git.samba.org/sfrench/cifs-2.6:
  cifs: Fix use-after-free on mid_q_entry
  Update cifs version number
  Add way to query server fs info for smb3

9 years agodax: update PMD fault handler with PMEM API
Ross Zwisler [Wed, 9 Sep 2015 16:29:40 +0000 (10:29 -0600)]
dax: update PMD fault handler with PMEM API

As part of the v4.3 merge window the DAX code was updated by Matthew and
Kirill to handle PMD pages.  Also as part of the v4.3 merge window we
updated the DAX code to do proper PMEM flushing (commit 2765cfbb342c:
"dax: update I/O path to do proper PMEM flushing").

The additional code added by the DAX PMD patches also needs to be
updated to properly use the PMEM API.  This ensures that after a PMD
fault is handled the zeros written to the newly allocated pages are
durable on the DIMMs.

linux/dax.h is included to get rid of a bunch of sparse warnings.

Signed-off-by: Ross Zwisler <[email protected]>
Cc: Matthew Wilcox <[email protected]>,
Cc: Dan Williams <[email protected]>
Cc: Kirill Shutemov <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
9 years agoRevert "Hexagon: fix signal.c compile error"
Mike Frysinger [Thu, 23 Apr 2015 01:28:04 +0000 (21:28 -0400)]
Revert "Hexagon: fix signal.c compile error"

This reverts commit f3f601c1d2728f02544cfd143eaa82e5398b3e9b.

UAPI headers cannot use "uapi/" in their paths by design -- when they're
installed, they do not have the uapi/ prefix.  Otherwise doing so breaks
userland badly.

Signed-off-by: Mike Frysinger <[email protected]>
Signed-off-by: Richard Kuo <[email protected]>
9 years agoMerge tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dledford/rdma
Linus Torvalds [Wed, 9 Sep 2015 15:33:31 +0000 (08:33 -0700)]
Merge tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dledford/rdma

Pull inifiniband/rdma updates from Doug Ledford:
 "This is a fairly sizeable set of changes.  I've put them through a
  decent amount of testing prior to sending the pull request due to
  that.

  There are still a few fixups that I know are coming, but I wanted to
  go ahead and get the big, sizable chunk into your hands sooner rather
  than waiting for those last few fixups.

  Of note is the fact that this creates what is intended to be a
  temporary area in the drivers/staging tree specifically for some
  cleanups and additions that are coming for the RDMA stack.  We
  deprecated two drivers (ipath and amso1100) and are waiting to hear
  back if we can deprecate another one (ehca).  We also put Intel's new
  hfi1 driver into this area because it needs to be refactored and a
  transfer library created out of the factored out code, and then it and
  the qib driver and the soft-roce driver should all be modified to use
  that library.

  I expect drivers/staging/rdma to be around for three or four kernel
  releases and then to go away as all of the work is completed and final
  deletions of deprecated drivers are done.

  Summary of changes for 4.3:

   - Create drivers/staging/rdma
   - Move amso1100 driver to staging/rdma and schedule for deletion
   - Move ipath driver to staging/rdma and schedule for deletion
   - Add hfi1 driver to staging/rdma and set TODO for move to regular
     tree
   - Initial support for namespaces to be used on RDMA devices
   - Add RoCE GID table handling to the RDMA core caching code
   - Infrastructure to support handling of devices with differing read
     and write scatter gather capabilities
   - Various iSER updates
   - Kill off unsafe usage of global mr registrations
   - Update SRP driver
   - Misc  mlx4 driver updates
   - Support for the mr_alloc verb
   - Support for a netlink interface between kernel and user space cache
     daemon to speed path record queries and route resolution
   - Ininitial support for safe hot removal of verbs devices"

* tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dledford/rdma: (136 commits)
  IB/ipoib: Suppress warning for send only join failures
  IB/ipoib: Clean up send-only multicast joins
  IB/srp: Fix possible protection fault
  IB/core: Move SM class defines from ib_mad.h to ib_smi.h
  IB/core: Remove unnecessary defines from ib_mad.h
  IB/hfi1: Add PSM2 user space header to header_install
  IB/hfi1: Add CSRs for CONFIG_SDMA_VERBOSITY
  mlx5: Fix incorrect wc pkey_index assignment for GSI messages
  IB/mlx5: avoid destroying a NULL mr in reg_user_mr error flow
  IB/uverbs: reject invalid or unknown opcodes
  IB/cxgb4: Fix if statement in pick_local_ip6adddrs
  IB/sa: Fix rdma netlink message flags
  IB/ucma: HW Device hot-removal support
  IB/mlx4_ib: Disassociate support
  IB/uverbs: Enable device removal when there are active user space applications
  IB/uverbs: Explicitly pass ib_dev to uverbs commands
  IB/uverbs: Fix race between ib_uverbs_open and remove_one
  IB/uverbs: Fix reference counting usage of event files
  IB/core: Make ib_dealloc_pd return void
  IB/srp: Create an insecure all physical rkey only if needed
  ...

This page took 0.125167 seconds and 4 git commands to generate.