diff options
Diffstat (limited to 'sound/parisc/harmony.c')
| -rw-r--r-- | sound/parisc/harmony.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/sound/parisc/harmony.c b/sound/parisc/harmony.c index e924492df21d..f47f9e226b08 100644 --- a/sound/parisc/harmony.c +++ b/sound/parisc/harmony.c | |||
| @@ -624,6 +624,9 @@ snd_harmony_pcm_init(struct snd_harmony *h) | |||
| 624 | struct snd_pcm *pcm; | 624 | struct snd_pcm *pcm; |
| 625 | int err; | 625 | int err; |
| 626 | 626 | ||
| 627 | if (snd_BUG_ON(!h)) | ||
| 628 | return -EINVAL; | ||
| 629 | |||
| 627 | harmony_disable_interrupts(h); | 630 | harmony_disable_interrupts(h); |
| 628 | 631 | ||
| 629 | err = snd_pcm_new(h->card, "harmony", 0, 1, 1, &pcm); | 632 | err = snd_pcm_new(h->card, "harmony", 0, 1, 1, &pcm); |
| @@ -865,11 +868,12 @@ snd_harmony_mixer_reset(struct snd_harmony *h) | |||
| 865 | static int __devinit | 868 | static int __devinit |
| 866 | snd_harmony_mixer_init(struct snd_harmony *h) | 869 | snd_harmony_mixer_init(struct snd_harmony *h) |
| 867 | { | 870 | { |
| 868 | struct snd_card *card = h->card; | 871 | struct snd_card *card; |
| 869 | int idx, err; | 872 | int idx, err; |
| 870 | 873 | ||
| 871 | if (snd_BUG_ON(!h)) | 874 | if (snd_BUG_ON(!h)) |
| 872 | return -EINVAL; | 875 | return -EINVAL; |
| 876 | card = h->card; | ||
| 873 | strcpy(card->mixername, "Harmony Gain control interface"); | 877 | strcpy(card->mixername, "Harmony Gain control interface"); |
| 874 | 878 | ||
| 875 | for (idx = 0; idx < HARMONY_CONTROLS; idx++) { | 879 | for (idx = 0; idx < HARMONY_CONTROLS; idx++) { |
