Suspending uart with Zephyr console

NCS 3.02 54L10

I am using uart0 in async mode for printk and user input (my own callback not zephyr CLI). I need to be able to put the uart into suspend after an inactivity timeout to reduce current consumption.

Based on advice from ticket 344896 I am using rc = pm_device_action_run(uart_dev, PM_DEVICE_ACTION_SUSPEND) gets me an error -88 Not Implemented.

These are my config options:

CONFIG_SERIAL=y
CONFIG_PM_DEVICE=y
CONFIG_UART_ASYNC_API=y
CONFIG_UART_ASYNC_ADAPTER=y
CONFIG_UART_CONSOLE=y
CONFIG_PM_DEVICE=y
CONFIG_PM_DEVICE_RUNTIME=y
CONFIG_CONSOLE=y

I get a feeling this might be because the console is using the driver? In any case, how can I force a shutdown of the uart? It doesn't matter if there is no way of restarting it outside of a reboot.

Related