aboutsummaryrefslogtreecommitdiff
path: root/sound/synth/emux/emux_seq.c
diff options
context:
space:
mode:
authorArjan van de Ven <arjan@linux.intel.com>2008-10-17 09:20:26 -0700
committerArjan van de Ven <arjan@linux.intel.com>2008-10-17 09:20:26 -0700
commit651dab4264e4ba0e563f5ff56f748127246e9065 (patch)
tree016630974bdcb00fe529b673f96d389e0fd6dc94 /sound/synth/emux/emux_seq.c
parent40b8606253552109815786e5d4b0de98782d31f5 (diff)
parent2e532d68a2b3e2aa6b19731501222069735c741c (diff)
Merge commit 'linus/master' into merge-linus
Conflicts: arch/x86/kvm/i8254.c
Diffstat (limited to 'sound/synth/emux/emux_seq.c')
-rw-r--r--sound/synth/emux/emux_seq.c15
1 files changed, 10 insertions, 5 deletions
diff --git a/sound/synth/emux/emux_seq.c b/sound/synth/emux/emux_seq.c
index d176cc01742..335aa2ce257 100644
--- a/sound/synth/emux/emux_seq.c
+++ b/sound/synth/emux/emux_seq.c
@@ -257,7 +257,8 @@ snd_emux_event_input(struct snd_seq_event *ev, int direct, void *private_data,
struct snd_emux_port *port;
port = private_data;
- snd_assert(port != NULL && ev != NULL, return -EINVAL);
+ if (snd_BUG_ON(!port || !ev))
+ return -EINVAL;
snd_midi_process_event(&emux_ops, ev, &port->chset);
@@ -308,9 +309,11 @@ snd_emux_use(void *private_data, struct snd_seq_port_subscribe *info)
struct snd_emux *emu;
p = private_data;
- snd_assert(p != NULL, return -EINVAL);
+ if (snd_BUG_ON(!p))
+ return -EINVAL;
emu = p->emu;
- snd_assert(emu != NULL, return -EINVAL);
+ if (snd_BUG_ON(!emu))
+ return -EINVAL;
mutex_lock(&emu->register_mutex);
snd_emux_init_port(p);
@@ -329,9 +332,11 @@ snd_emux_unuse(void *private_data, struct snd_seq_port_subscribe *info)
struct snd_emux *emu;
p = private_data;
- snd_assert(p != NULL, return -EINVAL);
+ if (snd_BUG_ON(!p))
+ return -EINVAL;
emu = p->emu;
- snd_assert(emu != NULL, return -EINVAL);
+ if (snd_BUG_ON(!emu))
+ return -EINVAL;
mutex_lock(&emu->register_mutex);
snd_emux_sounds_off_all(p);