[alsa-devel] [PATCH] ASoC: core: Configure pin muxing via pinctrl when registering a DAI
linus.walleij at linaro.org
Tue Sep 25 13:43:21 CEST 2012
NOTE: can someone relay me the original patch in this thread or
cross-post it to linux-kernel since that is where it obviously
needs to be discussed? I'm not on alsa-devel... (OK I will subscribe...)
On Tue, Sep 25, 2012 at 1:24 PM, Peter Ujfalusi <peter.ujfalusi at ti.com> wrote:
> But the pinctrl could be used to change the mux runtime. For example in OMAP
> for most of the audio related pins we need to select MODE0 mux configuration
> in order to route the signal to the pin. However the same pin can be
> configured to SAFE_MODE which disconnects the pin from outside.
> During audio activity we obviously need to configure these pins to MODE0 but
> when there is not activity we could set them to SAFE_MODE which could result
> some power savings (preventing leakage, etc).
> For this to work it would be ideal to use the pm_runtime as a centralized
> place to handle clocks, pinctrl, etc...
So this is exactly what we are doing for the ux500 and implementing in most
of the AMBA devs.
We even have standard names for it in the pinctrl subsystem - the modes
named "default" and "sleep" or maybe "idle" if you also have a separate
"sleep" state apart from the relaxed state.
So we go into "default" when the device is in use and relax it by going
into "sleep" whenever we can.
> But again, what to do with the cases when this is not needed (the pinctrl part
> for the devices)?
This is too unspecific for me, sorry... are you thinking about Stephen's
preference to do this using hogs or of systems not using pinctrl at all?
(They should be safe since not configuring pinctrl means it gets stubbed out.)
More information about the Alsa-devel