diff options
Diffstat (limited to 'sound/pci/cmipci.c')
-rw-r--r-- | sound/pci/cmipci.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/sound/pci/cmipci.c b/sound/pci/cmipci.c index 9971b5b7735b..1a74ca62c314 100644 --- a/sound/pci/cmipci.c +++ b/sound/pci/cmipci.c | |||
@@ -2357,7 +2357,8 @@ static int snd_cmipci_uswitch_get(struct snd_kcontrol *kcontrol, | |||
2357 | { | 2357 | { |
2358 | struct cmipci_switch_args *args; | 2358 | struct cmipci_switch_args *args; |
2359 | args = (struct cmipci_switch_args *)kcontrol->private_value; | 2359 | args = (struct cmipci_switch_args *)kcontrol->private_value; |
2360 | snd_assert(args != NULL, return -EINVAL); | 2360 | if (snd_BUG_ON(!args)) |
2361 | return -EINVAL; | ||
2361 | return _snd_cmipci_uswitch_get(kcontrol, ucontrol, args); | 2362 | return _snd_cmipci_uswitch_get(kcontrol, ucontrol, args); |
2362 | } | 2363 | } |
2363 | 2364 | ||
@@ -2401,7 +2402,8 @@ static int snd_cmipci_uswitch_put(struct snd_kcontrol *kcontrol, | |||
2401 | { | 2402 | { |
2402 | struct cmipci_switch_args *args; | 2403 | struct cmipci_switch_args *args; |
2403 | args = (struct cmipci_switch_args *)kcontrol->private_value; | 2404 | args = (struct cmipci_switch_args *)kcontrol->private_value; |
2404 | snd_assert(args != NULL, return -EINVAL); | 2405 | if (snd_BUG_ON(!args)) |
2406 | return -EINVAL; | ||
2405 | return _snd_cmipci_uswitch_put(kcontrol, ucontrol, args); | 2407 | return _snd_cmipci_uswitch_put(kcontrol, ucontrol, args); |
2406 | } | 2408 | } |
2407 | 2409 | ||
@@ -2662,7 +2664,8 @@ static int __devinit snd_cmipci_mixer_new(struct cmipci *cm, int pcm_spdif_devic | |||
2662 | unsigned int idx; | 2664 | unsigned int idx; |
2663 | int err; | 2665 | int err; |
2664 | 2666 | ||
2665 | snd_assert(cm != NULL && cm->card != NULL, return -EINVAL); | 2667 | if (snd_BUG_ON(!cm || !cm->card)) |
2668 | return -EINVAL; | ||
2666 | 2669 | ||
2667 | card = cm->card; | 2670 | card = cm->card; |
2668 | 2671 | ||