* [PATCH 1/4] ARM: OMAP2+: Fix l4ls clk domain handling in STANDBY
2025-03-18 23:00 [PATCH 0/4] PM: TI: AM335x: PM STANDBY fixes Sukrut Bellary
@ 2025-03-18 23:00 ` Sukrut Bellary
2025-03-18 23:00 ` [PATCH 2/4] pmdomain: ti: Fix STANDBY handling of PER power domain Sukrut Bellary
` (4 subsequent siblings)
5 siblings, 0 replies; 13+ messages in thread
From: Sukrut Bellary @ 2025-03-18 23:00 UTC (permalink / raw)
To: Kevin Hilman, Russell King, Rob Herring, Tony Lindgren,
Krzysztof Kozlowski, Nishanth Menon, Ulf Hansson
Cc: Sukrut Bellary, Aaro Koskinen, Andreas Kemnade, Roger Quadros,
Conor Dooley, Santosh Shilimkar, Bajjuri Praneeth,
Raghavendra Vignesh, Bin Liu, linux-kernel, linux-arm-kernel,
linux-omap, devicetree, linux-pm
Don't put the l4ls clk domain to sleep in case of standby.
Since CM3 PM FW[1](ti-v4.1.y) doesn't wake-up/enable the l4ls clk domain
upon wake-up, CM3 PM FW fails to wake-up the MPU.
[1] https://git.ti.com/cgit/processor-firmware/ti-amx3-cm3-pm-firmware/
Signed-off-by: Sukrut Bellary <sbellary@baylibre.com>
---
arch/arm/mach-omap2/clockdomain.h | 1 +
arch/arm/mach-omap2/clockdomains33xx_data.c | 2 +-
arch/arm/mach-omap2/cm33xx.c | 14 +++++++++++++-
3 files changed, 15 insertions(+), 2 deletions(-)
diff --git a/arch/arm/mach-omap2/clockdomain.h b/arch/arm/mach-omap2/clockdomain.h
index c36fb2721261..86a2f9e5d0ef 100644
--- a/arch/arm/mach-omap2/clockdomain.h
+++ b/arch/arm/mach-omap2/clockdomain.h
@@ -48,6 +48,7 @@
#define CLKDM_NO_AUTODEPS (1 << 4)
#define CLKDM_ACTIVE_WITH_MPU (1 << 5)
#define CLKDM_MISSING_IDLE_REPORTING (1 << 6)
+#define CLKDM_STANDBY_FORCE_WAKEUP BIT(7)
#define CLKDM_CAN_HWSUP (CLKDM_CAN_ENABLE_AUTO | CLKDM_CAN_DISABLE_AUTO)
#define CLKDM_CAN_SWSUP (CLKDM_CAN_FORCE_SLEEP | CLKDM_CAN_FORCE_WAKEUP)
diff --git a/arch/arm/mach-omap2/clockdomains33xx_data.c b/arch/arm/mach-omap2/clockdomains33xx_data.c
index 87f4e927eb18..c05a3c07d448 100644
--- a/arch/arm/mach-omap2/clockdomains33xx_data.c
+++ b/arch/arm/mach-omap2/clockdomains33xx_data.c
@@ -19,7 +19,7 @@ static struct clockdomain l4ls_am33xx_clkdm = {
.pwrdm = { .name = "per_pwrdm" },
.cm_inst = AM33XX_CM_PER_MOD,
.clkdm_offs = AM33XX_CM_PER_L4LS_CLKSTCTRL_OFFSET,
- .flags = CLKDM_CAN_SWSUP,
+ .flags = CLKDM_CAN_SWSUP | CLKDM_STANDBY_FORCE_WAKEUP,
};
static struct clockdomain l3s_am33xx_clkdm = {
diff --git a/arch/arm/mach-omap2/cm33xx.c b/arch/arm/mach-omap2/cm33xx.c
index acdf72a541c0..a4dd42abda89 100644
--- a/arch/arm/mach-omap2/cm33xx.c
+++ b/arch/arm/mach-omap2/cm33xx.c
@@ -20,6 +20,9 @@
#include "cm-regbits-34xx.h"
#include "cm-regbits-33xx.h"
#include "prm33xx.h"
+#if IS_ENABLED(CONFIG_SUSPEND)
+#include <linux/suspend.h>
+#endif
/*
* CLKCTRL_IDLEST_*: possible values for the CM_*_CLKCTRL.IDLEST bitfield:
@@ -328,8 +331,17 @@ static int am33xx_clkdm_clk_disable(struct clockdomain *clkdm)
{
bool hwsup = false;
+#if IS_ENABLED(CONFIG_SUSPEND)
+ /*
+ * In case of standby, Don't put the l4ls clk domain to sleep.
+ * Since CM3 PM FW doesn't wake-up/enable the l4ls clk domain
+ * upon wake-up, CM3 PM FW fails to wake-up th MPU.
+ */
+ if (pm_suspend_target_state == PM_SUSPEND_STANDBY &&
+ (clkdm->flags & CLKDM_STANDBY_FORCE_WAKEUP))
+ return 0;
+#endif
hwsup = am33xx_cm_is_clkdm_in_hwsup(clkdm->cm_inst, clkdm->clkdm_offs);
-
if (!hwsup && (clkdm->flags & CLKDM_CAN_FORCE_SLEEP))
am33xx_clkdm_sleep(clkdm);
--
2.34.1
^ permalink raw reply related [flat|nested] 13+ messages in thread* [PATCH 2/4] pmdomain: ti: Fix STANDBY handling of PER power domain
2025-03-18 23:00 [PATCH 0/4] PM: TI: AM335x: PM STANDBY fixes Sukrut Bellary
2025-03-18 23:00 ` [PATCH 1/4] ARM: OMAP2+: Fix l4ls clk domain handling in STANDBY Sukrut Bellary
@ 2025-03-18 23:00 ` Sukrut Bellary
2025-05-08 13:14 ` Kevin Hilman
2025-05-19 14:19 ` Ulf Hansson
2025-03-18 23:00 ` [PATCH 3/4] ARM: dts: am335x: Set wakeup-source for UART0 Sukrut Bellary
` (3 subsequent siblings)
5 siblings, 2 replies; 13+ messages in thread
From: Sukrut Bellary @ 2025-03-18 23:00 UTC (permalink / raw)
To: Kevin Hilman, Russell King, Rob Herring, Tony Lindgren,
Krzysztof Kozlowski, Nishanth Menon, Ulf Hansson
Cc: Sukrut Bellary, Aaro Koskinen, Andreas Kemnade, Roger Quadros,
Conor Dooley, Santosh Shilimkar, Bajjuri Praneeth,
Raghavendra Vignesh, Bin Liu, linux-kernel, linux-arm-kernel,
linux-omap, devicetree, linux-pm
Per AM335x TRM[1](section 8.1.4.3 Power mode), in case of STANDBY,
PER domain should be ON. So, fix the PER power domain handling on standby.
[1] https://www.ti.com/lit/ug/spruh73q/spruh73q.pdf
Signed-off-by: Sukrut Bellary <sbellary@baylibre.com>
---
drivers/pmdomain/ti/omap_prm.c | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/drivers/pmdomain/ti/omap_prm.c b/drivers/pmdomain/ti/omap_prm.c
index b8ceb3c2b81c..7e36e675a8c6 100644
--- a/drivers/pmdomain/ti/omap_prm.c
+++ b/drivers/pmdomain/ti/omap_prm.c
@@ -18,7 +18,9 @@
#include <linux/pm_domain.h>
#include <linux/reset-controller.h>
#include <linux/delay.h>
-
+#if IS_ENABLED(CONFIG_SUSPEND)
+#include <linux/suspend.h>
+#endif
#include <linux/platform_data/ti-prm.h>
enum omap_prm_domain_mode {
@@ -88,6 +90,7 @@ struct omap_reset_data {
#define OMAP_PRM_HAS_RSTST BIT(1)
#define OMAP_PRM_HAS_NO_CLKDM BIT(2)
#define OMAP_PRM_RET_WHEN_IDLE BIT(3)
+#define OMAP_PRM_ON_WHEN_STANDBY BIT(4)
#define OMAP_PRM_HAS_RESETS (OMAP_PRM_HAS_RSTCTRL | OMAP_PRM_HAS_RSTST)
@@ -404,7 +407,8 @@ static const struct omap_prm_data am3_prm_data[] = {
.name = "per", .base = 0x44e00c00,
.pwrstctrl = 0xc, .pwrstst = 0x8, .dmap = &omap_prm_noinact,
.rstctrl = 0x0, .rstmap = am3_per_rst_map,
- .flags = OMAP_PRM_HAS_RSTCTRL, .clkdm_name = "pruss_ocp"
+ .flags = OMAP_PRM_HAS_RSTCTRL | OMAP_PRM_ON_WHEN_STANDBY,
+ .clkdm_name = "pruss_ocp",
},
{
.name = "wkup", .base = 0x44e00d00,
--
2.34.1
^ permalink raw reply related [flat|nested] 13+ messages in thread* Re: [PATCH 2/4] pmdomain: ti: Fix STANDBY handling of PER power domain
2025-03-18 23:00 ` [PATCH 2/4] pmdomain: ti: Fix STANDBY handling of PER power domain Sukrut Bellary
@ 2025-05-08 13:14 ` Kevin Hilman
2025-05-19 14:19 ` Ulf Hansson
1 sibling, 0 replies; 13+ messages in thread
From: Kevin Hilman @ 2025-05-08 13:14 UTC (permalink / raw)
To: Sukrut Bellary, Russell King, Rob Herring, Tony Lindgren,
Krzysztof Kozlowski, Nishanth Menon, Ulf Hansson
Cc: Sukrut Bellary, Aaro Koskinen, Andreas Kemnade, Roger Quadros,
Conor Dooley, Santosh Shilimkar, Bajjuri Praneeth,
Raghavendra Vignesh, Bin Liu, linux-kernel, linux-arm-kernel,
linux-omap, devicetree, linux-pm
Sukrut Bellary <sbellary@baylibre.com> writes:
> Per AM335x TRM[1](section 8.1.4.3 Power mode), in case of STANDBY,
> PER domain should be ON. So, fix the PER power domain handling on standby.
>
> [1] https://www.ti.com/lit/ug/spruh73q/spruh73q.pdf
>
> Signed-off-by: Sukrut Bellary <sbellary@baylibre.com>
Reviewed-by: Kevin Hilman <khilman@baylibre.com>
Ulf, this series has been tested now. Go ahead and take this patch.
Thanks,
Kevin
> ---
> drivers/pmdomain/ti/omap_prm.c | 8 ++++++--
> 1 file changed, 6 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/pmdomain/ti/omap_prm.c b/drivers/pmdomain/ti/omap_prm.c
> index b8ceb3c2b81c..7e36e675a8c6 100644
> --- a/drivers/pmdomain/ti/omap_prm.c
> +++ b/drivers/pmdomain/ti/omap_prm.c
> @@ -18,7 +18,9 @@
> #include <linux/pm_domain.h>
> #include <linux/reset-controller.h>
> #include <linux/delay.h>
> -
> +#if IS_ENABLED(CONFIG_SUSPEND)
> +#include <linux/suspend.h>
> +#endif
> #include <linux/platform_data/ti-prm.h>
>
> enum omap_prm_domain_mode {
> @@ -88,6 +90,7 @@ struct omap_reset_data {
> #define OMAP_PRM_HAS_RSTST BIT(1)
> #define OMAP_PRM_HAS_NO_CLKDM BIT(2)
> #define OMAP_PRM_RET_WHEN_IDLE BIT(3)
> +#define OMAP_PRM_ON_WHEN_STANDBY BIT(4)
>
> #define OMAP_PRM_HAS_RESETS (OMAP_PRM_HAS_RSTCTRL | OMAP_PRM_HAS_RSTST)
>
> @@ -404,7 +407,8 @@ static const struct omap_prm_data am3_prm_data[] = {
> .name = "per", .base = 0x44e00c00,
> .pwrstctrl = 0xc, .pwrstst = 0x8, .dmap = &omap_prm_noinact,
> .rstctrl = 0x0, .rstmap = am3_per_rst_map,
> - .flags = OMAP_PRM_HAS_RSTCTRL, .clkdm_name = "pruss_ocp"
> + .flags = OMAP_PRM_HAS_RSTCTRL | OMAP_PRM_ON_WHEN_STANDBY,
> + .clkdm_name = "pruss_ocp",
> },
> {
> .name = "wkup", .base = 0x44e00d00,
> --
> 2.34.1
^ permalink raw reply [flat|nested] 13+ messages in thread* Re: [PATCH 2/4] pmdomain: ti: Fix STANDBY handling of PER power domain
2025-03-18 23:00 ` [PATCH 2/4] pmdomain: ti: Fix STANDBY handling of PER power domain Sukrut Bellary
2025-05-08 13:14 ` Kevin Hilman
@ 2025-05-19 14:19 ` Ulf Hansson
1 sibling, 0 replies; 13+ messages in thread
From: Ulf Hansson @ 2025-05-19 14:19 UTC (permalink / raw)
To: Sukrut Bellary
Cc: Kevin Hilman, Russell King, Rob Herring, Tony Lindgren,
Krzysztof Kozlowski, Nishanth Menon, Aaro Koskinen,
Andreas Kemnade, Roger Quadros, Conor Dooley, Santosh Shilimkar,
Bajjuri Praneeth, Raghavendra Vignesh, Bin Liu, linux-kernel,
linux-arm-kernel, linux-omap, devicetree, linux-pm
On Wed, 19 Mar 2025 at 00:00, Sukrut Bellary <sbellary@baylibre.com> wrote:
>
> Per AM335x TRM[1](section 8.1.4.3 Power mode), in case of STANDBY,
> PER domain should be ON. So, fix the PER power domain handling on standby.
>
> [1] https://www.ti.com/lit/ug/spruh73q/spruh73q.pdf
>
> Signed-off-by: Sukrut Bellary <sbellary@baylibre.com>
Applied for next, thanks!
Kind regards
Uffe
> ---
> drivers/pmdomain/ti/omap_prm.c | 8 ++++++--
> 1 file changed, 6 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/pmdomain/ti/omap_prm.c b/drivers/pmdomain/ti/omap_prm.c
> index b8ceb3c2b81c..7e36e675a8c6 100644
> --- a/drivers/pmdomain/ti/omap_prm.c
> +++ b/drivers/pmdomain/ti/omap_prm.c
> @@ -18,7 +18,9 @@
> #include <linux/pm_domain.h>
> #include <linux/reset-controller.h>
> #include <linux/delay.h>
> -
> +#if IS_ENABLED(CONFIG_SUSPEND)
> +#include <linux/suspend.h>
> +#endif
> #include <linux/platform_data/ti-prm.h>
>
> enum omap_prm_domain_mode {
> @@ -88,6 +90,7 @@ struct omap_reset_data {
> #define OMAP_PRM_HAS_RSTST BIT(1)
> #define OMAP_PRM_HAS_NO_CLKDM BIT(2)
> #define OMAP_PRM_RET_WHEN_IDLE BIT(3)
> +#define OMAP_PRM_ON_WHEN_STANDBY BIT(4)
>
> #define OMAP_PRM_HAS_RESETS (OMAP_PRM_HAS_RSTCTRL | OMAP_PRM_HAS_RSTST)
>
> @@ -404,7 +407,8 @@ static const struct omap_prm_data am3_prm_data[] = {
> .name = "per", .base = 0x44e00c00,
> .pwrstctrl = 0xc, .pwrstst = 0x8, .dmap = &omap_prm_noinact,
> .rstctrl = 0x0, .rstmap = am3_per_rst_map,
> - .flags = OMAP_PRM_HAS_RSTCTRL, .clkdm_name = "pruss_ocp"
> + .flags = OMAP_PRM_HAS_RSTCTRL | OMAP_PRM_ON_WHEN_STANDBY,
> + .clkdm_name = "pruss_ocp",
> },
> {
> .name = "wkup", .base = 0x44e00d00,
> --
> 2.34.1
>
^ permalink raw reply [flat|nested] 13+ messages in thread
* [PATCH 3/4] ARM: dts: am335x: Set wakeup-source for UART0
2025-03-18 23:00 [PATCH 0/4] PM: TI: AM335x: PM STANDBY fixes Sukrut Bellary
2025-03-18 23:00 ` [PATCH 1/4] ARM: OMAP2+: Fix l4ls clk domain handling in STANDBY Sukrut Bellary
2025-03-18 23:00 ` [PATCH 2/4] pmdomain: ti: Fix STANDBY handling of PER power domain Sukrut Bellary
@ 2025-03-18 23:00 ` Sukrut Bellary
2025-03-18 23:00 ` [PATCH 4/4] ARM: multi_v7_defconfig: Enable am335x PM configs Sukrut Bellary
` (2 subsequent siblings)
5 siblings, 0 replies; 13+ messages in thread
From: Sukrut Bellary @ 2025-03-18 23:00 UTC (permalink / raw)
To: Kevin Hilman, Russell King, Rob Herring, Tony Lindgren,
Krzysztof Kozlowski, Nishanth Menon, Ulf Hansson
Cc: Sukrut Bellary, Aaro Koskinen, Andreas Kemnade, Roger Quadros,
Conor Dooley, Santosh Shilimkar, Bajjuri Praneeth,
Raghavendra Vignesh, Bin Liu, linux-kernel, linux-arm-kernel,
linux-omap, devicetree, linux-pm
On am335x evm[1], UART0(UART1-HW) has a wakeup capability.
Set wakeup-source, which will be used in the omap serial driver to enable
the device wakeup capability.
[1] https://www.ti.com/tool/TMDXEVM3358
[2] AM335x TRM - https://www.ti.com/lit/ug/spruh73q/spruh73q.pdf
Signed-off-by: Sukrut Bellary <sbellary@baylibre.com>
---
arch/arm/boot/dts/ti/omap/am335x-evm.dts | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/arm/boot/dts/ti/omap/am335x-evm.dts b/arch/arm/boot/dts/ti/omap/am335x-evm.dts
index 61bf8bcd4c4e..20222f82f21b 100644
--- a/arch/arm/boot/dts/ti/omap/am335x-evm.dts
+++ b/arch/arm/boot/dts/ti/omap/am335x-evm.dts
@@ -388,7 +388,7 @@ AM33XX_PADCONF(AM335X_PIN_UART0_RTSN, PIN_INPUT_PULLDOWN, MUX_MODE2) /* uart0_rt
&uart0 {
pinctrl-names = "default";
pinctrl-0 = <&uart0_pins>;
-
+ wakeup-source;
status = "okay";
};
--
2.34.1
^ permalink raw reply related [flat|nested] 13+ messages in thread* [PATCH 4/4] ARM: multi_v7_defconfig: Enable am335x PM configs
2025-03-18 23:00 [PATCH 0/4] PM: TI: AM335x: PM STANDBY fixes Sukrut Bellary
` (2 preceding siblings ...)
2025-03-18 23:00 ` [PATCH 3/4] ARM: dts: am335x: Set wakeup-source for UART0 Sukrut Bellary
@ 2025-03-18 23:00 ` Sukrut Bellary
2025-05-08 13:20 ` Kevin Hilman
2025-04-11 0:30 ` [PATCH 0/4] PM: TI: AM335x: PM STANDBY fixes Kevin Hilman
2025-05-06 20:01 ` Judith Mendez
5 siblings, 1 reply; 13+ messages in thread
From: Sukrut Bellary @ 2025-03-18 23:00 UTC (permalink / raw)
To: Kevin Hilman, Russell King, Rob Herring, Tony Lindgren,
Krzysztof Kozlowski, Nishanth Menon, Ulf Hansson
Cc: Sukrut Bellary, Aaro Koskinen, Andreas Kemnade, Roger Quadros,
Conor Dooley, Santosh Shilimkar, Bajjuri Praneeth,
Raghavendra Vignesh, Bin Liu, linux-kernel, linux-arm-kernel,
linux-omap, devicetree, linux-pm
Enable Power management related defconfigs for TI AM335x[1].
[1] AM335x TRM - https://www.ti.com/lit/ug/spruh73q/spruh73q.pdf
Signed-off-by: Sukrut Bellary <sbellary@baylibre.com>
---
arch/arm/configs/multi_v7_defconfig | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/arch/arm/configs/multi_v7_defconfig b/arch/arm/configs/multi_v7_defconfig
index 37e3baa33b67..1d2600b5f975 100644
--- a/arch/arm/configs/multi_v7_defconfig
+++ b/arch/arm/configs/multi_v7_defconfig
@@ -985,6 +985,7 @@ CONFIG_EDAC=y
CONFIG_EDAC_LAYERSCAPE=y
CONFIG_EDAC_HIGHBANK_MC=y
CONFIG_EDAC_HIGHBANK_L2=y
+CONFIG_RTC_DRV_OMAP=y
CONFIG_RTC_CLASS=y
CONFIG_RTC_DRV_AC100=y
CONFIG_RTC_DRV_AS3722=y
@@ -1095,6 +1096,7 @@ CONFIG_TEGRA_IOMMU_SMMU=y
CONFIG_EXYNOS_IOMMU=y
CONFIG_QCOM_IOMMU=y
CONFIG_REMOTEPROC=y
+CONFIG_WKUP_M3_RPROC=m
CONFIG_OMAP_REMOTEPROC=m
CONFIG_OMAP_REMOTEPROC_WATCHDOG=y
CONFIG_KEYSTONE_REMOTEPROC=m
@@ -1146,6 +1148,8 @@ CONFIG_ARCH_TEGRA_3x_SOC=y
CONFIG_ARCH_TEGRA_114_SOC=y
CONFIG_ARCH_TEGRA_124_SOC=y
CONFIG_SOC_TI=y
+CONFIG_AMX3_PM=m
+CONFIG_WKUP_M3_IPC=m
CONFIG_KEYSTONE_NAVIGATOR_QMSS=y
CONFIG_KEYSTONE_NAVIGATOR_DMA=y
CONFIG_RASPBERRYPI_POWER=y
@@ -1162,6 +1166,7 @@ CONFIG_EXTCON_MAX77693=m
CONFIG_EXTCON_MAX8997=m
CONFIG_EXTCON_USB_GPIO=y
CONFIG_TI_AEMIF=y
+CONFIG_TI_EMIF_SRAM=m
CONFIG_STM32_FMC2_EBI=y
CONFIG_EXYNOS5422_DMC=m
CONFIG_IIO=y
--
2.34.1
^ permalink raw reply related [flat|nested] 13+ messages in thread* Re: [PATCH 4/4] ARM: multi_v7_defconfig: Enable am335x PM configs
2025-03-18 23:00 ` [PATCH 4/4] ARM: multi_v7_defconfig: Enable am335x PM configs Sukrut Bellary
@ 2025-05-08 13:20 ` Kevin Hilman
2025-05-29 17:21 ` Kevin Hilman
0 siblings, 1 reply; 13+ messages in thread
From: Kevin Hilman @ 2025-05-08 13:20 UTC (permalink / raw)
To: Sukrut Bellary, Russell King, Rob Herring, Tony Lindgren,
Krzysztof Kozlowski, Nishanth Menon, Ulf Hansson, soc
Cc: Sukrut Bellary, Aaro Koskinen, Andreas Kemnade, Roger Quadros,
Conor Dooley, Santosh Shilimkar, Bajjuri Praneeth,
Raghavendra Vignesh, Bin Liu, linux-kernel, linux-arm-kernel,
linux-omap, devicetree, linux-pm
Sukrut Bellary <sbellary@baylibre.com> writes:
> Enable Power management related defconfigs for TI AM335x[1].
>
> [1] AM335x TRM - https://www.ti.com/lit/ug/spruh73q/spruh73q.pdf
>
> Signed-off-by: Sukrut Bellary <sbellary@baylibre.com>
Reviewed-by: Kevin Hilman <khilman@baylibre.com>
Arnd, can you take this via the SoC tree please?
Kevin
> ---
> arch/arm/configs/multi_v7_defconfig | 5 +++++
> 1 file changed, 5 insertions(+)
>
> diff --git a/arch/arm/configs/multi_v7_defconfig b/arch/arm/configs/multi_v7_defconfig
> index 37e3baa33b67..1d2600b5f975 100644
> --- a/arch/arm/configs/multi_v7_defconfig
> +++ b/arch/arm/configs/multi_v7_defconfig
> @@ -985,6 +985,7 @@ CONFIG_EDAC=y
> CONFIG_EDAC_LAYERSCAPE=y
> CONFIG_EDAC_HIGHBANK_MC=y
> CONFIG_EDAC_HIGHBANK_L2=y
> +CONFIG_RTC_DRV_OMAP=y
> CONFIG_RTC_CLASS=y
> CONFIG_RTC_DRV_AC100=y
> CONFIG_RTC_DRV_AS3722=y
> @@ -1095,6 +1096,7 @@ CONFIG_TEGRA_IOMMU_SMMU=y
> CONFIG_EXYNOS_IOMMU=y
> CONFIG_QCOM_IOMMU=y
> CONFIG_REMOTEPROC=y
> +CONFIG_WKUP_M3_RPROC=m
> CONFIG_OMAP_REMOTEPROC=m
> CONFIG_OMAP_REMOTEPROC_WATCHDOG=y
> CONFIG_KEYSTONE_REMOTEPROC=m
> @@ -1146,6 +1148,8 @@ CONFIG_ARCH_TEGRA_3x_SOC=y
> CONFIG_ARCH_TEGRA_114_SOC=y
> CONFIG_ARCH_TEGRA_124_SOC=y
> CONFIG_SOC_TI=y
> +CONFIG_AMX3_PM=m
> +CONFIG_WKUP_M3_IPC=m
> CONFIG_KEYSTONE_NAVIGATOR_QMSS=y
> CONFIG_KEYSTONE_NAVIGATOR_DMA=y
> CONFIG_RASPBERRYPI_POWER=y
> @@ -1162,6 +1166,7 @@ CONFIG_EXTCON_MAX77693=m
> CONFIG_EXTCON_MAX8997=m
> CONFIG_EXTCON_USB_GPIO=y
> CONFIG_TI_AEMIF=y
> +CONFIG_TI_EMIF_SRAM=m
> CONFIG_STM32_FMC2_EBI=y
> CONFIG_EXYNOS5422_DMC=m
> CONFIG_IIO=y
> --
> 2.34.1
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: [PATCH 4/4] ARM: multi_v7_defconfig: Enable am335x PM configs
2025-05-08 13:20 ` Kevin Hilman
@ 2025-05-29 17:21 ` Kevin Hilman
0 siblings, 0 replies; 13+ messages in thread
From: Kevin Hilman @ 2025-05-29 17:21 UTC (permalink / raw)
To: soc, Arnd Bergmann
Cc: Sukrut Bellary, Aaro Koskinen, Andreas Kemnade, Roger Quadros,
Conor Dooley, Santosh Shilimkar, Bajjuri Praneeth,
Raghavendra Vignesh, Bin Liu, linux-kernel, linux-arm-kernel,
linux-omap, devicetree, linux-pm, Sukrut Bellary, Russell King,
Rob Herring, Tony Lindgren, Krzysztof Kozlowski, Nishanth Menon,
Ulf Hansson
Hi Arnd,
Kevin Hilman <khilman@baylibre.com> writes:
> Sukrut Bellary <sbellary@baylibre.com> writes:
>
>> Enable Power management related defconfigs for TI AM335x[1].
>>
>> [1] AM335x TRM - https://www.ti.com/lit/ug/spruh73q/spruh73q.pdf
>>
>> Signed-off-by: Sukrut Bellary <sbellary@baylibre.com>
>
> Reviewed-by: Kevin Hilman <khilman@baylibre.com>
>
> Arnd, can you take this via the SoC tree please?
Looks like this slipped through the cracks for v6.16. Could you apply
this for v6.17 please?
Thanks,
Kevin
>> ---
>> arch/arm/configs/multi_v7_defconfig | 5 +++++
>> 1 file changed, 5 insertions(+)
>>
>> diff --git a/arch/arm/configs/multi_v7_defconfig b/arch/arm/configs/multi_v7_defconfig
>> index 37e3baa33b67..1d2600b5f975 100644
>> --- a/arch/arm/configs/multi_v7_defconfig
>> +++ b/arch/arm/configs/multi_v7_defconfig
>> @@ -985,6 +985,7 @@ CONFIG_EDAC=y
>> CONFIG_EDAC_LAYERSCAPE=y
>> CONFIG_EDAC_HIGHBANK_MC=y
>> CONFIG_EDAC_HIGHBANK_L2=y
>> +CONFIG_RTC_DRV_OMAP=y
>> CONFIG_RTC_CLASS=y
>> CONFIG_RTC_DRV_AC100=y
>> CONFIG_RTC_DRV_AS3722=y
>> @@ -1095,6 +1096,7 @@ CONFIG_TEGRA_IOMMU_SMMU=y
>> CONFIG_EXYNOS_IOMMU=y
>> CONFIG_QCOM_IOMMU=y
>> CONFIG_REMOTEPROC=y
>> +CONFIG_WKUP_M3_RPROC=m
>> CONFIG_OMAP_REMOTEPROC=m
>> CONFIG_OMAP_REMOTEPROC_WATCHDOG=y
>> CONFIG_KEYSTONE_REMOTEPROC=m
>> @@ -1146,6 +1148,8 @@ CONFIG_ARCH_TEGRA_3x_SOC=y
>> CONFIG_ARCH_TEGRA_114_SOC=y
>> CONFIG_ARCH_TEGRA_124_SOC=y
>> CONFIG_SOC_TI=y
>> +CONFIG_AMX3_PM=m
>> +CONFIG_WKUP_M3_IPC=m
>> CONFIG_KEYSTONE_NAVIGATOR_QMSS=y
>> CONFIG_KEYSTONE_NAVIGATOR_DMA=y
>> CONFIG_RASPBERRYPI_POWER=y
>> @@ -1162,6 +1166,7 @@ CONFIG_EXTCON_MAX77693=m
>> CONFIG_EXTCON_MAX8997=m
>> CONFIG_EXTCON_USB_GPIO=y
>> CONFIG_TI_AEMIF=y
>> +CONFIG_TI_EMIF_SRAM=m
>> CONFIG_STM32_FMC2_EBI=y
>> CONFIG_EXYNOS5422_DMC=m
>> CONFIG_IIO=y
>> --
>> 2.34.1
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: [PATCH 0/4] PM: TI: AM335x: PM STANDBY fixes
2025-03-18 23:00 [PATCH 0/4] PM: TI: AM335x: PM STANDBY fixes Sukrut Bellary
` (3 preceding siblings ...)
2025-03-18 23:00 ` [PATCH 4/4] ARM: multi_v7_defconfig: Enable am335x PM configs Sukrut Bellary
@ 2025-04-11 0:30 ` Kevin Hilman
2025-04-24 10:04 ` Ulf Hansson
2025-05-06 20:01 ` Judith Mendez
5 siblings, 1 reply; 13+ messages in thread
From: Kevin Hilman @ 2025-04-11 0:30 UTC (permalink / raw)
To: Sukrut Bellary, Russell King, Rob Herring, Tony Lindgren,
Krzysztof Kozlowski, Nishanth Menon, Ulf Hansson
Cc: Sukrut Bellary, Aaro Koskinen, Andreas Kemnade, Roger Quadros,
Conor Dooley, Santosh Shilimkar, Bajjuri Praneeth,
Raghavendra Vignesh, Bin Liu, linux-kernel, linux-arm-kernel,
linux-omap, devicetree, linux-pm
Sukrut Bellary <sbellary@baylibre.com> writes:
> This patch series fixes the Power management issues on TI's am335x soc.
>
> on AM335x, the wakeup doesn't work in the case of STANDBY.
This series is specifically targetted at the AM335x EVM (which I don't
have to test), so I'd appreciate getting any test reports for this
before I queue it up.
For AM335x, I currently only have the ICEv2 and Beaglebone Black,
neithor of which support suspend resume with RTC wake AFAICT. If they
do, please enlighten me. :)
I was able to do a basic boot test on the 2 boards I have with this
series applied on top of v6.15-rc1 and basic boot still works, but I was
not able to test the PM path that's being changed here, so any tests on
AM3 platforms that actually use this path are appreciated.
Kevin
^ permalink raw reply [flat|nested] 13+ messages in thread* Re: [PATCH 0/4] PM: TI: AM335x: PM STANDBY fixes
2025-04-11 0:30 ` [PATCH 0/4] PM: TI: AM335x: PM STANDBY fixes Kevin Hilman
@ 2025-04-24 10:04 ` Ulf Hansson
2025-05-02 16:52 ` Kevin Hilman
0 siblings, 1 reply; 13+ messages in thread
From: Ulf Hansson @ 2025-04-24 10:04 UTC (permalink / raw)
To: Sukrut Bellary, Kevin Hilman
Cc: Russell King, Rob Herring, Tony Lindgren, Krzysztof Kozlowski,
Nishanth Menon, Aaro Koskinen, Andreas Kemnade, Roger Quadros,
Conor Dooley, Santosh Shilimkar, Bajjuri Praneeth,
Raghavendra Vignesh, Bin Liu, linux-kernel, linux-arm-kernel,
linux-omap, devicetree, linux-pm
On Fri, 11 Apr 2025 at 02:30, Kevin Hilman <khilman@baylibre.com> wrote:
>
> Sukrut Bellary <sbellary@baylibre.com> writes:
>
> > This patch series fixes the Power management issues on TI's am335x soc.
> >
> > on AM335x, the wakeup doesn't work in the case of STANDBY.
>
> This series is specifically targetted at the AM335x EVM (which I don't
> have to test), so I'd appreciate getting any test reports for this
> before I queue it up.
>
> For AM335x, I currently only have the ICEv2 and Beaglebone Black,
> neithor of which support suspend resume with RTC wake AFAICT. If they
> do, please enlighten me. :)
>
> I was able to do a basic boot test on the 2 boards I have with this
> series applied on top of v6.15-rc1 and basic boot still works, but I was
> not able to test the PM path that's being changed here, so any tests on
> AM3 platforms that actually use this path are appreciated.
>
> Kevin
Is the pmdomain patch(3) ready to be applied here? Please let me know
if you want me to pick it up.
Kind regards
Uffe
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: [PATCH 0/4] PM: TI: AM335x: PM STANDBY fixes
2025-04-24 10:04 ` Ulf Hansson
@ 2025-05-02 16:52 ` Kevin Hilman
0 siblings, 0 replies; 13+ messages in thread
From: Kevin Hilman @ 2025-05-02 16:52 UTC (permalink / raw)
To: Ulf Hansson, Sukrut Bellary
Cc: Russell King, Rob Herring, Tony Lindgren, Krzysztof Kozlowski,
Nishanth Menon, Aaro Koskinen, Andreas Kemnade, Roger Quadros,
Conor Dooley, Santosh Shilimkar, Bajjuri Praneeth,
Raghavendra Vignesh, Bin Liu, linux-kernel, linux-arm-kernel,
linux-omap, devicetree, linux-pm
Ulf Hansson <ulf.hansson@linaro.org> writes:
> On Fri, 11 Apr 2025 at 02:30, Kevin Hilman <khilman@baylibre.com> wrote:
>>
>> Sukrut Bellary <sbellary@baylibre.com> writes:
>>
>> > This patch series fixes the Power management issues on TI's am335x soc.
>> >
>> > on AM335x, the wakeup doesn't work in the case of STANDBY.
>>
>> This series is specifically targetted at the AM335x EVM (which I don't
>> have to test), so I'd appreciate getting any test reports for this
>> before I queue it up.
>>
>> For AM335x, I currently only have the ICEv2 and Beaglebone Black,
>> neithor of which support suspend resume with RTC wake AFAICT. If they
>> do, please enlighten me. :)
>>
>> I was able to do a basic boot test on the 2 boards I have with this
>> series applied on top of v6.15-rc1 and basic boot still works, but I was
>> not able to test the PM path that's being changed here, so any tests on
>> AM3 platforms that actually use this path are appreciated.
>>
>> Kevin
>
> Is the pmdomain patch(3) ready to be applied here? Please let me know
> if you want me to pick it up.
Not yet, I have some concerns so I'd like to see more testing on the
actual hardware, which I don't have (yet, but it's on the way).
Kevin
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: [PATCH 0/4] PM: TI: AM335x: PM STANDBY fixes
2025-03-18 23:00 [PATCH 0/4] PM: TI: AM335x: PM STANDBY fixes Sukrut Bellary
` (4 preceding siblings ...)
2025-04-11 0:30 ` [PATCH 0/4] PM: TI: AM335x: PM STANDBY fixes Kevin Hilman
@ 2025-05-06 20:01 ` Judith Mendez
5 siblings, 0 replies; 13+ messages in thread
From: Judith Mendez @ 2025-05-06 20:01 UTC (permalink / raw)
To: Sukrut Bellary, Kevin Hilman, Nishanth Menon, Ulf Hansson
Cc: Aaro Koskinen, Andreas Kemnade, Roger Quadros, Conor Dooley,
Santosh Shilimkar, Bajjuri Praneeth, Raghavendra Vignesh, Bin Liu,
linux-kernel, linux-arm-kernel, linux-omap, devicetree, linux-pm,
Russell King, Rob Herring, Tony Lindgren, Krzysztof Kozlowski
Hello Sukrut, Keven, Ulf,
On 3/18/25 6:00 PM, Sukrut Bellary wrote:
> This patch series fixes the Power management issues on TI's am335x soc.
>
> on AM335x, the wakeup doesn't work in the case of STANDBY.
>
> 1. Since CM3 PM FW [1](ti-v4.1.y) doesn't enable l4ls clockdomain upon
> wakeup, it fails to wakeup the MPU.
> To fix this, don't turn off the l4ls clk domain in the STANDBY transition
> in MPU.
>
> 2. Also Per AM335x TRM [2](section 8.1.4.3 Power mode), in case of STANDBY,
> PER domain should be ON. So fix PER power domain handling for
> standby. l4ls is a part of the PER domain.
>
> Since we are not turning off the l4ls clockdomain on STANDBY in MPU,
> PER power domain would remain ON. But still, explicitly handle this
> to be in sync with the STANDBY requirement.
>
> 3. On am335x evm[1], UART0 - (UART1-HW) has a wakeup capability.
> Set the wakeup-source property in DT for AM335x.
>
> 4. Enable PM configs for AM335x.
>
> [1] https://git.ti.com/cgit/processor-firmware/ti-amx3-cm3-pm-firmware/
> [2] https://www.ti.com/lit/ug/spruh73q/spruh73q.pdf
> [3] https://www.ti.com/tool/TMDXEVM3358
>
> Test log:
> https://gist.github.com/sukrutb/bdbfd1220fe8578a9decf87d0bac6796
>
Thanks for the patches, Sukrut.
I was able to test this series on am335x EVM, baseline being rc5 next
branch: https://gist.github.com/jmenti/cda1675b5fc5844b6f065376e98026f5
Tested-by: Judith Mendez <jm@ti.com>
regards,
~ Judith
^ permalink raw reply [flat|nested] 13+ messages in thread