summaryrefslogtreecommitdiffstats
path: root/sound/spi/at73c213.c
diff options
context:
space:
mode:
Diffstat (limited to 'sound/spi/at73c213.c')
-rw-r--r--sound/spi/at73c213.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/sound/spi/at73c213.c b/sound/spi/at73c213.c
index 09802e8..4c7b051 100644
--- a/sound/spi/at73c213.c
+++ b/sound/spi/at73c213.c
@@ -965,12 +965,11 @@ static int __devinit snd_at73c213_probe(struct spi_device *spi)
return PTR_ERR(board->dac_clk);
}
- retval = -ENOMEM;
-
/* Allocate "card" using some unused identifiers. */
snprintf(id, sizeof id, "at73c213_%d", board->ssc_id);
- card = snd_card_new(-1, id, THIS_MODULE, sizeof(struct snd_at73c213));
- if (!card)
+ retval = snd_card_create(-1, id, THIS_MODULE,
+ sizeof(struct snd_at73c213), &card);
+ if (retval < 0)
goto out;
chip = card->private_data;
OpenPOWER on IntegriCloud