blob: e75562d48c04081658cb3df6efda92e2559b068b [file] [log] [blame]
Sundar Iyer4f724be2010-09-15 10:50:59 +01001/*
2 * Copyright (C) ST-Ericsson SA 2010
3 *
4 * License Terms: GNU General Public License v2
5 *
Bengt Jonssona1e516e2010-12-10 11:08:48 +01006 * Authors: Sundar Iyer <sundar.iyer@stericsson.com>
7 * Bengt Jonsson <bengt.g.jonsson@stericsson.com>
Sundar Iyer4f724be2010-09-15 10:50:59 +01008 *
9 * MOP500 board specific initialization for regulators
10 */
11#include <linux/kernel.h>
12#include <linux/regulator/machine.h>
Bengt Jonssona1e516e2010-12-10 11:08:48 +010013#include <linux/regulator/ab8500.h>
Linus Walleijd1de85a2010-12-02 17:10:14 +010014#include "board-mop500-regulators.h"
15
Lee Jones0b5ea1e2012-09-03 14:33:39 +010016static struct regulator_consumer_supply gpio_en_3v3_consumers[] = {
17 REGULATOR_SUPPLY("vdd33a", "smsc911x.0"),
18};
19
20struct regulator_init_data gpio_en_3v3_regulator = {
21 .constraints = {
22 .name = "EN-3V3",
23 .min_uV = 3300000,
24 .max_uV = 3300000,
25 .valid_ops_mask = REGULATOR_CHANGE_STATUS,
26 },
27 .num_consumer_supplies = ARRAY_SIZE(gpio_en_3v3_consumers),
28 .consumer_supplies = gpio_en_3v3_consumers,
29};
30
Linus Walleijfe67dfc2011-03-07 11:48:15 +010031/*
32 * TPS61052 regulator
33 */
34static struct regulator_consumer_supply tps61052_vaudio_consumers[] = {
35 /*
36 * Boost converter supply to raise voltage on audio speaker, this
37 * is actually connected to three pins, VInVhfL (left amplifier)
38 * VInVhfR (right amplifier) and VIntDClassInt - all three must
39 * be connected to the same voltage.
40 */
41 REGULATOR_SUPPLY("vintdclassint", "ab8500-codec.0"),
42};
43
44struct regulator_init_data tps61052_regulator = {
45 .constraints = {
46 .name = "vaudio-hf",
47 .min_uV = 4500000,
48 .max_uV = 4500000,
49 .valid_ops_mask = REGULATOR_CHANGE_STATUS,
50 },
51 .num_consumer_supplies = ARRAY_SIZE(tps61052_vaudio_consumers),
52 .consumer_supplies = tps61052_vaudio_consumers,
53};
54
Linus Walleijd1de85a2010-12-02 17:10:14 +010055static struct regulator_consumer_supply ab8500_vaux1_consumers[] = {
Lee Jones27f26de2013-03-21 15:59:05 +000056 /* Main display, u8500 R3 uib */
57 REGULATOR_SUPPLY("vddi", "mcde_disp_sony_acx424akp.0"),
58 /* Main display, u8500 uib and ST uib */
59 REGULATOR_SUPPLY("vdd1", "samsung_s6d16d0.0"),
60 /* Secondary display, ST uib */
61 REGULATOR_SUPPLY("vdd1", "samsung_s6d16d0.1"),
Linus Walleijd1de85a2010-12-02 17:10:14 +010062 /* SFH7741 proximity sensor */
63 REGULATOR_SUPPLY("vcc", "gpio-keys.0"),
64 /* BH1780GLS ambient light sensor */
65 REGULATOR_SUPPLY("vcc", "2-0029"),
66 /* lsm303dlh accelerometer */
67 REGULATOR_SUPPLY("vdd", "3-0018"),
68 /* lsm303dlh magnetometer */
69 REGULATOR_SUPPLY("vdd", "3-001e"),
70 /* Rohm BU21013 Touchscreen devices */
71 REGULATOR_SUPPLY("avdd", "3-005c"),
72 REGULATOR_SUPPLY("avdd", "3-005d"),
73 /* Synaptics RMI4 Touchscreen device */
74 REGULATOR_SUPPLY("vdd", "3-004b"),
Lee Jonesefb34d22013-03-21 15:59:10 +000075 /* L3G4200D Gyroscope device */
76 REGULATOR_SUPPLY("vdd", "2-0068"),
Linus Walleijd1de85a2010-12-02 17:10:14 +010077};
78
79static struct regulator_consumer_supply ab8500_vaux2_consumers[] = {
80 /* On-board eMMC power */
81 REGULATOR_SUPPLY("vmmc", "sdi4"),
82 /* AB8500 audio codec */
83 REGULATOR_SUPPLY("vcc-N2158", "ab8500-codec.0"),
84};
85
86static struct regulator_consumer_supply ab8500_vaux3_consumers[] = {
87 /* External MMC slot power */
88 REGULATOR_SUPPLY("vmmc", "sdi0"),
89};
90
91static struct regulator_consumer_supply ab8500_vtvout_consumers[] = {
92 /* TV-out DENC supply */
93 REGULATOR_SUPPLY("vtvout", "ab8500-denc.0"),
94 /* Internal general-purpose ADC */
95 REGULATOR_SUPPLY("vddadc", "ab8500-gpadc.0"),
96};
97
Ola Lilja29bd2ab2012-02-01 14:18:10 +010098static struct regulator_consumer_supply ab8500_vaud_consumers[] = {
99 /* AB8500 audio-codec main supply */
100 REGULATOR_SUPPLY("vaud", "ab8500-codec.0"),
101};
102
103static struct regulator_consumer_supply ab8500_vamic1_consumers[] = {
104 /* AB8500 audio-codec Mic1 supply */
105 REGULATOR_SUPPLY("vamic1", "ab8500-codec.0"),
106};
107
108static struct regulator_consumer_supply ab8500_vamic2_consumers[] = {
109 /* AB8500 audio-codec Mic2 supply */
110 REGULATOR_SUPPLY("vamic2", "ab8500-codec.0"),
111};
112
113static struct regulator_consumer_supply ab8500_vdmic_consumers[] = {
114 /* AB8500 audio-codec DMic supply */
115 REGULATOR_SUPPLY("vdmic", "ab8500-codec.0"),
116};
117
Linus Walleijd1de85a2010-12-02 17:10:14 +0100118static struct regulator_consumer_supply ab8500_vintcore_consumers[] = {
119 /* SoC core supply, no device */
120 REGULATOR_SUPPLY("v-intcore", NULL),
Joe Perches7c9d4402011-06-23 11:39:20 -0700121 /* USB Transceiver */
Linus Walleijd1de85a2010-12-02 17:10:14 +0100122 REGULATOR_SUPPLY("vddulpivio18", "ab8500-usb.0"),
123};
124
125static struct regulator_consumer_supply ab8500_vana_consumers[] = {
126 /* External displays, connector on board, 1v8 power supply */
127 REGULATOR_SUPPLY("vsmps2", "mcde.0"),
128};
Sundar Iyer4f724be2010-09-15 10:50:59 +0100129
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100130/* ab8500 regulator register initialization */
Bengt Jonsson732805a2013-03-21 15:59:03 +0000131static struct ab8500_regulator_reg_init ab8500_reg_init[] = {
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100132 /*
133 * VanaRequestCtrl = HP/LP depending on VxRequest
Lee Jonesd79df322013-03-21 15:58:58 +0000134 * VpllRequestCtrl = HP/LP depending on VxRequest
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100135 * VextSupply1RequestCtrl = HP/LP depending on VxRequest
136 */
Lee Jones3c1b8432013-03-21 15:59:01 +0000137 INIT_REGULATOR_REGISTER(AB8500_REGUREQUESTCTRL2, 0xfc, 0x00),
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100138 /*
139 * VextSupply2RequestCtrl = HP/LP depending on VxRequest
140 * VextSupply3RequestCtrl = HP/LP depending on VxRequest
141 * Vaux1RequestCtrl = HP/LP depending on VxRequest
142 * Vaux2RequestCtrl = HP/LP depending on VxRequest
143 */
Lee Jones3c1b8432013-03-21 15:59:01 +0000144 INIT_REGULATOR_REGISTER(AB8500_REGUREQUESTCTRL3, 0xff, 0x00),
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100145 /*
146 * Vaux3RequestCtrl = HP/LP depending on VxRequest
147 * SwHPReq = Control through SWValid disabled
148 */
Lee Jones3c1b8432013-03-21 15:59:01 +0000149 INIT_REGULATOR_REGISTER(AB8500_REGUREQUESTCTRL4, 0x07, 0x00),
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100150 /*
Lee Jonesd79df322013-03-21 15:58:58 +0000151 * Vsmps1SysClkReq1HPValid = enabled
152 * Vsmps2SysClkReq1HPValid = enabled
153 * Vsmps3SysClkReq1HPValid = enabled
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100154 * VanaSysClkReq1HPValid = disabled
Lee Jonesd79df322013-03-21 15:58:58 +0000155 * VpllSysClkReq1HPValid = enabled
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100156 * Vaux1SysClkReq1HPValid = disabled
157 * Vaux2SysClkReq1HPValid = disabled
158 * Vaux3SysClkReq1HPValid = disabled
159 */
Lee Jones3c1b8432013-03-21 15:59:01 +0000160 INIT_REGULATOR_REGISTER(AB8500_REGUSYSCLKREQ1HPVALID1, 0xff, 0x17),
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100161 /*
162 * VextSupply1SysClkReq1HPValid = disabled
163 * VextSupply2SysClkReq1HPValid = disabled
164 * VextSupply3SysClkReq1HPValid = SysClkReq1 controlled
165 */
Lee Jones3c1b8432013-03-21 15:59:01 +0000166 INIT_REGULATOR_REGISTER(AB8500_REGUSYSCLKREQ1HPVALID2, 0x70, 0x40),
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100167 /*
168 * VanaHwHPReq1Valid = disabled
169 * Vaux1HwHPreq1Valid = disabled
170 * Vaux2HwHPReq1Valid = disabled
171 * Vaux3HwHPReqValid = disabled
172 */
Lee Jones3c1b8432013-03-21 15:59:01 +0000173 INIT_REGULATOR_REGISTER(AB8500_REGUHWHPREQ1VALID1, 0xe8, 0x00),
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100174 /*
175 * VextSupply1HwHPReq1Valid = disabled
176 * VextSupply2HwHPReq1Valid = disabled
177 * VextSupply3HwHPReq1Valid = disabled
178 */
Lee Jones3c1b8432013-03-21 15:59:01 +0000179 INIT_REGULATOR_REGISTER(AB8500_REGUHWHPREQ1VALID2, 0x07, 0x00),
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100180 /*
181 * VanaHwHPReq2Valid = disabled
182 * Vaux1HwHPReq2Valid = disabled
183 * Vaux2HwHPReq2Valid = disabled
184 * Vaux3HwHPReq2Valid = disabled
185 */
Lee Jones3c1b8432013-03-21 15:59:01 +0000186 INIT_REGULATOR_REGISTER(AB8500_REGUHWHPREQ2VALID1, 0xe8, 0x00),
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100187 /*
188 * VextSupply1HwHPReq2Valid = disabled
189 * VextSupply2HwHPReq2Valid = disabled
190 * VextSupply3HwHPReq2Valid = HWReq2 controlled
191 */
Lee Jones3c1b8432013-03-21 15:59:01 +0000192 INIT_REGULATOR_REGISTER(AB8500_REGUHWHPREQ2VALID2, 0x07, 0x04),
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100193 /*
194 * VanaSwHPReqValid = disabled
195 * Vaux1SwHPReqValid = disabled
196 */
Lee Jones3c1b8432013-03-21 15:59:01 +0000197 INIT_REGULATOR_REGISTER(AB8500_REGUSWHPREQVALID1, 0xa0, 0x00),
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100198 /*
199 * Vaux2SwHPReqValid = disabled
200 * Vaux3SwHPReqValid = disabled
201 * VextSupply1SwHPReqValid = disabled
202 * VextSupply2SwHPReqValid = disabled
203 * VextSupply3SwHPReqValid = disabled
204 */
Lee Jones3c1b8432013-03-21 15:59:01 +0000205 INIT_REGULATOR_REGISTER(AB8500_REGUSWHPREQVALID2, 0x1f, 0x00),
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100206 /*
207 * SysClkReq2Valid1 = SysClkReq2 controlled
208 * SysClkReq3Valid1 = disabled
209 * SysClkReq4Valid1 = SysClkReq4 controlled
210 * SysClkReq5Valid1 = disabled
211 * SysClkReq6Valid1 = SysClkReq6 controlled
212 * SysClkReq7Valid1 = disabled
213 * SysClkReq8Valid1 = disabled
214 */
Lee Jones3c1b8432013-03-21 15:59:01 +0000215 INIT_REGULATOR_REGISTER(AB8500_REGUSYSCLKREQVALID1, 0xfe, 0x2a),
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100216 /*
217 * SysClkReq2Valid2 = disabled
218 * SysClkReq3Valid2 = disabled
219 * SysClkReq4Valid2 = disabled
220 * SysClkReq5Valid2 = disabled
221 * SysClkReq6Valid2 = SysClkReq6 controlled
222 * SysClkReq7Valid2 = disabled
223 * SysClkReq8Valid2 = disabled
224 */
Lee Jones3c1b8432013-03-21 15:59:01 +0000225 INIT_REGULATOR_REGISTER(AB8500_REGUSYSCLKREQVALID2, 0xfe, 0x20),
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100226 /*
227 * VTVoutEna = disabled
228 * Vintcore12Ena = disabled
229 * Vintcore12Sel = 1.25 V
230 * Vintcore12LP = inactive (HP)
231 * VTVoutLP = inactive (HP)
232 */
Lee Jones3c1b8432013-03-21 15:59:01 +0000233 INIT_REGULATOR_REGISTER(AB8500_REGUMISC1, 0xfe, 0x10),
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100234 /*
235 * VaudioEna = disabled
236 * VdmicEna = disabled
237 * Vamic1Ena = disabled
238 * Vamic2Ena = disabled
239 */
Lee Jones3c1b8432013-03-21 15:59:01 +0000240 INIT_REGULATOR_REGISTER(AB8500_VAUDIOSUPPLY, 0x1e, 0x00),
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100241 /*
242 * Vamic1_dzout = high-Z when Vamic1 is disabled
243 * Vamic2_dzout = high-Z when Vamic2 is disabled
244 */
Lee Jones3c1b8432013-03-21 15:59:01 +0000245 INIT_REGULATOR_REGISTER(AB8500_REGUCTRL1VAMIC, 0x03, 0x00),
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100246 /*
Lee Jonesd79df322013-03-21 15:58:58 +0000247 * Vsmps1Regu = HW control
248 * Vsmps1SelCtrl = Vsmps1 voltage defined by Vsmsp1Sel2
249 */
Lee Jones3c1b8432013-03-21 15:59:01 +0000250 INIT_REGULATOR_REGISTER(AB8500_VSMPS1REGU, 0x0f, 0x06),
Lee Jonesd79df322013-03-21 15:58:58 +0000251 /*
252 * Vsmps2Regu = HW control
253 * Vsmps2SelCtrl = Vsmps2 voltage defined by Vsmsp2Sel2
254 */
Lee Jones3c1b8432013-03-21 15:59:01 +0000255 INIT_REGULATOR_REGISTER(AB8500_VSMPS2REGU, 0x0f, 0x06),
Lee Jonesd79df322013-03-21 15:58:58 +0000256 /*
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100257 * VPll = Hw controlled
258 * VanaRegu = force off
259 */
Lee Jones3c1b8432013-03-21 15:59:01 +0000260 INIT_REGULATOR_REGISTER(AB8500_VPLLVANAREGU, 0x0f, 0x02),
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100261 /*
262 * VrefDDREna = disabled
263 * VrefDDRSleepMode = inactive (no pulldown)
264 */
Lee Jones3c1b8432013-03-21 15:59:01 +0000265 INIT_REGULATOR_REGISTER(AB8500_VREFDDR, 0x03, 0x00),
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100266 /*
267 * VextSupply1Regu = HW control
268 * VextSupply2Regu = HW control
269 * VextSupply3Regu = HW control
270 * ExtSupply2Bypass = ExtSupply12LPn ball is 0 when Ena is 0
271 * ExtSupply3Bypass = ExtSupply3LPn ball is 0 when Ena is 0
272 */
Lee Jones3c1b8432013-03-21 15:59:01 +0000273 INIT_REGULATOR_REGISTER(AB8500_EXTSUPPLYREGU, 0xff, 0x1a),
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100274 /*
275 * Vaux1Regu = force HP
276 * Vaux2Regu = force off
277 */
Lee Jones3c1b8432013-03-21 15:59:01 +0000278 INIT_REGULATOR_REGISTER(AB8500_VAUX12REGU, 0x0f, 0x01),
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100279 /*
Lee Jonesd79df322013-03-21 15:58:58 +0000280 * Vrf1Regu = HW control
281 * Vaux3Regu = force off
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100282 */
Lee Jones3c1b8432013-03-21 15:59:01 +0000283 INIT_REGULATOR_REGISTER(AB8500_VRF1VAUX3REGU, 0x0f, 0x08),
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100284 /*
285 * Vsmps1 = 1.15V
286 */
Lee Jones3c1b8432013-03-21 15:59:01 +0000287 INIT_REGULATOR_REGISTER(AB8500_VSMPS1SEL1, 0x3f, 0x24),
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100288 /*
289 * Vaux1Sel = 2.5 V
290 */
Lee Jones3c1b8432013-03-21 15:59:01 +0000291 INIT_REGULATOR_REGISTER(AB8500_VAUX1SEL, 0x0f, 0x08),
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100292 /*
293 * Vaux2Sel = 2.9 V
294 */
Lee Jones3c1b8432013-03-21 15:59:01 +0000295 INIT_REGULATOR_REGISTER(AB8500_VAUX2SEL, 0x0f, 0x0d),
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100296 /*
297 * Vaux3Sel = 2.91 V
298 */
Lee Jones3c1b8432013-03-21 15:59:01 +0000299 INIT_REGULATOR_REGISTER(AB8500_VRF1VAUX3SEL, 0x07, 0x07),
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100300 /*
301 * VextSupply12LP = disabled (no LP)
302 */
Lee Jones3c1b8432013-03-21 15:59:01 +0000303 INIT_REGULATOR_REGISTER(AB8500_REGUCTRL2SPARE, 0x01, 0x00),
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100304 /*
305 * Vaux1Disch = short discharge time
306 * Vaux2Disch = short discharge time
307 * Vaux3Disch = short discharge time
308 * Vintcore12Disch = short discharge time
309 * VTVoutDisch = short discharge time
310 * VaudioDisch = short discharge time
311 */
Lee Jones3c1b8432013-03-21 15:59:01 +0000312 INIT_REGULATOR_REGISTER(AB8500_REGUCTRLDISCH, 0xfc, 0x00),
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100313 /*
314 * VanaDisch = short discharge time
315 * VdmicPullDownEna = pulldown disabled when Vdmic is disabled
316 * VdmicDisch = short discharge time
317 */
Lee Jones3c1b8432013-03-21 15:59:01 +0000318 INIT_REGULATOR_REGISTER(AB8500_REGUCTRLDISCH2, 0x16, 0x00),
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100319};
320
Bengt Jonssona1e516e2010-12-10 11:08:48 +0100321/* AB8500 regulators */
Bengt Jonsson732805a2013-03-21 15:59:03 +0000322static struct regulator_init_data ab8500_regulators[AB8500_NUM_REGULATORS] = {
Bengt Jonssona1e516e2010-12-10 11:08:48 +0100323 /* supplies to the display/camera */
324 [AB8500_LDO_AUX1] = {
325 .constraints = {
326 .name = "V-DISPLAY",
327 .min_uV = 2500000,
328 .max_uV = 2900000,
329 .valid_ops_mask = REGULATOR_CHANGE_VOLTAGE |
330 REGULATOR_CHANGE_STATUS,
Linus Walleijdb245202011-04-04 10:44:51 +0200331 .boot_on = 1, /* display is on at boot */
332 /*
333 * This voltage cannot be disabled right now because
334 * it is somehow affecting the external MMC
335 * functionality, though that typically will use
336 * AUX3.
337 */
338 .always_on = 1,
Bengt Jonssona1e516e2010-12-10 11:08:48 +0100339 },
Linus Walleijd1de85a2010-12-02 17:10:14 +0100340 .num_consumer_supplies = ARRAY_SIZE(ab8500_vaux1_consumers),
341 .consumer_supplies = ab8500_vaux1_consumers,
Bengt Jonssona1e516e2010-12-10 11:08:48 +0100342 },
343 /* supplies to the on-board eMMC */
344 [AB8500_LDO_AUX2] = {
345 .constraints = {
346 .name = "V-eMMC1",
347 .min_uV = 1100000,
348 .max_uV = 3300000,
349 .valid_ops_mask = REGULATOR_CHANGE_VOLTAGE |
350 REGULATOR_CHANGE_STATUS,
351 },
Linus Walleijd1de85a2010-12-02 17:10:14 +0100352 .num_consumer_supplies = ARRAY_SIZE(ab8500_vaux2_consumers),
353 .consumer_supplies = ab8500_vaux2_consumers,
Bengt Jonssona1e516e2010-12-10 11:08:48 +0100354 },
355 /* supply for VAUX3, supplies to SDcard slots */
356 [AB8500_LDO_AUX3] = {
357 .constraints = {
358 .name = "V-MMC-SD",
359 .min_uV = 1100000,
360 .max_uV = 3300000,
361 .valid_ops_mask = REGULATOR_CHANGE_VOLTAGE |
362 REGULATOR_CHANGE_STATUS,
363 },
Linus Walleijd1de85a2010-12-02 17:10:14 +0100364 .num_consumer_supplies = ARRAY_SIZE(ab8500_vaux3_consumers),
365 .consumer_supplies = ab8500_vaux3_consumers,
Bengt Jonssona1e516e2010-12-10 11:08:48 +0100366 },
367 /* supply for tvout, gpadc, TVOUT LDO */
368 [AB8500_LDO_TVOUT] = {
369 .constraints = {
370 .name = "V-TVOUT",
371 .valid_ops_mask = REGULATOR_CHANGE_STATUS,
372 },
Linus Walleijd1de85a2010-12-02 17:10:14 +0100373 .num_consumer_supplies = ARRAY_SIZE(ab8500_vtvout_consumers),
374 .consumer_supplies = ab8500_vtvout_consumers,
Bengt Jonssona1e516e2010-12-10 11:08:48 +0100375 },
376 /* supply for ab8500-vaudio, VAUDIO LDO */
377 [AB8500_LDO_AUDIO] = {
378 .constraints = {
379 .name = "V-AUD",
380 .valid_ops_mask = REGULATOR_CHANGE_STATUS,
381 },
Ola Lilja29bd2ab2012-02-01 14:18:10 +0100382 .num_consumer_supplies = ARRAY_SIZE(ab8500_vaud_consumers),
383 .consumer_supplies = ab8500_vaud_consumers,
Bengt Jonssona1e516e2010-12-10 11:08:48 +0100384 },
385 /* supply for v-anamic1 VAMic1-LDO */
386 [AB8500_LDO_ANAMIC1] = {
387 .constraints = {
388 .name = "V-AMIC1",
389 .valid_ops_mask = REGULATOR_CHANGE_STATUS,
390 },
Ola Lilja29bd2ab2012-02-01 14:18:10 +0100391 .num_consumer_supplies = ARRAY_SIZE(ab8500_vamic1_consumers),
392 .consumer_supplies = ab8500_vamic1_consumers,
Bengt Jonssona1e516e2010-12-10 11:08:48 +0100393 },
394 /* supply for v-amic2, VAMIC2 LDO, reuse constants for AMIC1 */
395 [AB8500_LDO_ANAMIC2] = {
396 .constraints = {
397 .name = "V-AMIC2",
398 .valid_ops_mask = REGULATOR_CHANGE_STATUS,
399 },
Ola Lilja29bd2ab2012-02-01 14:18:10 +0100400 .num_consumer_supplies = ARRAY_SIZE(ab8500_vamic2_consumers),
401 .consumer_supplies = ab8500_vamic2_consumers,
Bengt Jonssona1e516e2010-12-10 11:08:48 +0100402 },
403 /* supply for v-dmic, VDMIC LDO */
404 [AB8500_LDO_DMIC] = {
405 .constraints = {
406 .name = "V-DMIC",
407 .valid_ops_mask = REGULATOR_CHANGE_STATUS,
408 },
Ola Lilja29bd2ab2012-02-01 14:18:10 +0100409 .num_consumer_supplies = ARRAY_SIZE(ab8500_vdmic_consumers),
410 .consumer_supplies = ab8500_vdmic_consumers,
Bengt Jonssona1e516e2010-12-10 11:08:48 +0100411 },
412 /* supply for v-intcore12, VINTCORE12 LDO */
413 [AB8500_LDO_INTCORE] = {
414 .constraints = {
415 .name = "V-INTCORE",
416 .valid_ops_mask = REGULATOR_CHANGE_STATUS,
417 },
Linus Walleijd1de85a2010-12-02 17:10:14 +0100418 .num_consumer_supplies = ARRAY_SIZE(ab8500_vintcore_consumers),
419 .consumer_supplies = ab8500_vintcore_consumers,
Bengt Jonssona1e516e2010-12-10 11:08:48 +0100420 },
421 /* supply for U8500 CSI/DSI, VANA LDO */
422 [AB8500_LDO_ANA] = {
423 .constraints = {
424 .name = "V-CSI/DSI",
425 .valid_ops_mask = REGULATOR_CHANGE_STATUS,
426 },
Linus Walleijd1de85a2010-12-02 17:10:14 +0100427 .num_consumer_supplies = ARRAY_SIZE(ab8500_vana_consumers),
428 .consumer_supplies = ab8500_vana_consumers,
Sundar Iyer4f724be2010-09-15 10:50:59 +0100429 },
430};
Bengt Jonsson732805a2013-03-21 15:59:03 +0000431
432struct ab8500_regulator_platform_data ab8500_regulator_plat_data = {
433 .reg_init = ab8500_reg_init,
434 .num_reg_init = ARRAY_SIZE(ab8500_reg_init),
435 .regulator = ab8500_regulators,
436 .num_regulator = ARRAY_SIZE(ab8500_regulators),
437};