Skip to content

Commit 908ef80

Browse files
jimxbj-dottiwai
authored andcommitted
ALSA: hda/tas2781: Ignore reset check for SPI device
In the SPI driver probe, the device should be in the default state, so the device status check is not necessary. It should be forced to do the firmware download as I2C device. Signed-off-by: Baojun Xu <baojun.xu@ti.com> Link: https://patch.msgid.link/20260211030946.2330-1-baojun.xu@ti.com Signed-off-by: Takashi Iwai <tiwai@suse.de>
1 parent 3a6b7dc commit 908ef80

1 file changed

Lines changed: 7 additions & 13 deletions

File tree

sound/hda/codecs/side-codecs/tas2781_hda_spi.c

Lines changed: 7 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -631,7 +631,7 @@ static void tasdev_fw_ready(const struct firmware *fmw, void *context)
631631
struct tasdevice_priv *tas_priv = context;
632632
struct tas2781_hda *tas_hda = dev_get_drvdata(tas_priv->dev);
633633
struct hda_codec *codec = tas_priv->codec;
634-
int ret, val;
634+
int ret;
635635

636636
guard(pm_runtime_active_auto)(tas_priv->dev);
637637
guard(mutex)(&tas_priv->codec_lock);
@@ -670,20 +670,14 @@ static void tasdev_fw_ready(const struct firmware *fmw, void *context)
670670
tas_priv->rcabin.profile_cfg_id = 0;
671671

672672
tas_priv->fw_state = TASDEVICE_DSP_FW_ALL_OK;
673-
ret = tasdevice_spi_dev_read(tas_priv, tas_priv->index,
674-
TAS2781_REG_CLK_CONFIG, &val);
675-
if (ret < 0)
676-
goto out;
677673

678-
if (val == TAS2781_REG_CLK_CONFIG_RESET) {
679-
ret = tasdevice_prmg_load(tas_priv, 0);
680-
if (ret < 0) {
681-
dev_err(tas_priv->dev, "FW download failed = %d\n",
682-
ret);
683-
goto out;
684-
}
685-
tas_priv->fw_state = TASDEVICE_DSP_FW_ALL_OK;
674+
ret = tasdevice_prmg_load(tas_priv, 0);
675+
if (ret < 0) {
676+
dev_err(tas_priv->dev, "FW download failed = %d\n", ret);
677+
goto out;
686678
}
679+
tas_priv->fw_state = TASDEVICE_DSP_FW_ALL_OK;
680+
687681
if (tas_priv->fmw->nr_programs > 0)
688682
tas_priv->tasdevice[tas_priv->index].cur_prog = 0;
689683
if (tas_priv->fmw->nr_configurations > 0)

0 commit comments

Comments
 (0)