ALSA/hda: intel-dsp-config: reduce log verbosity
authorPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Mon, 27 May 2024 19:38:08 +0000 (14:38 -0500)
committerTakashi Iwai <tiwai@suse.de>
Tue, 28 May 2024 11:07:51 +0000 (13:07 +0200)
The information on PCI class/subclass was interesting in the Skylake
timeframe, since the DSP was only enabled on a limited number of
platforms. Now most Intel platforms do enable the DSP, so the
information is less interesting to log.

When a DSP driver is used, the common helper may be called multiple
times due to deferred probes, but there's no reason to print the same
information multiple times. Using dev_info_once() covers all the
existing usages for internal cards with DSPs. External cards don't
rely on DSPs so far.

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com>
Link: https://lore.kernel.org/r/20240527193808.165652-1-pierre-louis.bossart@linux.intel.com
Signed-off-by: Takashi Iwai <tiwai@suse.de>
sound/hda/intel-dsp-config.c

index cfdb1b7..5378634 100644 (file)
@@ -668,7 +668,7 @@ int snd_intel_dsp_driver_probe(struct pci_dev *pci)
                return SND_INTEL_DSP_DRIVER_LEGACY;
        }
 
-       dev_info(&pci->dev, "DSP detected with PCI class/subclass/prog-if info 0x%06x\n", pci->class);
+       dev_dbg(&pci->dev, "DSP detected with PCI class/subclass/prog-if info 0x%06x\n", pci->class);
 
        /* find the configuration for the specific device */
        cfg = snd_intel_dsp_find_config(pci, config_table, ARRAY_SIZE(config_table));
@@ -678,12 +678,12 @@ int snd_intel_dsp_driver_probe(struct pci_dev *pci)
        if (cfg->flags & FLAG_SOF) {
                if (cfg->flags & FLAG_SOF_ONLY_IF_SOUNDWIRE &&
                    snd_intel_dsp_check_soundwire(pci) > 0) {
-                       dev_info(&pci->dev, "SoundWire enabled on CannonLake+ platform, using SOF driver\n");
+                       dev_info_once(&pci->dev, "SoundWire enabled on CannonLake+ platform, using SOF driver\n");
                        return SND_INTEL_DSP_DRIVER_SOF;
                }
                if (cfg->flags & FLAG_SOF_ONLY_IF_DMIC &&
                    snd_intel_dsp_check_dmic(pci)) {
-                       dev_info(&pci->dev, "Digital mics found on Skylake+ platform, using SOF driver\n");
+                       dev_info_once(&pci->dev, "Digital mics found on Skylake+ platform, using SOF driver\n");
                        return SND_INTEL_DSP_DRIVER_SOF;
                }
                if (!(cfg->flags & FLAG_SOF_ONLY_IF_DMIC_OR_SOUNDWIRE))
@@ -694,7 +694,7 @@ int snd_intel_dsp_driver_probe(struct pci_dev *pci)
        if (cfg->flags & FLAG_SST) {
                if (cfg->flags & FLAG_SST_ONLY_IF_DMIC) {
                        if (snd_intel_dsp_check_dmic(pci)) {
-                               dev_info(&pci->dev, "Digital mics found on Skylake+ platform, using SST driver\n");
+                               dev_info_once(&pci->dev, "Digital mics found on Skylake+ platform, using SST driver\n");
                                return SND_INTEL_DSP_DRIVER_SST;
                        }
                } else {