diff options
author | Takashi Iwai <tiwai@suse.de> | 2005-02-11 16:35:24 +0000 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2005-02-11 16:35:24 +0000 |
commit | f9b9015245178df34454853c2dd74288ed16a136 (patch) | |
tree | 171f7bd36d4fd3268b543dfe2b6a5a8701f9c388 /src/seq | |
parent | 237d46cfb6999614b91dc57ce0e90db2c73f9104 (diff) |
Fix resmgr support
Call normal open() before trying with res_open_device().
snd_open_device() is defined to do this procedure.
Diffstat (limited to 'src/seq')
-rw-r--r-- | src/seq/seq_hw.c | 21 |
1 files changed, 3 insertions, 18 deletions
diff --git a/src/seq/seq_hw.c b/src/seq/seq_hw.c index d1b3a336..7c2c4812 100644 --- a/src/seq/seq_hw.c +++ b/src/seq/seq_hw.c @@ -23,9 +23,6 @@ #include <fcntl.h> #include <sys/ioctl.h> #include "seq_local.h" -#ifdef SUPPORT_RESMGR -#include <resmgr.h> -#endif #ifndef PIC /* entry for static linking */ @@ -443,24 +440,12 @@ int snd_seq_hw_open(snd_seq_t **handle, const char *name, int streams, int mode) fmode |= O_NONBLOCK; filename = SNDRV_FILE_SEQ; -#ifdef SUPPORT_RESMGR - fd = rsm_open_device(filename, fmode); -#else - fd = open(filename, fmode); -#endif + fd = snd_open_device(filename, fmode); if (fd < 0) { -#ifdef SUPPORT_RESMGR - fd = open(SNDRV_FILE_ALOADSEQ, O_RDWR); -#else - fd = open(SNDRV_FILE_ALOADSEQ, fmode); -#endif + fd = snd_open_device(SNDRV_FILE_ALOADSEQ, fmode); if (fd >= 0) close(fd); -#ifdef SUPPORT_RESMGR - fd = rsm_open_device(filename, fmode); -#else - fd = open(filename, fmode); -#endif + fd = snd_open_device(filename, fmode); if (fd < 0) { SYSERR("open %s failed", filename); return -errno; |