]> git.alsa-project.org Git - alsa-lib.git/commitdiff
Added SNDRV_PCM_IOCTL_TTSTAMP and updated PCM API version to 2.0.9
authorJaroslav Kysela <perex@perex.cz>
Mon, 17 Dec 2007 08:04:42 +0000 (09:04 +0100)
committerJaroslav Kysela <perex@perex.cz>
Mon, 17 Dec 2007 08:04:42 +0000 (09:04 +0100)
include/sound/asound.h
src/pcm/pcm_hw.c

index 3909e837057643785bfed2bb38bef4417e47ab55..18eeb073ed311009625280fd4913fb1626de61f5 100644 (file)
@@ -157,7 +157,7 @@ enum {
  *                                                                           *
  *****************************************************************************/
 
-#define SNDRV_PCM_VERSION              SNDRV_PROTOCOL_VERSION(2, 0, 7)
+#define SNDRV_PCM_VERSION              SNDRV_PROTOCOL_VERSION(2, 0, 9)
 
 typedef unsigned long sndrv_pcm_uframes_t;
 typedef long sndrv_pcm_sframes_t;
@@ -460,10 +460,18 @@ struct sndrv_xfern {
        sndrv_pcm_uframes_t frames;
 };
 
+
+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,
+};
+
 enum {
        SNDRV_PCM_IOCTL_PVERSION = _IOR('A', 0x00, int),
        SNDRV_PCM_IOCTL_INFO = _IOR('A', 0x01, struct sndrv_pcm_info),
        SNDRV_PCM_IOCTL_TSTAMP = _IOW('A', 0x02, int),
+       SNDRV_PCM_IOCTL_TTSTAMP = _IOW('A', 0x03, int),
        SNDRV_PCM_IOCTL_HW_REFINE = _IOWR('A', 0x10, struct sndrv_pcm_hw_params),
        SNDRV_PCM_IOCTL_HW_PARAMS = _IOWR('A', 0x11, struct sndrv_pcm_hw_params),
        SNDRV_PCM_IOCTL_HW_FREE = _IO('A', 0x12),
index 7be92961e7bf55055c8116c434a6dca2a7e78813..94eca84e2d487c88f8422a10288bcefeb4887288 100644 (file)
@@ -102,7 +102,7 @@ typedef struct {
 
 #define SNDRV_FILE_PCM_STREAM_PLAYBACK         ALSA_DEVICE_DIRECTORY "pcmC%iD%ip"
 #define SNDRV_FILE_PCM_STREAM_CAPTURE          ALSA_DEVICE_DIRECTORY "pcmC%iD%ic"
-#define SNDRV_PCM_VERSION_MAX                  SNDRV_PROTOCOL_VERSION(2, 0, 5)
+#define SNDRV_PCM_VERSION_MAX                  SNDRV_PROTOCOL_VERSION(2, 0, 9)
 
 /* update appl_ptr with driver */
 #define FAST_PCM_STATE(hw) \