ASoC: SOF: Intel: lnl: add helper to detect SoundWire wakes
authorPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Thu, 4 Apr 2024 19:03:55 +0000 (14:03 -0500)
committerMark Brown <broonie@kernel.org>
Thu, 4 Apr 2024 19:25:38 +0000 (20:25 +0100)
commitab9182441ee5a94dd6f47743ed1b7b6b07b63cb2
tree5d10747d40f2dd58c83421cfcf7902a7e2bceb38
parentbd5863f9ef12e26c2cfdce9c0adbf0222c731a3c
ASoC: SOF: Intel: lnl: add helper to detect SoundWire wakes

The global STATESTS register will provide information on all
links. Rather than iterate on all possible links, the helpers only
filters the range of possible bits for a quick lookup. The
process_wakeen() helper will walk through all the links and deal with
wakes.

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com>
Reviewed-by: Rander Wang <rander.wang@intel.com>
Link: https://msgid.link/r/20240404190357.138073-3-pierre-louis.bossart@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/sof/intel/lnl.c