Skip to content

AM437x: Add rtc-only + DDR mode support

Keerthy linux-arm-kernel linux-omap linux-rtc 3 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v3 Latest4 patches 6 repliesIn review
  2. v25 patches 5 repliesSuperseded
  3. v15 patches 10 repliesSuperseded

Changes in v3 from the cover letter

* Exported out omap_rtc_poweroff_program function & removed the patch to add a generic rtc interface as it is specific to am43 at the moment.

Patches in v3 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/4rtc: OMAP: Add support for rtc-only modedrivers/rtc/rtc-omap.c include/linux/rtc/rtc-omap.h+48 -81 reply
2/4arm: mach-omap2: pm33xx: Add support for rtc+ddr in self refresh modearch/arm/mach-omap2/pm33xx-core.c include/linux/platform_data/pm33xx.h+80 -10 replies
3/4soc: ti: pm33xx: Move the am33xx_push_sram_idle to the topdrivers/soc/ti/pm33xx.c+50 -500 replies
4/4soc: ti: pm33xx: AM437X: Add rtc_only with ddr in self-refresh supportdrivers/soc/ti/Kconfig drivers/soc/ti/pm33xx.c+185 -110 replies

Reviews trailers per patch

1 of 4 patches has a Reviewed-by or Acked-by.

PatchAlexandre Belloni
1/4A-b
2/4
3/4
4/4

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v3 thread

Cover letter [PATCH v3 0/4] AM437x: Add rtc-only + DDR mode support

RTC plus DDR in self-refresh is a power saving mode where in the entire system including the different voltage rails from PMIC are shutdown except the ones feeding on to RTC and DDR. DDR is kept in self-refresh hence the contents are preserved.

RTC ALARM2 is connected to PMIC_EN line. TPS65218 PMIC has granular voltage rail control. The voltage rail feeding RTC is kept on while the rest of the PMIC regulators are powered off.

Once the ALARM2 is triggered we enter the mode with DDR in self-refresh and RTC Ticking. After a predetermined time an RTC ALARM1 triggers waking up the system. The control goes to bootloader. The bootloader then checks RTC scratchpad registers to confirm it was an rtc_only wakeup and follows a different path, configure bare minimal clocks for ddr and then jumps to the resume address in another RTC scratchpad registers and transfers the control to Kernel. Kernel then restores the saved context.

The patch series adds rtc-only + DDR mode support am am437x Tested DS0, rtc+ddr back and forth on am437x-gp-evm board.

This mode works only with u-boot built with am43xx_evm_rtconly_defconfig

Additional patch is needed for omap-gpio save restore which will come as fixes later.

Hardware Description of this mode can be found here:

http://www.ti.com/lit/ug/spruhl7h/spruhl7h.pdf Page 2884.

Changes in v3:

* Exported out omap_rtc_poweroff_program function & removed the patch to add a generic rtc interface as it is specific to am43 at the moment.

Keerthy (4):
rtc: OMAP: Add support for rtc-only mode
arm: mach-omap2: pm33xx: Add support for rtc+ddr in self refresh mode
soc: ti: pm33xx: Push the am33xx_push_sram_idle to the top
soc: ti: pm33xx: AM437X: Add rtc_only with ddr in self-refresh support

 arch/arm/mach-omap2/pm33xx-core.c    |  76 +++++++-
 drivers/rtc/rtc-omap.c               |  49 ++++-
 drivers/soc/ti/Kconfig               |   5 +-
 drivers/soc/ti/pm33xx.c              | 273 ++++++++++++++++++++++-----
 include/linux/platform_data/pm33xx.h |   5 +
 include/linux/rtc/rtc-omap.h         |   7 +
 6 files changed, 354 insertions(+), 61 deletions(-)
 create mode 100644 include/linux/rtc/rtc-omap.h
Signature · 1 line
2.17.1