Re: [PATCH v3 25/27] ASoC: codecs: rt712: Use guard() for mutex locks

From: Bui Duc Phuc

Date: Mon Jul 13 2026 - 02:44:43 EST


I'd like to confirm one more point.

As I understand it, cache_only must be disabled before
re-writing the paging selector registers. Otherwise, _regmap_write()
would update only the cache and return without calling
map->reg_write(), so the hardware state would not actually
be restored.
If my understanding is correct, I'm planning to submit a follow-up
patch like the one below.

---------------------------------

bool cache_only ;
cache_only = map->cache_only;

map->cache_only = false;

for_each_selector_register() {
if (regcache_read(map, selector_reg, &selector_val))
continue;
paging_ret = _regmap_write(map, selector_reg, selector_val);
}


map->cache_only = cache_only;
-----------------------------------

I'd appreciate any feedback.

Best regards,
Phuc