From 82753c8a0c338f489a20e0554eac589a390ac6bb Mon Sep 17 00:00:00 2001 From: Mauro Carvalho Chehab Date: Tue, 14 Apr 2009 11:02:14 -0300 Subject: backport commit 758021bfa9ea25c58e62d2f68512628b19502ce7 From: Mauro Carvalho Chehab Author: Takashi Iwai Date: Mon Jan 12 15:17:09 2009 +0100 drivers/media: Convert to snd_card_create() Convert from snd_card_new() to the new snd_card_create() function. While here, backport also cx231xx-audio upstream changes for using snd_card_create(). kernel-sync: Priority: normal Signed-off-by: Mauro Carvalho Chehab --- linux/drivers/media/video/cx231xx/cx231xx-audio.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'linux/drivers/media/video/cx231xx/cx231xx-audio.c') diff --git a/linux/drivers/media/video/cx231xx/cx231xx-audio.c b/linux/drivers/media/video/cx231xx/cx231xx-audio.c index 0f7fb3ca7..3a060a746 100644 --- a/linux/drivers/media/video/cx231xx/cx231xx-audio.c +++ b/linux/drivers/media/video/cx231xx/cx231xx-audio.c @@ -560,9 +560,10 @@ static int cx231xx_audio_init(struct cx231xx *dev) cx231xx_info("cx231xx-audio.c: probing for cx231xx " "non standard usbaudio\n"); - card = snd_card_new(index[devnr], "Cx231xx Audio", THIS_MODULE, 0); - if (card == NULL) - return -ENOMEM; + err = snd_card_create(index[devnr], "Cx231xx Audio", THIS_MODULE, + 0, &card); + if (err < 0) + return err; spin_lock_init(&adev->slock); err = snd_pcm_new(card, "Cx231xx Audio", 0, 0, 1, &pcm); -- cgit v1.2.3