KMix merge requestshttps://invent.kde.org/multimedia/kmix/-/merge_requests2021-12-13T16:50:19Zhttps://invent.kde.org/multimedia/kmix/-/merge_requests/13Draft: alsa: Make card names unique by adding the alsa card number2021-12-13T16:50:19ZAlex HermannDraft: alsa: Make card names unique by adding the alsa card numberUnfortunately, the number <-> card mapping may change every boot, or when
reloading modules.Unfortunately, the number <-> card mapping may change every boot, or when
reloading modules.https://invent.kde.org/multimedia/kmix/-/merge_requests/12alsa: Register the card ID instead of the name2022-01-02T19:53:46ZAlex Hermannalsa: Register the card ID instead of the nameIn ALSA, only the ID is guaranteed to be unique. The name can be duplicated,
expecially whe using multiple (nearly) identical cards.
There is a hint of handling duplicate card names in the registerCard()
function, but this code is flawe...In ALSA, only the ID is guaranteed to be unique. The name can be duplicated,
expecially whe using multiple (nearly) identical cards.
There is a hint of handling duplicate card names in the registerCard()
function, but this code is flawed on multiple aspects:
1) The "discriminator" counter (s_mixerNums[cardBaseName]) is never
incremented, so it will always return 0.
2) The class in which the counter is stored, is instantiated for every card
separately, so the discrimination will never be possible across multiple
cards.
To circumvent, implement getId() and return the ALSA ID. This will create
DBUS names based on the ID, so selecting the right card is now possible.
Because the GUI requirers unique names, the ID is also added to the name.
Fixes BKO#340502https://invent.kde.org/multimedia/kmix/-/merge_requests/10Draft: alsa: use long name instead of name2021-11-27T20:08:22ZLuis Javier MerinoDraft: alsa: use long name instead of namename can be ambiguous, e.g. if there is HDMI and a "normal" soundcard,
both identified as "HD-Audio Generic".
See bugs:
- https://bugs.kde.org/show_bug.cgi?id=441476
- https://bugs.kde.org/show_bug.cgi?id=340502
and probably:
- ht...name can be ambiguous, e.g. if there is HDMI and a "normal" soundcard,
both identified as "HD-Audio Generic".
See bugs:
- https://bugs.kde.org/show_bug.cgi?id=441476
- https://bugs.kde.org/show_bug.cgi?id=340502
and probably:
- https://bugs.kde.org/show_bug.cgi?id=437516
- https://bugs.kde.org/show_bug.cgi?id=311527
- https://bugs.kde.org/show_bug.cgi?id=381283