summaryrefslogtreecommitdiff
path: root/include/uapi/sound/asound.h
diff options
context:
space:
mode:
authorMark Brown <broonie@linaro.org>2014-07-08 18:51:49 +0400
committerTakashi Iwai <tiwai@suse.de>2014-07-10 18:58:13 +0400
commit0ac8a52d4541adc284a4f3e8a1f6847236de1d8a (patch)
treee8f02e842c72fc9f9549cffa90198c12e07004e9 /include/uapi/sound/asound.h
parent2408c219df9e7a47680d43ed7877aaaec3feca1b (diff)
downloadlinux-0ac8a52d4541adc284a4f3e8a1f6847236de1d8a.tar.xz
ALSA: Provide a CLOCK_MONOTONIC_RAW timestamp type
For applications which need to synchronise with external timebases such as broadcast TV applications the kernel monotonic time is not optimal as it includes adjustments from NTP and so may still include discontinuities due to that. A raw monotonic time which does not include any adjustments is available in the kernel from getrawmonotonic() so provide userspace with a new timestamp type SNDRV_PCM_TSTAMP_TYPE_MONOTONIC_RAW which provides timestamps based on this as an option. [dropped tstamp_type assignment code, as it's no longer needed -- tiwai] Reported-by: Daniel Thompson <daniel.thompson@linaro.org> Signed-off-by: Mark Brown <broonie@linaro.org> Acked-by: Jaroslav Kysela <perex@perex.cz> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'include/uapi/sound/asound.h')
-rw-r--r--include/uapi/sound/asound.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/include/uapi/sound/asound.h b/include/uapi/sound/asound.h
index 224948342f14..cbf7dc850a46 100644
--- a/include/uapi/sound/asound.h
+++ b/include/uapi/sound/asound.h
@@ -462,7 +462,8 @@ struct snd_xfern {
enum {
SNDRV_PCM_TSTAMP_TYPE_GETTIMEOFDAY = 0, /* gettimeofday equivalent */
SNDRV_PCM_TSTAMP_TYPE_MONOTONIC, /* posix_clock_monotonic equivalent */
- SNDRV_PCM_TSTAMP_TYPE_LAST = SNDRV_PCM_TSTAMP_TYPE_MONOTONIC,
+ SNDRV_PCM_TSTAMP_TYPE_MONOTONIC_RAW, /* monotonic_raw (no NTP) */
+ SNDRV_PCM_TSTAMP_TYPE_LAST = SNDRV_PCM_TSTAMP_TYPE_MONOTONIC_RAW,
};
/* channel positions */