Commit a2fefc35 authored by Takashi Iwai's avatar Takashi Iwai

ALSA: sparc: Convert to snd_card_new() with a device pointer

Also remove superfluous snd_card_set_dev() calls.
Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
parent e7182ac5
...@@ -1019,8 +1019,8 @@ static int amd7930_sbus_probe(struct platform_device *op) ...@@ -1019,8 +1019,8 @@ static int amd7930_sbus_probe(struct platform_device *op)
return -ENOENT; return -ENOENT;
} }
err = snd_card_create(index[dev_num], id[dev_num], THIS_MODULE, 0, err = snd_card_new(&op->dev, index[dev_num], id[dev_num],
&card); THIS_MODULE, 0, &card);
if (err < 0) if (err < 0)
return err; return err;
......
...@@ -1565,7 +1565,8 @@ static int snd_cs4231_mixer(struct snd_card *card) ...@@ -1565,7 +1565,8 @@ static int snd_cs4231_mixer(struct snd_card *card)
static int dev; static int dev;
static int cs4231_attach_begin(struct snd_card **rcard) static int cs4231_attach_begin(struct platform_device *op,
struct snd_card **rcard)
{ {
struct snd_card *card; struct snd_card *card;
struct snd_cs4231 *chip; struct snd_cs4231 *chip;
...@@ -1581,8 +1582,8 @@ static int cs4231_attach_begin(struct snd_card **rcard) ...@@ -1581,8 +1582,8 @@ static int cs4231_attach_begin(struct snd_card **rcard)
return -ENOENT; return -ENOENT;
} }
err = snd_card_create(index[dev], id[dev], THIS_MODULE, err = snd_card_new(&op->dev, index[dev], id[dev], THIS_MODULE,
sizeof(struct snd_cs4231), &card); sizeof(struct snd_cs4231), &card);
if (err < 0) if (err < 0)
return err; return err;
...@@ -1869,7 +1870,7 @@ static int cs4231_sbus_probe(struct platform_device *op) ...@@ -1869,7 +1870,7 @@ static int cs4231_sbus_probe(struct platform_device *op)
struct snd_card *card; struct snd_card *card;
int err; int err;
err = cs4231_attach_begin(&card); err = cs4231_attach_begin(op, &card);
if (err) if (err)
return err; return err;
...@@ -2060,7 +2061,7 @@ static int cs4231_ebus_probe(struct platform_device *op) ...@@ -2060,7 +2061,7 @@ static int cs4231_ebus_probe(struct platform_device *op)
struct snd_card *card; struct snd_card *card;
int err; int err;
err = cs4231_attach_begin(&card); err = cs4231_attach_begin(op, &card);
if (err) if (err)
return err; return err;
......
...@@ -2615,8 +2615,8 @@ static int dbri_probe(struct platform_device *op) ...@@ -2615,8 +2615,8 @@ static int dbri_probe(struct platform_device *op)
return -ENODEV; return -ENODEV;
} }
err = snd_card_create(index[dev], id[dev], THIS_MODULE, err = snd_card_new(&op->dev, index[dev], id[dev], THIS_MODULE,
sizeof(struct snd_dbri), &card); sizeof(struct snd_dbri), &card);
if (err < 0) if (err < 0)
return err; return err;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment