Lines Matching full:name
574 static const struct regul_struct *get_regulator_data(const char *name) in get_regulator_data() argument
579 if (strcmp(name, regulators_table[i].dt_node_name) == 0) in get_regulator_data()
582 DMSG("Regulator %s not found", name); in get_regulator_data()
586 bool stpmic1_regulator_is_valid(const char *name) in stpmic1_regulator_is_valid() argument
588 return get_regulator_data(name); in stpmic1_regulator_is_valid()
591 void stpmic1_regulator_levels_mv(const char *name, in stpmic1_regulator_levels_mv() argument
595 const struct regul_struct *regul = get_regulator_data(name); in stpmic1_regulator_levels_mv()
611 static size_t voltage_to_index(const char *name, uint16_t millivolts) in voltage_to_index() argument
613 const struct regul_struct *regul = get_regulator_data(name); in voltage_to_index()
636 int stpmic1_regulator_enable(const char *name) in stpmic1_regulator_enable() argument
638 const struct regul_struct *regul = get_regulator_data(name); in stpmic1_regulator_enable()
645 int stpmic1_regulator_disable(const char *name) in stpmic1_regulator_disable() argument
647 const struct regul_struct *regul = get_regulator_data(name); in stpmic1_regulator_disable()
653 bool stpmic1_is_regulator_enabled(const char *name) in stpmic1_is_regulator_enabled() argument
655 const struct regul_struct *regul = get_regulator_data(name); in stpmic1_is_regulator_enabled()
665 static uint8_t find_plat_mask(const char *name) in find_plat_mask() argument
667 if (!strncmp(name, "buck", 4)) in find_plat_mask()
670 if (!strncmp(name, "ldo", 3) && strcmp(name, "ldo4")) in find_plat_mask()
676 int stpmic1_regulator_voltage_set(const char *name, uint16_t millivolts) in stpmic1_regulator_voltage_set() argument
678 size_t voltage_index = voltage_to_index(name, millivolts); in stpmic1_regulator_voltage_set()
679 const struct regul_struct *regul = get_regulator_data(name); in stpmic1_regulator_voltage_set()
685 mask = find_plat_mask(name); in stpmic1_regulator_voltage_set()
694 int stpmic1_regulator_mask_reset_set(const char *name) in stpmic1_regulator_mask_reset_set() argument
696 const struct regul_struct *regul = get_regulator_data(name); in stpmic1_regulator_mask_reset_set()
709 int stpmic1_bo_enable_cfg(const char *name, struct stpmic1_bo_cfg *cfg) in stpmic1_bo_enable_cfg() argument
711 const struct regul_struct *regul = get_regulator_data(name); in stpmic1_bo_enable_cfg()
727 int stpmic1_bo_voltage_cfg(const char *name, uint16_t min_millivolt, in stpmic1_bo_voltage_cfg() argument
730 size_t min_index = voltage_to_index(name, min_millivolt); in stpmic1_bo_voltage_cfg()
731 const struct regul_struct *regul = get_regulator_data(name); in stpmic1_bo_voltage_cfg()
737 mask = find_plat_mask(name); in stpmic1_bo_voltage_cfg()
764 int stpmic1_bo_pull_down_cfg(const char *name, struct stpmic1_bo_cfg *cfg) in stpmic1_bo_pull_down_cfg() argument
766 const struct regul_struct *regul = get_regulator_data(name); in stpmic1_bo_pull_down_cfg()
769 DMSG("No pull down for regu %s", name); in stpmic1_bo_pull_down_cfg()
788 int stpmic1_bo_mask_reset_cfg(const char *name, struct stpmic1_bo_cfg *cfg) in stpmic1_bo_mask_reset_cfg() argument
790 const struct regul_struct *regul = get_regulator_data(name); in stpmic1_bo_mask_reset_cfg()
793 DMSG("No reset mask for regu %s", name); in stpmic1_bo_mask_reset_cfg()
812 int stpmic1_regulator_voltage_get(const char *name) in stpmic1_regulator_voltage_get() argument
814 const struct regul_struct *regul = get_regulator_data(name); in stpmic1_regulator_voltage_get()
818 mask = find_plat_mask(name); in stpmic1_regulator_voltage_get()
833 int stpmic1_lp_copy_reg(const char *name) in stpmic1_lp_copy_reg() argument
835 const struct regul_struct *regul = get_regulator_data(name); in stpmic1_lp_copy_reg()
849 bool stpmic1_regu_has_lp_cfg(const char *name) in stpmic1_regu_has_lp_cfg() argument
851 return get_regulator_data(name)->low_power_reg; in stpmic1_regu_has_lp_cfg()
854 int stpmic1_lp_cfg(const char *name, struct stpmic1_lp_cfg *cfg) in stpmic1_lp_cfg() argument
856 const struct regul_struct *regul = get_regulator_data(name); in stpmic1_lp_cfg()
881 int stpmic1_lp_reg_on_off(const char *name, uint8_t enable) in stpmic1_lp_reg_on_off() argument
883 const struct regul_struct *regul = get_regulator_data(name); in stpmic1_lp_reg_on_off()
900 int stpmic1_lp_set_mode(const char *name, uint8_t hplp) in stpmic1_lp_set_mode() argument
902 const struct regul_struct *regul = get_regulator_data(name); in stpmic1_lp_set_mode()
919 int stpmic1_lp_set_voltage(const char *name, uint16_t millivolts) in stpmic1_lp_set_voltage() argument
921 size_t voltage_index = voltage_to_index(name, millivolts); in stpmic1_lp_set_voltage()
922 const struct regul_struct *regul = get_regulator_data(name); in stpmic1_lp_set_voltage()
927 mask = find_plat_mask(name); in stpmic1_lp_set_voltage()
936 int stpmic1_lp_voltage_cfg(const char *name, uint16_t millivolts, in stpmic1_lp_voltage_cfg() argument
940 size_t voltage_index = voltage_to_index(name, millivolts); in stpmic1_lp_voltage_cfg()
943 mask = find_plat_mask(name); in stpmic1_lp_voltage_cfg()
948 cfg->lp_reg == get_regulator_data(name)->low_power_reg); in stpmic1_lp_voltage_cfg()
1005 char __maybe_unused const *name = NULL; in stpmic1_dump_regulators() local
1011 name = regulators_table[i].dt_node_name; in stpmic1_dump_regulators()
1013 name, stpmic1_is_regulator_enabled(name) ? "en" : "dis", in stpmic1_dump_regulators()
1014 stpmic1_regulator_voltage_get(name)); in stpmic1_dump_regulators()