aboutsummaryrefslogtreecommitdiffstats
path: root/sound/sparc/cs4231.c
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2014-01-29 08:41:09 -0500
committerTakashi Iwai <tiwai@suse.de>2014-02-14 02:14:07 -0500
commita2fefc35a99f684b4ba15d243995170fa23bdd7e (patch)
treea9d3cf0de672a70b06f49e9f99b43988508972f0 /sound/sparc/cs4231.c
parente7182ac5a3de8836a7b03655a5b8d6b71873fcbc (diff)
ALSA: sparc: Convert to snd_card_new() with a device pointer
Also remove superfluous snd_card_set_dev() calls. Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/sparc/cs4231.c')
-rw-r--r--sound/sparc/cs4231.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/sound/sparc/cs4231.c b/sound/sparc/cs4231.c
index dbb1b625eb2f..4e91bcaa3664 100644
--- a/sound/sparc/cs4231.c
+++ b/sound/sparc/cs4231.c
@@ -1565,7 +1565,8 @@ static int snd_cs4231_mixer(struct snd_card *card)
1565 1565
1566static int dev; 1566static int dev;
1567 1567
1568static int cs4231_attach_begin(struct snd_card **rcard) 1568static int cs4231_attach_begin(struct platform_device *op,
1569 struct snd_card **rcard)
1569{ 1570{
1570 struct snd_card *card; 1571 struct snd_card *card;
1571 struct snd_cs4231 *chip; 1572 struct snd_cs4231 *chip;
@@ -1581,8 +1582,8 @@ static int cs4231_attach_begin(struct snd_card **rcard)
1581 return -ENOENT; 1582 return -ENOENT;
1582 } 1583 }
1583 1584
1584 err = snd_card_create(index[dev], id[dev], THIS_MODULE, 1585 err = snd_card_new(&op->dev, index[dev], id[dev], THIS_MODULE,
1585 sizeof(struct snd_cs4231), &card); 1586 sizeof(struct snd_cs4231), &card);
1586 if (err < 0) 1587 if (err < 0)
1587 return err; 1588 return err;
1588 1589
@@ -1869,7 +1870,7 @@ static int cs4231_sbus_probe(struct platform_device *op)
1869 struct snd_card *card; 1870 struct snd_card *card;
1870 int err; 1871 int err;
1871 1872
1872 err = cs4231_attach_begin(&card); 1873 err = cs4231_attach_begin(op, &card);
1873 if (err) 1874 if (err)
1874 return err; 1875 return err;
1875 1876
@@ -2060,7 +2061,7 @@ static int cs4231_ebus_probe(struct platform_device *op)
2060 struct snd_card *card; 2061 struct snd_card *card;
2061 int err; 2062 int err;
2062 2063
2063 err = cs4231_attach_begin(&card); 2064 err = cs4231_attach_begin(op, &card);
2064 if (err) 2065 if (err)
2065 return err; 2066 return err;
2066 2067