Added snd_hwdep_ioctl function.

This commit is contained in:
Jaroslav Kysela 2000-01-11 17:35:50 +00:00
parent 6ab3208c1d
commit be2d24f3e7
2 changed files with 10 additions and 0 deletions

View file

@ -21,6 +21,7 @@ int snd_hwdep_close(snd_hwdep_t *handle);
int snd_hwdep_file_descriptor(snd_hwdep_t *handle);
int snd_hwdep_block_mode(snd_hwdep_t *handle, int enable);
int snd_hwdep_info(snd_hwdep_t *handle, snd_hwdep_info_t * info);
int snd_hwdep_ioctl(snd_hwdep_t *handle, int request, void * arg);
ssize_t snd_hwdep_write(snd_hwdep_t *handle, const void *buffer, size_t size);
ssize_t snd_hwdep_read(snd_hwdep_t *handle, void *buffer, size_t size);

View file

@ -119,6 +119,15 @@ int snd_hwdep_info(snd_hwdep_t *hwdep, snd_hwdep_info_t * info)
return 0;
}
int snd_hwdep_ioctl(snd_hwdep_t *hwdep, int request, void * arg)
{
if (!hwdep)
return -EINVAL;
if (ioctl(hwdep->fd, request, arg) < 0)
return -errno;
return 0;
}
ssize_t snd_hwdep_write(snd_hwdep_t *hwdep, const void *buffer, size_t size)
{
ssize_t result;