diff options
author | Lars-Peter Clausen <lars@metafoo.de> | 2015-01-02 12:24:36 +0100 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2015-01-02 16:26:20 +0100 |
commit | 7f605418837add961466dc66f7370332d44c1a92 (patch) | |
tree | f12dd6b0429e92d38c477b151ca47867379665e1 /sound/isa/ad1816a/ad1816a_lib.c | |
parent | e9dd86267f2571a9649399c9e268266ca5aa6152 (diff) | |
download | talos-obmc-linux-7f605418837add961466dc66f7370332d44c1a92.tar.gz talos-obmc-linux-7f605418837add961466dc66f7370332d44c1a92.zip |
ALSA: ad1816a: Remove always NULL parameters
snd_ad1816a_pcm() and snd_ad1816a_timer() take a pointer to a pointer of a
PCM/timer where if this parameter is provided the newly allocated object 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/ad1816a/ad1816a_lib.c')
-rw-r--r-- | sound/isa/ad1816a/ad1816a_lib.c | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/sound/isa/ad1816a/ad1816a_lib.c b/sound/isa/ad1816a/ad1816a_lib.c index 01a07986f4a3..5f99102cc0c1 100644 --- a/sound/isa/ad1816a/ad1816a_lib.c +++ b/sound/isa/ad1816a/ad1816a_lib.c @@ -675,7 +675,7 @@ static struct snd_pcm_ops snd_ad1816a_capture_ops = { .pointer = snd_ad1816a_capture_pointer, }; -int snd_ad1816a_pcm(struct snd_ad1816a *chip, int device, struct snd_pcm **rpcm) +int snd_ad1816a_pcm(struct snd_ad1816a *chip, int device) { int error; struct snd_pcm *pcm; @@ -697,13 +697,10 @@ int snd_ad1816a_pcm(struct snd_ad1816a *chip, int device, struct snd_pcm **rpcm) 64*1024, chip->dma1 > 3 || chip->dma2 > 3 ? 128*1024 : 64*1024); chip->pcm = pcm; - if (rpcm) - *rpcm = pcm; return 0; } -int snd_ad1816a_timer(struct snd_ad1816a *chip, int device, - struct snd_timer **rtimer) +int snd_ad1816a_timer(struct snd_ad1816a *chip, int device) { struct snd_timer *timer; struct snd_timer_id tid; @@ -720,8 +717,6 @@ int snd_ad1816a_timer(struct snd_ad1816a *chip, int device, timer->private_data = chip; chip->timer = timer; timer->hw = snd_ad1816a_timer_table; - if (rtimer) - *rtimer = timer; return 0; } |