This patch fixes the usage of the wrong struct device when calling
function snd_card_new.

Reported-by: Eugeniu Rosca <ero...@de.adit-jv.com>
Signed-off-by: Christian Gromm <christian.gr...@microchip.com>
---
 drivers/staging/most/sound/sound.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/most/sound/sound.c 
b/drivers/staging/most/sound/sound.c
index 7c99867..342f390 100644
--- a/drivers/staging/most/sound/sound.c
+++ b/drivers/staging/most/sound/sound.c
@@ -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;
-- 
2.7.4

_______________________________________________
devel mailing list
de...@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel

Reply via email to