]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commitdiff
staging: most: sound: pass correct device when creating a sound card
authorChristian Gromm <christian.gromm@microchip.com>
Tue, 30 Apr 2019 12:07:48 +0000 (14:07 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 30 Apr 2019 12:34:06 +0000 (14:34 +0200)
This patch fixes the usage of the wrong struct device when calling
function snd_card_new.

Reported-by: Eugeniu Rosca <erosca@de.adit-jv.com>
Signed-off-by: Christian Gromm <christian.gromm@microchip.com>
Fixes: 69c90cf1b2fa ("staging: most: sound: call snd_card_new with struct device")
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/most/sound/sound.c

index 7c998673a6f8299f67d40b789568596148b1d486..342f390d68b36739b2fa4953223863b9ed596e0f 100644 (file)
@@ -613,7 +613,7 @@ static int audio_probe_channel(struct most_interface *iface, int channel_id,
        INIT_LIST_HEAD(&adpt->dev_list);
        iface->priv = adpt;
        list_add_tail(&adpt->list, &adpt_list);
-       ret = snd_card_new(&iface->dev, -1, "INIC", THIS_MODULE,
+       ret = snd_card_new(iface->driver_dev, -1, "INIC", THIS_MODULE,
                           sizeof(*channel), &adpt->card);
        if (ret < 0)
                goto err_free_adpt;