/external/u-boot/drivers/power/regulator/ |
D | regulator-uclass.c | 16 struct dm_regulator_uclass_platdata *uc_pdata; in regulator_mode() local 20 uc_pdata = dev_get_uclass_platdata(dev); in regulator_mode() 21 if (!uc_pdata) in regulator_mode() 24 *modep = uc_pdata->mode; in regulator_mode() 25 return uc_pdata->mode_count; in regulator_mode() 41 struct dm_regulator_uclass_platdata *uc_pdata; in regulator_set_value() local 43 uc_pdata = dev_get_uclass_platdata(dev); in regulator_set_value() 44 if (uc_pdata->min_uV != -ENODATA && uV < uc_pdata->min_uV) in regulator_set_value() 46 if (uc_pdata->max_uV != -ENODATA && uV > uc_pdata->max_uV) in regulator_set_value() 82 struct dm_regulator_uclass_platdata *uc_pdata; in regulator_set_current() local [all …]
|
D | palmas_regulator.c | 54 struct dm_regulator_uclass_platdata *uc_pdata; in palmas_smps_enable() local 56 uc_pdata = dev_get_uclass_platdata(dev); in palmas_smps_enable() 57 adr = uc_pdata->ctrl_reg; in palmas_smps_enable() 123 struct dm_regulator_uclass_platdata *uc_pdata; in palmas_smps_val() local 125 uc_pdata = dev_get_uclass_platdata(dev); in palmas_smps_val() 130 adr = uc_pdata->volt_reg; in palmas_smps_val() 199 struct dm_regulator_uclass_platdata *uc_pdata; in palmas_ldo_enable() local 201 uc_pdata = dev_get_uclass_platdata(dev); in palmas_ldo_enable() 202 adr = uc_pdata->ctrl_reg; in palmas_ldo_enable() 259 struct dm_regulator_uclass_platdata *uc_pdata; in palmas_ldo_val() local [all …]
|
D | fixed.c | 23 struct dm_regulator_uclass_platdata *uc_pdata; in fixed_regulator_ofdata_to_platdata() local 30 uc_pdata = dev_get_uclass_platdata(dev); in fixed_regulator_ofdata_to_platdata() 31 if (!uc_pdata) in fixed_regulator_ofdata_to_platdata() 35 uc_pdata->type = REGULATOR_TYPE_FIXED; in fixed_regulator_ofdata_to_platdata() 59 struct dm_regulator_uclass_platdata *uc_pdata; in fixed_regulator_get_value() local 61 uc_pdata = dev_get_uclass_platdata(dev); in fixed_regulator_get_value() 62 if (!uc_pdata) in fixed_regulator_get_value() 65 if (uc_pdata->min_uV != uc_pdata->max_uV) { in fixed_regulator_get_value() 66 debug("Invalid constraints for: %s\n", uc_pdata->name); in fixed_regulator_get_value() 70 return uc_pdata->min_uV; in fixed_regulator_get_value() [all …]
|
D | lp873x_regulator.c | 27 struct dm_regulator_uclass_platdata *uc_pdata; in lp873x_buck_enable() local 29 uc_pdata = dev_get_uclass_platdata(dev); in lp873x_buck_enable() 30 adr = uc_pdata->ctrl_reg; in lp873x_buck_enable() 90 struct dm_regulator_uclass_platdata *uc_pdata; in lp873x_buck_val() local 92 uc_pdata = dev_get_uclass_platdata(dev); in lp873x_buck_val() 97 adr = uc_pdata->volt_reg; in lp873x_buck_val() 129 struct dm_regulator_uclass_platdata *uc_pdata; in lp873x_ldo_enable() local 131 uc_pdata = dev_get_uclass_platdata(dev); in lp873x_ldo_enable() 132 adr = uc_pdata->ctrl_reg; in lp873x_ldo_enable() 185 struct dm_regulator_uclass_platdata *uc_pdata; in lp873x_ldo_val() local [all …]
|
D | stpmu1.c | 185 struct dm_regulator_uclass_platdata *uc_pdata; in stpmu1_buck_set_enable() local 193 uc_pdata = dev_get_uclass_platdata(dev); in stpmu1_buck_set_enable() 195 if ((uv < uc_pdata->min_uV) || (uv > uc_pdata->max_uV)) in stpmu1_buck_set_enable() 196 stpmu1_buck_set_value(dev, uc_pdata->min_uV); in stpmu1_buck_set_enable() 231 struct dm_regulator_uclass_platdata *uc_pdata; in stpmu1_buck_probe() local 236 uc_pdata = dev_get_uclass_platdata(dev); in stpmu1_buck_probe() 238 uc_pdata->type = REGULATOR_TYPE_BUCK; in stpmu1_buck_probe() 239 uc_pdata->mode = (struct dm_regulator_mode *)buck_modes; in stpmu1_buck_probe() 240 uc_pdata->mode_count = ARRAY_SIZE(buck_modes); in stpmu1_buck_probe() 363 struct dm_regulator_uclass_platdata *uc_pdata; in stpmu1_ldo_set_enable() local [all …]
|
D | sandbox.c | 143 struct dm_regulator_uclass_platdata *uc_pdata; in out_get_mode() local 149 uc_pdata = dev_get_uclass_platdata(dev); in out_get_mode() 158 for (i = 0; i < uc_pdata->mode_count; i++) { in out_get_mode() 159 if (reg_val == uc_pdata->mode[i].register_value) in out_get_mode() 160 return uc_pdata->mode[i].id; in out_get_mode() 169 struct dm_regulator_uclass_platdata *uc_pdata; in out_set_mode() local 175 uc_pdata = dev_get_uclass_platdata(dev); in out_set_mode() 177 if (mode >= uc_pdata->mode_count) in out_set_mode() 180 for (i = 0; i < uc_pdata->mode_count; i++) { in out_set_mode() 181 if (mode == uc_pdata->mode[i].id) { in out_set_mode() [all …]
|
D | lp87565_regulator.c | 25 struct dm_regulator_uclass_platdata *uc_pdata; in lp87565_buck_enable() local 27 uc_pdata = dev_get_uclass_platdata(dev); in lp87565_buck_enable() 28 adr = uc_pdata->ctrl_reg; in lp87565_buck_enable() 88 struct dm_regulator_uclass_platdata *uc_pdata; in lp87565_buck_val() local 90 uc_pdata = dev_get_uclass_platdata(dev); in lp87565_buck_val() 95 adr = uc_pdata->volt_reg; in lp87565_buck_val() 125 struct dm_regulator_uclass_platdata *uc_pdata; in lp87565_buck_probe() local 128 uc_pdata = dev_get_uclass_platdata(dev); in lp87565_buck_probe() 129 uc_pdata->type = REGULATOR_TYPE_BUCK; in lp87565_buck_probe() 143 uc_pdata->ctrl_reg = lp87565_buck_ctrl1[idx]; in lp87565_buck_probe() [all …]
|
D | pfuze100.c | 262 struct dm_regulator_uclass_platdata *uc_pdata; in pfuze100_regulator_probe() local 292 uc_pdata = dev_get_uclass_platdata(dev); in pfuze100_regulator_probe() 294 uc_pdata->type = desc->type; in pfuze100_regulator_probe() 295 if (uc_pdata->type == REGULATOR_TYPE_BUCK) { in pfuze100_regulator_probe() 297 uc_pdata->mode = pfuze_swbst_modes; in pfuze100_regulator_probe() 298 uc_pdata->mode_count = ARRAY_SIZE(pfuze_swbst_modes); in pfuze100_regulator_probe() 300 uc_pdata->mode = pfuze_sw_modes; in pfuze100_regulator_probe() 301 uc_pdata->mode_count = ARRAY_SIZE(pfuze_sw_modes); in pfuze100_regulator_probe() 303 } else if (uc_pdata->type == REGULATOR_TYPE_LDO) { in pfuze100_regulator_probe() 304 uc_pdata->mode = pfuze_ldo_modes; in pfuze100_regulator_probe() [all …]
|
D | gpio-regulator.c | 28 struct dm_regulator_uclass_platdata *uc_pdata; in gpio_regulator_ofdata_to_platdata() local 37 uc_pdata = dev_get_uclass_platdata(dev); in gpio_regulator_ofdata_to_platdata() 38 if (!uc_pdata) in gpio_regulator_ofdata_to_platdata() 42 uc_pdata->type = REGULATOR_TYPE_GPIO; in gpio_regulator_ofdata_to_platdata() 73 struct dm_regulator_uclass_platdata *uc_pdata; in gpio_regulator_get_value() local 80 uc_pdata = dev_get_uclass_platdata(dev); in gpio_regulator_get_value() 81 if (uc_pdata->min_uV > uc_pdata->max_uV) { in gpio_regulator_get_value() 82 debug("Invalid constraints for: %s\n", uc_pdata->name); in gpio_regulator_get_value()
|
D | rk8xx.c | 281 struct dm_regulator_uclass_platdata *uc_pdata; in rk8xx_buck_probe() local 283 uc_pdata = dev_get_uclass_platdata(dev); in rk8xx_buck_probe() 285 uc_pdata->type = REGULATOR_TYPE_BUCK; in rk8xx_buck_probe() 286 uc_pdata->mode_count = 0; in rk8xx_buck_probe() 293 struct dm_regulator_uclass_platdata *uc_pdata; in rk8xx_ldo_probe() local 295 uc_pdata = dev_get_uclass_platdata(dev); in rk8xx_ldo_probe() 297 uc_pdata->type = REGULATOR_TYPE_LDO; in rk8xx_ldo_probe() 298 uc_pdata->mode_count = 0; in rk8xx_ldo_probe() 305 struct dm_regulator_uclass_platdata *uc_pdata; in rk8xx_switch_probe() local 307 uc_pdata = dev_get_uclass_platdata(dev); in rk8xx_switch_probe() [all …]
|
D | as3722_regulator.c | 116 struct dm_regulator_uclass_platdata *uc_pdata; in as3722_stepdown_probe() local 118 uc_pdata = dev_get_uclass_platdata(dev); in as3722_stepdown_probe() 120 uc_pdata->type = REGULATOR_TYPE_BUCK; in as3722_stepdown_probe() 127 struct dm_regulator_uclass_platdata *uc_pdata; in as3722_ldo_probe() local 129 uc_pdata = dev_get_uclass_platdata(dev); in as3722_ldo_probe() 131 uc_pdata->type = REGULATOR_TYPE_LDO; in as3722_ldo_probe()
|
D | pwm_regulator.c | 123 struct dm_regulator_uclass_platdata *uc_pdata; in pwm_regulator_probe() local 125 uc_pdata = dev_get_uclass_platdata(dev); in pwm_regulator_probe() 127 uc_pdata->type = REGULATOR_TYPE_BUCK; in pwm_regulator_probe() 128 uc_pdata->mode_count = 0; in pwm_regulator_probe() 129 priv->max_voltage = uc_pdata->max_uV; in pwm_regulator_probe() 130 priv->min_voltage = uc_pdata->min_uV; in pwm_regulator_probe()
|
D | s5m8767.c | 133 struct dm_regulator_uclass_platdata *uc_pdata; in s5m8767_ldo_probe() local 135 uc_pdata = dev_get_uclass_platdata(dev); in s5m8767_ldo_probe() 137 uc_pdata->type = REGULATOR_TYPE_LDO; in s5m8767_ldo_probe() 138 uc_pdata->mode_count = 0; in s5m8767_ldo_probe() 202 struct dm_regulator_uclass_platdata *uc_pdata; in s5m8767_buck_probe() local 204 uc_pdata = dev_get_uclass_platdata(dev); in s5m8767_buck_probe() 206 uc_pdata->type = REGULATOR_TYPE_BUCK; in s5m8767_buck_probe() 207 uc_pdata->mode_count = 0; in s5m8767_buck_probe()
|
D | s2mps11_regulator.c | 307 struct dm_regulator_uclass_platdata *uc_pdata; in s2mps11_buck_probe() local 309 uc_pdata = dev_get_uclass_platdata(dev); in s2mps11_buck_probe() 311 uc_pdata->type = REGULATOR_TYPE_BUCK; in s2mps11_buck_probe() 312 uc_pdata->mode = s2mps11_buck_modes; in s2mps11_buck_probe() 313 uc_pdata->mode_count = ARRAY_SIZE(s2mps11_buck_modes); in s2mps11_buck_probe() 570 struct dm_regulator_uclass_platdata *uc_pdata; in s2mps11_ldo_probe() local 572 uc_pdata = dev_get_uclass_platdata(dev); in s2mps11_ldo_probe() 573 uc_pdata->type = REGULATOR_TYPE_LDO; in s2mps11_ldo_probe() 574 uc_pdata->mode = s2mps11_ldo_modes; in s2mps11_ldo_probe() 575 uc_pdata->mode_count = ARRAY_SIZE(s2mps11_ldo_modes); in s2mps11_ldo_probe()
|
/external/u-boot/cmd/ |
D | regulator.c | 27 struct dm_regulator_uclass_platdata *uc_pdata; in do_dev() local 45 uc_pdata = dev_get_uclass_platdata(currdev); in do_dev() 46 if (!uc_pdata) { in do_dev() 51 printf("dev: %s @ %s\n", uc_pdata->name, currdev->name); in do_dev() 58 struct dm_regulator_uclass_platdata **uc_pdata, in curr_dev_and_platdata() argument 62 *uc_pdata = NULL; in curr_dev_and_platdata() 71 *uc_pdata = dev_get_uclass_platdata(*devp); in curr_dev_and_platdata() 72 if (!*uc_pdata) { in curr_dev_and_platdata() 77 if (!allow_type_fixed && (*uc_pdata)->type == REGULATOR_TYPE_FIXED) { in curr_dev_and_platdata() 87 struct dm_regulator_uclass_platdata *uc_pdata; in do_list() local [all …]
|
/external/u-boot/drivers/remoteproc/ |
D | sandbox_testproc.c | 125 struct dm_rproc_uclass_pdata *uc_pdata; in sandbox_testproc_probe() local 129 uc_pdata = dev_get_uclass_platdata(dev); in sandbox_testproc_probe() 132 debug("%s: platform private data missing\n", uc_pdata->name); in sandbox_testproc_probe() 136 debug("%s: called(%d)\n", uc_pdata->name, ret); in sandbox_testproc_probe() 149 struct dm_rproc_uclass_pdata *uc_pdata; in sandbox_testproc_init() local 152 uc_pdata = dev_get_uclass_platdata(dev); in sandbox_testproc_init() 156 debug("%s: called(%d)\n", uc_pdata->name, ret); in sandbox_testproc_init() 158 debug("%s init failed\n", uc_pdata->name); in sandbox_testproc_init() 171 struct dm_rproc_uclass_pdata *uc_pdata; in sandbox_testproc_reset() local 174 uc_pdata = dev_get_uclass_platdata(dev); in sandbox_testproc_reset() [all …]
|
D | rproc-uclass.c | 31 struct dm_rproc_uclass_pdata *uc_pdata, in for_each_remoteproc_device() argument 37 struct dm_rproc_uclass_pdata *uc_pdata; in for_each_remoteproc_device() local 44 uc_pdata = dev_get_uclass_platdata(dev); in for_each_remoteproc_device() 45 ret = fn(dev, uc_pdata, data); in for_each_remoteproc_device() 63 struct dm_rproc_uclass_pdata *uc_pdata, in _rproc_name_is_unique() argument 69 if (!uc_pdata->name || !check_name) in _rproc_name_is_unique() 73 if (strlen(uc_pdata->name) != strlen(check_name)) in _rproc_name_is_unique() 76 if (!strcmp(uc_pdata->name, check_name)) in _rproc_name_is_unique() 110 struct dm_rproc_uclass_pdata *uc_pdata; in rproc_pre_probe() local 113 uc_pdata = dev_get_uclass_platdata(dev); in rproc_pre_probe() [all …]
|
D | ti_power_proc.c | 69 struct dm_rproc_uclass_pdata *uc_pdata; in ti_powerproc_probe() local 73 uc_pdata = dev_get_uclass_platdata(dev); in ti_powerproc_probe() 79 uc_pdata->name, priv->loadaddr, priv->psc_module, ret); in ti_powerproc_probe() 94 struct dm_rproc_uclass_pdata *uc_pdata; in ti_powerproc_load() local 98 uc_pdata = dev_get_uclass_platdata(dev); in ti_powerproc_load() 99 if (!uc_pdata) { in ti_powerproc_load() 108 uc_pdata->name, priv->psc_module, ret); in ti_powerproc_load() 113 uc_pdata->name, addr, size, priv->loadaddr); in ti_powerproc_load() 117 debug("%s: Complete!\n", uc_pdata->name); in ti_powerproc_load() 129 struct dm_rproc_uclass_pdata *uc_pdata; in ti_powerproc_start() local [all …]
|
/external/u-boot/drivers/adc/ |
D | adc-uclass.c | 30 struct adc_uclass_platdata *uc_pdata = dev_get_uclass_platdata(dev); in check_channel() local 38 if ((uc_pdata->channel_mask >= mask) && (uc_pdata->channel_mask & mask)) in check_channel() 49 struct adc_uclass_platdata *uc_pdata = dev_get_uclass_platdata(dev); in adc_supply_enable() local 53 if (uc_pdata->vdd_supply) { in adc_supply_enable() 55 ret = regulator_set_enable(uc_pdata->vdd_supply, true); in adc_supply_enable() 58 if (!ret && uc_pdata->vss_supply) { in adc_supply_enable() 60 ret = regulator_set_enable(uc_pdata->vss_supply, true); in adc_supply_enable() 71 struct adc_uclass_platdata *uc_pdata = dev_get_uclass_platdata(dev); in adc_data_mask() local 73 if (!uc_pdata) in adc_data_mask() 76 *data_mask = uc_pdata->data_mask; in adc_data_mask() [all …]
|
D | rockchip-saradc.c | 45 struct adc_uclass_platdata *uc_pdata = dev_get_uclass_platdata(dev); in rockchip_saradc_channel_data() local 58 *data &= uc_pdata->data_mask; in rockchip_saradc_channel_data() 120 struct adc_uclass_platdata *uc_pdata = dev_get_uclass_platdata(dev); in rockchip_saradc_ofdata_to_platdata() local 132 uc_pdata->data_mask = (1 << priv->data->num_bits) - 1;; in rockchip_saradc_ofdata_to_platdata() 133 uc_pdata->data_format = ADC_DATA_FORMAT_BIN; in rockchip_saradc_ofdata_to_platdata() 134 uc_pdata->data_timeout_us = SARADC_TIMEOUT / 5; in rockchip_saradc_ofdata_to_platdata() 135 uc_pdata->channel_mask = (1 << priv->data->num_channels) - 1; in rockchip_saradc_ofdata_to_platdata()
|
D | sandbox.c | 140 struct adc_uclass_platdata *uc_pdata = dev_get_uclass_platdata(dev); in sandbox_adc_ofdata_to_platdata() local 142 uc_pdata->data_mask = SANDBOX_ADC_DATA_MASK; in sandbox_adc_ofdata_to_platdata() 143 uc_pdata->data_format = ADC_DATA_FORMAT_BIN; in sandbox_adc_ofdata_to_platdata() 144 uc_pdata->data_timeout_us = 0; in sandbox_adc_ofdata_to_platdata() 147 uc_pdata->channel_mask = (1 << SANDBOX_ADC_CHANNELS) - 1; in sandbox_adc_ofdata_to_platdata()
|
D | exynos-adc.c | 106 struct adc_uclass_platdata *uc_pdata = dev_get_uclass_platdata(dev); in exynos_adc_ofdata_to_platdata() local 115 uc_pdata->data_mask = ADC_V2_DAT_MASK; in exynos_adc_ofdata_to_platdata() 116 uc_pdata->data_format = ADC_DATA_FORMAT_BIN; in exynos_adc_ofdata_to_platdata() 117 uc_pdata->data_timeout_us = ADC_V2_CONV_TIMEOUT_US; in exynos_adc_ofdata_to_platdata() 120 uc_pdata->channel_mask = (2 << ADC_V2_MAX_CHANNEL) - 1; in exynos_adc_ofdata_to_platdata()
|
/external/u-boot/test/dm/ |
D | regulator.c | 51 struct dm_regulator_uclass_platdata *uc_pdata; in dm_test_power_regulator_get() local 78 uc_pdata = dev_get_uclass_platdata(dev_by_platname); in dm_test_power_regulator_get() 79 ut_assert(uc_pdata); in dm_test_power_regulator_get() 80 ut_asserteq_str(platname, uc_pdata->name); in dm_test_power_regulator_get() 96 struct dm_regulator_uclass_platdata *uc_pdata; in dm_test_power_regulator_set_get_voltage() local 105 uc_pdata = dev_get_uclass_platdata(dev); in dm_test_power_regulator_set_get_voltage() 106 ut_assert(uc_pdata); in dm_test_power_regulator_set_get_voltage() 108 val_set = uc_pdata->min_uV; in dm_test_power_regulator_set_get_voltage() 123 struct dm_regulator_uclass_platdata *uc_pdata; in dm_test_power_regulator_set_get_current() local 132 uc_pdata = dev_get_uclass_platdata(dev); in dm_test_power_regulator_set_get_current() [all …]
|
D | test-uclass.c | 32 struct dm_test_perdev_uc_pdata *uc_pdata; in test_post_bind() local 37 uc_pdata = dev_get_uclass_platdata(dev); in test_post_bind() 38 ut_assert(uc_pdata); in test_post_bind() 40 uc_pdata->intval1 = TEST_UC_PDATA_INTVAL1; in test_post_bind() 41 uc_pdata->intval2 = TEST_UC_PDATA_INTVAL2; in test_post_bind() 42 uc_pdata->intval3 = TEST_UC_PDATA_INTVAL3; in test_post_bind()
|
/external/u-boot/arch/arm/mach-stm32mp/ |
D | pwr_regulator.c | 136 struct dm_regulator_uclass_platdata *uc_pdata; in stm32mp_pwr_regulator_probe() local 138 uc_pdata = dev_get_uclass_platdata(dev); in stm32mp_pwr_regulator_probe() 165 uc_pdata->type = REGULATOR_TYPE_FIXED; in stm32mp_pwr_regulator_probe() 173 struct dm_regulator_uclass_platdata *uc_pdata; in stm32mp_pwr_regulator_set_value() local 175 uc_pdata = dev_get_uclass_platdata(dev); in stm32mp_pwr_regulator_set_value() 176 if (!uc_pdata) in stm32mp_pwr_regulator_set_value() 179 if (uc_pdata->min_uV != uV) { in stm32mp_pwr_regulator_set_value() 180 dev_dbg(dev, "Invalid uV=%d for: %s\n", uV, uc_pdata->name); in stm32mp_pwr_regulator_set_value() 189 struct dm_regulator_uclass_platdata *uc_pdata; in stm32mp_pwr_regulator_get_value() local 191 uc_pdata = dev_get_uclass_platdata(dev); in stm32mp_pwr_regulator_get_value() [all …]
|