Two regression fixes for omaps

Fix AM33XX_IOPAD macro that broke after recent pinctrl changes
 to use #pinctrl-cells = 2. And fix omap_enter_idle_coupled()
 for cases where cpu_cluster_pm_enter() returns an error as
 otherwise we may end up wrongly idling the MPU domain on the
 next WFI.
 -----BEGIN PGP SIGNATURE-----
 
 iQJFBAABCAAvFiEEkgNvrZJU/QSQYIcQG9Q+yVyrpXMFAl91oP4RHHRvbnlAYXRv
 bWlkZS5jb20ACgkQG9Q+yVyrpXNjyQ/+O5YLq9sOHq4QS5HD8xbopZ6RZsGiodwo
 RDuKINgh24kfRsAJGJ/GTN8rq0H1Mf86kviXWl7xE7PElFGRNzk1R9YmiJKfwjDf
 xKm7WuEipfxG18CMjp2XFPq+/1ANbnKyRVR/zq/uSInDvIcxuQlz4OrrrkR/MCOv
 PL34VVD0k2XaA5cQc62jyZXsWLja7xflG6+wkSmx5GvLoa4kDAfCyPXx+e+21WPH
 PvMgO4G2VKsUrzevSCg4B3oqW1HtreBO3uhp71C1UBrUI7xaBqJPifoZ/DusI60s
 5MNqVu+cbOOfP3h1VHYfPKfqrduaWqfxWhe81TShEiz6J9HoHHnTg2jt7R854o8Q
 nvpNV8Kwbf8huTamIm1//itNHeuex1eGeWPbdjNR3wz4Fv6qYVV3UbKACRgmkAHm
 nRrS7KOwBs1a9NGoST2gex05NhfAdw7RInRXoI/7YRsgC1eTwmABaX9lYpueFS7g
 BO/IlLI5PFaGDDDz8VYeT1VAzpkEf/nwIfLcIVCOpXpwenXmQHZHgeEYpM91omLs
 u2csHQEEhmbDuPX/dJKsPJIUQ7eHZWhlLx8zl4FEYCmLlremVyD4ll1QpXtP/XdD
 k8+rJqFn35CuR8nqeMUdLt9cs2+Ch/VK7+83FuiBnm/CdnEwxY/zByv6CSCYyhxI
 EnRILdVOEO0=
 =sdtl
 -----END PGP SIGNATURE-----

Merge tag 'omap-for-v5.9/fixes-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap into arm/fixes

Two regression fixes for omaps

Fix AM33XX_IOPAD macro that broke after recent pinctrl changes
to use #pinctrl-cells = 2. And fix omap_enter_idle_coupled()
for cases where cpu_cluster_pm_enter() returns an error as
otherwise we may end up wrongly idling the MPU domain on the
next WFI.

* tag 'omap-for-v5.9/fixes-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap:
  ARM: OMAP2+: Restore MPU power domain if cpu_cluster_pm_enter() fails
  ARM: dts: am33xx: modify AM33XX_IOPAD for #pinctrl-cells = 2

Link: https://lore.kernel.org/r/pull-1601544624-617679@atomide.com
Signed-off-by: Olof Johansson <olof@lixom.net>
This commit is contained in:
Olof Johansson 2020-10-03 12:45:11 -07:00
commit 6869f774b1
2 changed files with 4 additions and 2 deletions

View file

@ -174,8 +174,10 @@ static int omap_enter_idle_coupled(struct cpuidle_device *dev,
*/
if (mpuss_can_lose_context) {
error = cpu_cluster_pm_enter();
if (error)
if (error) {
omap_set_pwrdm_state(mpu_pd, PWRDM_POWER_ON);
goto cpu_cluster_pm_out;
}
}
}

View file

@ -64,7 +64,7 @@
#define OMAP3_WKUP_IOPAD(pa, val) OMAP_IOPAD_OFFSET((pa), 0x2a00) (val)
#define DM814X_IOPAD(pa, val) OMAP_IOPAD_OFFSET((pa), 0x0800) (val)
#define DM816X_IOPAD(pa, val) OMAP_IOPAD_OFFSET((pa), 0x0800) (val)
#define AM33XX_IOPAD(pa, val) OMAP_IOPAD_OFFSET((pa), 0x0800) (val)
#define AM33XX_IOPAD(pa, val) OMAP_IOPAD_OFFSET((pa), 0x0800) (val) (0)
#define AM33XX_PADCONF(pa, conf, mux) OMAP_IOPAD_OFFSET((pa), 0x0800) (conf) (mux)
/*