File tree Expand file tree Collapse file tree 4 files changed +12
-10
lines changed Expand file tree Collapse file tree 4 files changed +12
-10
lines changed Original file line number Diff line number Diff line change 2
2
//
3
3
// ALSA SoC Texas Instruments TAS2563/TAS2781 Audio Smart Amplifier
4
4
//
5
- // Copyright (C) 2022 - 2023 Texas Instruments Incorporated
5
+ // Copyright (C) 2022 - 2024 Texas Instruments Incorporated
6
6
// https://www.ti.com
7
7
//
8
8
// The TAS2563/TAS2781 driver implements a flexible and configurable
43
43
(page * 128)) + reg)
44
44
45
45
/*Software Reset */
46
- #define TAS2781_REG_SWRESET TASDEVICE_REG(0x0, 0X0, 0x01)
47
- #define TAS2781_REG_SWRESET_RESET BIT(0)
46
+ #define TASDEVICE_REG_SWRESET TASDEVICE_REG(0x0, 0X0, 0x01)
47
+ #define TASDEVICE_REG_SWRESET_RESET BIT(0)
48
48
49
49
/*I2C Checksum */
50
50
#define TASDEVICE_I2CChecksum TASDEVICE_REG(0x0, 0x0, 0x7E)
@@ -140,7 +140,7 @@ struct tasdevice_priv {
140
140
void (* apply_calibration )(struct tasdevice_priv * tas_priv );
141
141
};
142
142
143
- void tas2781_reset (struct tasdevice_priv * tas_dev );
143
+ void tasdevice_reset (struct tasdevice_priv * tas_dev );
144
144
int tascodec_init (struct tasdevice_priv * tas_priv , void * codec ,
145
145
struct module * module ,
146
146
void (* cont )(const struct firmware * fw , void * context ));
Original file line number Diff line number Diff line change @@ -834,7 +834,7 @@ static int tas2781_hda_i2c_probe(struct i2c_client *clt)
834
834
pm_runtime_set_active (tas_hda -> dev );
835
835
pm_runtime_enable (tas_hda -> dev );
836
836
837
- tas2781_reset (tas_hda -> priv );
837
+ tasdevice_reset (tas_hda -> priv );
838
838
839
839
ret = component_add (tas_hda -> dev , & tas2781_hda_comp_ops );
840
840
if (ret ) {
@@ -929,7 +929,7 @@ static int tas2781_system_resume(struct device *dev)
929
929
tas_hda -> priv -> tasdevice [i ].cur_prog = -1 ;
930
930
tas_hda -> priv -> tasdevice [i ].cur_conf = -1 ;
931
931
}
932
- tas2781_reset (tas_hda -> priv );
932
+ tasdevice_reset (tas_hda -> priv );
933
933
tasdevice_prmg_load (tas_hda -> priv , tas_hda -> priv -> cur_prog );
934
934
935
935
/* If calibrated data occurs error, dsp will still work with default
Original file line number Diff line number Diff line change @@ -243,7 +243,7 @@ struct tasdevice_priv *tasdevice_kzalloc(struct i2c_client *i2c)
243
243
}
244
244
EXPORT_SYMBOL_GPL (tasdevice_kzalloc );
245
245
246
- void tas2781_reset (struct tasdevice_priv * tas_dev )
246
+ void tasdevice_reset (struct tasdevice_priv * tas_dev )
247
247
{
248
248
int ret , i ;
249
249
@@ -254,8 +254,8 @@ void tas2781_reset(struct tasdevice_priv *tas_dev)
254
254
} else {
255
255
for (i = 0 ; i < tas_dev -> ndev ; i ++ ) {
256
256
ret = tasdevice_dev_write (tas_dev , i ,
257
- TAS2781_REG_SWRESET ,
258
- TAS2781_REG_SWRESET_RESET );
257
+ TASDEVICE_REG_SWRESET ,
258
+ TASDEVICE_REG_SWRESET_RESET );
259
259
if (ret < 0 )
260
260
dev_err (tas_dev -> dev ,
261
261
"dev %d swreset fail, %d\n" ,
@@ -264,7 +264,7 @@ void tas2781_reset(struct tasdevice_priv *tas_dev)
264
264
}
265
265
usleep_range (1000 , 1050 );
266
266
}
267
- EXPORT_SYMBOL_GPL (tas2781_reset );
267
+ EXPORT_SYMBOL_GPL (tasdevice_reset );
268
268
269
269
int tascodec_init (struct tasdevice_priv * tas_priv , void * codec ,
270
270
struct module * module ,
Original file line number Diff line number Diff line change @@ -742,6 +742,8 @@ static int tasdevice_i2c_probe(struct i2c_client *i2c)
742
742
if (ret )
743
743
goto err ;
744
744
745
+ tasdevice_reset (tas_priv );
746
+
745
747
ret = devm_snd_soc_register_component (tas_priv -> dev ,
746
748
& soc_codec_driver_tasdevice ,
747
749
tasdevice_dai_driver , ARRAY_SIZE (tasdevice_dai_driver ));
You can’t perform that action at this time.
0 commit comments