Commit graph

692907 commits

Author SHA1 Message Date
Icenowy Zheng
dff751c689 arm64: allwinner: a64: pine64: add missing ethernet0 alias
The EMAC Ethernet controller was enabled, but an accompanying alias
was not added. This results in unstable numbering if other Ethernet
devices, such as a USB dongle, are present. Also, the bootloader uses
the alias to assign a generated stable MAC address to the device node.

Signed-off-by: Icenowy Zheng <icenowy@aosc.io>
Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
Fixes: 9702394374 ("arm64: allwinner: pine64: Enable dwmac-sun8i")
[wens@csie.org: Rewrite commit log as fixing a previous patch with Fixes]
Signed-off-by: Chen-Yu Tsai <wens@csie.org>
2017-08-10 14:01:38 +08:00
Icenowy Zheng
7dc88d2afb arm64: allwinner: a64: bananapi-m64: add missing ethernet0 alias
The EMAC Ethernet controller was enabled, but an accompanying alias
was not added. This results in unstable numbering if other Ethernet
devices, such as a USB dongle, are present. Also, the bootloader uses
the alias to assign a generated stable MAC address to the device node.

Signed-off-by: Icenowy Zheng <icenowy@aosc.io>
Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
Fixes: e729549990 ("arm64: allwinner: bananapi-m64: Enable dwmac-sun8i")
[wens@csie.org: Rewrite commit log as fixing a previous patch with Fixes]
Signed-off-by: Chen-Yu Tsai <wens@csie.org>
2017-08-10 14:00:10 +08:00
Masahiro Yamada
ac5aebabfc ARM: dts: uniphier: remove sLD3 SoC support
This SoC is too old.  It is difficult to maintain any longer.

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
2017-08-10 01:47:17 +09:00
Katsuhiro Suzuki
d3a48c6c0a ARM: dts: uniphier: add audio out pin-mux node
The UniPhier AIO2013 audio system needs I2S and clock signal pins
to connect external codec chip.

Signed-off-by: Katsuhiro Suzuki <suzuki.katsuhiro@socionext.com>
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
2017-08-10 00:51:51 +09:00
Neil Armstrong
ec9b59162f ARM: dts: meson6: use stable UART bindings
The UART bindings needs specifying a SoC family, use the meson6 family
for the UART nodes like the other nodes.
Switch to the stable UART bindings for meson6 by adding a XTAL node and
using the proper compatible strings.

Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
Signed-off-by: Kevin Hilman <khilman@baylibre.com>
2017-08-08 14:49:12 -07:00
Christian Lamparter
0d363594c5 ARM: dts: qcom: add and enable both wifi blocks on the IPQ4019
This patch adds and enables the device-tree definitions for
both qcom,ipq4019-wifi blocks for the IPQ4019.

Support for these have been added into the ath10k driver since:
commit 280e762e9c ("ath10k: enable ipq4019 device probe in ahb module")

The binding documentation was added in:
commit a47aaa69de ("dt: bindings: add new dt entry for pre calibration in qcom, ath10k.txt")

This has been tested on an ASUS RT-AC58U (IPQ4019),
an AVM Fritz!Box 4040 (IPQ4018), a Compex WPJ428 (IPQ4028)
and a Cisco Meraki MR33 (IPQ4029).

| a000000.wifi: qca4019 hw1.0 target 0x01000000 chip_id 0x003b00ff [...]
| a000000.wifi: kconfig debug 0 debugfs 1 tracing 0 dfs 1 testmode 1
| a000000.wifi: firmware ver 10.4-3.4-00082 api 5 features no-p2p,mfp,[...]
| a000000.wifi: board_file api 2 bmi_id 0:16 crc32 5773b188
| a000000.wifi: htt-ver 2.2 wmi-op 6 htt-op 4 cal pre-cal-file [...]
...
| a800000.wifi: qca4019 hw1.0 target 0x01000000 chip_id 0x003b00ff sub 0000:0000
| a800000.wifi: kconfig debug 0 debugfs 1 tracing 0 dfs 1 testmode 1
| a800000.wifi: firmware ver 10.4-3.4-00082 api 5 features no-p2p, [...]
| a800000.wifi: board_file api 2 bmi_id 0:17 crc32 5773b188
| a800000.wifi: htt-ver 2.2 wmi-op 6 htt-op 4 cal pre-cal-file [...]

Signed-off-by: Christian Lamparter <chunkeey@googlemail.com>
Signed-off-by: Andy Gross <andy.gross@linaro.org>
2017-08-08 14:53:12 -05:00
Suzuki K. Poulose
8d4c75fbb0 ARM: dts: qcom-msm8974: dts: Update coresight replicator
Replace the obsolete compatible string for Coresight programmable
replicator with the new one.

Cc: Andy Gross <andy.gross@linaro.org>
Cc: David Brown <david.brown@linaro.org>
Cc: linux-arm-msm@vger.kernel.org
Cc: Mathieu Poirier <mathieu.poirier@linaro.org>
Reviewed-by: Mathieu Poirier <mathieu.poirier@linaro.org>
Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com>
Signed-off-by: Andy Gross <andy.gross@linaro.org>
2017-08-08 14:53:07 -05:00
Christian Lamparter
6bfe03ddcd ARM: dts: qcom: add pseudo random number generator on the IPQ4019
This architecture has a pseudo random number generator
supported by the existing "qcom,prng" binding.

rngtest: bits received from input: 5795960032
rngtest: FIPS 140-2 successes: 289591
rngtest: FIPS 140-2 failures: 207
rngtest: FIPS 140-2(2001-10-10) Monobit: 25
rngtest: FIPS 140-2(2001-10-10) Poker: 28
rngtest: FIPS 140-2(2001-10-10) Runs: 91
rngtest: FIPS 140-2(2001-10-10) Long run: 67
rngtest: FIPS 140-2(2001-10-10) Continuous run: 0
rngtest: input channel speed: (min=244; avg=46122; max=3906250)Kibits/s
rngtest: FIPS tests speed: (min=1.327; avg=20.966; max=26.345)Mibits/s
rngtest: Program run time: 386965827 microseconds

Signed-off-by: Christian Lamparter <chunkeey@googlemail.com>
Signed-off-by: Andy Gross <andy.gross@linaro.org>
2017-08-08 14:53:03 -05:00
Varadarajan Narayanan
75ea98acf7 ARM: dts: ipq4019: Move xo and timer nodes to SoC dtsi
The node for xo and timer belong to the SoC DTS file.
Else, new board DT files may not inherit these nodes.

Signed-off-by: Varadarajan Narayanan <varada@codeaurora.org>
Signed-off-by: Andy Gross <andy.gross@linaro.org>
2017-08-08 14:52:58 -05:00
Varadarajan Narayanan
ba4ca27ba9 ARM: dts: ipq4019: Fix pinctrl node name
This patch fixes the pinctrl node addresses to be the correct format.

Signed-off-by: Varadarajan Narayanan <varada@codeaurora.org>
Signed-off-by: Andy Gross <andy.gross@linaro.org>
2017-08-08 14:52:54 -05:00
Varadarajan Narayanan
e099febc8e dt-bindings: qcom: Add IPQ8074 bindings
This patch adds the IPQ8074 and related boards to the QCOM bindings.

Signed-off-by: Varadarajan Narayanan <varada@codeaurora.org>
Acked-by: Rob Herring <robh@kernel.org>
Signed-off-by: Andy Gross <andy.gross@linaro.org>
2017-08-08 14:50:52 -05:00
Linus Walleij
f328c2eac5 ARM: dts: gemini: add pin control set-up for the SoC
This adds the basic pin control muliplexing settings for the
Gemini SoC: parallel (NOR) flash, SATA, optional IDE, PCI and
UART.

We also select the right GPIO groups on all applicable systems
so that GPIO keys/LEDs work smoothly.

We can then build upon this for more complex systems.

Acked-by: Hans Ulli Kroll <ulli.kroll@googlemail.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2017-08-08 14:20:00 +02:00
Linus Walleij
22789ae3bb ARM: dts: Add DTS file for D-Link DIR-685
This adds a device tree file for the Gemini-based D-Link DIR-685
router, supporting all devices that are currently supported in
the main DTSI SoC file.

Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2017-08-08 14:19:29 +02:00
Linus Walleij
5896a4d802 ARM: dts: gemini: Switch to using macros
The macros for reset and clock lines were merged during the merge
window, this switches the Gemini to use these macros rather than
numerical defines.

Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2017-08-08 14:19:04 +02:00
Chen-Yu Tsai
5bcfff2cc3 ARM: sun8i: a83t: h8homlet-v2: Enable AC100 combo chip in AXP818 PMIC
The AXP813/AXP818 PMICs used with the A83T/H8 SoCs are actually 2 dies
in one package sharing the serial bus (I2C/RSB) pins. One die is the
actual PMIC. The other is an AC100 codec / RTC combo chip.

This patch adds the device nodes for the AC100 chip to the h8homlet-v2
device tree.

Signed-off-by: Chen-Yu Tsai <wens@csie.org>
Acked-by: Maxime Ripard <maxime.ripard@free-electrons.com>
2017-08-08 12:04:01 +08:00
Chen-Yu Tsai
29067930e7 ARM: sun8i: a83t: h8homlet-v2: Enable PMIC part of AXP818 PMIC
The AXP813/AXP818 PMICs used with the A83T/H8 SoCs are actually 2 dies
in one package sharing the serial bus (I2C/RSB) pins. One die is the
actual PMIC. The other is an AC100 codec / RTC combo chip.

This patch enables the RSB controller and adds a device node for the
PMIC die to the h8homlet-v2 device tree. Since the AXP813 and AXP818
are virtually identical, this patch uses the compatible string for
the former as a fallback.

Signed-off-by: Chen-Yu Tsai <wens@csie.org>
Acked-by: Maxime Ripard <maxime.ripard@free-electrons.com>
2017-08-08 12:04:00 +08:00
Chen-Yu Tsai
0c62fb093e ARM: sun8i: a83t: cubietruck-plus: Enable AC100 combo chip in AXP818 PMIC
The AXP813/AXP818 PMICs used with the A83T/H8 SoCs are actually 2 dies
in one package sharing the serial bus (I2C/RSB) pins. One die is the
actual PMIC. The other is an AC100 codec / RTC combo chip.

This patch adds the device nodes for the AC100 chip to the Cubietruck
Plus device tree.

Signed-off-by: Chen-Yu Tsai <wens@csie.org>
Acked-by: Maxime Ripard <maxime.ripard@free-electrons.com>
2017-08-08 12:03:59 +08:00
Chen-Yu Tsai
31f0491da6 ARM: sun8i: a83t: cubietruck-plus: Enable PMIC part of AXP818 PMIC
The AXP813/AXP818 PMICs used with the A83T/H8 SoCs are actually 2 dies
in one package sharing the serial bus (I2C/RSB) pins. One die is the
actual PMIC. The other is an AC100 codec / RTC combo chip.

This patch enables the RSB controller and adds a device node for the
PMIC die to the Cubietruck Plus device tree. Since the AXP813 and
AXP818 are virtually identical, this patch uses the compatible string
for the former as a fallback.

Signed-off-by: Chen-Yu Tsai <wens@csie.org>
Acked-by: Maxime Ripard <maxime.ripard@free-electrons.com>
2017-08-08 12:03:58 +08:00
Chen-Yu Tsai
b99b8832e4 ARM: sun8i: a83t: Add device node and pinmux setting for RSB controller
The A83T has an RSB controller for talking to the PMIC and audio codec.
Add a device node for it. Since there is only one usable pinmux setting,
for it, add that as well.

Signed-off-by: Chen-Yu Tsai <wens@csie.org>
Acked-by: Maxime Ripard <maxime.ripard@free-electrons.com>
2017-08-08 12:03:58 +08:00
Florian Fainelli
ad41eacc11 This pull request brings in a new DT for the Raspberry Pi Zero W.
-----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEE/JuuFDWp9/ZkuCBXtdYpNtH8nugFAlmIlOcACgkQtdYpNtH8
 nugc/xAAh6qezRxjhcbPKz2F6Gl7tBdfH+YDMFrkd5TtzjjyrnA6pZnbAqMQYcMV
 8IY4csOTVC2ykoVUyCE68nP+wyA7x6mb9ctM5VEUj1V6NOzdfgcjy6xXyMpuKiVi
 vrt7FEm5/1NSCebbuHM763lzx23J4zzFFv2nJofQzAdqRKY8cQeO4d7sR08/9gFc
 Q8iNPr5Mfu3ijr7dVMu3+dq+RLA5DaFmpgbD81UywDgP8hAI6KGwt795JUcAF764
 Iq7T+Mm+i77haQ6ZmdHiC30s2ReybNX6MTd9fOBVcimQsuOsl6X9fUG1h8vdlwAk
 q8CvZ9YsgS2cd7Bm4WIPMxdQ+5PoNG4B5kfBymV5yPrlXA1FN/AWmhJhWX/aUjbK
 amqbiVcmFiaraMeFNy1yAcX+6E7oStvxZt3KRldjeXqBCD4+/Tic2dZupSYZKnjS
 Hw3suK7r/RgRsFzJdMJ2ZNNNH88knwhPZyQtRZ78SfBCsZwYvft72Bmo1UMZ95CS
 AsjYDwi3EYMD5XtrggP/ZqMuNH4m7fxGBxkhPbOmO/f8H4JHoypApSwGEnVEsxzq
 86egU7O6TUJyC+dpZ/hFII3Qm9M9YVBHFcPd1pngD5uA8CfE53OiHKa1pEd4xYUr
 vXIA7F1nluZY5DYBEp+qouOQJAXz5R9SnBinRA01NH6jsSLP8tY=
 =Glp8
 -----END PGP SIGNATURE-----
gpgsig -----BEGIN PGP SIGNATURE-----
 
 iQIcBAABCAAGBQJZiKdKAAoJEIfQlpxEBwcE8IwP/2Mm4VrTdqBG9K+RWPRmwMuE
 oVSKfhly8UrfZR0Knl2KLPTiHhu59fOmjuwo4i11w6glIuQECBKVms7R6d7HuQ4g
 JGeSJwnSnBUVCnzLD9ACAaMrpG3qZtmRxBEn27ZA954pwm/KAXTLtbaKcNlI4Ptr
 tvIZUEVZwk5o4AGmZ4Bt8fMQX4X1zcxjzrT+cO9KHwm/LMRCaq5nNPvcR7lWxylw
 gRNJRF3jagkICVz+uQHVKAcsOYxmYUJKXf3DZ7VEMiq2ld1yW4l6tC0IqPWXssHv
 YT1c5uOhuwH7yi9+MRBAvCV3pD0jmTDGwRY44/FYhmx6VyRs4nKdAtv3/ePgDY3W
 r07o2bUsRcpwPPLJDLfDBkByMoAVi8nBxBI4fiFgOIlGrM0oLIZWEOwmnbamsdqB
 26wAmTgFGHLH5ukhCgmxz4F7zQtCNvmfgbk5yBYM9oKBuJ5CKluHr8wjtTTX00H4
 hHL8oabtWLLogrO3pkMEsDJI9Ar06v84uiNafD3G62QOvI60yFJu7B4HHx1Y8+q9
 Yt01JUNWQ1DpJw8cCF2oKsBOPTf5Jv5pDWzENkVNP77CP6fJqx1VxqOftyNWu6cB
 jlnu7WPZ0dsLV2wYp7+7t7/b64WIyEDwwARgAu5x4SWRQ93zUl+rQTqCgDY+6cIo
 SJ2/ag1lUv3b0F0kKJpw
 =MsqM
 -----END PGP SIGNATURE-----

Merge tag 'bcm2835-dt-next-2017-08-07' into devicetree/next

This pull request brings in a new DT for the Raspberry Pi Zero W.

Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
2017-08-07 10:45:35 -07:00
Florian Fainelli
092ccf0415 ARM: dts: BCM53573: Add Broadcom BCM947189ACDBMR board support
Adds support for the Broadcom reference board BCM947189ACDMBR which
features the following:

* 128MB of DRAM
* External MoCA support through a Broadcom BCM6802 chip
* 1x external Gigabit PHY through the external BCM6802
* 1x USB 2.0 port
* 1x PCIE slot
* Few configurable buttons and LEDs

Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
2017-08-07 10:39:21 -07:00
Rafał Miłecki
0b1f11002a ARM: dts: BCM5301X: Specify USB ports for USB LEDs of few devices
This uses trigger-sources documented in commit 80dc6e1cd8 ("dt-bindings:
leds: document new trigger-sources property") to specify USB ports. Such an
information can be used by operating system to setup LEDs behavior.

I updated dts files for 7 devices I own and I was able to test.

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
2017-08-07 10:38:54 -07:00
Jon Mason
bbe526f55b ARM: dts: NSP: Add USB3 and USB3 PHY to NSP
This uses the existing Northstar USB3 PHY driver to enable the USB3
ports on NSP.

Signed-off-by: Jon Mason <jon.mason@broadcom.com>
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
2017-08-07 10:32:20 -07:00
Jon Mason
2c5b8512c5 ARM: dts: NSP: Rearrage USB entries
The rest of the DTSI file is in incrementing addresses, but the USB
OHCI/ECHI entries are out of sequence.  Move them to put them in the
proper place.

Signed-off-by: Jon Mason <jon.mason@broadcom.com>
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
2017-08-07 10:32:19 -07:00
Jon Mason
56e2ff0346 ARM: dts: NSP: Add dma-coherent to relevant DT entries
Cache related issues with DMA rings and performance issues related to
caching are being caused by not properly setting the "dma-coherent" flag
in the device tree entries.  Adding it here to correct the issue.

Signed-off-by: Jon Mason <jon.mason@broadcom.com>
Fixes: 3107fa5bcf ("ARM: dts: NSP: Add SD/MMC support")
Fixes: 13d04f2093 ("ARM: dts: NSP: Add AMAC entries")
Fixes: 5aeda7bf8a ("ARM: dts: NSP: Add and enable amac2")
Fixes: 17d5171723 ("ARM: dts: NSP: Add mailbox (PDC) to NSP")
Fixes: 1d8ece6639 ("ARM: dts: NSP: Add EHCI/OHCI USB nodes to device tree")
Fixes: 0f9f27a36d ("ARM: dts: NSP: Add I2C support to the DT")
Fixes: 8dbcad020f ("ARM: dts: nsp: Add sata device tree entry")
Fixes: 522199029f ("ARM: dts: NSP: Fix PCIE DT issue")
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
2017-08-07 10:31:59 -07:00
Lokesh Vutla
edd404e05e ARM: dts: keystone-k2g-evm: Enable MMC0 and MMC1
Enable MMC0 which is used for micro SD and MMC1 which is used for the on
board EMMC.

Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
[fcooper@ti.com: add mmc1, bufferclass and pullup/pulldown settings]
Signed-off-by: Franklin S Cooper Jr <fcooper@ti.com>
[nsekhar@ti.com: add card detect GPIO support]
Signed-off-by: Sekhar Nori <nsekhar@ti.com>
Signed-off-by: Santosh Shilimkar <ssantosh@kernel.org>
2017-08-07 06:36:08 -07:00
Lokesh Vutla
9529de63a4 ARM: dts: keystone-k2g: add MMC0 and MMC1 nodes
Add device tree nodes for MMC0 and MMC1 pesent
on 66AK2G device.

Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
[nsekhar@ti.com: fix clock-names for mmc1 node]
Signed-off-by: Sekhar Nori <nsekhar@ti.com>
Signed-off-by: Santosh Shilimkar <ssantosh@kernel.org>
2017-08-07 06:36:08 -07:00
Peter Ujfalusi
f8d4416b82 ARM: dts: keystone-k2g: Add eDMA nodes
Add nodes for eDMA0 and eDMA1.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Signed-off-by: Dave Gerlach <d-gerlach@ti.com>
Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
Signed-off-by: Santosh Shilimkar <ssantosh@kernel.org>
2017-08-07 06:33:53 -07:00
Lokesh Vutla
3f465cfac7 dt-bindings: ti,omap-hsmmc: Add 66AK2G mmc controller
Update the ti,omap-hsmmc.txt to include information about
66AK2G specific mmc controller. Also cleanup the entries
under optional properties to look a bit nicer.

Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
Signed-off-by: Santosh Shilimkar <ssantosh@kernel.org>
2017-08-07 06:33:34 -07:00
Lokesh Vutla
470bbff038 dt-bindings: ti,edma: Add 66AK2G specific information
Update ti,edma binding documentation to reflect 66AK2G specific
properties.

Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
Signed-off-by: Santosh Shilimkar <ssantosh@kernel.org>
2017-08-07 06:33:34 -07:00
Keerthy
87b7c3acc5 ARM: dts: keystone-k2g: Add gpio nodes
66AK2G has 2 instances of gpio. The first one has all the 144 GPIOs
functional. 9 banks with 16 gpios making a total of 144. The second
instance has only the GPIO0:GPIO67 functional and rest are marked
reserved.

Signed-off-by: Keerthy <j-keerthy@ti.com>
Acked-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Santosh Shilimkar <ssantosh@kernel.org>
2017-08-07 06:22:29 -07:00
Linus Torvalds
aae4e7a8bc Linux 4.13-rc4 2017-08-06 18:44:49 -07:00
Linus Torvalds
acdae9ee6a platform-drivers-x86 for v4.13-4
Fix loop preventing some platforms from waking up via the power
 button in s2idle.
 
 intel-vbtn:
  - match power button on press rather than release
 -----BEGIN PGP SIGNATURE-----
 
 iQEcBAABAgAGBQJZhjtgAAoJEKbMaAwKp3647u4IALEnsRt10hj2ognbpQUPxqzB
 uwjlQ7ukqwWVbpgElQ6q2hKUFHNnk2CGuzIEjvRKpme0UpsSPUQRPZGeUGDmvC3l
 cOxNSmyTJkmeCEU9G7yj1NrcaOEFQ9iRLrZmSRnYBSWBgjzYdpfC/xog2y8mVkgO
 FQAU2ul9Ph5eXEOTQBw56LtzsraJtBdV76aKESuJEAw3h0E8svhLeV43caVic/Go
 Yv9aRZRkj/5oQHwXe+GC5K4dFdWFYZ9iGLQFHgcICRACcUq7p0ysVvf8YMVQplyR
 Xm2j8Dq1ierId5g90p5fznIM4BeBnIM2Iclkk4dPaIrP3Fogd9eq1gvxQKvWgpY=
 =IOnZ
 -----END PGP SIGNATURE-----

Merge tag 'platform-drivers-x86-v4.13-4' of git://git.infradead.org/linux-platform-drivers-x86

Pull x86 platform driver fix from Darren Hart:
 "Fix loop preventing some platforms from waking up via the power button
  in s2idle:

   - intel-vbtn: match power button on press rather than release"

* tag 'platform-drivers-x86-v4.13-4' of git://git.infradead.org/linux-platform-drivers-x86:
  platform/x86: intel-vbtn: match power button on press rather than release
2017-08-06 16:11:34 -07:00
Linus Torvalds
ed66da1104 A large number of ext4 bug fixes and cleanups for v4.13
-----BEGIN PGP SIGNATURE-----
 
 iQEzBAABCAAdFiEEK2m5VNv+CHkogTfJ8vlZVpUNgaMFAlmHbBAACgkQ8vlZVpUN
 gaMu3gf+LpI5bI1XA3R8KbXB2snnz6wM7OzArfqvreX+m+xP1CK6nVpAIgpkZqfw
 QkQ1xPJk7Q25vex/pPcsgLO0Vxf0i4vpydK+fYnf30S4WvGQVq6OHZWFFv2zM2YB
 7TWxjG+KryM7j6JSXdUiSTKP3nX84TW/IMIWuZMR1nuOa8N5M4yD3uc+3EBTjSbq
 P/dxfmkp2hQKnlZVBWqCjJDhtxwUYTF4iZ/pbSVeGbgHCh1674ml+airb4K9ltNU
 0vR0JChD12YJaafjaAyIrqqKwDGvnN+H5wyhCodEV9w8jthbcU04Jfmi1auB9UxT
 y7/sgbV64W2o5hBwxY3RXjZkVLpDsw==
 =Mtr7
 -----END PGP SIGNATURE-----

Merge tag 'ext4_for_linus_stable' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4

Pull ext4 fixes from Ted Ts'o:
 "A large number of ext4 bug fixes and cleanups for v4.13"

* tag 'ext4_for_linus_stable' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4:
  ext4: fix copy paste error in ext4_swap_extents()
  ext4: fix overflow caused by missing cast in ext4_resize_fs()
  ext4, project: expand inode extra size if possible
  ext4: cleanup ext4_expand_extra_isize_ea()
  ext4: restructure ext4_expand_extra_isize
  ext4: fix forgetten xattr lock protection in ext4_expand_extra_isize
  ext4: make xattr inode reads faster
  ext4: inplace xattr block update fails to deduplicate blocks
  ext4: remove unused mode parameter
  ext4: fix warning about stack corruption
  ext4: fix dir_nlink behaviour
  ext4: silence array overflow warning
  ext4: fix SEEK_HOLE/SEEK_DATA for blocksize < pagesize
  ext4: release discard bio after sending discard commands
  ext4: convert swap_inode_data() over to use swap() on most of the fields
  ext4: error should be cleared if ea_inode isn't added to the cache
  ext4: Don't clear SGID when inheriting ACLs
  ext4: preserve i_mode if __ext4_set_acl() fails
  ext4: remove unused metadata accounting variables
  ext4: correct comment references to ext4_ext_direct_IO()
2017-08-06 12:31:17 -07:00
Linus Torvalds
6ea1bc9b1a Merge branch 'upstream' of git://git.linux-mips.org/pub/scm/ralf/upstream-linus
Pull MIPS fixes from Ralf Baechle:
 "This fixes two build issues for ralink platforms, both due to missing
  #includes which used to be included indirectly via other headers"

* 'upstream' of git://git.linux-mips.org/pub/scm/ralf/upstream-linus:
  MIPS: ralink: mt7620: Add missing header
  MIPS: ralink: Fix build error due to missing header
2017-08-06 11:52:01 -07:00
Dmitry V. Levin
fbb77611e9 Fix compat_sys_sigpending breakage
The latest change of compat_sys_sigpending in commit 8f13621abc
("sigpending(): move compat to native") has broken it in two ways.

First, it tries to write 4 bytes more than userspace expects:
sizeof(old_sigset_t) == sizeof(long) == 8 instead of
sizeof(compat_old_sigset_t) == sizeof(u32) == 4.

Second, on big endian architectures these bytes are being written in the
wrong order.

This bug was found by strace test suite.

Reported-by: Anatoly Pugachev <matorola@gmail.com>
Inspired-by: Eugene Syromyatnikov <evgsyr@gmail.com>
Fixes: 8f13621abc ("sigpending(): move compat to native")
Signed-off-by: Dmitry V. Levin <ldv@altlinux.org>
Acked-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2017-08-06 11:48:27 -07:00
Elaine Zhang
a376a4b045 clk: rockchip: fix up indentation of some RV1108 clock-ids
Make the code look better.

Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
Signed-off-by: Andy Yan <andy.yan@rock-chips.com>
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2017-08-06 19:45:19 +02:00
Elaine Zhang
1b6428a286 clk: rockchip: rename the clk id for HCLK_I2S1_2CH
i2s1 has 2 channels but not 8 channels.

Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
Signed-off-by: Andy Yan <andy.yan@rock-chips.com>

[and the clock id hasn't been used in either clock-driver nor dts,
 so is safe to rename]
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2017-08-06 19:43:35 +02:00
Elaine Zhang
cbbd6c2f55 clk: rockchip: add more clk ids for rv1108
Add new clk ids for the peripherals on rv1108 soc.

Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
Signed-off-by: Andy Yan <andy.yan@rock-chips.com>
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2017-08-06 19:42:43 +02:00
Simon Xue
1cc47e6359 ARM: dts: rockchip: add more iommu nodes on rk3288
Add IEP/ISP/VPU/HEVC iommu nodes

Signed-off-by: Simon Xue <xxm@rock-chips.com>
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2017-08-06 12:55:07 +02:00
Tao Huang
79db45be2b ARM: dts: rockchip: convert rk3288 device tree files to 64 bits
In order to be able to use more than 4GB of RAM when the LPAE is
activated, the dts must be converted in 64 bits.

Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2017-08-06 12:54:04 +02:00
Huibin Hong
febdf63999 ARM: dts: rockchip: add spi node and spi pinctrl on rk3228/rk3229
Add spi node and spi pinctrl for rk322x

Signed-off-by: Huibin Hong <huibin.hong@rock-chips.com>
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2017-08-06 12:37:12 +02:00
Maninder Singh
4e56201321 ext4: fix copy paste error in ext4_swap_extents()
This bug was found by a static code checker tool for copy paste
problems.

Signed-off-by: Maninder Singh <maninder1.s@samsung.com>
Signed-off-by: Vaneet Narang <v.narang@samsung.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
2017-08-06 01:33:07 -04:00
Jerry Lee
aec51758ce ext4: fix overflow caused by missing cast in ext4_resize_fs()
On a 32-bit platform, the value of n_blcoks_count may be wrong during
the file system is resized to size larger than 2^32 blocks.  This may
caused the superblock being corrupted with zero blocks count.

Fixes: 1c6bd7173d
Signed-off-by: Jerry Lee <jerrylee@qnap.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Cc: stable@vger.kernel.org # 3.7+
2017-08-06 01:18:31 -04:00
Miao Xie
c03b45b853 ext4, project: expand inode extra size if possible
When upgrading from old format, try to set project id
to old file first time, it will return EOVERFLOW, but if
that file is dirtied(touch etc), changing project id will
be allowed, this might be confusing for users, we could
try to expand @i_extra_isize here too.

Reported-by: Zhang Yi <yi.zhang@huawei.com>
Signed-off-by: Miao Xie <miaoxie@huawei.com>
Signed-off-by: Wang Shilong <wshilong@ddn.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
2017-08-06 01:00:49 -04:00
Miao Xie
b640b2c51b ext4: cleanup ext4_expand_extra_isize_ea()
Clean up some goto statement, make ext4_expand_extra_isize_ea() clearer.

Signed-off-by: Miao Xie <miaoxie@huawei.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Reviewed-by: Wang Shilong <wshilong@ddn.com>
2017-08-06 00:55:48 -04:00
Miao Xie
cf0a5e818f ext4: restructure ext4_expand_extra_isize
Current ext4_expand_extra_isize just tries to expand extra isize, if
someone is holding xattr lock or some check fails, it will give up.
So rename its name to ext4_try_to_expand_extra_isize.

Besides that, we clean up unnecessary check and move some relative checks
into it.

Signed-off-by: Miao Xie <miaoxie@huawei.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Reviewed-by: Wang Shilong <wshilong@ddn.com>
2017-08-06 00:40:01 -04:00
Miao Xie
3b10fdc6d8 ext4: fix forgetten xattr lock protection in ext4_expand_extra_isize
We should avoid the contention between the i_extra_isize update and
the inline data insertion, so move the xattr trylock in front of
i_extra_isize update.

Signed-off-by: Miao Xie <miaoxie@huawei.com>
Reviewed-by: Wang Shilong <wshilong@ddn.com>
2017-08-06 00:27:38 -04:00
Tahsin Erdogan
9699d4f91d ext4: make xattr inode reads faster
ext4_xattr_inode_read() currently reads each block sequentially while
waiting for io operation to complete before moving on to the next
block. This prevents request merging in block layer.

Add a ext4_bread_batch() function that starts reads for all blocks
then optionally waits for them to complete. A similar logic is used
in ext4_find_entry(), so update that code to use the new function.

Signed-off-by: Tahsin Erdogan <tahsin@google.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
2017-08-06 00:07:01 -04:00
Tahsin Erdogan
ec00022030 ext4: inplace xattr block update fails to deduplicate blocks
When an xattr block has a single reference, block is updated inplace
and it is reinserted to the cache. Later, a cache lookup is performed
to see whether an existing block has the same contents. This cache
lookup will most of the time return the just inserted entry so
deduplication is not achieved.

Running the following test script will produce two xattr blocks which
can be observed in "File ACL: " line of debugfs output:

  mke2fs -b 1024 -I 128 -F -O extent /dev/sdb 1G
  mount /dev/sdb /mnt/sdb

  touch /mnt/sdb/{x,y}

  setfattr -n user.1 -v aaa /mnt/sdb/x
  setfattr -n user.2 -v bbb /mnt/sdb/x

  setfattr -n user.1 -v aaa /mnt/sdb/y
  setfattr -n user.2 -v bbb /mnt/sdb/y

  debugfs -R 'stat x' /dev/sdb | cat
  debugfs -R 'stat y' /dev/sdb | cat

This patch defers the reinsertion to the cache so that we can locate
other blocks with the same contents.

Signed-off-by: Tahsin Erdogan <tahsin@google.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Reviewed-by: Andreas Dilger <adilger@dilger.ca>
2017-08-05 22:41:42 -04:00