summaryrefslogtreecommitdiffstats
path: root/include/power
diff options
context:
space:
mode:
authorMarcel Ziswiler <marcel.ziswiler@toradex.com>2018-05-08 17:34:08 +0200
committerTom Warren <twarren@nvidia.com>2018-05-10 16:34:20 -0700
commit4616e33b6a01b2f12c422d0d27afbbbbee2985e8 (patch)
treee9026afe9cc5ee3d9758ac513ee3df2d9a34648c /include/power
parentc0cb8c8e8656639ebeeaa0d98a1f3c0807f590b3 (diff)
downloadu-boot-4616e33b6a01b2f12c422d0d27afbbbbee2985e8.tar.gz
u-boot-4616e33b6a01b2f12c422d0d27afbbbbee2985e8.tar.xz
u-boot-4616e33b6a01b2f12c422d0d27afbbbbee2985e8.zip
power: as3722: fix ldo_get/set_enable for ldo index bigger than 7
Fix ldo_get_enable() and ldo_set_enable() functions for LDOs with an index > 7. Turns out there are actually two separate AS3722_LDO_CONTROL registers AS3722_LDO_CONTROL0 and AS3722_LDO_CONTROL1. Actually make use of both. While at it also actually use the enable parameter of the ldo_set_enable() function which now truly allows disabling as opposed to only enabling LDOs. Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com> Signed-off-by: Tom Warren <twarren@nvidia.com>
Diffstat (limited to 'include/power')
-rw-r--r--include/power/as3722.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/include/power/as3722.h b/include/power/as3722.h
index 9f045d5ab6..ab969809ee 100644
--- a/include/power/as3722.h
+++ b/include/power/as3722.h
@@ -13,7 +13,8 @@
#define AS3722_SD_VOLTAGE(n) (0x00 + (n))
#define AS3722_LDO_VOLTAGE(n) (0x10 + (n))
#define AS3722_SD_CONTROL 0x4d
-#define AS3722_LDO_CONTROL 0x4e
+#define AS3722_LDO_CONTROL0 0x4e
+#define AS3722_LDO_CONTROL1 0x4f
#define AS3722_ASIC_ID1 0x90
#define AS3722_ASIC_ID2 0x91