regulator: max8952: Simplify the logic to get vid[0|1] status
authorAxel Lin <axel.lin@gmail.com>
Thu, 15 Mar 2012 00:47:48 +0000 (08:47 +0800)
committerMark Brown <broonie@opensource.wolfsonmicro.com>
Sun, 1 Apr 2012 10:59:25 +0000 (11:59 +0100)
commitc8237f01db63b458c34222d07f66c5417cfd866b
tree37862f1459b4ed044868b8857ee3c7d502c124aa
parent1f793ff258c7a48e8cc3729ac13bfd1b3850b9c9
regulator: max8952: Simplify the logic to get vid[0|1] status

The syntax "(((vid >> 1) % 2) == 1)" is inefficient and also hard to read.
Use bitwidse AND operator instead.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
drivers/regulator/max8952.c