Commit Graph

334 Commits

Author SHA1 Message Date
Linus Torvalds
d8bfb96a2e powerpc updates for 4.9 #2
Freescale updates from Scott:
 
 "Highlights include qbman support (a prerequisite for datapath drivers
 such as ethernet), a PCI DMA fix+improvement, reset handler changes, more
 8xx optimizations, and some cleanups and fixes."
 
 Fixes:
  - selftests/powerpc: Add missing binaries to .gitignores (Michael Ellerman)
  - selftests/powerpc: Fix build break caused by EXPORT_SYMBOL changes (Michael Ellerman)
  - powerpc/pseries: Fix stack corruption in htpe code (Laurent Dufour)
  - powerpc/64s: Fix power4_fixup_nap placement (Nicholas Piggin)
  - powerpc/64: Fix incorrect return value from __copy_tofrom_user (Paul Mackerras)
  - powerpc/mm/hash64: Fix might_have_hea() check (Michael Ellerman)
 
 Other:
  - MAINTAINERS: Remove myself from PA Semi entries (Olof Johansson)
  - MAINTAINERS: Drop separate pseries entry (Michael Ellerman)
  - MAINTAINERS: Update powerpc website & add selftests (Michael Ellerman)
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1
 
 iQIcBAABAgAGBQJX/1EOAAoJEFHr6jzI4aWAu0UQAIsmnc361a4xOl1ODRzJNWSD
 OqBbuGQPZ3I3XPMxB6BBK4mnpR507nb+L1yxMDidDebJal/pRJdXkGi7I5pe9uq+
 12XJcaePtVfmrHKKWAhC/fef0gQHSusBDpIIDquN5QE1BVvUDGbynG4GjnpX9ZaT
 gmXGL03u/yJvUoUNexG7lrMAJ7bZgU8BzFKyojzWtoEDF4SM7rpWKs1hGwojW4/T
 EYcek5uTNo01UsN/WNrtBkHA8eC9unnLk9NisOxvBXu7eJfEq38Bz71fhoowFO+C
 FDRboPdkXxySzzNTBb3hROontLZS2S13upzjcrRo2/f4gxvcimRJtDzxuRKrYX5n
 xdXcZVdFSRsKanbuV0Dwjki05IU4zeOhsHUqYqaS2UD+QlAbNCu0N9DZOhPMn+H2
 8uT3cOOrBLBrhIH3e7DMK9Rx97FBeuCvwrbjnZp8My7s55VXXd2CZTFYf5/wW0b2
 VEf5eoXM1BB2zuh9kFZ785Sq5iYnsKoNhKjoXULkBrf3m7WtmjPIbHzRTJM5ltwt
 YUvFMG6nncQB0ERVOvDIXXNzwVB0JkJTVX2BBZ2a7Fr+8KHE6rTYkgcQiosibUmq
 gLV9M59MFamAgJlna3A1OmGIpEiZ3RrriYL2mgraWwuLUn/qW3yPiPE6hBk0uomL
 cARvlIjGf8rWhi+3qAb1
 =lwsd
 -----END PGP SIGNATURE-----

Merge tag 'powerpc-4.9-2' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux

Pull more powerpc updates from Michael Ellerman:
 "Some more powerpc updates for 4.9:

  Freescale updates from Scott Wood:
   - qbman support (a prerequisite for datapath drivers such as ethernet)
   - a PCI DMA fix+improvement
   - reset handler changes
   - more 8xx optimizations
   - some cleanups and fixes.'

  Fixes:
   - selftests/powerpc: Add missing binaries to .gitignores (Michael Ellerman)
   - selftests/powerpc: Fix build break caused by EXPORT_SYMBOL changes (Michael Ellerman)
   - powerpc/pseries: Fix stack corruption in htpe code (Laurent Dufour)
   - powerpc/64s: Fix power4_fixup_nap placement (Nicholas Piggin)
   - powerpc/64: Fix incorrect return value from __copy_tofrom_user (Paul Mackerras)
   - powerpc/mm/hash64: Fix might_have_hea() check (Michael Ellerman)

  Other:
   - MAINTAINERS: Remove myself from PA Semi entries (Olof Johansson)
   - MAINTAINERS: Drop separate pseries entry (Michael Ellerman)
   - MAINTAINERS: Update powerpc website & add selftests (Michael Ellerman):

* tag 'powerpc-4.9-2' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux: (35 commits)
  powerpc/mm/hash64: Fix might_have_hea() check
  powerpc/64: Fix incorrect return value from __copy_tofrom_user
  powerpc/64s: Fix power4_fixup_nap placement
  powerpc/pseries: Fix stack corruption in htpe code
  selftests/powerpc: Fix build break caused by EXPORT_SYMBOL changes
  MAINTAINERS: Update powerpc website & add selftests
  MAINTAINERS: Drop separate pseries entry
  MAINTAINERS: Remove myself from PA Semi entries
  selftests/powerpc: Add missing binaries to .gitignores
  arch/powerpc: Add CONFIG_FSL_DPAA to corenetXX_smp_defconfig
  soc/qman: Add self-test for QMan driver
  soc/bman: Add self-test for BMan driver
  soc/fsl: Introduce DPAA 1.x QMan device driver
  soc/fsl: Introduce DPAA 1.x BMan device driver
  powerpc/8xx: make user addr DTLB miss the short path
  powerpc/8xx: Move additional DTLBMiss handlers out of exception area
  powerpc/8xx: use r3 to scratch CR in ITLBmiss
  soc/fsl/qe: fix gpio save_regs functions
  powerpc/8xx: add dedicated machine check handler
  powerpc/8xx: add system_reset_exception
  ...
2016-10-14 11:07:42 -07:00
Linus Torvalds
6afd563d4b ARM: SoC driver updates for v4.9
Driver updates for ARM SoCs, including a couple of newly added drivers:
 
 - The Qualcomm external bus interface 2 (EBI2), used in some of their
   mobile phone chips for connecting flash memory, LCD displays or
   other peripherals
 
 - Secure monitor firmware for Amlogic SoCs, and an NVMEM driver for the
   EFUSE based on that firmware interface.
 
 - Perf support for the AppliedMicro X-Gene performance monitor unit
 
 - Reset driver for STMicroelectronics STM32
 
 - Reset driver for SocioNext UniPhier SoCs
 
 Aside from these, there are minor updates to SoC-specific bus,
 clocksource, firmware, pinctrl, reset, rtc and pmic drivers.
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1
 
 iQIVAwUAV/gaimCrR//JCVInAQJaOQ/6A++YfLVmdF4wxgcu/0ti28lA7SkQIGJV
 UAsfCmqMEutbeDvnloVGmTV2K2NS7mzxdxsJGbVB7Oe/zdOFN+T9sf9hAlId01QA
 oVkoagpofoxlyKoKJ/l+heuEEZMa0Ekk3XXRTGv/Ovymo7252o4tEdGu9c+gyaMJ
 KqgixcrQRzxuWDgPpHUPUez2vY1iRMvvdcb0EmfiHcIgPOEJc6MIxulsqEIrkoMz
 WYeGFIeqRJxnrur3QD8WnD+aZD6bV01wkFTkWXGWg4H87QfEESgVBu5A7TL+5sL8
 1SlX/b7S5/ZJbrOiOS2IUyvbK7NiA/Q+NunHW2rMVnUWuEvJ9HAQB1kVSQH5LIYO
 6OBokjcijm6m/j6O6fdDfvNd6PLsIEUqfWVws7O+uofMMqKPxqak4VBTRdFM+aeF
 ZtK7mEbzteCX0bnC+XblZrseAlkIehYnP80CLDbtDTerTWP4gsjxGVt3U6MO0NzB
 K0ACWZOclzrcFscNKrmP6uPCpfZriiPV/XMCEHcylA/X2iYsVmpqKzdLuNs5aeUr
 uPzQbNWu9ygg/bDRXMYY2E3Kzjsc0eIOKEOPyhLaZdSo4e1FQxud6L2V2Vj0RLB/
 iMA7/CyQZqn6Yzgs0VMZm/bnh+hIdHioGFl5K5j6Fcw9VZRkNmnEQJzX4VU5efGO
 g1+5av0vFXg=
 =GvTq
 -----END PGP SIGNATURE-----

Merge tag 'armsoc-drivers' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc

Pull ARM SoC driver updates from Arnd Bergmann:
 "Driver updates for ARM SoCs, including a couple of newly added
  drivers:

   - The Qualcomm external bus interface 2 (EBI2), used in some of their
     mobile phone chips for connecting flash memory, LCD displays or
     other peripherals

   - Secure monitor firmware for Amlogic SoCs, and an NVMEM driver for
     the EFUSE based on that firmware interface.

   - Perf support for the AppliedMicro X-Gene performance monitor unit

   - Reset driver for STMicroelectronics STM32

   - Reset driver for SocioNext UniPhier SoCs

  Aside from these, there are minor updates to SoC-specific bus,
  clocksource, firmware, pinctrl, reset, rtc and pmic drivers"

* tag 'armsoc-drivers' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (50 commits)
  bus: qcom-ebi2: depend on HAS_IOMEM
  pinctrl: mvebu: orion5x: Generalise mv88f5181l support for 88f5181
  clk: mvebu: Add clk support for the orion5x SoC mv88f5181
  dt-bindings: EXYNOS: Add Exynos5433 PMU compatible
  clocksource: exynos_mct: Add the support for ARM64
  perf: xgene: Add APM X-Gene SoC Performance Monitoring Unit driver
  Documentation: Add documentation for APM X-Gene SoC PMU DTS binding
  MAINTAINERS: Add entry for APM X-Gene SoC PMU driver
  bus: qcom: add EBI2 driver
  bus: qcom: add EBI2 device tree bindings
  rtc: rtc-pm8xxx: Add support for pm8018 rtc
  nvmem: amlogic: Add Amlogic Meson EFUSE driver
  firmware: Amlogic: Add secure monitor driver
  soc: qcom: smd: Reset rx tail rather than tx
  memory: atmel-sdramc: fix a possible NULL dereference
  reset: hi6220: allow to compile test driver on other architectures
  reset: zynq: add driver Kconfig option
  reset: sunxi: add driver Kconfig option
  reset: stm32: add driver Kconfig option
  reset: socfpga: add driver Kconfig option
  ...
2016-10-07 21:23:40 -07:00
Claudiu Manoil
e0b80f00bb arch/powerpc: Add CONFIG_FSL_DPAA to corenetXX_smp_defconfig
Enable the drivers on the powerpc arch.

Signed-off-by: Roy Pledge <roy.pledge@nxp.com>
Signed-off-by: Claudiu Manoil <claudiu.manoil@nxp.com>
Signed-off-by: Scott Wood <oss@buserror.net>
2016-09-25 02:39:01 -05:00
Claudiu Manoil
de77562339 soc/qman: Add self-test for QMan driver
Add self tests for the DPAA 1.x Queue Manager driver. The tests
ensure that the driver can properly enqueue and dequeue to/from
frame queues using the QMan portal infrastructure.

Signed-off-by: Roy Pledge <roy.pledge@nxp.com>
Signed-off-by: Claudiu Manoil <claudiu.manoil@nxp.com>
Signed-off-by: Scott Wood <oss@buserror.net>
2016-09-25 02:39:00 -05:00
Claudiu Manoil
97e0d385b1 soc/bman: Add self-test for BMan driver
Add a self test for the DPAA 1.x Buffer Manager driver. This
test ensures that the driver can properly acquire and release
buffers using the BMan portal infrastructure.

Signed-off-by: Roy Pledge <roy.pledge@nxp.com>
Signed-off-by: Claudiu Manoil <claudiu.manoil@nxp.com>
Signed-off-by: Scott Wood <oss@buserror.net>
2016-09-25 02:38:59 -05:00
Claudiu Manoil
c535e923bb soc/fsl: Introduce DPAA 1.x QMan device driver
This driver enables the Freescale DPAA 1.x Queue Manager block.
QMan is a hardware accelerator that manages frame queues.  It allows
CPUs and other accelerators connected to the SoC datapath to enqueue
and dequeue ethernet frames, thus providing the infrastructure for
data exchange among CPUs and datapath accelerators.

Signed-off-by: Roy Pledge <roy.pledge@nxp.com>
Signed-off-by: Claudiu Manoil <claudiu.manoil@nxp.com>
Signed-off-by: Scott Wood <oss@buserror.net>
2016-09-25 02:38:59 -05:00
Claudiu Manoil
1f9c0a7727 soc/fsl: Introduce DPAA 1.x BMan device driver
This driver enables the Freescale DPAA 1.x Buffer Manager block.
BMan is a hardware accelerator that manages buffer pools.  It allows
CPUs and other accelerators connected to the SoC datapath to acquire
and release buffers during data processing.

Signed-off-by: Roy Pledge <roy.pledge@nxp.com>
Signed-off-by: Claudiu Manoil <claudiu.manoil@nxp.com>
Signed-off-by: Scott Wood <oss@buserror.net>
2016-09-25 02:38:58 -05:00
Christophe Leroy
5dc6f3fede soc/fsl/qe: fix gpio save_regs functions
of_mm_gpiochip_add_data() calls mm_gc->save_regs() before
setting the data. Therefore ->save_regs() cannot use
gpiochip_get_data()

An Oops is encountered without this fix.

fixes: 1e714e54b5 ("powerpc: qe_lib-gpio: use gpiochip data pointer")
Signed-off-by: Christophe Leroy <christophe.leroy@c-s.fr>
Cc: <stable@vger.kernel.org>
Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Scott Wood <oss@buserror.net>
2016-09-25 02:38:56 -05:00
Christophe Leroy
4d486e0083 soc/fsl/qe: fix Oops on CPM1 (and likely CPM2)
Commit 0e6e01ff69 ("CPM/QE: use genalloc to manage CPM/QE muram")
has changed the way muram is managed.
genalloc uses kmalloc(), hence requires the SLAB to be up and running.

On powerpc 8xx, cpm_reset() is called early during startup.
cpm_reset() then calls cpm_muram_init() before SLAB is available,
hence the following Oops.

cpm_reset() cannot be called during initcalls because the CPM is
needed for console.

This patch removes the call to cpm_muram_init() from cpm_reset().
cpm_muram_init() will be called from a new function called cpm_init()
which is declared as subsys_initcall, unless cpm_muram_alloc() is
called earlier for the serial console in which case cpm_muram_init()
will be called from there.

The reason for calling it from two places is that some drivers
(e.g. i2c-cpm) need some of the initialisations done by
cpm_muram_init() but don't call cpm_muram_alloc(). The console
driver calls cpm_muram_alloc() but some platforms might not use
the CPM serial ports for console.

[    0.000000] Unable to handle kernel paging request for data at address 0x00000008
[    0.000000] Faulting instruction address: 0xc01acce0
[    0.000000] Oops: Kernel access of bad area, sig: 11 [#1]
[    0.000000] PREEMPT CMPC885
[    0.000000] CPU: 0 PID: 0 Comm: swapper Not tainted 4.4.14-g0886ed8 #5
[    0.000000] task: c05183e0 ti: c0536000 task.ti: c0536000
[    0.000000] NIP: c01acce0 LR: c0011068 CTR: 00000000
[    0.000000] REGS: c0537e50 TRAP: 0300   Not tainted (4.4.14-s3k-dev-g0886ed8-svn)
[    0.000000] MSR: 00001032 <ME,IR,DR,RI>  CR: 28044428  XER: 00000000
[    0.000000] DAR: 00000008 DSISR: c0000000
GPR00: c0011068 c0537f00 c05183e0 00000000 00009000 ffffffff 00000bc0 ffffffff
GPR08: ff003000 ff00b000 ff003bbf 00000000 22044422 100d43a8 00000000 07ff94e8
GPR16: 00000000 07bb5d70 00000000 07ff81f4 07ff81f4 07ff81f4 00000000 00000000
GPR24: 07ffb3a0 07fe7628 c0550000 c7ffa190 c0540000 ff003bbf 00000000 00000001
[    0.000000] NIP [c01acce0] gen_pool_add_virt+0x14/0xdc
[    0.000000] LR [c0011068] cpm_muram_init+0xd4/0x18c
[    0.000000] Call Trace:
[    0.000000] [c0537f00] [00000200] 0x200 (unreliable)
[    0.000000] [c0537f20] [c0011068] cpm_muram_init+0xd4/0x18c
[    0.000000] [c0537f70] [c0494684] cpm_reset+0xb4/0xc8
[    0.000000] [c0537f90] [c0494c64] cmpc885_setup_arch+0x10/0x30
[    0.000000] [c0537fa0] [c0493cd4] setup_arch+0x130/0x168
[    0.000000] [c0537fb0] [c04906bc] start_kernel+0x88/0x380
[    0.000000] [c0537ff0] [c0002224] start_here+0x38/0x98
[    0.000000] Instruction dump:
[    0.000000] 91430010 91430014 80010014 83e1000c 7c0803a6 38210010 4e800020 7c0802a6
[    0.000000] 9421ffe0 bf61000c 90010024 7c7e1b78 <80630008> 7c9c2378 7cc31c30 3863001f
[    0.000000] ---[ end trace dc8fa200cb88537f ]---

fixes: 0e6e01ff69 ("CPM/QE: use genalloc to manage CPM/QE muram")
Cc: stable@vger.linux.org
Signed-off-by: Christophe Leroy <christophe.leroy@c-s.fr>
[scottwood: Removed some string changes unrelated to bugfix]
Signed-off-by: Scott Wood <oss@buserror.net>
2016-09-25 02:38:52 -05:00
Julia Lawall
74c269f69c fsl/qe: use of_property_read_bool
Use of_property_read_bool to check for the existence of a property.

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

// <smpl>
@@
expression e1,e2;
statement S2,S1;
@@
-       if (of_get_property(e1,e2,NULL))
+       if (of_property_read_bool(e1,e2))
        S1 else S2
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Scott Wood <oss@buserror.net>
2016-09-25 02:38:51 -05:00
Zhao Qiang
5066943a51 soc/fsl/qe: Use of_adress_to_resource() in get_qe_base()
modify get_qe_base function with of_address_to_resource
instead of of_get_property and of_translate_address.

Signed-off-by: Zhao Qiang <qiang.zhao@nxp.com>
Signed-off-by: Scott Wood <oss@buserror.net>
2016-09-24 23:01:17 -05:00
Vaishali Thakkar
40f1ebd4e0 soc/fsl/qe: Use resource_size
Use the function resource_size instead of explicit computation.

Problem found using Coccinelle.

Signed-off-by: Vaishali Thakkar <vaishali.thakkar@oracle.com>
Signed-off-by: Scott Wood <oss@buserror.net>
2016-09-24 22:46:55 -05:00
Arnd Bergmann
70e0588355 - extent the waiting time of the pmic wrapper to 10 ms which
reduces the failure rate on the data transfer between pmic and
 pmic wrapper.
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v2
 
 iQIcBAABAgAGBQJX1stkAAoJELQ5Ylss8dND49UP/jP+fQvV7jEVXc+FQHTclOLo
 y+pjhtxLvE2nCN0rKdc1UPPH+Vr6ZpLqHaNe/1UQ4xmhZNmowwHpkjsFi2Xf9q0b
 T10cObpY58U3LSFo9w2aSguMQyDWQG0TWdOg5ppKKZ4xOUXrGJQvLp0AiE1U3YQ9
 g9rHKy77+G0vQaUHxAyrwQoewgiB0qzoZp65lEaOdP9A2WbF6sPrgopKcGPz1lhD
 bTaB8wlvhGUmiegBuKyenTSLrTlNpmQI05gBUQ1irfTaksmLm+cn8Rmf1NHAWqdf
 nikrgeW+uRFA38GE+FccBxNRgj58jhQEKXm9da2nanWTSXugXGOC+CvGTewy92Di
 VwXPlN546/vPYKjUvf4zgqhrSsTnGHKvY2B33lq+6QN5rcD8yrHBezk3xRBjjf7E
 96I+ipVnkrOIJd9l6vMGAGG4eSEHxNDevbNhpVzNLTNIr9e9wSe/WlKUXrFbCE5A
 TUzo+LmmnGWdZEyK+/EUPpMC7xMXfpZqNyhwU1kIE2U6n6Z/kLcJPmN2N8g5TH3a
 Fe4PGzntjiFgMIH6t2ryUcfxhEG9dH/WmzZAMB6h0I7kMYPE6dImsfzp2/E6GZPI
 FC9xp8oTtvMe1PuMKi5JVGovcrtmqrKyY8TS/I5HetcNpv4gEQZY5vB4x437Egy8
 ZpV36tQeffLcpEYcaM2D
 =qdYG
 -----END PGP SIGNATURE-----

Merge tag 'v4.8-next-soc' of https://github.com/mbgg/linux-mediatek into next/drivers

Pull "ARM: mediatek: soc updates for v4.9" from Matthias Brugger:

extent the waiting time of the pmic wrapper to 10 ms which
reduces the failure rate on the data transfer between pmic and
pmic wrapper.

* tag 'v4.8-next-soc' of https://github.com/mbgg/linux-mediatek:
  soc: mediatek: PMIC wrap: Extend the waiting time to 10ms.
2016-09-19 10:52:43 +02:00
Arnd Bergmann
bdfb3af1b3 soc/tegra: Changes for v4.9-rc1
This contains a single patch to fix an issue with setting the deep power
 down mode of I/O rails.
 -----BEGIN PGP SIGNATURE-----
 
 iQIwBAABCAAaBQJX0tDXExx0cmVkaW5nQG52aWRpYS5jb20ACgkQ3SOs138+s6E2
 Fw/+PM0dk1O9b4jlb1m8aRfBaYFUhTpVZizedZW2xSX1n/Y9SJoqkMcASxKEeqAm
 kECoCCeJkuKWozeEffJ79ewiLvmqjWg+LLEsKrIklKZJKlzcsSV3ooUkTdOtDZUr
 l4YMWRneJ2md6rK3/jcZj9S3SdLyn3R6Pwh6DzJge/4+yyhjQ+axVJiUNOU/D345
 yLZr4ErzixHg/a968CfnoLu9+3Tetlc41+VqoUQWurLqNXKu2ehi/t63Oceii/uy
 DhjKYOxtwXQlB46E9vJ5qWhc6gYc32Kwg7BAjCKte00T24r0obOivSz6n1dV9a5k
 wQcQP6zZGEMFFcgJI0+ytBrIE3V24go7RIotTathbvKBCNLkgyVlkrT7uhoP7kH4
 z4cgoo489/HYGd1BLF7FkmobSH8mAFvjYv43LjmObi/5w1r+MDqDQQqHTkrJ5GT0
 WMzb51AZY7Xohu+nP5o9k2+RBUXjamJCT0sfjKK1rVCid0Z0ddWRuV9uuKs6evJT
 47EFQxQzDzMuWkcZX/FcO3WrT4+7k1mXn6Cj0HNaITBIwYNWKa38HRNJJD8mxyS7
 fTev9l+ymP2kW07F1zH+eO6tzGir+48a0iWLDAPN2KZBuDazbHezomoifNURCfat
 TCQtV7260e0+ZZJ3+S1O75vTk3femXmzkHTAETbVrcySgQM=
 =IFfY
 -----END PGP SIGNATURE-----

Merge tag 'tegra-for-4.9-soc' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux into next/drivers

Pull "soc/tegra: Changes for v4.9-rc1" from Thierry Reding:

This contains a single patch to fix an issue with setting the deep power
down mode of I/O rails.

* tag 'tegra-for-4.9-soc' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux:
  soc/tegra: pmc: Fix incorrect DPD request
2016-09-15 00:41:12 +02:00
Arnd Bergmann
fceec41b68 Qualcomm ARM Based Driver Updates for v4.9
* Silence smem probe defer messages
 * Make scm explicitly non-modular
 * Assorted SMD bug fixes and minor changes
 * Add PM8018 RTC support
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1
 
 iQIcBAABAgAGBQJXycjdAAoJEFKiBbHx2RXVVJAQAMZigw99xIh0vIlgQbquq3NF
 ih5HBow+yq+y744Zn9FJQvmPzGzPaoxTuvcvAh8M8qqoKpocolblEkcCgdgR62YK
 vKDHf8ZwTsR1t37jP35oUWE4xMNyHX5HFfDu267dwjzOpsFDYATotThTdp/T1muz
 uOWkmugrRGi04EfkVkX28uBEmvBmxDIAOrPclPifgYxpFlJ2d0/sC2SDtXwPR/Kk
 /Qb9aK659WUaqU2q0BmHKU2cgvo7oKa14vcriMgjU7jmzYKtvQrGmqt0YvCS320I
 XpYm4pDffG1HlOyz5a3KBakBzQRN24wQCXaSvVrY99B2/nLZtdVDnX29tw9mUioU
 GhfXanDMehgf4XJRwjhMsxiAYbSKEbaD5Rpr6rHebhPOVv8G4Yo36o4Q7yUr3Rpz
 pwFJdBMqA3S3roV318u0bgDjr4YjkYH7rRh1E8yjV7GFb9cMK0NPvfP8d/5l64Fk
 DE62Xl0eBmaHDd+gpousEAzZpIUp/TrTuGr0jhgLZbY+JMLHDlgiP8IZNx/EiZY4
 PMN2xUFaqKVPw+OzWg4Weg6OirInpzOfvjaxyb10yQIaDb+FYJGrDcZjjKsf4MPS
 vlKjzC9GbfPa/XI5iq+ULGtF6T6g8Nv29pUdXb75oH6vOhca8wWSAvhscP151N79
 /G13oF2ivpj+kvdLLfaX
 =yt6n
 -----END PGP SIGNATURE-----

Merge tag 'qcom-drivers-for-4.9' of git://git.kernel.org/pub/scm/linux/kernel/git/agross/linux into next/drivers

Pull "Qualcomm ARM Based Driver Updates for v4.9" from Andy Gross:

* Silence smem probe defer messages
* Make scm explicitly non-modular
* Assorted SMD bug fixes and minor changes
* Add PM8018 RTC support

* tag 'qcom-drivers-for-4.9' of git://git.kernel.org/pub/scm/linux/kernel/git/agross/linux:
  rtc: rtc-pm8xxx: Add support for pm8018 rtc
  soc: qcom: smd: Reset rx tail rather than tx
  soc: qcom: smd: Represent smd edges as devices
  soc: qcom: smd: Request irqs after parsing properties
  soc: qcom: smd: Simplify multi channel handling
  soc: qcom: smd: Correct compile stub prototypes
  firmware: qcom_scm: make it explicitly non-modular
  soc: qcom: smem: Silence probe defer error
2016-09-15 00:18:56 +02:00
Jon Hunter
8d68c3713a ARM: EXYNOS: Remove calls to of_genpd_get_from_provider()
Update the EXYNOS PM domain code to use the of_genpd_add_subdomain()
and remove any calls to of_genpd_get_from_provider().

Signed-off-by: Jon Hunter <jonathanh@nvidia.com>
Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
Acked-by: Ulf Hansson <ulf.hansson@linaro.org>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
2016-09-13 02:49:33 +02:00
Bjorn Andersson
4e21a95d7f soc: qcom: smd: Reset rx tail rather than tx
The local end of each SMD channel is responsible for updating the tx
head and the rx tail, as such we should not touch the tx tail during a
reset.

Reported-by: Jeremy McNicoll <jmcnicol@redhat.com>
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
Signed-off-by: Andy Gross <andy.gross@linaro.org>
2016-09-01 14:19:50 -05:00
Bjorn Andersson
da0573026c soc: qcom: smd: Represent smd edges as devices
By representing each edge as its own device the channels are no longer
tied to being parented by the same smd device and as such an edge can
live as children of e.g. remoteproc instances.

Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
Signed-off-by: Andy Gross <andy.gross@linaro.org>
2016-08-23 15:46:33 -05:00
Bjorn Andersson
381a0b4ce4 soc: qcom: smd: Request irqs after parsing properties
The code exectued by the interrupt handler depends on the values parsed
after requesting the irq, just to be save we should therefor move the
request_irq() call to be done after parsing the properties.

Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
Signed-off-by: Andy Gross <andy.gross@linaro.org>
2016-08-23 15:46:33 -05:00
Bjorn Andersson
0a0c08cae0 soc: qcom: smd: Simplify multi channel handling
Multi-channel clients split between several drivers need a way to close
individual channels, as these drivers might be removed individually.
With this in place the responsibility of closing additionally opened
channels to the client as well only concerning smd about the primary
channel.

With this approach we will only trigger removal of SMD devices based on
the state of the primary channel, however we get in sync with how rpmsg
works.

Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
Signed-off-by: Andy Gross <andy.gross@linaro.org>
2016-08-23 15:46:32 -05:00
Stephen Boyd
951a5af922 soc: qcom: smem: Silence probe defer error
If we fail to get the hwspinlock due to probe defer, we shouldn't
print an error message. Just be silent in this case.

Cc: Bjorn Andersson <bjorn.andersson@linaro.org>
Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
Reviewed-by: Bjorn Andersson <bjorn.andersson@linaro.org>
Signed-off-by: Andy Gross <andy.gross@linaro.org>
2016-08-23 15:46:32 -05:00
Henry Chen
e180f887ba soc: mediatek: PMIC wrap: Extend the waiting time to 10ms.
Read data fails sometimes because of a timeout that PMIC cannot transfer data
to PMIC wrap on time, extend the waiting time to 10ms to reduce the failed
rate.

Signed-off-by: Henry Chen <henryc.chen@mediatek.com>
Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com>
2016-08-22 19:31:36 +02:00
Elaine Zhang
6f27ab3e42 soc: rockchip: support active_wakeup for rockchip power-domains
Register gpd_dev_ops.active_wakeup function to support keep power
during suspend state. And add flag to each power domain to
decide whether keep power during suspend or not.

Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2016-08-19 00:37:20 +02:00
Vince Hsu
a9ccc123a8 soc/tegra: pmc: Fix incorrect DPD request
Reading the DPD_REQ & DPD2_REQ registers returns the previous requests.
If we sets the current request bit with the returned value, then other
pads will be turned on or off unexpectedly.

Signed-off-by: Vince Hsu <vinceh@nvidia.com>
Reviewed-by: Jon Hunter <jonathanh@nvidia.com>
Signed-off-by: Thierry Reding <treding@nvidia.com>
2016-08-16 12:30:52 +02:00
Linus Torvalds
43a0a98aa8 ARM: SoC driver updates for v4.8
Driver updates for ARM SoCs.
 
 A slew of changes this release cycle. The reset driver tree, that we merge
 through arm-soc for historical reasons, is also sizable this time around.
 
 Among the changes:
 
  - clps711x: Treewide changes to compatible strings, merged here for simplicity.
  - Qualcomm: SCM firmware driver cleanups, move to platform driver
  - ux500: Major cleanups, removal of old mach-specific infrastructure.
  - Atmel external bus memory driver
  - Move of brcmstb platform to the rest of bcm
  - PMC driver updates for tegra, various fixes and improvements
  - Samsung platform driver updates to support 64-bit Exynos platforms
  - Reset controller cleanups moving to devm_reset_controller_register() APIs
  - Reset controller driver for Amlogic Meson
  - Reset controller driver for Hisilicon hi6220
  - ARM SCPI power domain support
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1
 
 iQIcBAABAgAGBQJXnm1XAAoJEIwa5zzehBx35lcP/ApuQarIXeZCQZtjlUBV9McW
 o3o7FhKFHePmEPeoYCvVeK5D8NykTkQv3WpnCknoxPJzxGJF7jbPWQJcVnXfKOXD
 kTcyIK15WL2HHtSE3lYyLfyUPz8AbJyRt0l0cxgcg6jvo+uzlWooNz1y78rLIYzg
 UwRssj7OiHv4dsyYRHZIsjnB8gMWw8rYMk154gP2xy6MnNXXzzOVVnOiVqxSZBm+
 EgIIcROMOqkkHuFlClMYKluIgrmgz1Ypjf+FuAg7dqXZd+TGRrmGXeI7SkGThfLu
 nyvY3N18NViNu7xOUkI9zg7+ifyYM8Si9ylalSICSJdIAxZfiwFqFaLJvVWKU1rY
 rBOBjKckQI0/X9WYusFNFHcijhIFV8/FgGAnVRRMPdvlCss7Zp03C9mR4AEhmKMX
 rLG49x81hU1C+LftC59ml3iB8dhZrrRkbxNHjLFHVGWNrKMrmJKa8JhXGRAoNM+u
 LRauiuJZatqvLfISNvpfcoW2EashVoU3f+uC8ymT3QCyME3wZm0t7T4tllxhMfBl
 sOgJqNkTKDmPLofwm/dASiLML7ZF1WePScrFyOACnj9K4mUD+OaCnowtWoQPu0eI
 aNmT84oosJ2S9F/iUDPtFHXdzQ+1QPPfSiQ9FXMoauciVq/2F+pqq68yYgqoxFOG
 vmkmG2YM4Wyq43u0BONR
 =O8+y
 -----END PGP SIGNATURE-----

Merge tag 'armsoc-drivers' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc

Pull ARM SoC driver updates from Olof Johansson:
 "Driver updates for ARM SoCs.

  A slew of changes this release cycle.  The reset driver tree, that we
  merge through arm-soc for historical reasons, is also sizable this
  time around.

  Among the changes:

   - clps711x: Treewide changes to compatible strings, merged here for simplicity.
   - Qualcomm: SCM firmware driver cleanups, move to platform driver
   - ux500: Major cleanups, removal of old mach-specific infrastructure.
   - Atmel external bus memory driver
   - Move of brcmstb platform to the rest of bcm
   - PMC driver updates for tegra, various fixes and improvements
   - Samsung platform driver updates to support 64-bit Exynos platforms
   - Reset controller cleanups moving to devm_reset_controller_register() APIs
   - Reset controller driver for Amlogic Meson
   - Reset controller driver for Hisilicon hi6220
   - ARM SCPI power domain support"

* tag 'armsoc-drivers' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (100 commits)
  ARM: ux500: consolidate base platform files
  ARM: ux500: move soc_id driver to drivers/soc
  ARM: ux500: call ux500_setup_id later
  ARM: ux500: consolidate soc_device code in id.c
  ARM: ux500: remove cpu_is_u* helpers
  ARM: ux500: use CLK_OF_DECLARE()
  ARM: ux500: move l2x0 init to .init_irq
  mfd: db8500 stop passing around platform data
  ASoC: ab8500-codec: remove platform data based probe
  ARM: ux500: move ab8500_regulator_plat_data into driver
  ARM: ux500: remove unused regulator data
  soc: raspberrypi-power: add CONFIG_OF dependency
  firmware: scpi: add CONFIG_OF dependency
  video: clps711x-fb: Changing the compatibility string to match with the smallest supported chip
  input: clps711x-keypad: Changing the compatibility string to match with the smallest supported chip
  pwm: clps711x: Changing the compatibility string to match with the smallest supported chip
  serial: clps711x: Changing the compatibility string to match with the smallest supported chip
  irqchip: clps711x: Changing the compatibility string to match with the smallest supported chip
  clocksource: clps711x: Changing the compatibility string to match with the smallest supported chip
  clk: clps711x: Changing the compatibility string to match with the smallest supported chip
  ...
2016-08-01 18:36:01 -04:00
Linus Torvalds
fbae5cbb43 ARM: SoC platform updates for v4.8
Improved and new platform support for various SoCs:
 
  - New SoC support:
    - Broadcom BCM23550
    - Freescale i.MX7Solo
    - Qualcomm MDM9615
    - Renesas r8a7792
  - Conversion of clps711x to multiplatform
  - debug uart improvements for Atmel platforms
  - Tango platform improvements: HOTPLUG_CPU, Suspend-to-ram
  - OMAP tweaks and improvements to hwmod
  - OMAP support for kexec on SMP
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1
 
 iQIcBAABAgAGBQJXnaibAAoJEIwa5zzehBx3h6AP/0TBATiDuYXTcX3V8zZ/ia9y
 7dWbP7gVX7DN39b5qdjLTa+DUx3Y3msxW9qsuUQR8RWijbqjCH7b/fyPwGA0fmpP
 3uZpFpyzs+6/3TiMDN1yw1T+/2YbVyM+4rOeNsCwncdXjGSx0FaMJAqLBrppiWLH
 1S9HhD/314znibl8skOy8QIDWwlW011sS2mNUIN+JelvnS/VDjtCDfpphpNrAQF9
 MZB6LhT9itvf6mIEGIsaDq/Ii7fgIAnA9WCtwv9tJkAZHzbS0cWkiJzb7hF1GzFO
 Q5HBAyzn+CkeTQ3+9NQU0G0vhfa3Ea0g1gfw6qRmAw+z8Qdiamjh8SSve6zm1fE8
 GmIewsMAWWIUYykEIi9hbWCTYq06Pw/Nn6KWRAuQ/lpt++jzMQ82qk6cxELLW15e
 uAC1JjFOCIFNBZhkrdQDU0qx6Ew/AUH4wCYqu4Xh7pW0MHu0V9NgsmooeoTmCkpd
 WtgKp8Wh5dsK3SdsbTjdR/IeHSQkeSdgNY/6TBTjpRwCIlEMwHlKbvwvRExk1xzi
 nLQJsR49MsjeSdPflzO6WUzOjJhQfuw2jCtAQjlom15EgkEZ569MT4RsAQIgvNCI
 PeUWkvIW1uCtW7Y6ADPRBKMIrajPs8YW4E/xTItuhrqLHp8z6efvRmVNdpzqBTVj
 tT2t2bRXF0cGiUvOeU7U
 =Kh9P
 -----END PGP SIGNATURE-----

Merge tag 'armsoc-soc' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc

Pull ARM SoC platform updates from Olof Johansson:
 "Improved and new platform support for various SoCs:

  New SoC support:
   - Broadcom BCM23550
   - Freescale i.MX7Solo
   - Qualcomm MDM9615
   - Renesas r8a7792

  Improvements:
   - convert clps711x to multiplatform
   - debug uart improvements for Atmel platforms
   - Tango platform improvements: HOTPLUG_CPU, Suspend-to-ram
   - OMAP tweaks and improvements to hwmod
   - OMAP support for kexec on SMP"

* tag 'armsoc-soc' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (109 commits)
  ARM: davinci: fix build break because of undeclared dm365_evm_snd_data
  ARM: s3c64xx: smartq: Avoid sparse warnings
  ARM: sti: Implement dummy L2 cache's write_sec
  ARM: STi: Update machine _namestr to be more generic.
  arm: meson: explicitly select clk drivers
  ARM: tango: add Suspend-to-RAM support
  ARM: hisi: consolidate the hisilicon machine entries
  ARM: tango: fix CONFIG_HOTPLUG_CPU=n build
  MAINTAINERS: Update BCM281XX/BCM11XXX/BCM216XX entry
  MAINTAINERS: Update BCM63XX entry
  MAINTAINERS: Add NS2 entry
  MAINTAINERS: Fix nsp false-positives
  MAINTAINERS: Change L to M for Broadcom ARM/ARM64 SoC entries
  ARM: debug: Enable DEBUG_BCM_5301X for Northstar Plus SoCs
  ARM: clps711x: Switch to MULTIPLATFORM
  ARM: clps711x: Remove boards support
  ARM: clps711x: Add basic DT support
  ARM: clps711x: Reduce static map size
  ARM: SAMSUNG: Constify iomem address passed to s5p_init_cpu
  ARM: oxnas: Change OX810SE default driver config
  ...
2016-08-01 18:27:08 -04:00
Arnd Bergmann
f8c6d88b2c Samsung drivers/soc update for v4.8, part 3
1. Fix size of allocation for Exynos SROM registers (too much was allocated).
 2. Constify fix.
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1
 
 iQIcBAABAgAGBQJXg8EAAAoJEME3ZuaGi4PXH2kP/im4hf/QbZ6+CCjAJilbg9kn
 QcvWdSQorhSPXo8WlbV1cM7RIEsZSs/GIEILEmK+CdGaFcFzzGugB96BceQR0Pkw
 HQY8QbVn2YduvePYa5LXafKNEsZKRwrRknhJw0WYDbrXGaDXfWURpZVNedz7w3CS
 DJDzVEw7JSYjhpeWOqg7fY9T5mZwInZhBhSJZ9FHTk3URioEX7dY+jBzLlQqfzdZ
 KFEhYFY3lOHcSw6ye0Lr+PJra+F5m5kplac4WlhxAsm0v5Kr9MuT1f9tPVDpWxDX
 jYIJfpD86RFwiJD39HxfJYHmfZ5sdTGVsWKRVP/3xjoTiUhxC1Takyeu3Uc0Mb45
 IjgAZA0QPJoilKBAusRHq8rsc0aZkCcfu7RWQHtsXpUxaHXnUcT0s/498t74Lerg
 WiSXl7HdkOkKckxHbLuB4h/FTWVZfGSHp5XM6cH/bJjwgXvzl7xol/B4bwQE6h8k
 irn5SyDAAeOIvuiLgi59k9iTZpPbXwfVwWrTGSCUNavOOV5yggZqJTEsO0iqBbwc
 m7B8L+tuu/DLqADHeZ+FRMfhqiWNJEZ9RMn8DaL0I+hhTesKBh8DPKCUoN1mrhb8
 AkaHSB6Xdm0Uu9AlDUAPgbaTCAEr2ur8dQS7QQLHv3jnJ53B0W2ylDRFy5L2Gp96
 5k51J/uD3dGZpJjbpdOt
 =7gEy
 -----END PGP SIGNATURE-----

Merge tag 'samsung-drivers-4.8-3' of git://git.kernel.org/pub/scm/linux/kernel/git/krzk/linux into next/drivers

Merge "Samsung drivers/soc update for v4.8, part 3" into next/drivers:

1. Fix size of allocation for Exynos SROM registers (too much was allocated).
2. Constify fix.

* tag 'samsung-drivers-4.8-3' of git://git.kernel.org/pub/scm/linux/kernel/git/krzk/linux:
  soc: samsung: pmu: Constify arrays with PMU data
  memory: samsung: exynos-srom: Fix wrong count of registers
2016-07-14 15:26:44 +02:00
Arnd Bergmann
f1844aca29 This is a set of cleanups for the Ux500 that reduce the number
of machine-local files and boardfile-type data for regulators
 and ASoC.
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1
 
 iQIcBAABAgAGBQJXhLdvAAoJEEEQszewGV1znkoQAMJy4s/VnTrhL5PdMdYu/Zr6
 rLr1EyQDJZTErmGnmRnlKoLfsxTs6of4Yka2nKJJJO13FMy4eHyHHi7Wbc+WHfbO
 oYEOQSK2y44niXBhSCm0P34CrMRSJuoh0LbnFyZfCcVgwYbyyklkwok4crIxkq3b
 bQg+/lA8pal2tM7Y7hC/f2u54Qi6jqPrEfzZc01PnbfS64Joiup8se5+CHTHwSeT
 v3nQy8TlQFJR9Suq0D8BxPZnBIHkTIJJkzQOc8Rzg7YNqq2WsXn3JZRaK0yYn/Vg
 E1BOjCypVSxSIkx46hUjCv+9xoWRfIvbJZXwYk1VYzw2vUvn9WAMJEhwWDdReJ//
 PpehqKG7yn2VYCBt0WF67CZC3AIYRPyfIbG3q4pKfn80/apAHkjJXO7QupHZdWsT
 QGxe/vGHjhXW+m8ptoePuIynBf4GJhN8TYbzoR9jptAgkl9/CgQmD0FQjMmrJHFo
 REeTvvddPsA5wQdbFRnmlRm9CPUaU6dGx9UwEIHs79pjR7IzWGf+wRxdJg3x28Z/
 Y6SVQkCcUoT1AX67XpEP2QgUo+wzUM5IObcjur+io8nLKQ1h9WfmBKZCZ3UIp8Uf
 incRtLP6UvLWcbLCHGy0pGlZ/4OFFyDDW7I9t1prHBCuIOmh18pWuzkJsXZUoRXQ
 FiVEOb7mF7lCTrgh65aR
 =VLJl
 -----END PGP SIGNATURE-----

Merge tag 'ux500-cleanup-bundle' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-stericsson into next/drivers

Merge "Ux500 cleanups from Arnd" from Linus Walleij:

This is a set of cleanups for the Ux500 that reduce the number
of machine-local files and boardfile-type data for regulators
and ASoC.

* tag 'ux500-cleanup-bundle' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-stericsson:
  ARM: ux500: consolidate base platform files
  ARM: ux500: move soc_id driver to drivers/soc
  ARM: ux500: call ux500_setup_id later
  ARM: ux500: consolidate soc_device code in id.c
  ARM: ux500: remove cpu_is_u* helpers
  ARM: ux500: use CLK_OF_DECLARE()
  ARM: ux500: move l2x0 init to .init_irq
  mfd: db8500 stop passing around platform data
  ASoC: ab8500-codec: remove platform data based probe
  ARM: ux500: move ab8500_regulator_plat_data into driver
  ARM: ux500: remove unused regulator data
2016-07-14 15:23:19 +02:00
Arnd Bergmann
18a9927878 ARM: ux500: move soc_id driver to drivers/soc
As the ux500 id code is basically a standalone driver, we can move it
out of the arch code into drivers/soc/ux500.

This is a user-visible change, as it moves all the devices in sysfs
from /sys/devices/soc0/ to /sys/devices/ and leaves the soc0 node as a
separate device.

Originally the idea was to put all on-chip devices under the soc node,
and ux500 was the first platform to have this device, but later platforms
almost all didn't follow that pattern, so this makes the platform do
the same thing as everyone else.

Since the platform is really obsolete now, I am optimistic that nothing
will break after moving the devices around.

As the SoC driver no longer has access to the private header files,
I'm changing the code to instead look up the address of the backupram
from devicetree, which is a good idea anyway.

Finally, having a separate Kconfig symbol means the driver is now
optional and could even be a loadable module rather than always being
built-in if we allowed that for soc_device.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
[Fixup mising Makefile, fixup BB_UID_BASE to fc0]
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2016-07-12 11:24:09 +02:00
Arnd Bergmann
9bb45cd447 soc: raspberrypi-power: add CONFIG_OF dependency
We get a harmless warning if the RASPBERRYPI_POWER driver is enabled without
CONFIG_OF during compile testing:

warning: RASPBERRYPI_POWER selects PM_GENERIC_DOMAINS_OF which has unmet direct dependencies (PM_GENERIC_DOMAINS && OF)

There is no need to select PM_GENERIC_DOMAINS_OF if OF is set, so we can
replace the 'select' with a dependency.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Acked-by: Eric Anholt <eric@anholt.net>
2016-07-07 14:58:38 +02:00
Olof Johansson
358c79174a soc/tegra: Changes for v4.8-rc1
Contains fixes and cleanups to the PMC driver, as well as some fixes for
 the generic PM domain support and some prep work to support PCIe on 64-
 bit ARM.
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v2
 
 iQIcBAABCAAGBQJXdn7eAAoJEN0jrNd/PrOhDc4P/2U04qs7hhaI94NmrWBDto2O
 OKHezveursISPEFZ+FebMF5mSNwdBG0RitKm813TwoYDEKk6Dc7GV4nQHwHPVYqW
 7xK2VrqU3GpEXXSgGu6dupwx/W6ID/L6gkghg01yVVwuvuNOrCDqWTv5EM++9Ydg
 5SPBP2Nvc3CQr/Q71WU8uQueTmtQoQanZC8an/CBzRO2nA8HDBDaXfQ+dgkP/U8l
 QfM9TJbFgbg9s+gwboL9UwnFmDtNNRDFPEYU8Ij9q+VDW4LEodErrVVO2NSwVhG4
 A8KlkUO6N/pHRTjWnERHXUS/kCUM7BRoOum+KjMUdz3SO6iSuZFaKUein7R2fld4
 iV+ichP+DpnkdSpPtgTcFYUeGM1QWfBij+9owloCE4k1pr08hS8eYWxReZ9rsVGN
 43ZBZg/ia41RhojfNDtAK0ntXhak7t5DIiDpi9OO7pvCtU6aYxZxzFu+C9UiCcZ3
 zPHDxHkCVEjbSdrbd6AhkOIbQ9BKk9pab0iya+B3JSJTFensxYkLhAbYkmDgXiPA
 8+pySykkmogBJjsiKBbANlz+5c0etMnjTpd9jBzBuagKahfpZndHtCL8VlA2Blhh
 d7KORcCf1PCEoqALoj0NXhi7IxF9KrbonpQcFspWV4zFSdhBkj5O8wkR10J5q4zG
 4iJt7/bmYoWO/dbRTjbr
 =eFoM
 -----END PGP SIGNATURE-----

Merge tag 'tegra-for-4.8-soc' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux into next/drivers

soc/tegra: Changes for v4.8-rc1

Contains fixes and cleanups to the PMC driver, as well as some fixes for
the generic PM domain support and some prep work to support PCIe on 64-
bit ARM.

* tag 'tegra-for-4.8-soc' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux:
  soc/tegra: Stub out PCIe IRQ workaround on 64-bit ARM
  soc/tegra: pmc: Enable XUSB partitions on boot
  soc/tegra: pmc: Initialise power partitions early
  soc/tegra: pmc: Add specific error messages
  soc/tegra: pmc: Use whitespace more consistently
  soc/tegra: pmc: Don't probe PMC if early initialisation fails
  soc/tegra: pmc: Add missing of_node_put()
  soc/tegra: pmc: Ensure mutex is always initialised
  soc/tegra: pmc: Don't populate SoC data until register space is mapped
  soc/tegra: pmc: Fix early initialisation of PMC
  soc/tegra: pmc: Ensure powergate is available when powering on
  soc/tegra: pmc: Initialise resets associated with a power partition
  soc/tegra: pmc: Use register definitions instead of magic values

Signed-off-by: Olof Johansson <olof@lixom.net>
2016-07-06 22:34:19 -07:00
Olof Johansson
b85751c761 Second Round of Renesas ARM Based SoC R-Car SYSC Updates for v4.8
* Prepare for handling SYSC interrupt configuration purely
   from DT in the rcar-sysc driver for new SoCs, while preserving
   backward compatibility with old DTBs for R-Car H1, H2, and M2-W
 * Add R8A7792 support
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1
 
 iQIcBAABAgAGBQJXdRvUAAoJENfPZGlqN0++qocQAJ6MApU5z9Bn+bLCCLOUeL+F
 5qtRZIQoO/VQ+7sbRR7pBTTLbKs13Zeizq9CxvhGVtq/YUqzP25/RJ8mE25j1Hq1
 +X3QVVOIqCnRQVDlGSq6Og7IMOvCVsNgqxWdmAwtkuiRkD75Qsb6lkmLH8MyNkRj
 6UcC7UUJ5P/Pes9Qgh7ZqfWHD+A7JkUbYlN8THQkuSOJyA5Vf/jAry6riQSkJiuy
 854xJ/f1FRAQas/Usqr3i+6gpZtRw66n5DA+JFubXJLxvrqnZUDdjV2d1tS8phC6
 /AIGxx8n967lPg7j9DO6YxEViF3sxFrvQNds8qYoxzH6+z7FtApBJW9EDLkb58+H
 nvP93DnYz1PzIjcKq0CDreqVnPDtBFK4kfDzkMxLIfbfQVgtSQlo0rpjHQzUA24u
 6zk0Nhl2DM7pe9BYxQNGwWK9f9QIKxiKx9y8Qqkghylq27V34tG+dBgRj0Klv6G+
 QHJNg2ShGZ/esup14eOh4YOw4ks6oNPeda0Rbl4ox3Ec970/42uIR495rsM40Avb
 G17hpvsCd4oVq5xhmr8CKSDzNleewRYGxbzs5Yp1VpWxAjkKOO2AlCxaWSYtYpQe
 gO1sT/YDWx4m0wiEa1/W0z3tO+U3w3wKaKOtxOZyjOj6dq99MJxPwMRoHYUGyMKW
 gGN/bJjsoxBJO/Kl0om+
 =/p9r
 -----END PGP SIGNATURE-----

Merge tag 'renesas-rcar-sysc2-for-v4.8' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas into next/drivers

Second Round of Renesas ARM Based SoC R-Car SYSC Updates for v4.8

* Prepare for handling SYSC interrupt configuration purely
  from DT in the rcar-sysc driver for new SoCs, while preserving
  backward compatibility with old DTBs for R-Car H1, H2, and M2-W
* Add R8A7792 support

* tag 'renesas-rcar-sysc2-for-v4.8' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas:
  soc: renesas: rcar-sysc: Improve SYSC interrupt config in legacy wrapper
  soc: renesas: rcar-sysc: Move SYSC interrupt config to rcar-sysc driver
  soc: renesas: rcar-sysc: Make rcar_sysc_init() init the PM domains
  soc: renesas: rcar-sysc: Fix uninitialized error code in rcar_sysc_pd_init()
  soc: renesas: rcar-sysc: add R8A7792 support

Signed-off-by: Olof Johansson <olof@lixom.net>
2016-07-06 22:12:04 -07:00
Krzysztof Kozlowski
aec6341e2a soc: samsung: pmu: Constify arrays with PMU data
Arrays storing values for Power Management Unit for given sleep mode can
be made const.

Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
2016-07-06 10:35:45 +02:00
Olof Johansson
7cd4837ee2 Qualcomm ARM Based Driver Updates for v4.8
* Rework of SCM driver
 * Add file patterns for Qualcomm Maintainers entry
 * Add worker for wcnss_ctrl signaling
 * Fixes for smp2p
 * Update smem_state properties to match documentation
 * Add SCM Peripheral Authentication service
 * Expose SCM PAS command 10 as a reset controller
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1
 
 iQIcBAABAgAGBQJXcaVxAAoJEFKiBbHx2RXVoxwQAMPI+3iN8M60JJ0SJvhP/VQA
 AlPUcuaS2j50K16srmLif4aG8JYReRI4SNdy0J1kaRRi9OAEHiyQ5yVVlDA+FTTT
 RErBxVzRUYyeCzrBpP1CL4khT+691QVx0dMcdlhnNRUttP3Cd42FM0J4GExWuDJO
 UuOVn1UV0PmgSNfmYzyk87LXOA1di7ZGht02Vnjnh+kcoVjUy4Ty/yLHzxGPYcaF
 RIj6lgYREtU7TN63MNkbYyx2FF+8WS9l5Q6U9E4Z/3nwRzhzhtPimWGtz1EHmxfy
 a8YXmkQYM3RvPa8Cigiyg5ubkLlPC7w2rkNExKUyC/Y/jbvE4l/XJNleCEiGZmMT
 f48F+7iAGgOwITL0+Lqj4VbKlUihwW28+OjcS/M5fTpDR6k0dmU0zHMhJKR9pYVU
 Cr7ucYcPvzF2M6d4Frre9tZski4DZkpke81xjf6HQ00gI2CaDV/lieXtFjikL/Cl
 ktdwQAo2+ydJ+7Ps5Qas2A+d66REe90vx2RCZWFRs9Nxe/CfSSz01LM6EeyONBKf
 XfQvbKc6V/ZVHkWkA/EILlfRFCho6KwpEAHpZpFt1NiplJXfUcDcQyy/CuIKLR4H
 c/UfKeGZCK+VyezbMWAKDb7ig3KywHD8yRieQpCyysVB/97oulJ/bHEs1KT5Bl5I
 uDjnR7KqyXJEOGANr5S2
 =WprH
 -----END PGP SIGNATURE-----

Merge tag 'qcom-drivers-for-4.8' of git://git.kernel.org/pub/scm/linux/kernel/git/agross/linux into next/drivers

Qualcomm ARM Based Driver Updates for v4.8

* Rework of SCM driver
* Add file patterns for Qualcomm Maintainers entry
* Add worker for wcnss_ctrl signaling
* Fixes for smp2p
* Update smem_state properties to match documentation
* Add SCM Peripheral Authentication service
* Expose SCM PAS command 10 as a reset controller

* tag 'qcom-drivers-for-4.8' of git://git.kernel.org/pub/scm/linux/kernel/git/agross/linux:
  firmware: qcom: scm: Expose PAS command 10 as reset-controller
  firmware: qcom: scm: Peripheral Authentication Service
  soc: qcom: Update properties for smem state referencing
  soc: qcom: smp2p: Drop io-accessors
  soc: qcom: smp2p: Correct addressing of outgoing value
  soc: qcom: wcnss_ctrl: Make wcnss_ctrl parent the other components
  firmware: qcom: scm: Add support for ARM64 SoCs
  firmware: qcom: scm: Convert to streaming DMA APIS
  firmware: qcom: scm: Generalize shared error map
  firmware: qcom: scm: Use atomic SCM for cold boot
  firmware: qcom: scm: Convert SCM to platform driver
  MAINTAINERS: Add file patterns for qcom device tree bindings

Signed-off-by: Olof Johansson <olof@lixom.net>
2016-07-04 22:30:11 -07:00
Jon Hunter
8df127456f soc/tegra: pmc: Enable XUSB partitions on boot
The Tegra XHCI driver does not currently manage the Tegra XUSB power
partitions and so it these partitions have not been enabled by the
bootloader then the system will crash when probing the XHCI device.

While proper support for managing the power partitions is being
developed to the XHCI driver for Tegra, for now power on all the XUSB
partitions for USB host and super-speed on boot if the XHCI driver is
enabled.

Signed-off-by: Jon Hunter <jonathanh@nvidia.com>
Signed-off-by: Thierry Reding <treding@nvidia.com>
2016-06-30 13:42:54 +02:00
Jon Hunter
e2d1796053 soc/tegra: pmc: Initialise power partitions early
If CONFIG_PM_GENERIC_DOMAINS is not enabled, then power partitions
associated with a device will not be enabled automatically by the PM
core when the device is in use. To avoid situations where a device in
a power partition is to be used but the partition is not enabled,
initialise the power partitions for Tegra early in the boot process and
if CONFIG_PM_GENERIC_DOMAINS is not enabled, then power on all
partitions defined in the device-tree blob.

Note that if CONFIG_PM_GENERIC_DOMAINS is not enabled, after the
partitions are turned on, the clocks and resets used as part of the
sequence for turning on the partition are released again as they are no
longer needed by the PMC driver. Another benefit of this is that this
avoids any issues of sharing resets between the PMC driver and other
device drivers that may wish to independently control a particular
reset.

Signed-off-by: Jon Hunter <jonathanh@nvidia.com>
Signed-off-by: Thierry Reding <treding@nvidia.com>
2016-06-30 13:41:46 +02:00
Jon Hunter
c2710ac9f5 soc/tegra: pmc: Add specific error messages
When initialising a powergate, only a single error message is shown if
the initialisation fails. Add more error messages to give specific
details of what failed if the initialisation failed and remove the
generic failure message.

Signed-off-by: Jon Hunter <jonathanh@nvidia.com>
Signed-off-by: Thierry Reding <treding@nvidia.com>
2016-06-30 13:30:40 +02:00
Thierry Reding
da8f4b4589 soc/tegra: pmc: Use whitespace more consistently
Use blank lines after blocks and before labels for consistency with the
existing code in the file.

Signed-off-by: Thierry Reding <treding@nvidia.com>
2016-06-30 12:23:31 +02:00
Jon Hunter
a83f1fc3f3 soc/tegra: pmc: Don't probe PMC if early initialisation fails
Commit 0259f522e0 ('soc/tegra: pmc: Restore base address on probe
failure') fixes an issue where the PMC base address pointer is not
restored on probe failure. However, this fix creates another problem
where if early initialisation of the PMC driver fails and an initial
mapping for the PMC address space is not created, then when the PMC
device is probed, the PMC base address pointer will not be valid and
this will cause a crash when tegra_pmc_init() is called and attempts
to access a register.

Although the PMC address space is mapped a 2nd time during the probe
and so this could be fixed by populating the base address pointer
earlier during the probe, this adds more complexity to the code.
Moreover, the PMC probe also assumes the the soc data pointer is also
initialised when the device is probed and if not will also lead to a
crash when calling tegra_pmc_init_tsense_reset(). Given that if the
early initialisation does fail then something bad has happen, it seems
acceptable to allow the PMC device probe to fail as well. Therefore, if
the PMC base address pointer or soc data pointer are not valid when
probing the PMC device, WARN and return an error.

Fixes: 0259f522e0 ('soc/tegra: pmc: Restore base address on probe failure')
Signed-off-by: Jon Hunter <jonathanh@nvidia.com>
Signed-off-by: Thierry Reding <treding@nvidia.com>
2016-06-30 12:23:27 +02:00
Jon Hunter
b69a625826 soc/tegra: pmc: Add missing of_node_put()
Add missing of_node_put() in PMC early initialisation function to avoid
leaking the device nodes.

Signed-off-by: Jon Hunter <jonathanh@nvidia.com>
[treding@nvidia.com: squash in a couple more of_node_put() calls]
Signed-off-by: Thierry Reding <treding@nvidia.com>
2016-06-30 12:23:08 +02:00
Jon Hunter
61fd284be8 soc/tegra: pmc: Ensure mutex is always initialised
The mutex used by the PMC driver may not be initialised if early
initialisation of the driver fails. If this does happen, then it could
be possible for callers of the public PMC functions to still attempt to
acquire the mutex. Fix this by initialising the mutex as soon as
possible to ensure it will always be initialised.

Signed-off-by: Jon Hunter <jonathanh@nvidia.com>
Signed-off-by: Thierry Reding <treding@nvidia.com>
2016-06-30 12:23:07 +02:00
Jon Hunter
718a2426e8 soc/tegra: pmc: Don't populate SoC data until register space is mapped
The public functions exported by the PMC driver use the presence of the
SoC data pointer to determine if the PMC device is configured and the
registers can be accessed. However, the SoC data is populated before the
PMC register space is mapped and this opens a window where the SoC data
pointer is valid but the register space has not yet been mapped which
could lead to a crash. Furthermore, if the mapping of the PMC register
space fails, then the SoC data pointer is not cleared and so would
expose a larger window where a crash could occur.

Fix this by initialising the SoC data pointer after the PMC register
space has been mapped.

Signed-off-by: Jon Hunter <jonathanh@nvidia.com>
Signed-off-by: Thierry Reding <treding@nvidia.com>
2016-06-30 12:22:22 +02:00
Jon Hunter
11131895cd soc/tegra: pmc: Fix early initialisation of PMC
During early initialisation, the available power partitions for a given
device is configured as well as the polarity of the PMC interrupt. Both
of which should only be configured if there is a valid device node for
the PMC device. This is because the soc data used for configuring the
power partitions is only available if a device node for the PMC is found
and the code to configure the interrupt polarity uses the device node
pointer directly.

Some early device-tree images may not have this device node and so fix
this by ensuring the device node pointer is valid when configuring these
items.

Signed-off-by: Jon Hunter <jonathanh@nvidia.com>
Signed-off-by: Thierry Reding <treding@nvidia.com>
2016-06-30 11:52:51 +02:00
Jon Hunter
403db2d21c soc/tegra: pmc: Ensure powergate is available when powering on
The function tegra_power_sequence_power_up() is a public function used
to power on a partition. When this function is called, we do not check
to see if the partition being powered up is valid/available. Fix this
by checking to see that the partition is valid/available.

Signed-off-by: Jon Hunter <jonathanh@nvidia.com>
Signed-off-by: Thierry Reding <treding@nvidia.com>
2016-06-30 11:48:39 +02:00
Jon Hunter
05cfb988a4 soc/tegra: pmc: Initialise resets associated with a power partition
When registering the Tegra power partitions with the generic PM domain
framework, the current state of the each partition is checked and used
as the default state for the partition. However, the state of each reset
associated with the partition is not initialised and so it is possible
that the state of the resets are not in the expected state. For example,
if a partition is on, then the resets should be de-asserted and if the
partition is off, the resets should be asserted.

There have been cases where the bootloader has powered on a partition
and only de-asserted some of the resets to some of the devices in the
partition. This can cause accesses to these devices to hang the system
when the kernel boots and attempts to probe these devices.

Ideally, the driver for the device should ensure the reset has been
de-asserted when probing, but the resets cannot be shared between the
PMC driver (that needs to de-assert/assert the reset when turning the
partition on or off) and another driver because we cannot ensure the
reset is in the correct state.

To ensure the resets are in the correct state, when using the generic
PM domain framework, put each reset associated with the partition in
the correct state (based upon the partition's current state) when
obtaining the resets for a partition.

Signed-off-by: Jon Hunter <jonathanh@nvidia.com>
Signed-off-by: Thierry Reding <treding@nvidia.com>
2016-06-30 11:48:33 +02:00
Geert Uytterhoeven
ced42730d1 soc: renesas: rcar-sysc: Improve SYSC interrupt config in legacy wrapper
Align SYSC interrupt configuration in the legacy wrapper with the DT
version:
  - Mask SYSC interrupt sources before enabling them (doesn't matter
    much as they're disabled at the GIC level anyway),
  - Make sure not to clear reserved SYSCIMR bits that were set before.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Reviewed-by: Ulrich Hecht <ulrich.hecht+renesas@gmail.com>
Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
2016-06-29 14:37:24 +02:00
Geert Uytterhoeven
053239987f soc: renesas: rcar-sysc: Move SYSC interrupt config to rcar-sysc driver
On R-Car H1 and Gen2, the SYSC interrupt registers are always configured
using hardcoded values in platform code. For R-Car Gen2, values are
provided for H2 and M2-W only, other SoCs are not yet supported, and
never will be.

Move this configuration from SoC-specific platform code to the
rcar_sysc_init() wrapper, so it can be skipped if the SYSC is configured
from DT. This would be the case not only for H1, H2, and M2-W using a
modern DTS, but also for other R-Car Gen2 SoCs not supported by the
platform code, relying purely on DT.

There is no longer a need to return the mapped register block, hence
make the function return void.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Reviewed-by: Ulrich Hecht <ulrich.hecht+renesas@gmail.com>
Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
2016-06-29 14:37:08 +02:00
Geert Uytterhoeven
b1e52287a2 soc: renesas: rcar-sysc: Make rcar_sysc_init() init the PM domains
Let rcar_sysc_init() trigger initialization of the SYSC PM domains from
DT if called before the early_initcall.
On failure, it falls back to mapping the passed register block, as
before.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
2016-06-29 14:36:51 +02:00
Geert Uytterhoeven
1023578ec3 soc: renesas: rcar-sysc: Fix uninitialized error code in rcar_sysc_pd_init()
On success, rcar_sysc_pd_init() returns an uninitialized error code.
Use the return value of of_genpd_add_provider_onecell() to fix this.

This went unnoticed, as early_initcall() doesn't care about the return
value.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
2016-06-29 14:36:37 +02:00
Bjorn Andersson
3680a4a974 soc: qcom: Update properties for smem state referencing
Update the property names to match device tree bindings, the correct
values should be qcom,smem-states and qcom,smem-state-names.

Also update the #qcom,smem-state-cells for consistency, before we merge
any users of these properties.

Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
Acked-by: Rob Herring <robh@kernel.org>
Signed-off-by: Andy Gross <andy.gross@linaro.org>
2016-06-24 22:53:41 -05:00