Messages in this thread | | | Date | Wed, 3 Nov 2021 17:01:16 +0000 | From | Mark Brown <> | Subject | Re: [PATCH] regmap: allow to define reg_update_bits for no bus configuration |
| |
On Tue, Nov 02, 2021 at 10:41:38PM +0100, Ansuel Smith wrote:
> @@ -3064,7 +3065,7 @@ static int _regmap_update_bits(struct regmap *map, unsigned int reg, > if (change) > *change = false; > > - if (regmap_volatile(map, reg) && map->reg_update_bits) { > + if ((regmap_volatile(map, reg) || !map->bus) && map->reg_update_bits) { > ret = map->reg_update_bits(map->bus_context, reg, mask, val); > if (ret == 0 && change) > *change = true;
I don't understand this change. The point of the check for volatile there is that if the register isn't volatile then we need to ensure that the cache gets updated with any change that happens so we need to go through paths that include cache updates. The presence or otherwise of a bus does not seem at all relevant here. [unhandled content-type:application/pgp-signature] | |