[PATCH] ALSA: hda/hdmi: Add Intel silent stream support

Pierre-Louis Bossart pierre-louis.bossart at linux.intel.com
Thu Jun 25 17:43:32 CEST 2020



On 6/25/20 10:30 AM, Jaroslav Kysela wrote:
> Dne 25. 06. 20 v 16:46 Pierre-Louis Bossart napsal(a):
>>
>>
>>
>>>>>>> So, rather the question is how we should provide the setup of such
>>>>>>> parameter.  It's supposed to be a part of power management stuff 
>>>>>>> that
>>>>>>> should be touched by either a smart PM tool or a manual override 
>>>>>>> such
>>>>>>> as runtime PM setup?  Or can it be seen as a more casual tuning?
>>>>>>
>>>>>> I am not aware of such tools. The only thing I know is that some of
>>>>>> the HDaudio power settings are already controlled by kernel
>>>>>> parameters, e.g.
>>>>>>
>>>>>> /etc/modprobe.d/audio_powersave.conf
>>>>>> options snd_hda_intel power_save=1
>>>>>
>>>>> Yes, it's been the primary knob for years to turn on/off the runtime
>>>>> PM for HD-audio and other legacy drivers.  This was used by powertop
>>>>> or some other power-aware daemons and tools, to be toggled dynamically
>>>>> per the power cable state or such.
>>>>>
>>>>> And, how the silent stream feature should be seen?
>>>>> Should it be a system-wide root-only setup or adjustable per user?
>>>>> Would it be changed often?  Such questions and answers will lead us to
>>>>> the right direction, I hope.
>>>>
>>>> For audio, would UCM not be the appropriate point for a system 
>>>> integrator to decide how the audio device should be set up?
>>>>
>>>> This would allow for a choice based on the situation in which the 
>>>> device is actually being deployed without users having to muck 
>>>> around with module parameters -- maybe someone wants want this 
>>>> enabled for an HTPC setup, but not on a desktop connected to a monitor.
>>>
>>> Right, that's my concern.  Many users with HDMI monitor that is
>>> capable of audio don't use HDMI audio because they don't need it
>>> and/or the output sucks.  For them, this feature is superfluous and
>>> harmful from the runtime PM POV. >
>>> If it were provided via UCM, would it be yet another UCM profile like
>>> HDMI+silentstream?  This can be confusing, too, I'm afraid.
>>
>> Unless I am mistaken, this silent stream would be applicable to the
>> legacy HDaudio driver, as well as SOF.
>>
>> UCM is not used for the legacy HDaudio case, so that would close the
>> door on UCM-based configurations, no?
> 
> UCM can be used for legacy HDA, too (and it is used for some legacy HDA 
> models - dual codecs). It seems that it's better to describe the 
> "abstract" device layout for users on the one place.

Did you mean represent the form-factor in UCM?

Currently we use e.g. the same bytcr-rt5640 UCM file for tablets, 
notebooks and headless devices (mini desktops). UCM would need to get 
the information from somewhere else, I don't think it'd be practical to 
hard-code form-factors in UCM proper.

> My plan is to migrate to UCM completely at some day when the major 
> issues are resolved. It may be a bit challenge for the legacy HDA driver 
> and USB devices but doable.

For USB I don't know how this would work. USB report descriptors, if you 
wanted to represent all possible cases with UCM you'd need to build the 
union of all possible cases and make parts conditional.


More information about the Alsa-devel mailing list