Re: [PATCH 2/2] regulator: da9052: Simplify checking DVC controlled regulators

From: Mark Brown
Date: Tue Jun 22 2021 - 08:50:51 EST


On Fri, Jun 18, 2021 at 10:14:12PM +0800, Axel Lin wrote:

> Only DVC controlled regulators have activate_bit set, so just check
> activate_bit we can know if the regulator is DVC controlled.

This feels a bit icky - what if the activate_bit for some variant were
bit 0? I'm not sure we're likely to see new variants but even so the
fact that 0 is a potentially valid value for the bit feels wrong.

Attachment: signature.asc
Description: PGP signature