diff options
author | Takashi Iwai <tiwai@suse.de> | 2008-08-08 11:12:14 -0400 |
---|---|---|
committer | Jaroslav Kysela <perex@perex.cz> | 2008-08-13 05:46:38 -0400 |
commit | da3cec35dd3c31d8706db4bf379372ce70d92118 (patch) | |
tree | 9379edebb1c7abc7a7a92ce3be30a35b77d9aa1d /sound/pci/ad1889.c | |
parent | 622207dc31895b4e82c39100db8635d885c795e2 (diff) |
ALSA: Kill snd_assert() in sound/pci/*
Kill snd_assert() in sound/pci/*, either removed or replaced with
if () with snd_BUG_ON().
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Diffstat (limited to 'sound/pci/ad1889.c')
-rw-r--r-- | sound/pci/ad1889.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/sound/pci/ad1889.c b/sound/pci/ad1889.c index 39ec55b57b1e..92f3a976ef2e 100644 --- a/sound/pci/ad1889.c +++ b/sound/pci/ad1889.c | |||
@@ -549,7 +549,8 @@ snd_ad1889_playback_pointer(struct snd_pcm_substream *ss) | |||
549 | ptr = ad1889_readl(chip, AD_DMA_WAVCA); | 549 | ptr = ad1889_readl(chip, AD_DMA_WAVCA); |
550 | ptr -= chip->wave.addr; | 550 | ptr -= chip->wave.addr; |
551 | 551 | ||
552 | snd_assert((ptr >= 0) && (ptr < chip->wave.size), return 0); | 552 | if (snd_BUG_ON(ptr >= chip->wave.size)) |
553 | return 0; | ||
553 | 554 | ||
554 | return bytes_to_frames(ss->runtime, ptr); | 555 | return bytes_to_frames(ss->runtime, ptr); |
555 | } | 556 | } |
@@ -567,7 +568,8 @@ snd_ad1889_capture_pointer(struct snd_pcm_substream *ss) | |||
567 | ptr = ad1889_readl(chip, AD_DMA_ADCCA); | 568 | ptr = ad1889_readl(chip, AD_DMA_ADCCA); |
568 | ptr -= chip->ramc.addr; | 569 | ptr -= chip->ramc.addr; |
569 | 570 | ||
570 | snd_assert((ptr >= 0) && (ptr < chip->ramc.size), return 0); | 571 | if (snd_BUG_ON(ptr >= chip->ramc.size)) |
572 | return 0; | ||
571 | 573 | ||
572 | return bytes_to_frames(ss->runtime, ptr); | 574 | return bytes_to_frames(ss->runtime, ptr); |
573 | } | 575 | } |