All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2 0/2] soc: ti: wkup_m3_ipc: support vtt toggle
@ 2022-04-09 21:12 ` Drew Fustini
  0 siblings, 0 replies; 16+ messages in thread
From: Drew Fustini @ 2022-04-09 21:12 UTC (permalink / raw)
  To: Rob Herring, Krzysztof Kozlowski, Dave Gerlach, Tony Lindgren,
	Nishanth Menon, Santosh Shilimkar
  Cc: devicetree, linux-arm-kernel, linux-kernel, Drew Fustini

This series enables the Cortex M3 processor found in AM33xx and AM43xx
SoCs to toggle the VTT regulator during low power mode transitions.

I recently converted the Wakeup M3 IPC bindings to YAML. Rob has applied
that patch [1]. It is a prerequisite for the wkup-m3-ipc.yaml patch in
this series.

[1] https://lore.kernel.org/linux-devicetree/YlCACSZx5xsPSwNC@robh.at.kernel.org/

Changes since v1:
- Removed unnecessary "ti,needs-vtt-toggle" property

Dave Gerlach (1):
  soc: ti: wkup_m3_ipc: Add support for toggling VTT regulator

Drew Fustini (1):
  dt-bindings: wkup-m3-ipc: Add vtt toggle gpio pin property

 .../bindings/soc/ti/wkup-m3-ipc.yaml          | 13 ++++++++++
 drivers/soc/ti/wkup_m3_ipc.c                  | 26 +++++++++++++++++--
 include/linux/wkup_m3_ipc.h                   |  1 +
 3 files changed, 38 insertions(+), 2 deletions(-)

-- 
2.32.0


^ permalink raw reply	[flat|nested] 16+ messages in thread

* [PATCH v2 0/2] soc: ti: wkup_m3_ipc: support vtt toggle
@ 2022-04-09 21:12 ` Drew Fustini
  0 siblings, 0 replies; 16+ messages in thread
From: Drew Fustini @ 2022-04-09 21:12 UTC (permalink / raw)
  To: Rob Herring, Krzysztof Kozlowski, Dave Gerlach, Tony Lindgren,
	Nishanth Menon, Santosh Shilimkar
  Cc: devicetree, linux-arm-kernel, linux-kernel, Drew Fustini

This series enables the Cortex M3 processor found in AM33xx and AM43xx
SoCs to toggle the VTT regulator during low power mode transitions.

I recently converted the Wakeup M3 IPC bindings to YAML. Rob has applied
that patch [1]. It is a prerequisite for the wkup-m3-ipc.yaml patch in
this series.

[1] https://lore.kernel.org/linux-devicetree/YlCACSZx5xsPSwNC@robh.at.kernel.org/

Changes since v1:
- Removed unnecessary "ti,needs-vtt-toggle" property

Dave Gerlach (1):
  soc: ti: wkup_m3_ipc: Add support for toggling VTT regulator

Drew Fustini (1):
  dt-bindings: wkup-m3-ipc: Add vtt toggle gpio pin property

 .../bindings/soc/ti/wkup-m3-ipc.yaml          | 13 ++++++++++
 drivers/soc/ti/wkup_m3_ipc.c                  | 26 +++++++++++++++++--
 include/linux/wkup_m3_ipc.h                   |  1 +
 3 files changed, 38 insertions(+), 2 deletions(-)

-- 
2.32.0


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [PATCH v2 1/2] dt-bindings: wkup-m3-ipc: Add vtt toggle gpio pin property
  2022-04-09 21:12 ` Drew Fustini
@ 2022-04-09 21:12   ` Drew Fustini
  -1 siblings, 0 replies; 16+ messages in thread
From: Drew Fustini @ 2022-04-09 21:12 UTC (permalink / raw)
  To: Rob Herring, Krzysztof Kozlowski, Dave Gerlach, Tony Lindgren,
	Nishanth Menon, Santosh Shilimkar
  Cc: devicetree, linux-arm-kernel, linux-kernel, Drew Fustini

Document Wakeup M3 IPC property that indicates a GPIO pin is connected
to the enable pin on DDR VTT regulator and can be toggled during low
power mode transitions.

Signed-off-by: Dave Gerlach <d-gerlach@ti.com>
[dfustini: converted to YAML, removed unnecessary "ti,needs-vtt-toggle"]
Signed-off-by: Drew Fustini <dfustini@baylibre.com>
---
 .../devicetree/bindings/soc/ti/wkup-m3-ipc.yaml     | 13 +++++++++++++
 1 file changed, 13 insertions(+)

diff --git a/Documentation/devicetree/bindings/soc/ti/wkup-m3-ipc.yaml b/Documentation/devicetree/bindings/soc/ti/wkup-m3-ipc.yaml
index d855c01ce61c..7f4a75c5fcaa 100644
--- a/Documentation/devicetree/bindings/soc/ti/wkup-m3-ipc.yaml
+++ b/Documentation/devicetree/bindings/soc/ti/wkup-m3-ipc.yaml
@@ -24,6 +24,14 @@ description: |+
   A wkup_m3_ipc device node is used to represent the IPC registers within an
   SoC.
 
+  Support for VTT Toggle
+  ==================================
+  On some boards like the AM335x EVM-SK and the AM437x GP EVM, a GPIO pin is
+  connected to the enable pin on the DDR VTT regulator. This allows the
+  regulator to be disabled upon suspend and enabled upon resume. Please note
+  that the GPIO pin must be part of the GPIO0 module as only this GPIO module
+  is in the wakeup power domain.
+
 properties:
   compatible:
     enum:
@@ -51,6 +59,10 @@ properties:
       mbox_wkupm3 child node.
     maxItems: 1
 
+  ti,vtt-gpio-pin:
+    $ref: /schemas/types.yaml#/definitions/uint32
+    description: GPIO pin connected to enable pin on VTT regulator
+
 required:
   - compatible
   - reg
@@ -76,6 +88,7 @@ examples:
            interrupts = <78>;
            ti,rproc = <&wkup_m3>;
            mboxes = <&mailbox &mbox_wkupm3>;
+           ti,vtt-gpio-pin = <7>;
         };
     };
 ...
-- 
2.32.0


^ permalink raw reply related	[flat|nested] 16+ messages in thread

* [PATCH v2 1/2] dt-bindings: wkup-m3-ipc: Add vtt toggle gpio pin property
@ 2022-04-09 21:12   ` Drew Fustini
  0 siblings, 0 replies; 16+ messages in thread
From: Drew Fustini @ 2022-04-09 21:12 UTC (permalink / raw)
  To: Rob Herring, Krzysztof Kozlowski, Dave Gerlach, Tony Lindgren,
	Nishanth Menon, Santosh Shilimkar
  Cc: devicetree, linux-arm-kernel, linux-kernel, Drew Fustini

Document Wakeup M3 IPC property that indicates a GPIO pin is connected
to the enable pin on DDR VTT regulator and can be toggled during low
power mode transitions.

Signed-off-by: Dave Gerlach <d-gerlach@ti.com>
[dfustini: converted to YAML, removed unnecessary "ti,needs-vtt-toggle"]
Signed-off-by: Drew Fustini <dfustini@baylibre.com>
---
 .../devicetree/bindings/soc/ti/wkup-m3-ipc.yaml     | 13 +++++++++++++
 1 file changed, 13 insertions(+)

diff --git a/Documentation/devicetree/bindings/soc/ti/wkup-m3-ipc.yaml b/Documentation/devicetree/bindings/soc/ti/wkup-m3-ipc.yaml
index d855c01ce61c..7f4a75c5fcaa 100644
--- a/Documentation/devicetree/bindings/soc/ti/wkup-m3-ipc.yaml
+++ b/Documentation/devicetree/bindings/soc/ti/wkup-m3-ipc.yaml
@@ -24,6 +24,14 @@ description: |+
   A wkup_m3_ipc device node is used to represent the IPC registers within an
   SoC.
 
+  Support for VTT Toggle
+  ==================================
+  On some boards like the AM335x EVM-SK and the AM437x GP EVM, a GPIO pin is
+  connected to the enable pin on the DDR VTT regulator. This allows the
+  regulator to be disabled upon suspend and enabled upon resume. Please note
+  that the GPIO pin must be part of the GPIO0 module as only this GPIO module
+  is in the wakeup power domain.
+
 properties:
   compatible:
     enum:
@@ -51,6 +59,10 @@ properties:
       mbox_wkupm3 child node.
     maxItems: 1
 
+  ti,vtt-gpio-pin:
+    $ref: /schemas/types.yaml#/definitions/uint32
+    description: GPIO pin connected to enable pin on VTT regulator
+
 required:
   - compatible
   - reg
@@ -76,6 +88,7 @@ examples:
            interrupts = <78>;
            ti,rproc = <&wkup_m3>;
            mboxes = <&mailbox &mbox_wkupm3>;
+           ti,vtt-gpio-pin = <7>;
         };
     };
 ...
-- 
2.32.0


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply related	[flat|nested] 16+ messages in thread

* [PATCH v2 2/2] soc: ti: wkup_m3_ipc: Add support for toggling VTT regulator
  2022-04-09 21:12 ` Drew Fustini
@ 2022-04-09 21:12   ` Drew Fustini
  -1 siblings, 0 replies; 16+ messages in thread
From: Drew Fustini @ 2022-04-09 21:12 UTC (permalink / raw)
  To: Rob Herring, Krzysztof Kozlowski, Dave Gerlach, Tony Lindgren,
	Nishanth Menon, Santosh Shilimkar
  Cc: devicetree, linux-arm-kernel, linux-kernel, Drew Fustini, Keerthy

From: Dave Gerlach <d-gerlach@ti.com>

Some boards like the AM335x EVM-SK and AM437x GP EVM provide software
control via a GPIO pin to toggle the DDR VTT regulator to reduce power
consumption in low power states.

The VTT regulator should be disabled after enabling self-refresh on
suspend, and should be enabled before disabling self-refresh on resume.
This is to allow proper self-refresh entry/exit commands to be
transmitted to the memory.

The "ti,vtt-gpio-pin" device tree property in the wkup_m3_ipc node
specifies which GPIO pin to use. This property is communicated to the
Wakeup Cortex M3 co-processor where the actual toggling of the GPIO pin
happens in CM3 firmware [1].

Please note that the GPIO pin must be on the GPIO0 module as that module
is in the wakeup power domain.

[1] https://git.ti.com/cgit/processor-firmware/ti-amx3-cm3-pm-firmware/tree/src/pm_services/ddr.c?h=08.02.00.006#n190

Signed-off-by: Dave Gerlach <d-gerlach@ti.com>
Signed-off-by: Keerthy <j-keerthy@ti.com>
[dfustini: remove the unnecessary "ti,needs-vtt-toggle" property]
Signed-off-by: Drew Fustini <dfustini@baylibre.com>
---
 drivers/soc/ti/wkup_m3_ipc.c | 26 ++++++++++++++++++++++++--
 include/linux/wkup_m3_ipc.h  |  1 +
 2 files changed, 25 insertions(+), 2 deletions(-)

diff --git a/drivers/soc/ti/wkup_m3_ipc.c b/drivers/soc/ti/wkup_m3_ipc.c
index 2f03ced0f411..247a4b57a372 100644
--- a/drivers/soc/ti/wkup_m3_ipc.c
+++ b/drivers/soc/ti/wkup_m3_ipc.c
@@ -40,6 +40,13 @@
 #define M3_FW_VERSION_MASK		0xffff
 #define M3_WAKE_SRC_MASK		0xff
 
+#define IPC_MEM_TYPE_SHIFT		(0x0)
+#define IPC_MEM_TYPE_MASK		(0x7 << 0)
+#define IPC_VTT_STAT_SHIFT		(0x3)
+#define IPC_VTT_STAT_MASK		(0x1 << 3)
+#define IPC_VTT_GPIO_PIN_SHIFT		(0x4)
+#define IPC_VTT_GPIO_PIN_MASK		(0x3f << 4)
+
 #define M3_STATE_UNKNOWN		0
 #define M3_STATE_RESET			1
 #define M3_STATE_INITED			2
@@ -215,6 +222,12 @@ static int wkup_m3_is_available(struct wkup_m3_ipc *m3_ipc)
 		(m3_ipc->state != M3_STATE_UNKNOWN));
 }
 
+static void wkup_m3_set_vtt_gpio(struct wkup_m3_ipc *m3_ipc, int gpio)
+{
+	m3_ipc->vtt_conf = (1 << IPC_VTT_STAT_SHIFT) |
+			    (gpio << IPC_VTT_GPIO_PIN_SHIFT);
+}
+
 /* Public functions */
 /**
  * wkup_m3_set_mem_type - Pass wkup_m3 which type of memory is in use
@@ -294,7 +307,8 @@ static int wkup_m3_prepare_low_power(struct wkup_m3_ipc *m3_ipc, int state)
 	/* Program each required IPC register then write defaults to others */
 	wkup_m3_ctrl_ipc_write(m3_ipc, m3_ipc->resume_addr, 0);
 	wkup_m3_ctrl_ipc_write(m3_ipc, m3_power_state, 1);
-	wkup_m3_ctrl_ipc_write(m3_ipc, m3_ipc->mem_type, 4);
+	wkup_m3_ctrl_ipc_write(m3_ipc, m3_ipc->mem_type |
+			       m3_ipc->vtt_conf, 4);
 
 	wkup_m3_ctrl_ipc_write(m3_ipc, DS_IPC_DEFAULT, 2);
 	wkup_m3_ctrl_ipc_write(m3_ipc, DS_IPC_DEFAULT, 3);
@@ -433,12 +447,13 @@ static int wkup_m3_rproc_boot_thread(void *arg)
 static int wkup_m3_ipc_probe(struct platform_device *pdev)
 {
 	struct device *dev = &pdev->dev;
-	int irq, ret;
+	int irq, ret, temp;
 	phandle rproc_phandle;
 	struct rproc *m3_rproc;
 	struct resource *res;
 	struct task_struct *task;
 	struct wkup_m3_ipc *m3_ipc;
+	struct device_node *np = dev->of_node;
 
 	m3_ipc = devm_kzalloc(dev, sizeof(*m3_ipc), GFP_KERNEL);
 	if (!m3_ipc)
@@ -496,6 +511,13 @@ static int wkup_m3_ipc_probe(struct platform_device *pdev)
 
 	m3_ipc->ops = &ipc_ops;
 
+	if (!of_property_read_u32(np, "ti,vtt-gpio-pin", &temp)) {
+		if (temp >= 0 && temp <= 31)
+			wkup_m3_set_vtt_gpio(m3_ipc, temp);
+		else
+			dev_warn(dev, "Invalid VTT GPIO(%d) pin\n", temp);
+	}
+
 	/*
 	 * Wait for firmware loading completion in a thread so we
 	 * can boot the wkup_m3 as soon as it's ready without holding
diff --git a/include/linux/wkup_m3_ipc.h b/include/linux/wkup_m3_ipc.h
index 3f496967b538..2bc52c6381d5 100644
--- a/include/linux/wkup_m3_ipc.h
+++ b/include/linux/wkup_m3_ipc.h
@@ -33,6 +33,7 @@ struct wkup_m3_ipc {
 
 	int mem_type;
 	unsigned long resume_addr;
+	int vtt_conf;
 	int state;
 
 	struct completion sync_complete;
-- 
2.32.0


^ permalink raw reply related	[flat|nested] 16+ messages in thread

* [PATCH v2 2/2] soc: ti: wkup_m3_ipc: Add support for toggling VTT regulator
@ 2022-04-09 21:12   ` Drew Fustini
  0 siblings, 0 replies; 16+ messages in thread
From: Drew Fustini @ 2022-04-09 21:12 UTC (permalink / raw)
  To: Rob Herring, Krzysztof Kozlowski, Dave Gerlach, Tony Lindgren,
	Nishanth Menon, Santosh Shilimkar
  Cc: devicetree, linux-arm-kernel, linux-kernel, Drew Fustini, Keerthy

From: Dave Gerlach <d-gerlach@ti.com>

Some boards like the AM335x EVM-SK and AM437x GP EVM provide software
control via a GPIO pin to toggle the DDR VTT regulator to reduce power
consumption in low power states.

The VTT regulator should be disabled after enabling self-refresh on
suspend, and should be enabled before disabling self-refresh on resume.
This is to allow proper self-refresh entry/exit commands to be
transmitted to the memory.

The "ti,vtt-gpio-pin" device tree property in the wkup_m3_ipc node
specifies which GPIO pin to use. This property is communicated to the
Wakeup Cortex M3 co-processor where the actual toggling of the GPIO pin
happens in CM3 firmware [1].

Please note that the GPIO pin must be on the GPIO0 module as that module
is in the wakeup power domain.

[1] https://git.ti.com/cgit/processor-firmware/ti-amx3-cm3-pm-firmware/tree/src/pm_services/ddr.c?h=08.02.00.006#n190

Signed-off-by: Dave Gerlach <d-gerlach@ti.com>
Signed-off-by: Keerthy <j-keerthy@ti.com>
[dfustini: remove the unnecessary "ti,needs-vtt-toggle" property]
Signed-off-by: Drew Fustini <dfustini@baylibre.com>
---
 drivers/soc/ti/wkup_m3_ipc.c | 26 ++++++++++++++++++++++++--
 include/linux/wkup_m3_ipc.h  |  1 +
 2 files changed, 25 insertions(+), 2 deletions(-)

diff --git a/drivers/soc/ti/wkup_m3_ipc.c b/drivers/soc/ti/wkup_m3_ipc.c
index 2f03ced0f411..247a4b57a372 100644
--- a/drivers/soc/ti/wkup_m3_ipc.c
+++ b/drivers/soc/ti/wkup_m3_ipc.c
@@ -40,6 +40,13 @@
 #define M3_FW_VERSION_MASK		0xffff
 #define M3_WAKE_SRC_MASK		0xff
 
+#define IPC_MEM_TYPE_SHIFT		(0x0)
+#define IPC_MEM_TYPE_MASK		(0x7 << 0)
+#define IPC_VTT_STAT_SHIFT		(0x3)
+#define IPC_VTT_STAT_MASK		(0x1 << 3)
+#define IPC_VTT_GPIO_PIN_SHIFT		(0x4)
+#define IPC_VTT_GPIO_PIN_MASK		(0x3f << 4)
+
 #define M3_STATE_UNKNOWN		0
 #define M3_STATE_RESET			1
 #define M3_STATE_INITED			2
@@ -215,6 +222,12 @@ static int wkup_m3_is_available(struct wkup_m3_ipc *m3_ipc)
 		(m3_ipc->state != M3_STATE_UNKNOWN));
 }
 
+static void wkup_m3_set_vtt_gpio(struct wkup_m3_ipc *m3_ipc, int gpio)
+{
+	m3_ipc->vtt_conf = (1 << IPC_VTT_STAT_SHIFT) |
+			    (gpio << IPC_VTT_GPIO_PIN_SHIFT);
+}
+
 /* Public functions */
 /**
  * wkup_m3_set_mem_type - Pass wkup_m3 which type of memory is in use
@@ -294,7 +307,8 @@ static int wkup_m3_prepare_low_power(struct wkup_m3_ipc *m3_ipc, int state)
 	/* Program each required IPC register then write defaults to others */
 	wkup_m3_ctrl_ipc_write(m3_ipc, m3_ipc->resume_addr, 0);
 	wkup_m3_ctrl_ipc_write(m3_ipc, m3_power_state, 1);
-	wkup_m3_ctrl_ipc_write(m3_ipc, m3_ipc->mem_type, 4);
+	wkup_m3_ctrl_ipc_write(m3_ipc, m3_ipc->mem_type |
+			       m3_ipc->vtt_conf, 4);
 
 	wkup_m3_ctrl_ipc_write(m3_ipc, DS_IPC_DEFAULT, 2);
 	wkup_m3_ctrl_ipc_write(m3_ipc, DS_IPC_DEFAULT, 3);
@@ -433,12 +447,13 @@ static int wkup_m3_rproc_boot_thread(void *arg)
 static int wkup_m3_ipc_probe(struct platform_device *pdev)
 {
 	struct device *dev = &pdev->dev;
-	int irq, ret;
+	int irq, ret, temp;
 	phandle rproc_phandle;
 	struct rproc *m3_rproc;
 	struct resource *res;
 	struct task_struct *task;
 	struct wkup_m3_ipc *m3_ipc;
+	struct device_node *np = dev->of_node;
 
 	m3_ipc = devm_kzalloc(dev, sizeof(*m3_ipc), GFP_KERNEL);
 	if (!m3_ipc)
@@ -496,6 +511,13 @@ static int wkup_m3_ipc_probe(struct platform_device *pdev)
 
 	m3_ipc->ops = &ipc_ops;
 
+	if (!of_property_read_u32(np, "ti,vtt-gpio-pin", &temp)) {
+		if (temp >= 0 && temp <= 31)
+			wkup_m3_set_vtt_gpio(m3_ipc, temp);
+		else
+			dev_warn(dev, "Invalid VTT GPIO(%d) pin\n", temp);
+	}
+
 	/*
 	 * Wait for firmware loading completion in a thread so we
 	 * can boot the wkup_m3 as soon as it's ready without holding
diff --git a/include/linux/wkup_m3_ipc.h b/include/linux/wkup_m3_ipc.h
index 3f496967b538..2bc52c6381d5 100644
--- a/include/linux/wkup_m3_ipc.h
+++ b/include/linux/wkup_m3_ipc.h
@@ -33,6 +33,7 @@ struct wkup_m3_ipc {
 
 	int mem_type;
 	unsigned long resume_addr;
+	int vtt_conf;
 	int state;
 
 	struct completion sync_complete;
-- 
2.32.0


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply related	[flat|nested] 16+ messages in thread

* Re: [PATCH v2 1/2] dt-bindings: wkup-m3-ipc: Add vtt toggle gpio pin property
  2022-04-09 21:12   ` Drew Fustini
@ 2022-04-10 14:17     ` Krzysztof Kozlowski
  -1 siblings, 0 replies; 16+ messages in thread
From: Krzysztof Kozlowski @ 2022-04-10 14:17 UTC (permalink / raw)
  To: Drew Fustini, Rob Herring, Krzysztof Kozlowski, Dave Gerlach,
	Tony Lindgren, Nishanth Menon, Santosh Shilimkar
  Cc: devicetree, linux-arm-kernel, linux-kernel

On 09/04/2022 23:12, Drew Fustini wrote:
> Document Wakeup M3 IPC property that indicates a GPIO pin is connected
> to the enable pin on DDR VTT regulator and can be toggled during low
> power mode transitions.
> 
> Signed-off-by: Dave Gerlach <d-gerlach@ti.com>
> [dfustini: converted to YAML, removed unnecessary "ti,needs-vtt-toggle"]
> Signed-off-by: Drew Fustini <dfustini@baylibre.com>
> ---
>  .../devicetree/bindings/soc/ti/wkup-m3-ipc.yaml     | 13 +++++++++++++
>  1 file changed, 13 insertions(+)
> 


Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>


Best regards,
Krzysztof

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH v2 1/2] dt-bindings: wkup-m3-ipc: Add vtt toggle gpio pin property
@ 2022-04-10 14:17     ` Krzysztof Kozlowski
  0 siblings, 0 replies; 16+ messages in thread
From: Krzysztof Kozlowski @ 2022-04-10 14:17 UTC (permalink / raw)
  To: Drew Fustini, Rob Herring, Krzysztof Kozlowski, Dave Gerlach,
	Tony Lindgren, Nishanth Menon, Santosh Shilimkar
  Cc: devicetree, linux-arm-kernel, linux-kernel

On 09/04/2022 23:12, Drew Fustini wrote:
> Document Wakeup M3 IPC property that indicates a GPIO pin is connected
> to the enable pin on DDR VTT regulator and can be toggled during low
> power mode transitions.
> 
> Signed-off-by: Dave Gerlach <d-gerlach@ti.com>
> [dfustini: converted to YAML, removed unnecessary "ti,needs-vtt-toggle"]
> Signed-off-by: Drew Fustini <dfustini@baylibre.com>
> ---
>  .../devicetree/bindings/soc/ti/wkup-m3-ipc.yaml     | 13 +++++++++++++
>  1 file changed, 13 insertions(+)
> 


Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>


Best regards,
Krzysztof

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH v2 1/2] dt-bindings: wkup-m3-ipc: Add vtt toggle gpio pin property
  2022-04-09 21:12   ` Drew Fustini
@ 2022-04-12 19:54     ` Rob Herring
  -1 siblings, 0 replies; 16+ messages in thread
From: Rob Herring @ 2022-04-12 19:54 UTC (permalink / raw)
  To: Drew Fustini
  Cc: Krzysztof Kozlowski, Dave Gerlach, Tony Lindgren, Nishanth Menon,
	Santosh Shilimkar, devicetree, linux-arm-kernel, linux-kernel

On Sat, Apr 09, 2022 at 02:12:14PM -0700, Drew Fustini wrote:
> Document Wakeup M3 IPC property that indicates a GPIO pin is connected
> to the enable pin on DDR VTT regulator and can be toggled during low
> power mode transitions.
> 
> Signed-off-by: Dave Gerlach <d-gerlach@ti.com>
> [dfustini: converted to YAML, removed unnecessary "ti,needs-vtt-toggle"]
> Signed-off-by: Drew Fustini <dfustini@baylibre.com>
> ---
>  .../devicetree/bindings/soc/ti/wkup-m3-ipc.yaml     | 13 +++++++++++++
>  1 file changed, 13 insertions(+)
> 
> diff --git a/Documentation/devicetree/bindings/soc/ti/wkup-m3-ipc.yaml b/Documentation/devicetree/bindings/soc/ti/wkup-m3-ipc.yaml
> index d855c01ce61c..7f4a75c5fcaa 100644
> --- a/Documentation/devicetree/bindings/soc/ti/wkup-m3-ipc.yaml
> +++ b/Documentation/devicetree/bindings/soc/ti/wkup-m3-ipc.yaml
> @@ -24,6 +24,14 @@ description: |+
>    A wkup_m3_ipc device node is used to represent the IPC registers within an
>    SoC.
>  
> +  Support for VTT Toggle
> +  ==================================
> +  On some boards like the AM335x EVM-SK and the AM437x GP EVM, a GPIO pin is
> +  connected to the enable pin on the DDR VTT regulator. This allows the
> +  regulator to be disabled upon suspend and enabled upon resume. Please note
> +  that the GPIO pin must be part of the GPIO0 module as only this GPIO module
> +  is in the wakeup power domain.
> +
>  properties:
>    compatible:
>      enum:
> @@ -51,6 +59,10 @@ properties:
>        mbox_wkupm3 child node.
>      maxItems: 1
>  
> +  ti,vtt-gpio-pin:
> +    $ref: /schemas/types.yaml#/definitions/uint32
> +    description: GPIO pin connected to enable pin on VTT regulator

Looking at the driver, can't you add 'maximum: 31' here? If so, I can 
add it when applying.

Rob

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH v2 1/2] dt-bindings: wkup-m3-ipc: Add vtt toggle gpio pin property
@ 2022-04-12 19:54     ` Rob Herring
  0 siblings, 0 replies; 16+ messages in thread
From: Rob Herring @ 2022-04-12 19:54 UTC (permalink / raw)
  To: Drew Fustini
  Cc: Krzysztof Kozlowski, Dave Gerlach, Tony Lindgren, Nishanth Menon,
	Santosh Shilimkar, devicetree, linux-arm-kernel, linux-kernel

On Sat, Apr 09, 2022 at 02:12:14PM -0700, Drew Fustini wrote:
> Document Wakeup M3 IPC property that indicates a GPIO pin is connected
> to the enable pin on DDR VTT regulator and can be toggled during low
> power mode transitions.
> 
> Signed-off-by: Dave Gerlach <d-gerlach@ti.com>
> [dfustini: converted to YAML, removed unnecessary "ti,needs-vtt-toggle"]
> Signed-off-by: Drew Fustini <dfustini@baylibre.com>
> ---
>  .../devicetree/bindings/soc/ti/wkup-m3-ipc.yaml     | 13 +++++++++++++
>  1 file changed, 13 insertions(+)
> 
> diff --git a/Documentation/devicetree/bindings/soc/ti/wkup-m3-ipc.yaml b/Documentation/devicetree/bindings/soc/ti/wkup-m3-ipc.yaml
> index d855c01ce61c..7f4a75c5fcaa 100644
> --- a/Documentation/devicetree/bindings/soc/ti/wkup-m3-ipc.yaml
> +++ b/Documentation/devicetree/bindings/soc/ti/wkup-m3-ipc.yaml
> @@ -24,6 +24,14 @@ description: |+
>    A wkup_m3_ipc device node is used to represent the IPC registers within an
>    SoC.
>  
> +  Support for VTT Toggle
> +  ==================================
> +  On some boards like the AM335x EVM-SK and the AM437x GP EVM, a GPIO pin is
> +  connected to the enable pin on the DDR VTT regulator. This allows the
> +  regulator to be disabled upon suspend and enabled upon resume. Please note
> +  that the GPIO pin must be part of the GPIO0 module as only this GPIO module
> +  is in the wakeup power domain.
> +
>  properties:
>    compatible:
>      enum:
> @@ -51,6 +59,10 @@ properties:
>        mbox_wkupm3 child node.
>      maxItems: 1
>  
> +  ti,vtt-gpio-pin:
> +    $ref: /schemas/types.yaml#/definitions/uint32
> +    description: GPIO pin connected to enable pin on VTT regulator

Looking at the driver, can't you add 'maximum: 31' here? If so, I can 
add it when applying.

Rob

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH v2 1/2] dt-bindings: wkup-m3-ipc: Add vtt toggle gpio pin property
  2022-04-12 19:54     ` Rob Herring
@ 2022-04-12 21:15       ` Drew Fustini
  -1 siblings, 0 replies; 16+ messages in thread
From: Drew Fustini @ 2022-04-12 21:15 UTC (permalink / raw)
  To: Rob Herring
  Cc: Krzysztof Kozlowski, Dave Gerlach, Tony Lindgren, Nishanth Menon,
	Santosh Shilimkar, devicetree, linux-arm-kernel, linux-kernel

On Tue, Apr 12, 2022 at 02:54:27PM -0500, Rob Herring wrote:
> On Sat, Apr 09, 2022 at 02:12:14PM -0700, Drew Fustini wrote:
> > Document Wakeup M3 IPC property that indicates a GPIO pin is connected
> > to the enable pin on DDR VTT regulator and can be toggled during low
> > power mode transitions.
> > 
> > Signed-off-by: Dave Gerlach <d-gerlach@ti.com>
> > [dfustini: converted to YAML, removed unnecessary "ti,needs-vtt-toggle"]
> > Signed-off-by: Drew Fustini <dfustini@baylibre.com>
> > ---
> >  .../devicetree/bindings/soc/ti/wkup-m3-ipc.yaml     | 13 +++++++++++++
> >  1 file changed, 13 insertions(+)
> > 
> > diff --git a/Documentation/devicetree/bindings/soc/ti/wkup-m3-ipc.yaml b/Documentation/devicetree/bindings/soc/ti/wkup-m3-ipc.yaml
> > index d855c01ce61c..7f4a75c5fcaa 100644
> > --- a/Documentation/devicetree/bindings/soc/ti/wkup-m3-ipc.yaml
> > +++ b/Documentation/devicetree/bindings/soc/ti/wkup-m3-ipc.yaml
> > @@ -24,6 +24,14 @@ description: |+
> >    A wkup_m3_ipc device node is used to represent the IPC registers within an
> >    SoC.
> >  
> > +  Support for VTT Toggle
> > +  ==================================
> > +  On some boards like the AM335x EVM-SK and the AM437x GP EVM, a GPIO pin is
> > +  connected to the enable pin on the DDR VTT regulator. This allows the
> > +  regulator to be disabled upon suspend and enabled upon resume. Please note
> > +  that the GPIO pin must be part of the GPIO0 module as only this GPIO module
> > +  is in the wakeup power domain.
> > +
> >  properties:
> >    compatible:
> >      enum:
> > @@ -51,6 +59,10 @@ properties:
> >        mbox_wkupm3 child node.
> >      maxItems: 1
> >  
> > +  ti,vtt-gpio-pin:
> > +    $ref: /schemas/types.yaml#/definitions/uint32
> > +    description: GPIO pin connected to enable pin on VTT regulator
> 
> Looking at the driver, can't you add 'maximum: 31' here? If so, I can 
> add it when applying.

Yes, good idea. I would appreciate it if that was added when applying.

Thank you,
Drew

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH v2 1/2] dt-bindings: wkup-m3-ipc: Add vtt toggle gpio pin property
@ 2022-04-12 21:15       ` Drew Fustini
  0 siblings, 0 replies; 16+ messages in thread
From: Drew Fustini @ 2022-04-12 21:15 UTC (permalink / raw)
  To: Rob Herring
  Cc: Krzysztof Kozlowski, Dave Gerlach, Tony Lindgren, Nishanth Menon,
	Santosh Shilimkar, devicetree, linux-arm-kernel, linux-kernel

On Tue, Apr 12, 2022 at 02:54:27PM -0500, Rob Herring wrote:
> On Sat, Apr 09, 2022 at 02:12:14PM -0700, Drew Fustini wrote:
> > Document Wakeup M3 IPC property that indicates a GPIO pin is connected
> > to the enable pin on DDR VTT regulator and can be toggled during low
> > power mode transitions.
> > 
> > Signed-off-by: Dave Gerlach <d-gerlach@ti.com>
> > [dfustini: converted to YAML, removed unnecessary "ti,needs-vtt-toggle"]
> > Signed-off-by: Drew Fustini <dfustini@baylibre.com>
> > ---
> >  .../devicetree/bindings/soc/ti/wkup-m3-ipc.yaml     | 13 +++++++++++++
> >  1 file changed, 13 insertions(+)
> > 
> > diff --git a/Documentation/devicetree/bindings/soc/ti/wkup-m3-ipc.yaml b/Documentation/devicetree/bindings/soc/ti/wkup-m3-ipc.yaml
> > index d855c01ce61c..7f4a75c5fcaa 100644
> > --- a/Documentation/devicetree/bindings/soc/ti/wkup-m3-ipc.yaml
> > +++ b/Documentation/devicetree/bindings/soc/ti/wkup-m3-ipc.yaml
> > @@ -24,6 +24,14 @@ description: |+
> >    A wkup_m3_ipc device node is used to represent the IPC registers within an
> >    SoC.
> >  
> > +  Support for VTT Toggle
> > +  ==================================
> > +  On some boards like the AM335x EVM-SK and the AM437x GP EVM, a GPIO pin is
> > +  connected to the enable pin on the DDR VTT regulator. This allows the
> > +  regulator to be disabled upon suspend and enabled upon resume. Please note
> > +  that the GPIO pin must be part of the GPIO0 module as only this GPIO module
> > +  is in the wakeup power domain.
> > +
> >  properties:
> >    compatible:
> >      enum:
> > @@ -51,6 +59,10 @@ properties:
> >        mbox_wkupm3 child node.
> >      maxItems: 1
> >  
> > +  ti,vtt-gpio-pin:
> > +    $ref: /schemas/types.yaml#/definitions/uint32
> > +    description: GPIO pin connected to enable pin on VTT regulator
> 
> Looking at the driver, can't you add 'maximum: 31' here? If so, I can 
> add it when applying.

Yes, good idea. I would appreciate it if that was added when applying.

Thank you,
Drew

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH v2 1/2] dt-bindings: wkup-m3-ipc: Add vtt toggle gpio pin property
  2022-04-09 21:12   ` Drew Fustini
@ 2022-04-13 21:48     ` Rob Herring
  -1 siblings, 0 replies; 16+ messages in thread
From: Rob Herring @ 2022-04-13 21:48 UTC (permalink / raw)
  To: Drew Fustini
  Cc: Krzysztof Kozlowski, linux-kernel, Tony Lindgren, Rob Herring,
	Santosh Shilimkar, Nishanth Menon, devicetree, linux-arm-kernel,
	Dave Gerlach

On Sat, 09 Apr 2022 14:12:14 -0700, Drew Fustini wrote:
> Document Wakeup M3 IPC property that indicates a GPIO pin is connected
> to the enable pin on DDR VTT regulator and can be toggled during low
> power mode transitions.
> 
> Signed-off-by: Dave Gerlach <d-gerlach@ti.com>
> [dfustini: converted to YAML, removed unnecessary "ti,needs-vtt-toggle"]
> Signed-off-by: Drew Fustini <dfustini@baylibre.com>
> ---
>  .../devicetree/bindings/soc/ti/wkup-m3-ipc.yaml     | 13 +++++++++++++
>  1 file changed, 13 insertions(+)
> 

Applied, thanks!

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH v2 1/2] dt-bindings: wkup-m3-ipc: Add vtt toggle gpio pin property
@ 2022-04-13 21:48     ` Rob Herring
  0 siblings, 0 replies; 16+ messages in thread
From: Rob Herring @ 2022-04-13 21:48 UTC (permalink / raw)
  To: Drew Fustini
  Cc: Krzysztof Kozlowski, linux-kernel, Tony Lindgren, Rob Herring,
	Santosh Shilimkar, Nishanth Menon, devicetree, linux-arm-kernel,
	Dave Gerlach

On Sat, 09 Apr 2022 14:12:14 -0700, Drew Fustini wrote:
> Document Wakeup M3 IPC property that indicates a GPIO pin is connected
> to the enable pin on DDR VTT regulator and can be toggled during low
> power mode transitions.
> 
> Signed-off-by: Dave Gerlach <d-gerlach@ti.com>
> [dfustini: converted to YAML, removed unnecessary "ti,needs-vtt-toggle"]
> Signed-off-by: Drew Fustini <dfustini@baylibre.com>
> ---
>  .../devicetree/bindings/soc/ti/wkup-m3-ipc.yaml     | 13 +++++++++++++
>  1 file changed, 13 insertions(+)
> 

Applied, thanks!

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: (subset) [PATCH v2 0/2] soc: ti: wkup_m3_ipc: support vtt toggle
  2022-04-09 21:12 ` Drew Fustini
@ 2022-04-22 23:14   ` Nishanth Menon
  -1 siblings, 0 replies; 16+ messages in thread
From: Nishanth Menon @ 2022-04-22 23:14 UTC (permalink / raw)
  To: Drew Fustini, Krzysztof Kozlowski, Rob Herring,
	Santosh Shilimkar, Dave Gerlach, Tony Lindgren
  Cc: Nishanth Menon, linux-kernel, linux-arm-kernel, devicetree

Hi Drew Fustini,

On Sat, 9 Apr 2022 14:12:13 -0700, Drew Fustini wrote:
> This series enables the Cortex M3 processor found in AM33xx and AM43xx
> SoCs to toggle the VTT regulator during low power mode transitions.
> 
> I recently converted the Wakeup M3 IPC bindings to YAML. Rob has applied
> that patch [1]. It is a prerequisite for the wkup-m3-ipc.yaml patch in
> this series.
> 
> [...]

I have applied the following to branch ti-drivers-soc-next on [1].
Thank you!

[2/2] soc: ti: wkup_m3_ipc: Add support for toggling VTT regulator
      commit: f226041424cf87245d39a1b2dfae304308b36b6b

All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent up the chain during
the next merge window (or sooner if it is a relevant bug fix), however if
problems are discovered then the patch may be dropped or reverted.

You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying
to this mail.

[1] git://git.kernel.org/pub/scm/linux/kernel/git/ti/linux.git
-- 
Regards,
Nishanth Menon
Key (0xDDB5849D1736249D) / Fingerprint: F8A2 8693 54EB 8232 17A3  1A34 DDB5 849D 1736 249D


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: (subset) [PATCH v2 0/2] soc: ti: wkup_m3_ipc: support vtt toggle
@ 2022-04-22 23:14   ` Nishanth Menon
  0 siblings, 0 replies; 16+ messages in thread
From: Nishanth Menon @ 2022-04-22 23:14 UTC (permalink / raw)
  To: Drew Fustini, Krzysztof Kozlowski, Rob Herring,
	Santosh Shilimkar, Dave Gerlach, Tony Lindgren
  Cc: Nishanth Menon, linux-kernel, linux-arm-kernel, devicetree

Hi Drew Fustini,

On Sat, 9 Apr 2022 14:12:13 -0700, Drew Fustini wrote:
> This series enables the Cortex M3 processor found in AM33xx and AM43xx
> SoCs to toggle the VTT regulator during low power mode transitions.
> 
> I recently converted the Wakeup M3 IPC bindings to YAML. Rob has applied
> that patch [1]. It is a prerequisite for the wkup-m3-ipc.yaml patch in
> this series.
> 
> [...]

I have applied the following to branch ti-drivers-soc-next on [1].
Thank you!

[2/2] soc: ti: wkup_m3_ipc: Add support for toggling VTT regulator
      commit: f226041424cf87245d39a1b2dfae304308b36b6b

All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent up the chain during
the next merge window (or sooner if it is a relevant bug fix), however if
problems are discovered then the patch may be dropped or reverted.

You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying
to this mail.

[1] git://git.kernel.org/pub/scm/linux/kernel/git/ti/linux.git
-- 
Regards,
Nishanth Menon
Key (0xDDB5849D1736249D) / Fingerprint: F8A2 8693 54EB 8232 17A3  1A34 DDB5 849D 1736 249D


^ permalink raw reply	[flat|nested] 16+ messages in thread

end of thread, other threads:[~2022-04-22 23:30 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-04-09 21:12 [PATCH v2 0/2] soc: ti: wkup_m3_ipc: support vtt toggle Drew Fustini
2022-04-09 21:12 ` Drew Fustini
2022-04-09 21:12 ` [PATCH v2 1/2] dt-bindings: wkup-m3-ipc: Add vtt toggle gpio pin property Drew Fustini
2022-04-09 21:12   ` Drew Fustini
2022-04-10 14:17   ` Krzysztof Kozlowski
2022-04-10 14:17     ` Krzysztof Kozlowski
2022-04-12 19:54   ` Rob Herring
2022-04-12 19:54     ` Rob Herring
2022-04-12 21:15     ` Drew Fustini
2022-04-12 21:15       ` Drew Fustini
2022-04-13 21:48   ` Rob Herring
2022-04-13 21:48     ` Rob Herring
2022-04-09 21:12 ` [PATCH v2 2/2] soc: ti: wkup_m3_ipc: Add support for toggling VTT regulator Drew Fustini
2022-04-09 21:12   ` Drew Fustini
2022-04-22 23:14 ` (subset) [PATCH v2 0/2] soc: ti: wkup_m3_ipc: support vtt toggle Nishanth Menon
2022-04-22 23:14   ` Nishanth Menon

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.