]> git.alsa-project.org Git - alsa-lib.git/commitdiff
Added snd_hwdep_ioctl function.
authorJaroslav Kysela <perex@perex.cz>
Tue, 11 Jan 2000 17:35:50 +0000 (17:35 +0000)
committerJaroslav Kysela <perex@perex.cz>
Tue, 11 Jan 2000 17:35:50 +0000 (17:35 +0000)
include/hwdep.h
src/hwdep/hwdep.c

index ad62dd652aef717c4d2be49db35f4f39d8082ae3..81918192608349c989a162ce55fc19cf6dd85cbf 100644 (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);
 
index c5544aab5db8eca7c1ab1a0c2589db0ef1f69cae..22e6001c6388e7bb4cfe4ffa759f8ca69a20277c 100644 (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;