Commit Graph

6490 Commits

Author SHA1 Message Date
Olof Johansson 6b4670af9f Non-urgent fixes for omaps for v5.14 merge window
Warn and block suspend for am335x unless the PM related modules and
 firmware are loaded and warn otherwise. Otherwise we easily end up
 with a suspended system with nothing capable of waking it up.
 
 We also drop a duplicated prototype for am33xx_init_early().
 -----BEGIN PGP SIGNATURE-----
 
 iQJFBAABCAAvFiEEkgNvrZJU/QSQYIcQG9Q+yVyrpXMFAmDMRw8RHHRvbnlAYXRv
 bWlkZS5jb20ACgkQG9Q+yVyrpXOjng//VpUrQ3LBtf2GTJIZ8k7K7VvTqvFwcpzH
 h3ZNhqt+IDdUJkgRIdKUi6MOoXjudukpi7l40DKtsqY3SoVsuiFKlAopl/ZL3GdU
 sCnom43nDSMmwWPX24aoHSWF/p60KlI13EIR6qMMOMBRbOpTmVAoIN+SzFV1RkjE
 jr/qUPiaQ89NZ+69JEYY0Tgx87AHjVXLbiVx6ElevsRQu9qtb7zRp68xiGf16hWo
 /YEvCWPMZ3Pkan8YZ8iu9XuNztYSh3KxN/gzi6L4w28O2KuqQ9MI1ndwabnlUQmE
 omj3wOPt9AosZrPBm5MiVbs8xCkGI2m23K1QW/rZ/DUvsYKIydb2/j/rOgAfF8nR
 6InmS7kdXMrmYFgeHQxmFN8aohT2rHQNVNKx8Ez0E2B1jKQSHBgi5G2iCl/DBJP3
 dPqCBIiz1DaBA/Wmoo0aHqS4D3KjnnmoXXJvmrSAgr5stbmLNXXmJWSUmIQUQ+Bx
 Mtu27tgEaOZ9gjDoQrlqKLuvXNSBsxpOCODfOyaHAM/zfKntGCMGCWSstyyWC8Xs
 2NeC2YKMEC532wCFmkOQLKrEbhk7mwx1e7BoQzwOqAmrrhEkAVx7Ih5C2G8EjFGp
 Xg0e2A0ykqigi27Ly7lJhU/Q5T2av5ekYlUCIBUveTCGd+jZpPe+504njP2eH6Rg
 IV2ix9t2HFo=
 =C1rS
 -----END PGP SIGNATURE-----
gpgsig -----BEGIN PGP SIGNATURE-----
 
 iQJDBAABCgAtFiEElf+HevZ4QCAJmMQ+jBrnPN6EHHcFAmDT47MPHG9sb2ZAbGl4
 b20ubmV0AAoJEIwa5zzehBx35NgP/2kQXoe3uU/bvHPG6uyMr3oSM5bvRNnhGRKw
 xeUoCY7GqB5PJAkC/NqJpZZqrbF8vrbFydfRP4Kbeitwsji+Xf93hMe/Y166uQUQ
 HzjpAX+RsHeAwrJRPOpZainbiY58D3A3oyz2Mom4l4aRmw2Au7w6WicsZzR3NNv9
 ipwn/1AujGpWUev1eMjMhpnfJ3/sdlUO/gah6Suh+he+AFT2Qy1cebyp4sQKZxRF
 ihGWFE9nRNRzjHejHX+cZ80pnE57WErzKKdwR7E2sT+RLNaYbDKzfJeSUH0HuAcv
 Cz/bHvQxxf1muCEaRL4chMsRApNXtVjJs+pAvd9w/sQWn5GPBpeHyHpcDiYWlOQf
 NySPDf/yhOJcCRdgmpLP2iRBx0mzDvw6kAnqk06TeUEhsCYL6MJ+lLFD//vKKy6m
 4QPH3vdRGQO8YYJ4/xibZzpHAuQeKxYztm84a2O1sngBbf8zymVx0WyZtlbWQEtR
 BDj+SB+Jp7q0nkwSvDpoWPZsuAAhKwozR7KwAzucrgo5ihrq2qQprf0Vmr82uPHA
 X2Dfbl4Xq1xD08jPuGU7ANDq7gdDjBuWR9NP55AHMcnEeD+yAjCuLoQu9r9YlyNn
 pn0aeKKJDzSu5eCxksxeANlRMrLXhLHx+iAjCZcQU4jFo2Id6tOZ0UEQ6VVtO+Sr
 W/SnMD5t
 =evlt
 -----END PGP SIGNATURE-----

Merge tag 'omap-for-v5.14/fixes-not-urgent-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap into arm/soc

Non-urgent fixes for omaps for v5.14 merge window

Warn and block suspend for am335x unless the PM related modules and
firmware are loaded and warn otherwise. Otherwise we easily end up
with a suspended system with nothing capable of waking it up.

We also drop a duplicated prototype for am33xx_init_early().

* tag 'omap-for-v5.14/fixes-not-urgent-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap:
  ARM: OMAP2+: Block suspend for am3 and am4 if PM is not configured
  ARM: OMAP2+: remove duplicated prototype
  ARM: dts: dra7: Fix duplicate USB4 target module node
  ARM: OMAP1: ams-delta: remove unused function ams_delta_camera_power
  bus: ti-sysc: Fix flakey idling of uarts and stop using swsup_sidle_act
  bus: ti-sysc: Fix am335x resume hang for usb otg module
  ARM: OMAP2+: Fix build warning when mmc_omap is not built
  ARM: OMAP1: isp1301-omap: Add missing gpiod_add_lookup_table function
  ARM: OMAP1: Fix use of possibly uninitialized irq variable
  bus: ti-sysc: Fix missing quirk flags for sata

Link: https://lore.kernel.org/r/pull-1624002812-396117@atomide.com
Signed-off-by: Olof Johansson <olof@lixom.net>
2021-06-23 18:45:23 -07:00
Tony Lindgren 093a474ce1 ARM: OMAP2+: Block suspend for am3 and am4 if PM is not configured
If the PM related modules are not loaded and PM firmware not configured,
the system suspend fails to resume. Let's fix this by adding initial
platform_suspend_ops to block suspend and warn about missing modules.

When pm33xx and wkup_m3_ipc have been loaded and m3 coprocessor booted
with it's firmware, pm33xx sets up working platform_suspend_ops. Note
that we need to configure at least PM_SUSPEND_STANDBY to have
suspend_set_ops().

Cc: Dave Gerlach <d-gerlach@ti.com>
Cc: Suman Anna <s-anna@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-06-11 10:43:08 +03:00
Alejandro Lucero a1e029b7a5 ARM: OMAP2+: remove duplicated prototype
The am33xx_init_early prototype is defined twice.

Signed-off-by: Alejandro Lucero <alucero@os3sl.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-06-11 10:41:35 +03:00
Dario Binacchi 57f2bf41b9 ARM: OMAP2+: remove omap2_set_globals_control()
The function is no longer used, so let's remove it.

Signed-off-by: Dario Binacchi <dariobin@libero.it>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-05-21 12:28:47 +03:00
Dario Binacchi ac189a7a99 ARM: OMAP2+: CM: remove omap2_set_globals_cm()
The function is no longer used, so let's remove it.

Signed-off-by: Dario Binacchi <dariobin@libero.it>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-05-21 12:27:59 +03:00
Yongqiang Liu 040ab72ee1 ARM: OMAP2+: Fix build warning when mmc_omap is not built
GCC reports the following warning with W=1:

arch/arm/mach-omap2/board-n8x0.c:325:19: warning:
variable 'index' set but not used [-Wunused-but-set-variable]
325 |  int bit, *openp, index;
    |                   ^~~~~

Fix this by moving CONFIG_MMC_OMAP to cover the rest codes
in the n8x0_mmc_callback().

Signed-off-by: Yongqiang Liu <liuyongqiang13@huawei.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-05-18 09:44:42 +03:00
Linus Torvalds 37f00ab4a0 ARM: SoC drivers for v5.13
Updates for SoC specific drivers include a few subsystems that
 have their own maintainers but send them through the soc tree:
 
 TEE/OP-TEE:
  -  Add tracepoints around calls to secure world
 
 Memory controller drivers:
  - Minor fixes for Renesas, Exynos, Mediatek and Tegra platforms
  - Add debug statistics to Tegra20 memory controller
  - Update Tegra bindings and convert to dtschema
 
 ARM SCMI Firmware:
  - Support for modular SCMI protocols and vendor specific extensions
  - New SCMI IIO driver
  - Per-cpu DVFS
 
 The other driver changes are all from the platform maintainers
 directly and reflect the drivers that don't fit into any other
 subsystem as well as treewide changes for a particular platform.
 
 SoCFPGA:
  - Various cleanups contributed by Krzysztof Kozlowski
 
 Mediatek:
  - add MT8183 support to mutex driver
  - MMSYS: use per SoC array to describe the possible routing
  - add MMSYS support for MT8183 and MT8167
  - add support for PMIC wrapper with integrated arbiter
  - add support for MT8192/MT6873
 
 Tegra:
  - Bug fixes to PMC and clock drivers
 
 NXP/i.MX:
  - Update SCU power domain driver to keep console domain power on.
  - Add missing ADC1 power domain to SCU power domain driver.
  - Update comments for single global power domain in SCU power domain
    driver.
  - Add i.MX51/i.MX53 unique id support to i.MX SoC driver.
 
 NXP/FSL SoC driver updates for v5.13
  - Add ACPI support for RCPM driver
  - Use generic io{read,write} for QE drivers after performance optimized
    for PowerPC
  - Fix QBMAN probe to cleanup HW states correctly for kexec
  - Various cleanup and style fix for QBMAN/QE/GUTS drivers
 
 OMAP:
  - Preparation to use devicetree for genpd
  - ti-sysc needs iorange check improved when the interconnect target module
    has no control registers listed
  - ti-sysc needs to probe l4_wkup and l4_cfg interconnects first to avoid
    issues with missing resources and unnecessary deferred probe
  - ti-sysc debug option can now detect more devices
  - ti-sysc now warns if an old incomplete devicetree data is found as we
    now rely on it being complete for am3 and 4
  - soc init code needs to check for prcm and prm nodes for omap4/5 and dra7
  - omap-prm driver needs to enable autoidle retention support for omap4
  - omap5 clocks are missing gpmc and ocmc clock registers
  - pci-dra7xx now needs to use builtin_platform_driver instead of using
    builtin_platform_driver_probe for deferred probe to work
 
 Raspberry Pi:
  - Fix-up all RPi firmware drivers so as for unbind to happen in an
    orderly fashion
  - Support for RPi's PoE hat PWM bus
 
 Qualcomm
  - Improved detection for SCM calling conventions
  - Support for OEM specific wifi firmware path
  - Added drivers for SC7280/SM8350: RPMH, LLCC< AOSS QMP
 
 Signed-off-by: Arnd Bergmann <arnd@arndb.de>
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEo6/YBQwIrVS28WGKmmx57+YAGNkFAmCC2JwACgkQmmx57+YA
 GNkgRg//cBtq2NyDbjiNABxFSkmGCfcc0w0C2wjVzr4cfg6BLTbuvvlpZxI912pu
 P1G2sbsdfQJ8sSeIyZos+PilWK0zHrqlaGZfKI19US45dMjpteDBgsPd7wNZwBjQ
 jbops3YLjztZK1HpY4dIdvMnfxt7yRqhBWaTbPuCwQ35c5KsOM8NHB3cP3BUINWK
 x1uuBCv9svppzwdDiPxneV93WKEzabOUo+WBMPyh5vnyvmW17Iif4BA/VKQxzymm
 mWUi8HHpKBpvntJOKwAD2hnLAdpR3SwX20SLOpyLhnJMotbzNUEqq3LdRxDNPdHk
 ry+rarJ78JGlYfpcfegf2bLf5ITNMfOyRGkjtzeYpcZIXPjufOg9DA9YtAy37k0u
 L0T/9gQ+tQ01WGMca77OyUtIqJKdblZrQMfuH/yGlR99bqFQMV7rNc7GNlX1MXp/
 zw4aOYrRWGtGEeAjx5JJWcYydvMSJpCrqxTz3YhgeJECHB2iA6YkV3NROR4TLW//
 tfxaKqxR/KmSqE6hoVOAuuQ0BLXNlql/+4EE6MKsAOBiKPJclvmJg4CyuY8G21ev
 9Su0zJnXMzai7gNu32v1pizGj26+AOhxCEgAG0mGgk2jlQSn24CKgm5e7kCUewcF
 j/1XksNPT95v/K8MsLpXe5xGvF3jhA1BlFfvjJNZOrcZywBXRxg=
 =iidq
 -----END PGP SIGNATURE-----

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

Pull ARM SoC driver updates from Arnd Bergmann:
 "Updates for SoC specific drivers include a few subsystems that have
  their own maintainers but send them through the soc tree:

  TEE/OP-TEE:
   - Add tracepoints around calls to secure world

  Memory controller drivers:
   - Minor fixes for Renesas, Exynos, Mediatek and Tegra platforms
   - Add debug statistics to Tegra20 memory controller
   - Update Tegra bindings and convert to dtschema

  ARM SCMI Firmware:
   - Support for modular SCMI protocols and vendor specific extensions
   - New SCMI IIO driver
   - Per-cpu DVFS

  The other driver changes are all from the platform maintainers
  directly and reflect the drivers that don't fit into any other
  subsystem as well as treewide changes for a particular platform.

  SoCFPGA:
   - Various cleanups contributed by Krzysztof Kozlowski

  Mediatek:
   - add MT8183 support to mutex driver
   - MMSYS: use per SoC array to describe the possible routing
   - add MMSYS support for MT8183 and MT8167
   - add support for PMIC wrapper with integrated arbiter
   - add support for MT8192/MT6873

  Tegra:
   - Bug fixes to PMC and clock drivers

  NXP/i.MX:
   - Update SCU power domain driver to keep console domain power on.
   - Add missing ADC1 power domain to SCU power domain driver.
   - Update comments for single global power domain in SCU power domain
     driver.
   - Add i.MX51/i.MX53 unique id support to i.MX SoC driver.

  NXP/FSL SoC driver updates for v5.13
   - Add ACPI support for RCPM driver
   - Use generic io{read,write} for QE drivers after performance
     optimized for PowerPC
   - Fix QBMAN probe to cleanup HW states correctly for kexec
   - Various cleanup and style fix for QBMAN/QE/GUTS drivers

  OMAP:
   - Preparation to use devicetree for genpd
   - ti-sysc needs iorange check improved when the interconnect target
     module has no control registers listed
   - ti-sysc needs to probe l4_wkup and l4_cfg interconnects first to
     avoid issues with missing resources and unnecessary deferred probe
   - ti-sysc debug option can now detect more devices
   - ti-sysc now warns if an old incomplete devicetree data is found as
     we now rely on it being complete for am3 and 4
   - soc init code needs to check for prcm and prm nodes for omap4/5 and
     dra7
   - omap-prm driver needs to enable autoidle retention support for
     omap4
   - omap5 clocks are missing gpmc and ocmc clock registers
   - pci-dra7xx now needs to use builtin_platform_driver instead of
     using builtin_platform_driver_probe for deferred probe to work

  Raspberry Pi:
   - Fix-up all RPi firmware drivers so as for unbind to happen in an
     orderly fashion
   - Support for RPi's PoE hat PWM bus

  Qualcomm
   - Improved detection for SCM calling conventions
   - Support for OEM specific wifi firmware path
   - Added drivers for SC7280/SM8350: RPMH, LLCC< AOSS QMP"

* tag 'arm-drivers-5.13' of git://git.kernel.org/pub/scm/linux/kernel/git/soc/soc: (165 commits)
  soc: aspeed: fix a ternary sign expansion bug
  memory: mtk-smi: Add device-link between smi-larb and smi-common
  memory: samsung: exynos5422-dmc: handle clk_set_parent() failure
  memory: renesas-rpc-if: fix possible NULL pointer dereference of resource
  clk: socfpga: fix iomem pointer cast on 64-bit
  soc: aspeed: Adapt to new LPC device tree layout
  pinctrl: aspeed-g5: Adapt to new LPC device tree layout
  ipmi: kcs: aspeed: Adapt to new LPC DTS layout
  ARM: dts: Remove LPC BMC and Host partitions
  dt-bindings: aspeed-lpc: Remove LPC partitioning
  soc: fsl: enable acpi support in RCPM driver
  soc: qcom: mdt_loader: Detect truncated read of segments
  soc: qcom: mdt_loader: Validate that p_filesz < p_memsz
  soc: qcom: pdr: Fix error return code in pdr_register_listener
  firmware: qcom_scm: Fix kernel-doc function names to match
  firmware: qcom_scm: Suppress sysfs bind attributes
  firmware: qcom_scm: Workaround lack of "is available" call on SC7180
  firmware: qcom_scm: Reduce locking section for __get_convention()
  firmware: qcom_scm: Make __qcom_scm_is_call_available() return bool
  Revert "soc: fsl: qe: introduce qe_io{read,write}* wrappers"
  ...
2021-04-26 12:11:52 -07:00
Linus Torvalds 01d7136894 ARM: SoC changes for v5.13
Almost all SoC code changes this time are for the TI OMAP
 platform, which continues its decade-long quest to move from
 describing a complex SoC in code to device tree.
 
 Aside from this, the Uniphier platform has a new maintainer
 and some platforms have minor bugfixes and cleanups that were
 not urgent enough for v5.12.
 
 Signed-off-by: Arnd Bergmann <arnd@arndb.de>
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEo6/YBQwIrVS28WGKmmx57+YAGNkFAmCC2JoACgkQmmx57+YA
 GNk2jg/9HPrMBjoxNMEynsN066Dnc3AVBG8veYAigS0mJuMX3HzUqp+RNn5YxEak
 0SKWgocjawi5MjtuCRmM/BO0SY4wPUMOxnqx/AE4q3u6VVpfx+XJu+1bywAx7UFC
 FnqstmqFAfJDLJUe4Pfv4SuXRJYyGKBoEdRK9Xr13qSstQ1gm4ccWbtRStWCcVvv
 f4J0gPK0dw99lgbCOLbrBMfz1zuxCwhILg+qZ0+WPl9NNfxurQ2+/Cj/8P/L0IH+
 BoiZ5NaISWnvlBWaSTh6P7d3omhbA149CPjybUy2b/s84oNHdm7XLpwymVp941zt
 sM3gBIi7UDKMfXUrjWDZAXY06MZa/62BLCHQ2Fx+A1ve9TC0AqmSmUxhB4Z8xXs2
 3U97kZnTAPX9Scno9k7eDXbVXKVzlDL8zdZtGvY56x/EiAiPSJaTcaU6puNgdF9z
 7IPFKdpMbePcxHN03dC17B4HYVoSTp2gCadOSRSrBmVjAoswzYKoAOHrzibCwUzI
 knbsShhJe/BtxvLJ7e/hq0YZBTTZXUcX/3Iuw6C+j+9l9Cod/JhYOoHQM7gvqHv6
 JRz0Wt9IrMhYBMYlf0g8zHZa7IUDAq7k6x8XwLjK/M/WdeS2tI3+Cmt5ePhlgZVb
 eBPzikxcvglDojE7zTkBeC/+jlpolWQ6UfRnptSvkof1DWVPkiE=
 =YFEX
 -----END PGP SIGNATURE-----

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

Pull ARM SoC updates from Arnd Bergmann:
 "Almost all SoC code changes this time are for the TI OMAP platform,
  which continues its decade-long quest to move from describing a
  complex SoC in code to device tree.

  Aside from this, the Uniphier platform has a new maintainer and some
  platforms have minor bugfixes and cleanups that were not urgent enough
  for v5.12"

* tag 'arm-soc-5.13' of git://git.kernel.org/pub/scm/linux/kernel/git/soc/soc: (96 commits)
  MAINTAINERS: Update ARM/UniPhier SoCs maintainers and status
  mailmap: Update email address for Nicolas Saenz
  MAINTAINERS: Update BCM2711/BCM2335 maintainer's mail
  ARM: exynos: correct kernel doc in platsmp
  ARM: hisi: use the correct HiSilicon copyright
  ARM: ux500: make ux500_cpu_die static
  ARM: s3c: Use pwm_get() in favour of pwm_request() in RX1950
  ARM: OMAP1: fix incorrect kernel-doc comment syntax in file
  ARM: OMAP2+: fix incorrect kernel-doc comment syntax in file
  ARM: OMAP2+: Use DEFINE_SPINLOCK() for spinlock
  ARM: at91: pm: Move prototypes to mutually included header
  ARM: OMAP2+: use true and false for bool variable
  ARM: OMAP2+: add missing call to of_node_put()
  ARM: OMAP2+: Replace DEFINE_SIMPLE_ATTRIBUTE with DEFINE_DEBUGFS_ATTRIBUTE
  ARM: imx: Kconfig: Fix typo in help
  ARM: mach-imx: Fix a spelling in the file pm-imx5.c
  bus: ti-sysc: Warn about old dtb for dra7 and omap4/5
  ARM: OMAP2+: Stop building legacy code for dra7 and omap4/5
  ARM: OMAP2+: Drop legacy platform data for omap5 hwmod
  ARM: OMAP2+: Drop legacy platform data for omap5 l3
  ...
2021-04-26 11:48:26 -07:00
Arnd Bergmann f47e8e1437 SoC changes for omaps for v5.13
Minor non-urgent fixes for issues found by robots and few typo fixes:
 
 - Use DEFINE_DEBUGFS_ATTRIBUTE
 
 - Add missing of_node_put()
 
 - Use true and false for bool variable
 
 - Use DEFINE_SPINLOCK
 
 - Fix incorrect kerneldoc usage
 -----BEGIN PGP SIGNATURE-----
 
 iQJFBAABCAAvFiEEkgNvrZJU/QSQYIcQG9Q+yVyrpXMFAmBsMLURHHRvbnlAYXRv
 bWlkZS5jb20ACgkQG9Q+yVyrpXOifhAA48WXNxmJ6GhYaDiJGfPlTGrQN1EwQo1p
 vQFvUf+u2fZQvg/q1KwPrDo67k5RScq97OH/LrQauvOHosn+dPHblHSZ+O5dYUxG
 IBtrbqLu6U4as46uDHIv6+vASB8SLyJBFRq5crWRqo+LFuSk4OfSa285W+LZ+Ks+
 8hpgKP2LuV4c8EX8otkBKktwdSSXy9CiQE8L42O36BrH4J7MP9iCHKsggZRtw12L
 GRvrQEPkp1YcFPHOjU0n7MCLMDBeecLKr2mafwTx2i4714I1528z1WQ+b7nh7oXV
 OBhg4QxxNuw2XhIWD9p1XePzs5pfiYbYSbpQTAbG/1/JdwgyYh1UtJemRhFPxmky
 oisDKLCJMIaW01XgI6PEC4xHNWXrtY+81abNuaFcegctNQ1fY+103TjWP9kT+tAK
 mP7C/RLQEsMwgwwlqkDOxQuz00bYY4kmIKAEm7ZM0MOwjmpS3vBtfKZTUzJoawSx
 yBirUChGeJicQQ6lFO9/vm7KOs5oMlfh99r101QTwuSozu4PrkJ2SdHyvAmvWSBP
 gm4kZNx8PQ5Gw8Rs9aOYYpLxQxzmD0aMcGbGGfgSRRXPxkbQOgv+1g7+t+hin7zj
 MxR83yyLo/X+m7uAOxqRIyZADSc7HcgroRbDr7o/QlTQqTyb2VUMHHplUXh4s3Vz
 pwUIJJGZ+zI=
 =+8vs
 -----END PGP SIGNATURE-----

Merge tag 'omap-for-v5.13/soc-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap into arm/soc

SoC changes for omaps for v5.13

Minor non-urgent fixes for issues found by robots and few typo fixes:

- Use DEFINE_DEBUGFS_ATTRIBUTE

- Add missing of_node_put()

- Use true and false for bool variable

- Use DEFINE_SPINLOCK

- Fix incorrect kerneldoc usage

* tag 'omap-for-v5.13/soc-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap:
  ARM: OMAP1: fix incorrect kernel-doc comment syntax in file
  ARM: OMAP2+: fix incorrect kernel-doc comment syntax in file
  ARM: OMAP2+: Use DEFINE_SPINLOCK() for spinlock
  ARM: OMAP2+: use true and false for bool variable
  ARM: OMAP2+: add missing call to of_node_put()
  ARM: OMAP2+: Replace DEFINE_SIMPLE_ATTRIBUTE with DEFINE_DEBUGFS_ATTRIBUTE

Link: https://lore.kernel.org/r/pull-1617703816-65652@atomide.com
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2021-04-08 21:56:11 +02:00
Tony Lindgren fc85dc42a3 ARM: OMAP2+: Fix uninitialized sr_inst
Fix uninitialized sr_inst.

Fixes: fbfa463be8 ("ARM: OMAP2+: Fix smartreflex init regression after dropping legacy data")
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-31 09:27:41 +03:00
Aditya Srivastava 7c4a0b3e5c ARM: OMAP2+: fix incorrect kernel-doc comment syntax in file
The opening comment mark '/**' is used for highlighting the beginning of
kernel-doc comments.
The header for arch/arm/mach-omap2/omap_twl.c follows this syntax, but the
content inside does not comply with kernel-doc.

This line was probably not meant for kernel-doc parsing, but is parsed
due to the presence of kernel-doc like comment syntax(i.e, '/**'), which
causes unexpected warning from kernel-doc:
"warning: wrong kernel-doc identifier on line:
 * OMAP and TWL PMIC specific initializations."

Provide a simple fix by replacing this occurrence with general comment
format, i.e. '/*', to prevent kernel-doc from parsing it.

Signed-off-by: Aditya Srivastava <yashsri421@gmail.com>
Acked-by: Randy Dunlap <rdunlap@infradead.org>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-31 09:04:22 +03:00
Yang Li 0db1f107f8 ARM: OMAP2+: use true and false for bool variable
fixed the following coccicheck:
./arch/arm/mach-omap2/powerdomain.c:1205:9-10: WARNING: return of 0/1 in
function 'pwrdm_can_ever_lose_context' with return type bool

Reported-by: Abaci Robot <abaci@linux.alibaba.com>
Signed-off-by: Yang Li <yang.lee@linux.alibaba.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-24 14:11:43 +02:00
Yang Li c3c83055bd ARM: OMAP2+: add missing call to of_node_put()
In one of the error paths of the for_each_child_of_node() loop,
add missing call to of_node_put().

Fix the following coccicheck warning:
./arch/arm/mach-omap2/omap_hwmod.c:2132:1-23: WARNING: Function
"for_each_child_of_node" should have of_node_put() before return around
line 2140.

Reported-by: Abaci Robot <abaci@linux.alibaba.com>
Signed-off-by: Yang Li <yang.lee@linux.alibaba.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-24 13:32:57 +02:00
Jiapeng Chong 02e9821b2b ARM: OMAP2+: Replace DEFINE_SIMPLE_ATTRIBUTE with DEFINE_DEBUGFS_ATTRIBUTE
Fix the following coccicheck warning:

./arch/arm/mach-omap2/pm-debug.c:171:0-23: WARNING: pwrdm_suspend_fops
should be defined with DEFINE_DEBUGFS_ATTRIBUTE.

Reported-by: Abaci Robot <abaci@linux.alibaba.com>
Signed-off-by: Jiapeng Chong <jiapeng.chong@linux.alibaba.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-24 13:27:36 +02:00
Tony Lindgren a3efe3f6d0 ARM: OMAP2+: Fix warning for omap_init_time_of()
Fix warning: no previous prototype for 'omap_init_time_of'.

Fixes: e69b4e1a75 ("ARM: OMAP2+: Add omap_init_time_of()")
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-24 12:23:58 +02:00
Wei Yongjun aa4e133184 ARM: OMAP2+: Make symbol 'pdata_quirks_init_clocks' static
The sparse tool complains as follows:

arch/arm/mach-omap2/pdata-quirks.c:578:1: warning:
 symbol 'pdata_quirks_init_clocks' was not declared. Should it be static?

This symbol is not used outside of pdata-quirks.c, so this
commit marks it static.

Fixes: a15de032a7 ("ARM: OMAP2+: Init both prm and prcm nodes early for clocks")
Reported-by: Hulk Robot <hulkci@huawei.com>
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-24 12:17:38 +02:00
Carlos Leija b3d09a06d8 ARM: OMAP4: PM: update ROM return address for OSWR and OFF
We need to add a dummy smc call to the cpuidle wakeup path to force the
ROM code to save the return address after MMU is enabled again. This is
needed to prevent random hangs on secure devices like droid4.

Otherwise the system will eventually hang when entering deeper SoC idle
states with the core and mpu domains in open-switch retention (OSWR).
The hang happens as the ROM code tries to use the earlier physical return
address set by omap-headsmp.S with MMU off while waking up CPU1 again.

The hangs started happening in theory already with commit caf8c87d7f
("ARM: OMAP2+: Allow core oswr for omap4"), but in practise the issue went
unnoticed as various drivers were often blocking any deeper idle states
with hardware autoidle features.

This patch is based on an earlier TI Linux kernel tree commit 92f0b3028d9e
("OMAP4: PM: update ROM return address for OSWR and OFF") written by
Carlos Leija <cileija@ti.com>, Praneeth Bajjuri <praneeth@ti.com>, and
Bryan Buckley <bryan.buckley@ti.com>. A later version of the patch was
updated to use CPU_PM notifiers by Tero Kristo <t-kristo@ti.com>.

Signed-off-by: Carlos Leija <cileija@ti.com>
Signed-off-by: Praneeth Bajjuri <praneeth@ti.com>
Signed-off-by: Bryan Buckley <bryan.buckley@ti.com>
Signed-off-by: Tero Kristo <t-kristo@ti.com>
Fixes: caf8c87d7f ("ARM: OMAP2+: Allow core oswr for omap4")
Reported-by: Carl Philipp Klemm <philipp@uvos.xyz>
Reported-by: Merlijn Wajer <merlijn@wizzup.org>
Cc: Ivan Jelincic <parazyd@dyne.org>
Cc: Pavel Machek <pavel@ucw.cz>
Cc: Sebastian Reichel <sre@kernel.org>
Cc: Tero Kristo <kristo@kernel.org>
[tony@atomide.com: updated to apply, updated description]
Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-17 15:15:52 +02:00
Tony Lindgren 30916faa1a ARM: OMAP4: Fix PMIC voltage domains for bionic
We are now registering the mpu domain three times instead of registering
mpu, core and iva domains like we should.

Fixes: d44fa156dc ("ARM: OMAP2+: Configure voltage controller for cpcap")
Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-17 15:15:45 +02:00
Tony Lindgren f21af4257c ARM: OMAP2+: Stop building legacy code for dra7 and omap4/5
With the recent changes we are now booting am3/4, dra7, and omap4/5
without legacy data using devicetree, simple-pm-bus and genpd. Let's not
initialize and build the legacy data unless CONFIG_OMAP_HWMOD is selected
based on the SoCs enabled in .config.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-12 10:11:24 +02:00
Tony Lindgren 569519de00 Merge branches 'omap-for-v5.13/genpd-dra7', 'omap-for-v5.13/genpd-omap4' and 'omap-for-v5.13/genpd-omap5' into omap-for-v5.13/genpd-drop-legacy
Merge together branches dropping legacy data to avoid a minor merge conflict.
2021-03-10 14:19:20 +02:00
Tony Lindgren 229e1e1146 ARM: OMAP2+: Drop legacy platform data for omap5 hwmod
We can now probe interconnects with simple-pm-bus and genpd.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-10 14:05:02 +02:00
Tony Lindgren e98cf7e694 ARM: OMAP2+: Drop legacy platform data for omap5 l3
We can now probe interconnects with simple-pm-bus and genpd.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-10 14:05:02 +02:00
Tony Lindgren 5b9a7b0d2f ARM: OMAP2+: Drop legacy platform data for omap5 l4_cfg
We can now probe interconnects with simple-pm-bus and genpd.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-10 14:05:01 +02:00
Tony Lindgren 8a32531946 ARM: OMAP2+: Drop legacy platform data for omap5 l4_per
We can now probe interconnects with simple-pm-bus and genpd.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-10 14:05:01 +02:00
Tony Lindgren a91560500c ARM: OMAP2+: Drop legacy platform data for omap5 l4_wkup
We can now probe interconnects with simple-pm-bus and genpd.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-10 14:05:00 +02:00
Tony Lindgren 21206c8f2c ARM: OMAP2+: Drop legacy platform data for omap5 sata
We can now probe devices with ti-sysc interconnect driver and dts data.
Let's drop the related platform data and custom ti,hwmods dts property.

As we're just dropping data, and the early platform data init is based on
the custom ti,hwmods property, we want to drop both the platform data and
ti,hwmods property in a single patch.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-10 14:05:00 +02:00
Tony Lindgren 3c648501f8 ARM: OMAP2+: Drop legacy platform data for omap5 mpu
We can now probe devices with ti-sysc interconnect driver and dts data.
Let's drop the related platform data and custom ti,hwmods dts property.

As we're just dropping data, and the early platform data init is based on
the custom ti,hwmods property, we want to drop both the platform data and
ti,hwmods property in a single patch.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-10 14:05:00 +02:00
Tony Lindgren aa820b664f ARM: OMAP2+: Drop legacy platform data for omap5 emif
We can now probe devices with ti-sysc interconnect driver and dts data.
Let's drop the related platform data and custom ti,hwmods dts property.

As we're just dropping data, and the early platform data init is based on
the custom ti,hwmods property, we want to drop both the platform data and
ti,hwmods property in a single patch.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-10 14:04:59 +02:00
Tony Lindgren 1006777ef4 ARM: OMAP2+: Drop legacy platform data for omap5 dmm
We can now probe devices with ti-sysc interconnect driver and dts data.
Let's drop the related platform data and custom ti,hwmods dts property.

As we're just dropping data, and the early platform data init is based on
the custom ti,hwmods property, we want to drop both the platform data and
ti,hwmods property in a single patch.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-10 14:04:59 +02:00
Tony Lindgren 2584d7e7f8 ARM: OMAP2+: Drop legacy platform data for omap4 hwmod
We can now probe interconnects with simple-pm-bus and genpd.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-10 14:04:37 +02:00
Tony Lindgren 3e1ea524d6 ARM: OMAP2+: Drop legacy platform data for omap4 l3
We can now probe interconnects with simple-pm-bus and genpd.

Let's drop the legacy data along with the ti,hwmods property and flip
over to using simple-pm-bus instead of simple-bus.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-10 14:04:37 +02:00
Tony Lindgren 058b4880a8 ARM: OMAP2+: Drop legacy platform data for omap4 l4_cfg
We can now probe interconnects with simple-pm-bus and genpd.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-10 14:04:36 +02:00
Tony Lindgren 6dd3c92597 ARM: OMAP2+: Drop legacy platform data for omap4 l4_per
We can now probe interconnects with simple-pm-bus and genpd.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-10 14:04:36 +02:00
Tony Lindgren e9c5aafaab ARM: OMAP2+: Drop legacy platform data for omap4 l4_wkup
We can now probe interconnects with simple-pm-bus and genpd.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-10 14:04:35 +02:00
Tony Lindgren 229f3477d6 ARM: OMAP2+: Drop legacy platform data for omap4 mpu
We can now probe devices with ti-sysc interconnect driver and dts data.
Let's drop the related platform data and custom ti,hwmods dts property.

As we're just dropping data, and the early platform data init is based on
the custom ti,hwmods property, we want to drop both the platform data and
ti,hwmods property in a single patch.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-10 14:04:35 +02:00
Tony Lindgren 88b1879168 ARM: OMAP2+: Drop legacy platform data for omap4 debugss
We can now probe devices with ti-sysc interconnect driver and dts data.
Let's drop the related platform data and custom ti,hwmods dts property.

As we're just dropping data, and the early platform data init is based on
the custom ti,hwmods property, we want to drop both the platform data and
ti,hwmods property in a single patch.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-10 14:04:35 +02:00
Tony Lindgren a8876b4a3d ARM: OMAP2+: Drop legacy platform data for omap4 emif
We can now probe devices with ti-sysc interconnect driver and dts data.
Let's drop the related platform data and custom ti,hwmods dts property.

As we're just dropping data, and the early platform data init is based on
the custom ti,hwmods property, we want to drop both the platform data and
ti,hwmods property in a single patch.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-10 14:04:34 +02:00
Tony Lindgren 35c34fbcbf ARM: OMAP2+: Drop legacy platform data for omap4 dmm
We can now probe devices with ti-sysc interconnect driver and dts data.
Let's drop the related platform data and custom ti,hwmods dts property.

As we're just dropping data, and the early platform data init is based on
the custom ti,hwmods property, we want to drop both the platform data and
ti,hwmods property in a single patch.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-10 14:04:34 +02:00
Tony Lindgren 40dbf5b13f ARM: OMAP2+: Drop legacy platform data for omap4 control modules
We can now probe devices with ti-sysc interconnect driver and dts
data. Let's drop the related platform data and custom ti,hwmods
dts property.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-10 14:04:33 +02:00
Tony Lindgren eb586ea39f ARM: OMAP2+: Drop legacy platform data for omap4 iss
We can now probe devices with ti-sysc interconnect driver and dts
data. Let's drop the related platform data and custom ti,hwmods
dts property.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-10 14:04:33 +02:00
Tony Lindgren 54bc4edb3e ARM: OMAP2+: Drop legacy platform data for dra7 hwmod
We can now probe interconnects with simple-pm-bus and genpd.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-10 14:04:07 +02:00
Tony Lindgren 53fb6ae97a ARM: OMAP2+: Drop legacy platform data for dra7 l3
We can now probe interconnects with simple-pm-bus and genpd.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-10 14:04:07 +02:00
Tony Lindgren b5ac9dedc1 ARM: OMAP2+: Drop legacy platform data for dra7 l4_cfg
We can now probe interconnects with simple-pm-bus and genpd.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-10 14:04:07 +02:00
Tony Lindgren b3db9b25ff ARM: OMAP2+: Drop legacy platform data for dra7 l4_per3
We can now probe interconnects with simple-pm-bus and genpd.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-10 14:04:07 +02:00
Tony Lindgren ca319f4f41 ARM: OMAP2+: Drop legacy platform data for dra7 l4_per2
We can now probe interconnects with simple-pm-bus and genpd.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-10 14:04:07 +02:00
Tony Lindgren 47a4b458c1 ARM: OMAP2+: Drop legacy platform data for dra7 l4_per1
We can now probe interconnects with simple-pm-bus and genpd.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-10 14:04:07 +02:00
Tony Lindgren 3e09b7d201 ARM: OMAP2+: Drop legacy platform data for dra7 l4_wkup
We can now probe interconnects with simple-pm-bus and genpd.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-10 14:04:07 +02:00
Tony Lindgren 860e246443 ARM: OMAP2+: Drop legacy platform data for dra7 dmm
We can now probe devices with ti-sysc interconnect driver and dts data.
Let's drop the related platform data and custom ti,hwmods dts property.

As we're just dropping data, and the early platform data init is based on
the custom ti,hwmods property, we want to drop both the platform data and
ti,hwmods property in a single patch.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-10 14:04:07 +02:00
Tony Lindgren 66b2f7fee1 ARM: OMAP2+: Drop legacy platform data for dra7 mpu
We can now probe devices with ti-sysc interconnect driver and dts data.
Let's drop the related platform data and custom ti,hwmods dts property.

As we're just dropping data, and the early platform data init is based on
the custom ti,hwmods property, we want to drop both the platform data and
ti,hwmods property in a single patch.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-10 14:04:07 +02:00
Tony Lindgren 98feab31ac ARM: OMAP2+: Drop legacy platform data for dra7 sata
We can now probe devices with ti-sysc interconnect driver and dts data.
Let's drop the related platform data and custom ti,hwmods dts property.

As we're just dropping data, and the early platform data init is based on
the custom ti,hwmods property, we want to drop both the platform data and
ti,hwmods property in a single patch.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2021-03-10 14:04:07 +02:00