Patch "ALSA: hda: Fix kctl->id initialization" has been added to the 6.3-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    ALSA: hda: Fix kctl->id initialization

to the 6.3-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     alsa-hda-fix-kctl-id-initialization.patch
and it can be found in the queue-6.3 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.


>From 5c219a340850233aecbb444af964653ecd3d1370 Mon Sep 17 00:00:00 2001
From: Takashi Iwai <tiwai@xxxxxxx>
Date: Tue, 6 Jun 2023 11:38:55 +0200
Subject: ALSA: hda: Fix kctl->id initialization

From: Takashi Iwai <tiwai@xxxxxxx>

commit 5c219a340850233aecbb444af964653ecd3d1370 upstream.

HD-audio core code replaces the kctl->id.index of SPDIF-related
controls after assigning via snd_ctl_add().  This doesn't work any
longer with the new Xarray lookup change.  The change of the kctl->id
content has to be done via snd_ctl_rename_id() helper, instead.

Fixes: c27e1efb61c5 ("ALSA: control: Use xarray for faster lookups")
Cc: <stable@xxxxxxxxxxxxxxx>
Reviewed-by: Jaroslav Kysela <perex@xxxxxxxx>
Link: https://lore.kernel.org/r/20230606093855.14685-5-tiwai@xxxxxxx
Signed-off-by: Takashi Iwai <tiwai@xxxxxxx>
Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>
---
 sound/pci/hda/hda_codec.c |    6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

--- a/sound/pci/hda/hda_codec.c
+++ b/sound/pci/hda/hda_codec.c
@@ -2458,10 +2458,14 @@ int snd_hda_create_dig_out_ctls(struct h
 		   type == HDA_PCM_TYPE_HDMI) {
 		/* suppose a single SPDIF device */
 		for (dig_mix = dig_mixes; dig_mix->name; dig_mix++) {
+			struct snd_ctl_elem_id id;
+
 			kctl = find_mixer_ctl(codec, dig_mix->name, 0, 0);
 			if (!kctl)
 				break;
-			kctl->id.index = spdif_index;
+			id = kctl->id;
+			id.index = spdif_index;
+			snd_ctl_rename_id(codec->card, &kctl->id, &id);
 		}
 		bus->primary_dig_out_type = HDA_PCM_TYPE_HDMI;
 	}


Patches currently in stable-queue which might be from tiwai@xxxxxxx are

queue-6.3/alsa-hda-fix-kctl-id-initialization.patch
queue-6.3/alsa-hda-realtek-add-quirk-for-clevo-ns50au.patch
queue-6.3/alsa-ice1712-ice1724-fix-the-kcontrol-id-initialization.patch
queue-6.3/alsa-hda-realtek-add-a-quirk-for-hp-slim-desktop-s01.patch
queue-6.3/alsa-hda-realtek-add-lenovo-p3-tower-platform.patch
queue-6.3/alsa-hda-realtek-add-quirks-for-asus-rog-2024-laptops-using-cs35l41.patch
queue-6.3/alsa-gus-fix-kctl-id-initialization.patch
queue-6.3/alsa-cmipci-fix-kctl-id-initialization.patch
queue-6.3/alsa-ymfpci-fix-kctl-id-initialization.patch



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux