diff --git a/linux-user/ioctls.h b/linux-user/ioctls.h index 8313af3672..de69487963 100644 --- a/linux-user/ioctls.h +++ b/linux-user/ioctls.h @@ -472,6 +472,11 @@ MK_PTR(MK_STRUCT(STRUCT_snd_timer_gstatus))) IOCTL(SNDRV_TIMER_IOCTL_SELECT, IOC_W, MK_PTR(MK_STRUCT(STRUCT_snd_timer_select))) + IOCTL(SNDRV_TIMER_IOCTL_INFO, IOC_R, MK_PTR(MK_STRUCT(STRUCT_snd_timer_info))) + IOCTL(SNDRV_TIMER_IOCTL_PARAMS, IOC_W, + MK_PTR(MK_STRUCT(STRUCT_snd_timer_params))) + IOCTL(SNDRV_TIMER_IOCTL_STATUS, IOC_R, + MK_PTR(MK_STRUCT(STRUCT_snd_timer_status))) IOCTL(HDIO_GETGEO, IOC_R, MK_PTR(MK_STRUCT(STRUCT_hd_geometry))) IOCTL(HDIO_GET_UNMASKINTR, IOC_R, MK_PTR(TYPE_INT)) diff --git a/linux-user/syscall_defs.h b/linux-user/syscall_defs.h index cac9228a37..cf34129fc3 100644 --- a/linux-user/syscall_defs.h +++ b/linux-user/syscall_defs.h @@ -2479,6 +2479,25 @@ struct target_snd_timer_select { unsigned char reserved[32]; }; +struct target_snd_timer_info { + unsigned int flags; + int card; + unsigned char id[64]; + unsigned char name[80]; + abi_ulong reserved0; + abi_ulong resolution; + unsigned char reserved[64]; +}; + +struct target_snd_timer_status { + struct target_timespec tstamp; + unsigned int resolution; + unsigned int lost; + unsigned int overrun; + unsigned int queue; + unsigned char reserved[64]; +}; + /* alsa timer ioctls */ #define TARGET_SNDRV_TIMER_IOCTL_PVERSION TARGET_IOR('T', 0x00, int) #define TARGET_SNDRV_TIMER_IOCTL_NEXT_DEVICE TARGET_IOWR('T', 0x01, \ @@ -2491,6 +2510,12 @@ struct target_snd_timer_select { struct target_snd_timer_gstatus) #define TARGET_SNDRV_TIMER_IOCTL_SELECT TARGET_IOW('T', 0x10, \ struct target_snd_timer_select) +#define TARGET_SNDRV_TIMER_IOCTL_INFO TARGET_IOR('T', 0x11, \ + struct target_snd_timer_info) +#define TARGET_SNDRV_TIMER_IOCTL_PARAMS TARGET_IOW('T', 0x12, \ + struct snd_timer_params) +#define TARGET_SNDRV_TIMER_IOCTL_STATUS TARGET_IOR('T', 0x14, \ + struct target_snd_timer_status) /* vfat ioctls */ #define TARGET_VFAT_IOCTL_READDIR_BOTH TARGET_IORU('r', 1) diff --git a/linux-user/syscall_types.h b/linux-user/syscall_types.h index 81bc719382..4e12c1661e 100644 --- a/linux-user/syscall_types.h +++ b/linux-user/syscall_types.h @@ -120,6 +120,35 @@ STRUCT(snd_timer_select, MK_STRUCT(STRUCT_snd_timer_id), /* id */ MK_ARRAY(TYPE_CHAR, 32)) /* reserved */ +STRUCT(snd_timer_info, + TYPE_INT, /* flags */ + TYPE_INT, /* card */ + MK_ARRAY(TYPE_CHAR, 64), /* id */ + MK_ARRAY(TYPE_CHAR, 80), /* name */ + TYPE_ULONG, /* reserved0 */ + TYPE_ULONG, /* resolution */ + MK_ARRAY(TYPE_CHAR, 64)) /* reserved */ + +STRUCT(snd_timer_params, + TYPE_INT, /* flags */ + TYPE_INT, /* ticks */ + TYPE_INT, /* queue_size */ + TYPE_INT, /* reserved0 */ + TYPE_INT, /* filter */ + MK_ARRAY(TYPE_CHAR, 60)) /* reserved */ + +STRUCT(timespec, + TYPE_LONG, /* tv_sec */ + TYPE_LONG) /* tv_nsec */ + +STRUCT(snd_timer_status, + MK_STRUCT(STRUCT_timespec), /* tstamp */ + TYPE_INT, /* resolution */ + TYPE_INT, /* lost */ + TYPE_INT, /* overrun */ + TYPE_INT, /* queue */ + MK_ARRAY(TYPE_CHAR, 64)) /* reserved */ + /* loop device ioctls */ STRUCT(loop_info, TYPE_INT, /* lo_number */