linux-iio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Controlling device power management from terminal
@ 2022-07-25  8:41 Crt Mori
  2022-07-25 21:26 ` Andy Shevchenko
  0 siblings, 1 reply; 8+ messages in thread
From: Crt Mori @ 2022-07-25  8:41 UTC (permalink / raw)
  To: Linux Iio

Hi,
I am implementing the power saving modes for mlx90632 device driver
and while I have implemented routines for SET_RUNTIME_PM_OPS
(runtime_pm_suspend and runtime_pm_resume) I am not able to find out
how to trigger them from the terminal.

It could be that my driver code for power management implementation is
incomplete and I need to initialize something more.

Maybe it is helpful, but the power submodule of the device contains below files:

$ ls -al /sys/bus/iio/devices/iio\:device0/power
total 0
drwxrwxr-x 2 root gpio    0 Apr  6 14:17 .
drwxrwxr-x 3 root gpio    0 Apr  6 14:17 ..
-rw-rw-r-- 1 root gpio 4096 Apr  6 14:17 async
-rw-rw-r-- 1 root gpio 4096 Apr  6 14:17 autosuspend_delay_ms
-rw-rw-r-- 1 root gpio 4096 Apr  6 14:18 control
-r--r--r-- 1 root gpio 4096 Apr  6 14:17 runtime_active_kids
-r--r--r-- 1 root gpio 4096 Apr  6 14:17 runtime_active_time
-r--r--r-- 1 root gpio 4096 Apr  6 14:17 runtime_enabled
-r--r--r-- 1 root gpio 4096 Apr  6 14:17 runtime_status
-r--r--r-- 1 root gpio 4096 Apr  6 14:17 runtime_suspended_time
-r--r--r-- 1 root gpio 4096 Apr  6 14:17 runtime_usage

And control is already set to "auto" which according to documentation
should allow the PM.

Thanks for the hints.

Best regards,
Crt Mori

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

end of thread, other threads:[~2022-08-13 15:02 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-07-25  8:41 Controlling device power management from terminal Crt Mori
2022-07-25 21:26 ` Andy Shevchenko
2022-07-25 21:35   ` Crt Mori
2022-07-25 21:45     ` Andy Shevchenko
2022-08-02 15:32       ` Crt Mori
2022-08-06 17:28         ` Jonathan Cameron
2022-08-07 21:44           ` Crt Mori
2022-08-13 15:12             ` Jonathan Cameron

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).