wm8350-regulator.c (01b944fe1cd4e21a2a9ed51adbdbafe2d5e905ba) | wm8350-regulator.c (b0d6dd3ba3c3f41bface6623a18d08439cb195bb) |
---|---|
1/* 2 * wm8350.c -- Voltage and current regulation for the Wolfson WM8350 PMIC 3 * 4 * Copyright 2007, 2008 Wolfson Microelectronics PLC. 5 * 6 * Author: Liam Girdwood 7 * linux@wolfsonmicro.com 8 * --- 927 unchanged lines hidden (view full) --- 936 break; 937 default: 938 mode = REGULATOR_MODE_NORMAL; 939 break; 940 } 941 return mode; 942} 943 | 1/* 2 * wm8350.c -- Voltage and current regulation for the Wolfson WM8350 PMIC 3 * 4 * Copyright 2007, 2008 Wolfson Microelectronics PLC. 5 * 6 * Author: Liam Girdwood 7 * linux@wolfsonmicro.com 8 * --- 927 unchanged lines hidden (view full) --- 936 break; 937 default: 938 mode = REGULATOR_MODE_NORMAL; 939 break; 940 } 941 return mode; 942} 943 |
944static struct regulator_ops wm8350_dcdc_ops = { | 944static const struct regulator_ops wm8350_dcdc_ops = { |
945 .set_voltage_sel = regulator_set_voltage_sel_regmap, 946 .get_voltage_sel = regulator_get_voltage_sel_regmap, 947 .list_voltage = regulator_list_voltage_linear, 948 .map_voltage = regulator_map_voltage_linear, 949 .enable = regulator_enable_regmap, 950 .disable = regulator_disable_regmap, 951 .is_enabled = regulator_is_enabled_regmap, 952 .get_mode = wm8350_dcdc_get_mode, 953 .set_mode = wm8350_dcdc_set_mode, 954 .get_optimum_mode = wm8350_dcdc_get_optimum_mode, 955 .set_suspend_voltage = wm8350_dcdc_set_suspend_voltage, 956 .set_suspend_enable = wm8350_dcdc_set_suspend_enable, 957 .set_suspend_disable = wm8350_dcdc_set_suspend_disable, 958 .set_suspend_mode = wm8350_dcdc_set_suspend_mode, 959}; 960 | 945 .set_voltage_sel = regulator_set_voltage_sel_regmap, 946 .get_voltage_sel = regulator_get_voltage_sel_regmap, 947 .list_voltage = regulator_list_voltage_linear, 948 .map_voltage = regulator_map_voltage_linear, 949 .enable = regulator_enable_regmap, 950 .disable = regulator_disable_regmap, 951 .is_enabled = regulator_is_enabled_regmap, 952 .get_mode = wm8350_dcdc_get_mode, 953 .set_mode = wm8350_dcdc_set_mode, 954 .get_optimum_mode = wm8350_dcdc_get_optimum_mode, 955 .set_suspend_voltage = wm8350_dcdc_set_suspend_voltage, 956 .set_suspend_enable = wm8350_dcdc_set_suspend_enable, 957 .set_suspend_disable = wm8350_dcdc_set_suspend_disable, 958 .set_suspend_mode = wm8350_dcdc_set_suspend_mode, 959}; 960 |
961static struct regulator_ops wm8350_dcdc2_5_ops = { | 961static const struct regulator_ops wm8350_dcdc2_5_ops = { |
962 .enable = regulator_enable_regmap, 963 .disable = regulator_disable_regmap, 964 .is_enabled = regulator_is_enabled_regmap, 965 .set_suspend_enable = wm8350_dcdc25_set_suspend_enable, 966 .set_suspend_disable = wm8350_dcdc25_set_suspend_disable, 967}; 968 | 962 .enable = regulator_enable_regmap, 963 .disable = regulator_disable_regmap, 964 .is_enabled = regulator_is_enabled_regmap, 965 .set_suspend_enable = wm8350_dcdc25_set_suspend_enable, 966 .set_suspend_disable = wm8350_dcdc25_set_suspend_disable, 967}; 968 |
969static struct regulator_ops wm8350_ldo_ops = { | 969static const struct regulator_ops wm8350_ldo_ops = { |
970 .map_voltage = regulator_map_voltage_linear_range, 971 .set_voltage_sel = regulator_set_voltage_sel_regmap, 972 .get_voltage_sel = regulator_get_voltage_sel_regmap, 973 .list_voltage = regulator_list_voltage_linear_range, 974 .enable = regulator_enable_regmap, 975 .disable = regulator_disable_regmap, 976 .is_enabled = regulator_is_enabled_regmap, 977 .get_mode = wm8350_ldo_get_mode, 978 .set_suspend_voltage = wm8350_ldo_set_suspend_voltage, 979 .set_suspend_enable = wm8350_ldo_set_suspend_enable, 980 .set_suspend_disable = wm8350_ldo_set_suspend_disable, 981}; 982 | 970 .map_voltage = regulator_map_voltage_linear_range, 971 .set_voltage_sel = regulator_set_voltage_sel_regmap, 972 .get_voltage_sel = regulator_get_voltage_sel_regmap, 973 .list_voltage = regulator_list_voltage_linear_range, 974 .enable = regulator_enable_regmap, 975 .disable = regulator_disable_regmap, 976 .is_enabled = regulator_is_enabled_regmap, 977 .get_mode = wm8350_ldo_get_mode, 978 .set_suspend_voltage = wm8350_ldo_set_suspend_voltage, 979 .set_suspend_enable = wm8350_ldo_set_suspend_enable, 980 .set_suspend_disable = wm8350_ldo_set_suspend_disable, 981}; 982 |
983static struct regulator_ops wm8350_isink_ops = { | 983static const struct regulator_ops wm8350_isink_ops = { |
984 .set_current_limit = wm8350_isink_set_current, 985 .get_current_limit = wm8350_isink_get_current, 986 .enable = wm8350_isink_enable, 987 .disable = wm8350_isink_disable, 988 .is_enabled = wm8350_isink_is_enabled, 989 .enable_time = wm8350_isink_enable_time, 990}; 991 --- 405 unchanged lines hidden --- | 984 .set_current_limit = wm8350_isink_set_current, 985 .get_current_limit = wm8350_isink_get_current, 986 .enable = wm8350_isink_enable, 987 .disable = wm8350_isink_disable, 988 .is_enabled = wm8350_isink_is_enabled, 989 .enable_time = wm8350_isink_enable_time, 990}; 991 --- 405 unchanged lines hidden --- |