summaryrefslogtreecommitdiffstats
path: root/sound/pci/ice1712/ews.c
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2008-10-11 12:39:35 -0700
committerDavid S. Miller <davem@davemloft.net>2008-10-11 12:39:35 -0700
commit56c5d900dbb8e042bfad035d18433476931d8f93 (patch)
tree00b793965beeef10db03e0ff021d2d965c410759 /sound/pci/ice1712/ews.c
parent4dd95b63ae25c5cad6986829b5e8788e9faa0330 (diff)
parentead9d23d803ea3a73766c3cb27bf7563ac8d7266 (diff)
downloadop-kernel-dev-56c5d900dbb8e042bfad035d18433476931d8f93.zip
op-kernel-dev-56c5d900dbb8e042bfad035d18433476931d8f93.tar.gz
Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/torvalds/linux-2.6
Conflicts: sound/core/memalloc.c
Diffstat (limited to 'sound/pci/ice1712/ews.c')
-rw-r--r--sound/pci/ice1712/ews.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/sound/pci/ice1712/ews.c b/sound/pci/ice1712/ews.c
index 013fc4f..6fe35b8 100644
--- a/sound/pci/ice1712/ews.c
+++ b/sound/pci/ice1712/ews.c
@@ -149,7 +149,8 @@ static int snd_ice1712_ews88mt_chip_select(struct snd_ice1712 *ice, int chip_mas
struct ews_spec *spec = ice->spec;
unsigned char data, ndata;
- snd_assert(chip_mask >= 0 && chip_mask <= 0x0f, return -EINVAL);
+ if (snd_BUG_ON(chip_mask < 0 || chip_mask > 0x0f))
+ return -EINVAL;
snd_i2c_lock(ice->i2c);
if (snd_i2c_readbytes(spec->i2cdevs[EWS_I2C_PCF2], &data, 1) != 1)
goto __error;
@@ -685,7 +686,8 @@ static int snd_ice1712_ews88mt_input_sense_get(struct snd_kcontrol *kcontrol, st
int channel = snd_ctl_get_ioffidx(kcontrol, &ucontrol->id);
unsigned char data;
- snd_assert(channel >= 0 && channel <= 7, return 0);
+ if (snd_BUG_ON(channel < 0 || channel > 7))
+ return 0;
snd_i2c_lock(ice->i2c);
if (snd_i2c_readbytes(spec->i2cdevs[EWS_I2C_PCF1], &data, 1) != 1) {
snd_i2c_unlock(ice->i2c);
@@ -705,7 +707,8 @@ static int snd_ice1712_ews88mt_input_sense_put(struct snd_kcontrol *kcontrol, st
int channel = snd_ctl_get_ioffidx(kcontrol, &ucontrol->id);
unsigned char data, ndata;
- snd_assert(channel >= 0 && channel <= 7, return 0);
+ if (snd_BUG_ON(channel < 0 || channel > 7))
+ return 0;
snd_i2c_lock(ice->i2c);
if (snd_i2c_readbytes(spec->i2cdevs[EWS_I2C_PCF1], &data, 1) != 1) {
snd_i2c_unlock(ice->i2c);
OpenPOWER on IntegriCloud