From: Cezary Rojewski Date: Fri, 5 Apr 2024 09:09:27 +0000 (+0200) Subject: ASoC: Intel: avs: Init debugfs before booting firmware X-Git-Tag: v6.10-rc1~146^2~3^2~68^2~2 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=ff0aefe2d217ce6fec6487b225737b2019eb88c0;p=thirdparty%2Fkernel%2Flinux.git ASoC: Intel: avs: Init debugfs before booting firmware When bringing up setups it's vital to have access to debug functionality even if firmware boot fails. As order of probe()ing operations is changed, update remove() procedure accordingly. Signed-off-by: Cezary Rojewski Link: https://msgid.link/r/20240405090929.1184068-12-cezary.rojewski@intel.com Signed-off-by: Mark Brown --- diff --git a/sound/soc/intel/avs/core.c b/sound/soc/intel/avs/core.c index d7f8940099cec..76782a0f32bc3 100644 --- a/sound/soc/intel/avs/core.c +++ b/sound/soc/intel/avs/core.c @@ -209,6 +209,7 @@ static void avs_hda_probe_work(struct work_struct *work) snd_hdac_ext_bus_ppcap_enable(bus, true); snd_hdac_ext_bus_ppcap_int_enable(bus, true); + avs_debugfs_init(adev); ret = avs_dsp_first_boot_firmware(adev); if (ret < 0) @@ -217,7 +218,6 @@ static void avs_hda_probe_work(struct work_struct *work) adev->nhlt = intel_nhlt_init(adev->dev); if (!adev->nhlt) dev_info(bus->dev, "platform has no NHLT\n"); - avs_debugfs_init(adev); avs_register_all_boards(adev); @@ -548,9 +548,9 @@ static void avs_pci_remove(struct pci_dev *pci) avs_unregister_all_boards(adev); - avs_debugfs_exit(adev); if (adev->nhlt) intel_nhlt_free(adev->nhlt); + avs_debugfs_exit(adev); if (avs_platattr_test(adev, CLDMA)) hda_cldma_free(&code_loader);