]> www.infradead.org Git - nvme.git/commit
ALSA: seq: Add tempo base unit for MIDI2 Set Tempo messages
authorTakashi Iwai <tiwai@suse.de>
Fri, 5 Jul 2024 16:03:42 +0000 (18:03 +0200)
committerTakashi Iwai <tiwai@suse.de>
Sat, 6 Jul 2024 07:38:27 +0000 (09:38 +0200)
commitfefbbdfb59d3a20fd98734363e6dd9fa7cc65c70
tree061d4b19a5afb6974d1011e412edf6e0d0d39436
parenta892b700e63bcb3679ebed1a0c3160e7b9225138
ALSA: seq: Add tempo base unit for MIDI2 Set Tempo messages

MIDI2 Set Tempo message defines the tempo in 10ns unit for finer
accuracy, while MIDI1 was defined in 1us unit.  For adapting this
different unit, introduce "tempo_base" field to snd_seq_queue_tempo
struct so that user-space can pass the proper tempo base unit.

The accepted value is limited, it must be either 0, 10 or 1000.

The protocol version is bumped to 1.0.4 along with this.

The access with the older protocol version ignores the tempo-base
value in ioctls and always treats as 1000.

Reviewed-by: Jaroslav Kysela <perex@perex.cz>
Link: https://patch.msgid.link/20240705160344.6481-1-tiwai@suse.de
Signed-off-by: Takashi Iwai <tiwai@suse.de>
include/uapi/sound/asequencer.h
sound/core/seq/seq_clientmgr.c
sound/core/seq/seq_queue.c
sound/core/seq/seq_timer.c
sound/core/seq/seq_timer.h