tangled
alpha
login
or
join now
tjh.dev
/
kernel
1
fork
atom
Linux kernel mirror (for testing)
git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel
os
linux
1
fork
atom
overview
issues
pulls
pipelines
Merge branch 'regulator-register' into regulator-drivers
Mark Brown
14 years ago
1474e4db
f604c10c
+19
-17
16 changed files
expand all
collapse all
unified
split
drivers
regulator
ad5398.c
core.c
isl6271a-regulator.c
lp3971.c
lp3972.c
max1586.c
max8649.c
max8660.c
max8952.c
pcap-regulator.c
pcf50633-regulator.c
tps6105x-regulator.c
tps65217-regulator.c
wm8350-regulator.c
wm8994-regulator.c
include
linux
regulator
driver.h
+1
-1
drivers/regulator/ad5398.c
reviewed
···
184
184
.is_enabled = ad5398_is_enabled,
185
185
};
186
186
187
187
-
static struct regulator_desc ad5398_reg = {
187
187
+
static const struct regulator_desc ad5398_reg = {
188
188
.name = "isink",
189
189
.id = 0,
190
190
.ops = &ad5398_ops,
+2
-1
drivers/regulator/core.c
reviewed
···
2829
2829
* Called by regulator drivers to register a regulator.
2830
2830
* Returns 0 on success.
2831
2831
*/
2832
2832
-
struct regulator_dev *regulator_register(struct regulator_desc *regulator_desc,
2832
2832
+
struct regulator_dev *
2833
2833
+
regulator_register(const struct regulator_desc *regulator_desc,
2833
2834
struct device *dev, const struct regulator_init_data *init_data,
2834
2835
void *driver_data, struct device_node *of_node)
2835
2836
{
+1
-1
drivers/regulator/isl6271a-regulator.c
reviewed
···
112
112
.list_voltage = isl6271a_list_fixed_voltage,
113
113
};
114
114
115
115
-
static struct regulator_desc isl_rd[] = {
115
115
+
static const struct regulator_desc isl_rd[] = {
116
116
{
117
117
.name = "Core Buck",
118
118
.id = 0,
+1
-1
drivers/regulator/lp3971.c
reviewed
···
281
281
.set_voltage_sel = lp3971_dcdc_set_voltage_sel,
282
282
};
283
283
284
284
-
static struct regulator_desc regulators[] = {
284
284
+
static const struct regulator_desc regulators[] = {
285
285
{
286
286
.name = "LDO1",
287
287
.id = LP3971_LDO1,
+1
-1
drivers/regulator/lp3972.c
reviewed
···
444
444
.set_voltage_sel = lp3972_dcdc_set_voltage_sel,
445
445
};
446
446
447
447
-
static struct regulator_desc regulators[] = {
447
447
+
static const struct regulator_desc regulators[] = {
448
448
{
449
449
.name = "LDO1",
450
450
.id = LP3972_LDO1,
+1
-1
drivers/regulator/max1586.c
reviewed
···
161
161
.list_voltage = max1586_v6_list,
162
162
};
163
163
164
164
-
static struct regulator_desc max1586_reg[] = {
164
164
+
static const struct regulator_desc max1586_reg[] = {
165
165
{
166
166
.name = "Output_V3",
167
167
.id = MAX1586_V3,
+1
-1
drivers/regulator/max8649.c
reviewed
···
207
207
208
208
};
209
209
210
210
-
static struct regulator_desc dcdc_desc = {
210
210
+
static const struct regulator_desc dcdc_desc = {
211
211
.name = "max8649",
212
212
.ops = &max8649_dcdc_ops,
213
213
.type = REGULATOR_VOLTAGE,
+1
-1
drivers/regulator/max8660.c
reviewed
···
313
313
.set_voltage = max8660_ldo67_set,
314
314
};
315
315
316
316
-
static struct regulator_desc max8660_reg[] = {
316
316
+
static const struct regulator_desc max8660_reg[] = {
317
317
{
318
318
.name = "V3(DCDC)",
319
319
.id = MAX8660_V3,
+1
-1
drivers/regulator/max8952.c
reviewed
···
159
159
.set_suspend_disable = max8952_disable,
160
160
};
161
161
162
162
-
static struct regulator_desc regulator = {
162
162
+
static const struct regulator_desc regulator = {
163
163
.name = "MAX8952_VOUT",
164
164
.id = 0,
165
165
.n_voltages = MAX8952_NUM_DVS_MODE,
+1
-1
drivers/regulator/pcap-regulator.c
reviewed
···
241
241
.owner = THIS_MODULE, \
242
242
}
243
243
244
244
-
static struct regulator_desc pcap_regulators[] = {
244
244
+
static const struct regulator_desc pcap_regulators[] = {
245
245
VREG(V1), VREG(V2), VREG(V3), VREG(V4), VREG(V5), VREG(V6), VREG(V7),
246
246
VREG(V8), VREG(V9), VREG(V10), VREG(VAUX1), VREG(VAUX2), VREG(VAUX3),
247
247
VREG(VAUX4), VREG(VSIM), VREG(VSIM2), VREG(VVIB), VREG(SW1), VREG(SW2),
+1
-1
drivers/regulator/pcf50633-regulator.c
reviewed
···
267
267
.is_enabled = pcf50633_regulator_is_enabled,
268
268
};
269
269
270
270
-
static struct regulator_desc regulators[] = {
270
270
+
static const struct regulator_desc regulators[] = {
271
271
[PCF50633_REGULATOR_AUTO] =
272
272
PCF50633_REGULATOR("auto", PCF50633_REGULATOR_AUTO, 128),
273
273
[PCF50633_REGULATOR_DOWN1] =
+1
-1
drivers/regulator/tps6105x-regulator.c
reviewed
···
123
123
.list_voltage = tps6105x_regulator_list_voltage,
124
124
};
125
125
126
126
-
static struct regulator_desc tps6105x_regulator_desc = {
126
126
+
static const struct regulator_desc tps6105x_regulator_desc = {
127
127
.name = "tps6105x-boost",
128
128
.ops = &tps6105x_regulator_ops,
129
129
.type = REGULATOR_VOLTAGE,
+1
-1
drivers/regulator/tps65217-regulator.c
reviewed
···
312
312
.list_voltage = tps65217_pmic_list_voltage,
313
313
};
314
314
315
315
-
static struct regulator_desc regulators[] = {
315
315
+
static const struct regulator_desc regulators[] = {
316
316
TPS65217_REGULATOR("DCDC1", TPS65217_DCDC_1, tps65217_pmic_ops, 64),
317
317
TPS65217_REGULATOR("DCDC2", TPS65217_DCDC_2, tps65217_pmic_ops, 64),
318
318
TPS65217_REGULATOR("DCDC3", TPS65217_DCDC_3, tps65217_pmic_ops, 64),
+1
-1
drivers/regulator/wm8350-regulator.c
reviewed
···
1269
1269
.enable_time = wm8350_isink_enable_time,
1270
1270
};
1271
1271
1272
1272
-
static struct regulator_desc wm8350_reg[NUM_WM8350_REGULATORS] = {
1272
1272
+
static const struct regulator_desc wm8350_reg[NUM_WM8350_REGULATORS] = {
1273
1273
{
1274
1274
.name = "DCDC1",
1275
1275
.id = WM8350_DCDC_1,
+1
-1
drivers/regulator/wm8994-regulator.c
reviewed
···
209
209
.set_voltage = wm8994_ldo2_set_voltage,
210
210
};
211
211
212
212
-
static struct regulator_desc wm8994_ldo_desc[] = {
212
212
+
static const struct regulator_desc wm8994_ldo_desc[] = {
213
213
{
214
214
.name = "LDO1",
215
215
.id = 1,
+3
-2
include/linux/regulator/driver.h
reviewed
···
184
184
* no other direct access).
185
185
*/
186
186
struct regulator_dev {
187
187
-
struct regulator_desc *desc;
187
187
+
const struct regulator_desc *desc;
188
188
int exclusive;
189
189
u32 use_count;
190
190
u32 open_count;
···
210
210
struct dentry *debugfs;
211
211
};
212
212
213
213
-
struct regulator_dev *regulator_register(struct regulator_desc *regulator_desc,
213
213
+
struct regulator_dev *
214
214
+
regulator_register(const struct regulator_desc *regulator_desc,
214
215
struct device *dev, const struct regulator_init_data *init_data,
215
216
void *driver_data, struct device_node *of_node);
216
217
void regulator_unregister(struct regulator_dev *rdev);