On Mon, Jul 07, 2025 at 04:34:03PM +0800, Nick Li wrote:
On Fri, Jul 04, 2025 at 03:37:32PM +0100, Mark Brown wrote:
quoted
On Fri, Jul 04, 2025 at 07:12:47PM +0800, Nick Li wrote:
quoted
On Thu, Jul 03, 2025 at 03:59:34PM +0100, Mark Brown wrote:
quoted
On Thu, Jul 03, 2025 at 11:56:37AM +0800, Nick wrote:
quoted
quoted
the volume will be masked in fs210x->vol[2],
we restore the volume when the driver resumes(reinitializes) the deivce.
quoted
You're not just restoring the values on resume, you're also overwriting
them on probe.
Yes, the volume will be set to the default value at the first time of initialization on probe,
and it may be updated by volume control later.
It's a good way to use the regmap cache(REGCACHE_RBTREE) to cache the volumes.
Great. Note that for new things you should generally use _MAPLE
instead, it's a more modern data structure - _RBTREE can still make
sense for some specialist use cases but this is unlikely to be one of
them.
quoted
There's not great options here, and you're going to loose the start of
playback especially with devices that don't start clocking until audio
starts. You really need the CPU vendors you're working with to
implement SND_SOC_DAIFMT_CONT or expose their clocks via the clock API
but not all hardware is able to do this. I think given how limited your
hardware is here you really need something in trigger() or some new
callback that runs later than that, the delayed work you've got there is
trying to fudge things to run after trigger.
We will start the start_work in dai->trigger if there is no clock bclk
for us to control, and disable fading in/out in firmware to reduce
the time consumption if it is needed(As a backup plan).
Great. You could also make the fade in/out user selectable so the
application can trade off between pops/clicks and cut off audio.