mirror of
https://github.com/torvalds/linux.git
synced 2026-10-12 05:17:15 +02:00
ASoC: rt1318: sort the register default table
reg_defaults must be sorted by ascending register address, as regcache_lookup_reg() locates entries in it with bsearch(). See commitfd80df352b("regcache: Add support for sorting defaults arrays"). The 0xdd93 and 0xdd94 entries are listed after 0xddc8 in rt1318_reg[], which leaves them unreachable for the binary search. regcache_reg_needs_sync() then cannot compare them against their default and reports that a sync is needed, so they are written to the device on every regcache_sync() even when they were never touched. Sort the table by register address. Fixes:fe1ff61487("ASoC: rt1318: Add RT1318 audio amplifier driver") Cc: stable@vger.kernel.org Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com> Link: https://patch.msgid.link/20260805090240.16991-17-peter.ujfalusi@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
parent
7b48eccfbb
commit
2a8e4b7114
|
|
@ -337,6 +337,8 @@ static const struct reg_default rt1318_reg[] = {
|
|||
{ 0xdd08, 0x40 },
|
||||
{ 0xdd12, 0x00 },
|
||||
{ 0xdd35, 0x00 },
|
||||
{ 0xdd93, 0x00 },
|
||||
{ 0xdd94, 0x64 },
|
||||
{ 0xddb5, 0x00 },
|
||||
{ 0xddb6, 0x40 },
|
||||
{ 0xddb7, 0x00 },
|
||||
|
|
@ -345,8 +347,6 @@ static const struct reg_default rt1318_reg[] = {
|
|||
{ 0xddc6, 0x00 },
|
||||
{ 0xddc7, 0x00 },
|
||||
{ 0xddc8, 0x00 },
|
||||
{ 0xdd93, 0x00 },
|
||||
{ 0xdd94, 0x64 },
|
||||
{ 0xdf00, 0x00 },
|
||||
{ 0xdf5f, 0x00 },
|
||||
{ 0xdf60, 0x00 },
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user