aboutsummaryrefslogtreecommitdiffstats
path: root/sound/pci
diff options
context:
space:
mode:
authorHarvey Harrison <harvey.harrison@gmail.com>2008-02-29 05:41:56 -0500
committerTakashi Iwai <tiwai@suse.de>2008-04-24 06:00:17 -0400
commit3fa4a9073886a1031400c19e8b09fca3eebb645f (patch)
treead9d7b20152b5ebbeae2df47ac28de7e6c3ffc07 /sound/pci
parent470f23b873679b045908551302fec6b1edf05a5a (diff)
[ALSA] sound: au88x0_pcm.c fix integer as NULL pointer warning
sound/pci/au88x0/au88x0_pcm.c:508:15: warning: Using plain integer as NULL pointer Also some small codingstyle fixes. Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/pci')
-rw-r--r--sound/pci/au88x0/au88x0_pcm.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/sound/pci/au88x0/au88x0_pcm.c b/sound/pci/au88x0/au88x0_pcm.c
index 526c6c5ecf7b..f9a58b4a30eb 100644
--- a/sound/pci/au88x0/au88x0_pcm.c
+++ b/sound/pci/au88x0/au88x0_pcm.c
@@ -498,14 +498,14 @@ static struct snd_kcontrol_new snd_vortex_mixer_spdif[] __devinitdata = {
498}; 498};
499 499
500/* create a pcm device */ 500/* create a pcm device */
501static int __devinit snd_vortex_new_pcm(vortex_t * chip, int idx, int nr) 501static int __devinit snd_vortex_new_pcm(vortex_t *chip, int idx, int nr)
502{ 502{
503 struct snd_pcm *pcm; 503 struct snd_pcm *pcm;
504 struct snd_kcontrol *kctl; 504 struct snd_kcontrol *kctl;
505 int i; 505 int i;
506 int err, nr_capt; 506 int err, nr_capt;
507 507
508 if ((chip == 0) || (idx < 0) || (idx >= VORTEX_PCM_LAST)) 508 if (!chip || idx < 0 || idx >= VORTEX_PCM_LAST)
509 return -ENODEV; 509 return -ENODEV;
510 510
511 /* idx indicates which kind of PCM device. ADB, SPDIF, I2S and A3D share the 511 /* idx indicates which kind of PCM device. ADB, SPDIF, I2S and A3D share the
@@ -514,9 +514,9 @@ static int __devinit snd_vortex_new_pcm(vortex_t * chip, int idx, int nr)
514 nr_capt = nr; 514 nr_capt = nr;
515 else 515 else
516 nr_capt = 0; 516 nr_capt = 0;
517 if ((err = 517 err = snd_pcm_new(chip->card, vortex_pcm_prettyname[idx], idx, nr,
518 snd_pcm_new(chip->card, vortex_pcm_prettyname[idx], idx, nr, 518 nr_capt, &pcm);
519 nr_capt, &pcm)) < 0) 519 if (err < 0)
520 return err; 520 return err;
521 strcpy(pcm->name, vortex_pcm_name[idx]); 521 strcpy(pcm->name, vortex_pcm_name[idx]);
522 chip->pcm[idx] = pcm; 522 chip->pcm[idx] = pcm;