@@ -204,12 +204,12 @@ static int rt715_set_main_switch_put(struct snd_kcontrol *kcontrol,
204204 struct snd_soc_dapm_context * dapm =
205205 snd_soc_component_get_dapm (component );
206206 struct rt715_priv * rt715 = snd_soc_component_get_drvdata (component );
207- unsigned int capture_reg_H [] = {RT715_SET_GAIN_MIC_ADC_H ,
208- RT715_SET_GAIN_LINE_ADC_H , RT715_SET_GAIN_MIX_ADC_H ,
209- RT715_SET_GAIN_MIX_ADC2_H };
210- unsigned int capture_reg_L [] = {RT715_SET_GAIN_MIC_ADC_L ,
211- RT715_SET_GAIN_LINE_ADC_L , RT715_SET_GAIN_MIX_ADC_L ,
212- RT715_SET_GAIN_MIX_ADC2_L };
207+ static const unsigned int capture_reg_H [] = {
208+ RT715_SET_GAIN_MIC_ADC_H , RT715_SET_GAIN_LINE_ADC_H ,
209+ RT715_SET_GAIN_MIX_ADC_H , RT715_SET_GAIN_MIX_ADC2_H };
210+ static const unsigned int capture_reg_L [] = {
211+ RT715_SET_GAIN_MIC_ADC_L , RT715_SET_GAIN_LINE_ADC_L ,
212+ RT715_SET_GAIN_MIX_ADC_L , RT715_SET_GAIN_MIX_ADC2_L };
213213 unsigned int addr_h , addr_l , val_h = 0x0 , val_ll , val_lr ;
214214 unsigned int k_shift = RT715_DIR_IN_SFT , k_changed = 0 ;
215215 unsigned int read_ll , read_rl , i , j , loop_cnt = 4 ;
@@ -284,12 +284,12 @@ static int rt715_set_main_switch_get(struct snd_kcontrol *kcontrol,
284284{
285285 struct snd_soc_component * component = snd_kcontrol_chip (kcontrol );
286286 struct rt715_priv * rt715 = snd_soc_component_get_drvdata (component );
287- unsigned int capture_reg_H [] = {RT715_SET_GAIN_MIC_ADC_H ,
288- RT715_SET_GAIN_LINE_ADC_H , RT715_SET_GAIN_MIX_ADC_H ,
289- RT715_SET_GAIN_MIX_ADC2_H };
290- unsigned int capture_reg_L [] = {RT715_SET_GAIN_MIC_ADC_L ,
291- RT715_SET_GAIN_LINE_ADC_L , RT715_SET_GAIN_MIX_ADC_L ,
292- RT715_SET_GAIN_MIX_ADC2_L };
287+ static const unsigned int capture_reg_H [] = {
288+ RT715_SET_GAIN_MIC_ADC_H , RT715_SET_GAIN_LINE_ADC_H ,
289+ RT715_SET_GAIN_MIX_ADC_H , RT715_SET_GAIN_MIX_ADC2_H };
290+ static const unsigned int capture_reg_L [] = {
291+ RT715_SET_GAIN_MIC_ADC_L , RT715_SET_GAIN_LINE_ADC_L ,
292+ RT715_SET_GAIN_MIX_ADC_L , RT715_SET_GAIN_MIX_ADC2_L };
293293 unsigned int addr_h , addr_l , val_h = 0x0 , i , loop_cnt = 4 ;
294294 unsigned int read_ll , read_rl ;
295295
@@ -312,12 +312,12 @@ static int rt715_set_main_vol_put(struct snd_kcontrol *kcontrol,
312312 struct snd_soc_dapm_context * dapm =
313313 snd_soc_component_get_dapm (component );
314314 struct rt715_priv * rt715 = snd_soc_component_get_drvdata (component );
315- unsigned int capture_reg_H [] = {RT715_SET_GAIN_MIC_ADC_H ,
316- RT715_SET_GAIN_LINE_ADC_H , RT715_SET_GAIN_MIX_ADC_H ,
317- RT715_SET_GAIN_MIX_ADC2_H };
318- unsigned int capture_reg_L [] = {RT715_SET_GAIN_MIC_ADC_L ,
319- RT715_SET_GAIN_LINE_ADC_L , RT715_SET_GAIN_MIX_ADC_L ,
320- RT715_SET_GAIN_MIX_ADC2_L };
315+ static const unsigned int capture_reg_H [] = {
316+ RT715_SET_GAIN_MIC_ADC_H , RT715_SET_GAIN_LINE_ADC_H ,
317+ RT715_SET_GAIN_MIX_ADC_H , RT715_SET_GAIN_MIX_ADC2_H };
318+ static const unsigned int capture_reg_L [] = {
319+ RT715_SET_GAIN_MIC_ADC_L , RT715_SET_GAIN_LINE_ADC_L ,
320+ RT715_SET_GAIN_MIX_ADC_L , RT715_SET_GAIN_MIX_ADC2_L };
321321 unsigned int addr_h , addr_l , val_h = 0x0 , val_ll , val_lr ;
322322 unsigned int read_ll , read_rl , i , j , loop_cnt = 4 , k_changed = 0 ;
323323 unsigned int k_shift = RT715_DIR_IN_SFT , k_max = 0x3f ;
@@ -393,12 +393,12 @@ static int rt715_set_main_vol_get(struct snd_kcontrol *kcontrol,
393393{
394394 struct snd_soc_component * component = snd_kcontrol_chip (kcontrol );
395395 struct rt715_priv * rt715 = snd_soc_component_get_drvdata (component );
396- unsigned int capture_reg_H [] = {RT715_SET_GAIN_MIC_ADC_H ,
397- RT715_SET_GAIN_LINE_ADC_H , RT715_SET_GAIN_MIX_ADC_H ,
398- RT715_SET_GAIN_MIX_ADC2_H };
399- unsigned int capture_reg_L [] = {RT715_SET_GAIN_MIC_ADC_L ,
400- RT715_SET_GAIN_LINE_ADC_L , RT715_SET_GAIN_MIX_ADC_L ,
401- RT715_SET_GAIN_MIX_ADC2_L };
396+ static const unsigned int capture_reg_H [] = {
397+ RT715_SET_GAIN_MIC_ADC_H , RT715_SET_GAIN_LINE_ADC_H ,
398+ RT715_SET_GAIN_MIX_ADC_H , RT715_SET_GAIN_MIX_ADC2_H };
399+ static const unsigned int capture_reg_L [] = {
400+ RT715_SET_GAIN_MIC_ADC_L , RT715_SET_GAIN_LINE_ADC_L ,
401+ RT715_SET_GAIN_MIX_ADC_L , RT715_SET_GAIN_MIX_ADC2_L };
402402 unsigned int addr_h , addr_l , val_h = 0x0 , i , loop_cnt = 4 ;
403403 unsigned int read_ll , read_rl ;
404404
0 commit comments