aboutsummaryrefslogtreecommitdiffstats
path: root/sound/isa
diff options
context:
space:
mode:
authorLars-Peter Clausen <lars@metafoo.de>2015-01-02 06:24:40 -0500
committerTakashi Iwai <tiwai@suse.de>2015-01-02 10:28:04 -0500
commitf6be4e624aa26699a9a89bc24089e88a227141c1 (patch)
tree68b70e9e4e350453ddfa038e12bee19154cac110 /sound/isa
parentdb5abb3c499e553a8afedee1417d6a6308dda7bd (diff)
ALSA: msnd: Remove always NULL parameter
snd_msnd_pcm() takes a pointer to a pointer of a PCM where if this parameter is provided the newly allocated PCM is stored. All callers pass NULL though, so remove the parameter. This makes the code a bit cleaner and shorter. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/isa')
-rw-r--r--sound/isa/msnd/msnd.c6
-rw-r--r--sound/isa/msnd/msnd.h2
-rw-r--r--sound/isa/msnd/msnd_pinnacle.c2
3 files changed, 3 insertions, 7 deletions
diff --git a/sound/isa/msnd/msnd.c b/sound/isa/msnd/msnd.c
index 1cee18fb28a8..835d4aa26761 100644
--- a/sound/isa/msnd/msnd.c
+++ b/sound/isa/msnd/msnd.c
@@ -679,8 +679,7 @@ static struct snd_pcm_ops snd_msnd_capture_ops = {
679}; 679};
680 680
681 681
682int snd_msnd_pcm(struct snd_card *card, int device, 682int snd_msnd_pcm(struct snd_card *card, int device)
683 struct snd_pcm **rpcm)
684{ 683{
685 struct snd_msnd *chip = card->private_data; 684 struct snd_msnd *chip = card->private_data;
686 struct snd_pcm *pcm; 685 struct snd_pcm *pcm;
@@ -696,9 +695,6 @@ int snd_msnd_pcm(struct snd_card *card, int device,
696 pcm->private_data = chip; 695 pcm->private_data = chip;
697 strcpy(pcm->name, "Hurricane"); 696 strcpy(pcm->name, "Hurricane");
698 697
699
700 if (rpcm)
701 *rpcm = pcm;
702 return 0; 698 return 0;
703} 699}
704EXPORT_SYMBOL(snd_msnd_pcm); 700EXPORT_SYMBOL(snd_msnd_pcm);
diff --git a/sound/isa/msnd/msnd.h b/sound/isa/msnd/msnd.h
index dbac3a42347b..5f3c7dcd9f9d 100644
--- a/sound/isa/msnd/msnd.h
+++ b/sound/isa/msnd/msnd.h
@@ -297,7 +297,7 @@ int snd_msnd_disable_irq(struct snd_msnd *chip);
297void snd_msnd_dsp_halt(struct snd_msnd *chip, struct file *file); 297void snd_msnd_dsp_halt(struct snd_msnd *chip, struct file *file);
298int snd_msnd_DAPQ(struct snd_msnd *chip, int start); 298int snd_msnd_DAPQ(struct snd_msnd *chip, int start);
299int snd_msnd_DARQ(struct snd_msnd *chip, int start); 299int snd_msnd_DARQ(struct snd_msnd *chip, int start);
300int snd_msnd_pcm(struct snd_card *card, int device, struct snd_pcm **rpcm); 300int snd_msnd_pcm(struct snd_card *card, int device);
301 301
302int snd_msndmidi_new(struct snd_card *card, int device); 302int snd_msndmidi_new(struct snd_card *card, int device);
303void snd_msndmidi_input_read(void *mpu); 303void snd_msndmidi_input_read(void *mpu);
diff --git a/sound/isa/msnd/msnd_pinnacle.c b/sound/isa/msnd/msnd_pinnacle.c
index 5016bf957f51..65b36825d194 100644
--- a/sound/isa/msnd/msnd_pinnacle.c
+++ b/sound/isa/msnd/msnd_pinnacle.c
@@ -582,7 +582,7 @@ static int snd_msnd_attach(struct snd_card *card)
582 if (err < 0) 582 if (err < 0)
583 goto err_release_region; 583 goto err_release_region;
584 584
585 err = snd_msnd_pcm(card, 0, NULL); 585 err = snd_msnd_pcm(card, 0);
586 if (err < 0) { 586 if (err < 0) {
587 printk(KERN_ERR LOGNAME ": error creating new PCM device\n"); 587 printk(KERN_ERR LOGNAME ": error creating new PCM device\n");
588 goto err_release_region; 588 goto err_release_region;