Home
last modified time | relevance | path

Searched refs:aw_dev (Results 1 – 7 of 7) sorted by relevance

/linux-6.12.1/sound/soc/codecs/aw88395/
Daw88395_device.c17 static int aw_dev_dsp_write_16bit(struct aw_device *aw_dev, in aw_dev_dsp_write_16bit() argument
22 ret = regmap_write(aw_dev->regmap, AW88395_DSPMADD_REG, dsp_addr); in aw_dev_dsp_write_16bit()
24 dev_err(aw_dev->dev, "%s write addr error, ret=%d", __func__, ret); in aw_dev_dsp_write_16bit()
28 ret = regmap_write(aw_dev->regmap, AW88395_DSPMDAT_REG, (u16)dsp_data); in aw_dev_dsp_write_16bit()
30 dev_err(aw_dev->dev, "%s write data error, ret=%d", __func__, ret); in aw_dev_dsp_write_16bit()
37 static int aw_dev_dsp_write_32bit(struct aw_device *aw_dev, in aw_dev_dsp_write_32bit() argument
43 ret = regmap_write(aw_dev->regmap, AW88395_DSPMADD_REG, dsp_addr); in aw_dev_dsp_write_32bit()
45 dev_err(aw_dev->dev, "%s write addr error, ret=%d", __func__, ret); in aw_dev_dsp_write_32bit()
50 ret = regmap_write(aw_dev->regmap, AW88395_DSPMDAT_REG, (u16)temp_data); in aw_dev_dsp_write_32bit()
52 dev_err(aw_dev->dev, "%s write datal error, ret=%d", __func__, ret); in aw_dev_dsp_write_32bit()
[all …]
Daw88395_lib.c25 static int aw_parse_bin_header(struct aw_device *aw_dev, struct aw_bin *bin);
27 static int aw_check_sum(struct aw_device *aw_dev, struct aw_bin *bin, int bin_num) in aw_check_sum() argument
42 dev_dbg(aw_dev->dev, "%s -- check_sum = %p, check_sum = 0x%x, sum_data = 0x%x", in aw_check_sum()
45 dev_err(aw_dev->dev, "%s. CheckSum Fail.bin_num=%d, CheckSum:0x%x, SumData:0x%x", in aw_check_sum()
53 static int aw_check_data_version(struct aw_device *aw_dev, struct aw_bin *bin, int bin_num) in aw_check_data_version() argument
57 dev_err(aw_dev->dev, "aw_bin_parse Unrecognized this bin data version\n"); in aw_check_data_version()
64 static int aw_check_register_num(struct aw_device *aw_dev, struct aw_bin *bin, int bin_num) in aw_check_register_num() argument
76 dev_dbg(aw_dev->dev, "%s,parse_register_num = 0x%x,check_register_num = 0x%x\n", in aw_check_register_num()
79 dev_err(aw_dev->dev, "%s parse_register_num = 0x%x,check_register_num = 0x%x\n", in aw_check_register_num()
91 static int aw_check_dsp_reg_num(struct aw_device *aw_dev, struct aw_bin *bin, int bin_num) in aw_check_dsp_reg_num() argument
[all …]
Daw88395_device.h176 int aw88395_init(struct aw_device **aw_dev, struct i2c_client *i2c, struct regmap *regmap);
177 int aw88395_dev_init(struct aw_device *aw_dev, struct aw_container *aw_cfg);
178 int aw88395_dev_start(struct aw_device *aw_dev);
179 int aw88395_dev_stop(struct aw_device *aw_dev);
180 int aw88395_dev_fw_update(struct aw_device *aw_dev, bool up_dsp_fw_en, bool force_up_en);
182 void aw88395_dev_set_volume(struct aw_device *aw_dev, unsigned short set_vol);
183 int aw88395_dev_get_prof_data(struct aw_device *aw_dev, int index,
185 int aw88395_dev_get_prof_name(struct aw_device *aw_dev, int index, char **prof_name);
186 int aw88395_dev_set_profile_index(struct aw_device *aw_dev, int index);
187 int aw88395_dev_get_profile_index(struct aw_device *aw_dev);
[all …]
Daw88395.c109 struct aw_device *aw_dev = aw88395->aw_pa; in aw88395_get_fade_in_time() local
111 ucontrol->value.integer.value[0] = aw_dev->fade_in_time; in aw88395_get_fade_in_time()
123 struct aw_device *aw_dev = aw88395->aw_pa; in aw88395_set_fade_in_time() local
131 if (time != aw_dev->fade_in_time) { in aw88395_set_fade_in_time()
132 aw_dev->fade_in_time = time; in aw88395_set_fade_in_time()
144 struct aw_device *aw_dev = aw88395->aw_pa; in aw88395_get_fade_out_time() local
146 ucontrol->value.integer.value[0] = aw_dev->fade_out_time; in aw88395_get_fade_out_time()
158 struct aw_device *aw_dev = aw88395->aw_pa; in aw88395_set_fade_out_time() local
165 if (time != aw_dev->fade_out_time) { in aw88395_set_fade_out_time()
166 aw_dev->fade_out_time = time; in aw88395_set_fade_out_time()
[all …]
/linux-6.12.1/sound/soc/codecs/
Daw88399.c27 static int aw_dev_dsp_write_16bit(struct aw_device *aw_dev, in aw_dev_dsp_write_16bit() argument
32 ret = regmap_write(aw_dev->regmap, AW88399_DSPMADD_REG, dsp_addr); in aw_dev_dsp_write_16bit()
34 dev_err(aw_dev->dev, "%s write addr error, ret=%d", __func__, ret); in aw_dev_dsp_write_16bit()
38 ret = regmap_write(aw_dev->regmap, AW88399_DSPMDAT_REG, (u16)dsp_data); in aw_dev_dsp_write_16bit()
40 dev_err(aw_dev->dev, "%s write data error, ret=%d", __func__, ret); in aw_dev_dsp_write_16bit()
47 static int aw_dev_dsp_read_16bit(struct aw_device *aw_dev, in aw_dev_dsp_read_16bit() argument
53 ret = regmap_write(aw_dev->regmap, AW88399_DSPMADD_REG, dsp_addr); in aw_dev_dsp_read_16bit()
55 dev_err(aw_dev->dev, "%s write error, ret=%d", __func__, ret); in aw_dev_dsp_read_16bit()
59 ret = regmap_read(aw_dev->regmap, AW88399_DSPMDAT_REG, &temp_data); in aw_dev_dsp_read_16bit()
61 dev_err(aw_dev->dev, "%s read error, ret=%d", __func__, ret); in aw_dev_dsp_read_16bit()
[all …]
Daw88261.c27 static void aw88261_dev_set_volume(struct aw_device *aw_dev, unsigned int value) in aw88261_dev_set_volume() argument
29 struct aw_volume_desc *vol_desc = &aw_dev->volume_desc; in aw88261_dev_set_volume()
36 regmap_read(aw_dev->regmap, AW88261_SYSCTRL2_REG, &reg_value); in aw88261_dev_set_volume()
40 dev_dbg(aw_dev->dev, "value 0x%x , real_value:0x%x", value, real_value); in aw88261_dev_set_volume()
42 regmap_write(aw_dev->regmap, AW88261_SYSCTRL2_REG, real_value); in aw88261_dev_set_volume()
45 static void aw88261_dev_fade_in(struct aw_device *aw_dev) in aw88261_dev_fade_in() argument
47 struct aw_volume_desc *desc = &aw_dev->volume_desc; in aw88261_dev_fade_in()
49 int fade_step = aw_dev->fade_step; in aw88261_dev_fade_in()
52 if (fade_step == 0 || aw_dev->fade_in_time == 0) { in aw88261_dev_fade_in()
53 aw88261_dev_set_volume(aw_dev, fade_in_vol); in aw88261_dev_fade_in()
[all …]
Daw87390.c26 static int aw87390_dev_reg_update(struct aw_device *aw_dev, in aw87390_dev_reg_update() argument
32 dev_err(aw_dev->dev, "data is NULL\n"); in aw87390_dev_reg_update()
42 ret = regmap_write(aw_dev->regmap, data[i], data[i + 1]); in aw87390_dev_reg_update()
50 static int aw87390_dev_get_prof_name(struct aw_device *aw_dev, int index, char **prof_name) in aw87390_dev_get_prof_name() argument
52 struct aw_prof_info *prof_info = &aw_dev->prof_info; in aw87390_dev_get_prof_name()
55 if ((index >= aw_dev->prof_info.count) || (index < 0)) { in aw87390_dev_get_prof_name()
56 dev_err(aw_dev->dev, "index[%d] overflow count[%d]\n", in aw87390_dev_get_prof_name()
57 index, aw_dev->prof_info.count); in aw87390_dev_get_prof_name()
61 prof_desc = &aw_dev->prof_info.prof_desc[index]; in aw87390_dev_get_prof_name()
68 static int aw87390_dev_get_prof_data(struct aw_device *aw_dev, int index, in aw87390_dev_get_prof_data() argument
[all …]