linux/sound/pci
Jaroslav Kysela f05c1ffc27 ALSA: pcm: reinvent the stream synchronization ID API
Until the commit e11f0f90a6 ("ALSA: pcm: remove SNDRV_PCM_IOCTL1_INFO
internal command"), there was a possibility to pass information
about the synchronized streams to the user space. The mentioned
commit removed blindly the appropriate code with an irrelevant comment.

The revert may be appropriate, but since this API was lost for several
years without any complains, it's time to improve it. The hardware
parameters may change the used stream clock source (e.g. USB hardware)
so move this synchronization ID to hw_params as read-only field.

It seems that pipewire can benefit from this API (disable adaptive
resampling for perfectly synchronized PCM streams) now.

Note that the contents of ID is not supposed to be used for direct
comparison with a specific byte sequence. The "empty" case is when
all bytes are zero (driver does not offer this information)
and all other cases must be only used for equal comparison among
PCM streams (including different sound cards) if they are using
identical hardware clock.

Cc: Takashi Sakamoto <takaswie@kernel.org>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Link: https://patch.msgid.link/20240625172836.589380-2-perex@perex.cz
2024-07-02 09:53:21 +02:00
..
ac97 ALSA: ac97: More cleanup with snd_ctl_find_id_mixer() 2024-03-04 09:22:51 +01:00
ali5451 ALSA: pci: Use *-y instead of *-objs in Makefile 2024-05-08 18:17:37 +02:00
asihpi ALSA: pci: Use *-y instead of *-objs in Makefile 2024-05-08 18:17:37 +02:00
au88x0 ALSA: pci: Use *-y instead of *-objs in Makefile 2024-05-08 18:17:37 +02:00
aw2 ALSA: pci: Use *-y instead of *-objs in Makefile 2024-05-08 18:17:37 +02:00
ca0106 ALSA: pci: Use *-y instead of *-objs in Makefile 2024-05-08 18:17:37 +02:00
cs46xx ALSA: cs46xx: Simplify with snd_ctl_find_id_mixer() 2023-07-21 09:10:39 +02:00
cs5535audio ALSA: cs5535audio: Remove the redundant assignment 2022-11-07 09:16:31 +01:00
ctxfi ALSA: pci: Use *-y instead of *-objs in Makefile 2024-05-08 18:17:37 +02:00
echoaudio ALSA: pci: Use *-y instead of *-objs in Makefile 2024-05-08 18:17:37 +02:00
emu10k1 ALSA: pcm: reinvent the stream synchronization ID API 2024-07-02 09:53:21 +02:00
hda Merge branch 'for-linus' into for-next 2024-06-26 22:11:13 +02:00
ice1712 ALSA: pci: Use *-y instead of *-objs in Makefile 2024-05-08 18:17:37 +02:00
korg1212 ALSA: pci: Use *-y instead of *-objs in Makefile 2024-05-08 18:17:37 +02:00
lola ALSA: lola: Bounds check loop iterator against streams array size 2022-05-21 08:48:57 +02:00
lx6464es ALSA: pci: Use *-y instead of *-objs in Makefile 2024-05-08 18:17:37 +02:00
mixart ALSA: pci: Use *-y instead of *-objs in Makefile 2024-05-08 18:17:37 +02:00
nm256 ALSA: pci: Use *-y instead of *-objs in Makefile 2024-05-08 18:17:37 +02:00
oxygen ALSA: pci: Use *-y instead of *-objs in Makefile 2024-05-08 18:17:37 +02:00
pcxhr ALSA: pci: Use *-y instead of *-objs in Makefile 2024-05-08 18:17:37 +02:00
riptide ALSA: pci: Use *-y instead of *-objs in Makefile 2024-05-08 18:17:37 +02:00
rme9652 ALSA: pci: Use *-y instead of *-objs in Makefile 2024-05-08 18:17:37 +02:00
trident ALSA: pci: Use *-y instead of *-objs in Makefile 2024-05-08 18:17:37 +02:00
vx222 ALSA: pci: Use *-y instead of *-objs in Makefile 2024-05-08 18:17:37 +02:00
ymfpci ALSA: pci: Use *-y instead of *-objs in Makefile 2024-05-08 18:17:37 +02:00
ad1889.c ALSA: ad1889: Fix the missing snd_card_free() call at probe error 2022-04-12 17:58:18 +02:00
ad1889.h
ak4531_codec.c ALSA: ak4531: Fix assignment in if condition 2021-06-09 17:29:49 +02:00
als300.c ALSA: als300: Replace with DEFINE_SIMPLE_DEV_PM_OPS() 2024-02-12 11:50:24 +01:00
als4000.c ALSA: als4000: Replace with DEFINE_SIMPLE_DEV_PM_OPS() 2024-02-12 11:50:24 +01:00
atiixp_modem.c ALSA: atiixp: Replace with DEFINE_SIMPLE_DEV_PM_OPS() 2024-02-12 11:50:24 +01:00
atiixp.c ALSA: atiixp: Replace with DEFINE_SIMPLE_DEV_PM_OPS() 2024-02-12 11:50:24 +01:00
azt3328.c ALSA: azt3328: Simplify with DEFINE_SIMPLE_DEV_PM_OPS() 2024-02-12 11:50:25 +01:00
azt3328.h
bt87x.c ALSA: bt87x: Fix the missing snd_card_free() call at probe error 2022-04-12 17:58:36 +02:00
cmipci.c ALSA: cmipci: Simplify with DEFINE_SIMPLE_DEV_PM_OPS() 2024-02-12 11:50:25 +01:00
cs4281.c ALSA: cs4281: Simplify with DEFINE_SIMPLE_DEV_PM_OPS() 2024-02-12 11:50:25 +01:00
cs5530.c ALSA: cs5530: Allocate resources with device-managed APIs 2021-07-19 16:16:43 +02:00
ens1370.c ALSA: ens137x: Replace with DEFINE_SIMPLE_DEV_PM_OPS() 2024-02-12 11:50:24 +01:00
ens1371.c
es1938.c ALSA: es1938: Simplify with DEFINE_SIMPLE_DEV_PM_OPS() 2024-02-12 11:50:26 +01:00
es1968.c ALSA: es1968: Simplify with DEFINE_SIMPLE_DEV_PM_OPS() 2024-02-12 11:50:26 +01:00
fm801.c ALSA: fm801: Simplify with DEFINE_SIMPLE_DEV_PM_OPS() 2024-02-12 11:50:26 +01:00
intel8x0.c ALSA: intel8x0: Replace with DEFINE_SIMPLE_DEV_PM_OPS() 2024-02-12 11:50:24 +01:00
intel8x0m.c ALSA: intel8x0: Replace with DEFINE_SIMPLE_DEV_PM_OPS() 2024-02-12 11:50:24 +01:00
Kconfig ALSA: add HAS_IOPORT dependencies 2023-05-22 16:43:47 +02:00
maestro3.c ALSA: maestro3: Simplify with DEFINE_SIMPLE_DEV_PM_OPS() 2024-02-12 11:50:26 +01:00
Makefile ALSA: pci: Use *-y instead of *-objs in Makefile 2024-05-08 18:17:37 +02:00
rme32.c ALSA: rme32: Convert to generic PCM copy ops 2023-08-18 12:18:21 +02:00
rme96.c ALSA: rme96: Simplify with DEFINE_SIMPLE_DEV_PM_OPS() 2024-02-12 11:50:26 +01:00
sis7019.c ALSA: sis7019: Simplify with DEFINE_SIMPLE_DEV_PM_OPS() 2024-02-12 11:50:26 +01:00
sis7019.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 274 2019-06-05 17:30:30 +02:00
sonicvibes.c ALSA: sonicvibes: Fix the missing snd_card_free() call at probe error 2022-04-12 17:58:33 +02:00
via82xx_modem.c ALSA: via82xx: Simplify with DEFINE_SIMPLE_DEV_PM_OPS() 2024-02-12 11:50:26 +01:00
via82xx.c ALSA: via82xx: Simplify with DEFINE_SIMPLE_DEV_PM_OPS() 2024-02-12 11:50:26 +01:00