diff options
| author | bui duc phuc <phucduc.bui@gmail.com> | 2026-10-23 17:28:18 +0700 |
|---|---|---|
| committer | Mark Brown <broonie@kernel.org> | 2026-10-28 12:41:13 +0000 |
| commit | 3b54e739273752b370e49b09976da152fa3b802c (patch) | |
| tree | fdf1279692e89cceb26e39c70cf8ed2bc5528f39 /scripts/basic | |
| parent | 99203e8d8968def973e82bb712ea959c6a46c16e (diff) | |
| download | linux-3b54e739273752b370e49b09976da152fa3b802c.tar.gz linux-3b54e739273752b370e49b09976da152fa3b802c.zip | |
ASoC: xilinx: formatter_pcm: Fix read-modify-write of AUD_CTRL in hw_params
xlnx_formatter_pcm_hw_params() does a read-modify-write on XLNX_AUD_CTRL
but only ORs in the new data width and active channel values without
clearing the old ones. If hw_params is called more than once on an
open stream, these fields may retain bits from the previous configuration,
resulting in an incorrect sample width or channel count.
Clear both fields before writing the new values, and use FIELD_PREP() so
the values cannot spill into neighbouring bits.
Fixes: 6f6c3c36f091 ("ASoC: xlnx: add pcm formatter platform driver")
Signed-off-by: bui duc phuc <phucduc.bui@gmail.com>
Reviewed-by: Gaddipati, Naveen <naveen.gaddipati@amd.com>
Link: https://patch.msgid.link/20261023102818.523331-1-phucduc.bui@gmail.com
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'scripts/basic')
0 files changed, 0 insertions, 0 deletions
