.. | .. |
---|
1 | | -/* |
---|
2 | | - * sky81452-regulator.c SKY81452 regulator driver |
---|
3 | | - * |
---|
4 | | - * Copyright 2014 Skyworks Solutions Inc. |
---|
5 | | - * Author : Gyungoh Yoo <jack.yoo@skyworksinc.com> |
---|
6 | | - * |
---|
7 | | - * This program is free software; you can redistribute it and/or modify it |
---|
8 | | - * under the terms of the GNU General Public License version 2 |
---|
9 | | - * as published by the Free Software Foundation. |
---|
10 | | - * |
---|
11 | | - * This program is distributed in the hope that it will be useful, but |
---|
12 | | - * WITHOUT ANY WARRANTY; without even the implied warranty of |
---|
13 | | - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
---|
14 | | - * General Public License for more details. |
---|
15 | | - * |
---|
16 | | - * You should have received a copy of the GNU General Public License along |
---|
17 | | - * with this program; if not, see <http://www.gnu.org/licenses/>. |
---|
18 | | - */ |
---|
| 1 | +// SPDX-License-Identifier: GPL-2.0 |
---|
| 2 | +// |
---|
| 3 | +// sky81452-regulator.c SKY81452 regulator driver |
---|
| 4 | +// |
---|
| 5 | +// Copyright 2014 Skyworks Solutions Inc. |
---|
| 6 | +// Author : Gyungoh Yoo <jack.yoo@skyworksinc.com> |
---|
19 | 7 | |
---|
20 | 8 | #include <linux/module.h> |
---|
21 | 9 | #include <linux/kernel.h> |
---|
.. | .. |
---|
34 | 22 | #define SKY81452_LEN 0x40 |
---|
35 | 23 | #define SKY81452_LOUT 0x1F |
---|
36 | 24 | |
---|
37 | | -static struct regulator_ops sky81452_reg_ops = { |
---|
| 25 | +static const struct regulator_ops sky81452_reg_ops = { |
---|
38 | 26 | .list_voltage = regulator_list_voltage_linear_range, |
---|
39 | 27 | .map_voltage = regulator_map_voltage_linear_range, |
---|
40 | 28 | .get_voltage_sel = regulator_get_voltage_sel_regmap, |
---|
.. | .. |
---|
44 | 32 | .is_enabled = regulator_is_enabled_regmap, |
---|
45 | 33 | }; |
---|
46 | 34 | |
---|
47 | | -static const struct regulator_linear_range sky81452_reg_ranges[] = { |
---|
| 35 | +static const struct linear_range sky81452_reg_ranges[] = { |
---|
48 | 36 | REGULATOR_LINEAR_RANGE(4500000, 0, 14, 250000), |
---|
49 | 37 | REGULATOR_LINEAR_RANGE(9000000, 15, 31, 1000000), |
---|
50 | 38 | }; |
---|