AM62 Low Power

From Variscite Wiki
Revision as of 13:55, 11 April 2024 by Ken (talk | contribs)
Warning: This page is designed to be used with a 'release' URL parameter.

This page is using the default release am62-yocto-kirkstone-6.1.46_09.01.00.08-v1.0.
To view this page for a specific Variscite SoM and software release, please follow these steps:

  1. Visit variwiki.com
  2. Select your SoM
  3. Select the software release
VAR-SOM-AM62 Low Power Modes

Background

TI's AM62 contains numerous low power modes and features. Extensive documentation on the subject can be found by consulting TI's Low Power Modes article.

While this wiki article does not serve to duplicate information, it will highlight some of the key important modes and usages on Variscite's development platform.

Suspend to RAM (Deep Sleep)

Deep Sleep AKA Suspend-to-RAM is a low-power mode that allows an embedded device to retain its state in RAM while the processor is turned off. This can save a significant amount of power, especially in devices that are battery-powered.

In order to enter deep sleep, use the following command:

# pm-suspend

Wake up

Various wakeup sources are possible on the AM62. On Variscite's development platform, the touchscreen has been configured as a wakeup source using TI's "I/O Daisy Chain" method.

ft5x06_ts: ft5x06_ts@38 {
	compatible = "edt,edt-ft5206";
	reg = <0x38>;
	pinctrl-names = "default";
	pinctrl-0 = <&captouch_pins_default>;
	interrupts-extended = <&main_gpio1 16 IRQ_TYPE_EDGE_FALLING>,
                              <&main_pmx0 0x1B8>;
	interrupt-names = "irq", "wakeup";
	touchscreen-size-x = <800>;
	touchscreen-size-y = <480>;
	touchscreen-inverted-x;
	touchscreen-inverted-y;
	wakeup-source;
	status = "okay";
};

For more information on various wake-up sources, please consult TI's Wakeup Sources article.

CPU Hotplug

The modern Linux kernel has features to support CPU "hotplugging." On the AM62, this allows for individual CPU cores to be completely powered down and back up dynamically. This can be used to help reduce power usage of a system at runtime.
For example, CPU3 can be powered off at runtime by issuing the following command:

root@am62x-var-som:~# echo off > /sys/devices/system/cpu/cpu3/online                                                                                                                                                               
[71329.969188] psci: CPU3 killed (polled 0 ms)


Then brought back online later with:

root@am62x-var-som:~# echo on > /sys/devices/system/cpu/cpu3/online                                              
I/TC: Secondary CPU 3 initializing                                                                                                                                                                                                 
I/TC: Secondary CPU 3 switching to normal world boot                                                                                                                                                                               
[71401.705095] Detected VIPT I-cache on CPU3                                                                                                                                                                                       
[71401.709422] GICv3: CPU3: found redistributor 3 region 0:0x00000000018e0000                                                                                                                                                      
[71401.716493] CPU3: Booted secondary processor 0x0000000003 [0x410fd034]


This can be repeated for any CPU, with the exception that one CPU must always remain online with this, that is, you cannot power off ALL CPUs simultaneously using the hotplug method.

Additional information can be found by consulting the kernel documentation on the subject:
CPU hotplug in the Kernel