hc
2023-12-06 08f87f769b595151be1afeff53e144f543faa614
kernel/drivers/regulator/lp3971.c
....@@ -1,3 +1,4 @@
1
+// SPDX-License-Identifier: GPL-2.0-only
12 /*
23 * Regulator driver for National Semiconductors LP3971 PMIC chip
34 *
....@@ -5,11 +6,6 @@
56 * Author: Marek Szyprowski <m.szyprowski@samsung.com>
67 *
78 * Based on wm8350.c
8
- *
9
- * This program is free software; you can redistribute it and/or modify
10
- * it under the terms of the GNU General Public License version 2 as
11
- * published by the Free Software Foundation.
12
- *
139 */
1410
1511 #include <linux/bug.h>
....@@ -159,7 +155,7 @@
159155 selector << LDO_VOL_CONTR_SHIFT(ldo));
160156 }
161157
162
-static struct regulator_ops lp3971_ldo_ops = {
158
+static const struct regulator_ops lp3971_ldo_ops = {
163159 .list_voltage = regulator_list_voltage_table,
164160 .map_voltage = regulator_map_voltage_ascend,
165161 .is_enabled = lp3971_ldo_is_enabled,
....@@ -233,7 +229,7 @@
233229 0 << BUCK_VOL_CHANGE_SHIFT(buck));
234230 }
235231
236
-static struct regulator_ops lp3971_dcdc_ops = {
232
+static const struct regulator_ops lp3971_dcdc_ops = {
237233 .list_voltage = regulator_list_voltage_table,
238234 .map_voltage = regulator_map_voltage_ascend,
239235 .is_enabled = lp3971_dcdc_is_enabled,
....@@ -404,8 +400,7 @@
404400 return 0;
405401 }
406402
407
-static int lp3971_i2c_probe(struct i2c_client *i2c,
408
- const struct i2c_device_id *id)
403
+static int lp3971_i2c_probe(struct i2c_client *i2c)
409404 {
410405 struct lp3971 *lp3971;
411406 struct lp3971_platform_data *pdata = dev_get_platdata(&i2c->dev);
....@@ -453,7 +448,7 @@
453448 .driver = {
454449 .name = "LP3971",
455450 },
456
- .probe = lp3971_i2c_probe,
451
+ .probe_new = lp3971_i2c_probe,
457452 .id_table = lp3971_i2c_id,
458453 };
459454