Re: [PATCH] regmap: rbtree: Fix register default look-up in sync

From: Mark Brown
Date: Fri Mar 23 2012 - 20:56:41 EST


On Fri, Mar 23, 2012 at 11:04:57AM +0100, Lars-Peter Clausen wrote:
> The code currently passes the register offset in the current block to
> regcache_lookup_reg. This works fine as long as there is only one block and with
> base register of 0, but in all other cases it will look-up the default for a
> wrong register, which can cause unnecessary register writes. This patch fixes
> it by passing the actual register number to regcache_lookup_reg.
>
> Signed-off-by: Lars-Peter Clausen <lars@xxxxxxxxxx>
> Cc: <stable@xxxxxxxxxxxxxxx>

Good catch - I'm fairly surprised nobody (including me) noticed it over
the couple of kernel releases it's been there. Will apply once we've
got an -rc1.

Attachment: signature.asc
Description: Digital signature