Commit 5e68d8e2 authored by Mauro Carvalho Chehab's avatar Mauro Carvalho Chehab

media: au0828: use signals instead of hardcoding a pad number

When creating the audio link, use pad signals, instead of
hardcoding using the pad index number.
Acked-by: default avatarHans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab+samsung@kernel.org>
parent f3efe15a
...@@ -266,11 +266,13 @@ static void au0828_media_graph_notify(struct media_entity *new, ...@@ -266,11 +266,13 @@ static void au0828_media_graph_notify(struct media_entity *new,
create_link: create_link:
if (decoder && mixer) { if (decoder && mixer) {
ret = media_create_pad_link(decoder, ret = media_get_pad_index(decoder, false,
DEMOD_PAD_AUDIO_OUT, PAD_SIGNAL_AUDIO);
mixer, 0, if (ret >= 0)
MEDIA_LNK_FL_ENABLED); ret = media_create_pad_link(decoder, ret,
if (ret) mixer, 0,
MEDIA_LNK_FL_ENABLED);
if (ret < 0)
dev_err(&dev->usbdev->dev, dev_err(&dev->usbdev->dev,
"Mixer Pad Link Create Error: %d\n", ret); "Mixer Pad Link Create Error: %d\n", ret);
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment