summaryrefslogtreecommitdiff
path: root/include/sound/seq_kernel.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/sound/seq_kernel.h')
-rw-r--r--include/sound/seq_kernel.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/include/sound/seq_kernel.h b/include/sound/seq_kernel.h
index 527e7f8ad661..c8621671fa70 100644
--- a/include/sound/seq_kernel.h
+++ b/include/sound/seq_kernel.h
@@ -75,6 +75,14 @@ int snd_seq_expand_var_event_at(const struct snd_seq_event *event, int count,
int snd_seq_dump_var_event(const struct snd_seq_event *event,
snd_seq_dump_func_t func, void *private_data);
+/* size of the event packet; it can be greater than snd_seq_event size */
+static inline size_t snd_seq_event_packet_size(struct snd_seq_event *ev)
+{
+ if (snd_seq_ev_is_ump(ev))
+ return sizeof(struct snd_seq_ump_event);
+ return sizeof(struct snd_seq_event);
+}
+
/* interface for OSS emulation */
int snd_seq_set_queue_tempo(int client, struct snd_seq_queue_tempo *tempo);