Replace snd_card_create with snd_card_new.
snd_card_create depcrecated starting form v3.15
Signed-off-by: Badhri Jagan Sridharan <Badhri@google.com>
Change-Id: I76f7d753812963d595055bce7d3e6518163482f5
audio = &_audio_dev;
- err = snd_card_create(SNDRV_DEFAULT_IDX1, SNDRV_DEFAULT_STR1,
+ err = snd_card_new(&c->cdev->gadget->dev,
+ SNDRV_DEFAULT_IDX1, SNDRV_DEFAULT_STR1,
THIS_MODULE, 0, &card);
if (err)
return err;
- snd_card_set_dev(card, &c->cdev->gadget->dev);
-
err = snd_pcm_new(card, "USB audio source", 0, 1, 0, &pcm);
if (err)
goto pcm_fail;
+
pcm->private_data = audio;
pcm->info_flags = 0;
audio->pcm = pcm;