From 6fe9a013aad73a0d033e49536b2037312e09f855 Mon Sep 17 00:00:00 2001 From: Axel Lin Date: Thu, 11 Mar 2010 09:50:07 +0800 Subject: [PATCH] --- yaml --- r: 188980 b: refs/heads/master c: 451a73cd46573444f68f412c87439c0a291718ec h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/drivers/regulator/lp3971.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/[refs] b/[refs] index aafcfc7395bc..654774c2b826 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: cdb868f58103825856e27aa4e1f26943fc119e41 +refs/heads/master: 451a73cd46573444f68f412c87439c0a291718ec diff --git a/trunk/drivers/regulator/lp3971.c b/trunk/drivers/regulator/lp3971.c index 8bdcf41ab68c..b20b3e1d821a 100644 --- a/trunk/drivers/regulator/lp3971.c +++ b/trunk/drivers/regulator/lp3971.c @@ -45,7 +45,7 @@ static int lp3971_set_bits(struct lp3971 *lp3971, u8 reg, u16 mask, u16 val); LP3971_BUCK2 -> 4 LP3971_BUCK3 -> 6 */ -#define BUCK_VOL_CHANGE_SHIFT(x) (((1 << x) & ~0x01) << 1) +#define BUCK_VOL_CHANGE_SHIFT(x) (((!!x) << 2) | (x & ~0x01)) #define BUCK_VOL_CHANGE_FLAG_GO 0x01 #define BUCK_VOL_CHANGE_FLAG_TARGET 0x02 #define BUCK_VOL_CHANGE_FLAG_MASK 0x03