summaryrefslogtreecommitdiffstats
path: root/drivers/media/media-device.c
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@osg.samsung.com>2015-12-11 18:09:13 -0200
committerMauro Carvalho Chehab <mchehab@osg.samsung.com>2016-01-11 12:19:10 -0200
commit82ae2a50597565cbb2c758b44a3f39adb158ef0a (patch)
treecb1a9c6a8f2ef3e453b6230a15e6aaedb014d8e4 /drivers/media/media-device.c
parent313895fba2040c7f223db3d6aa6cb3b5c5022042 (diff)
downloadlinux-82ae2a50597565cbb2c758b44a3f39adb158ef0a.tar.bz2
[media] media: move MEDIA_LNK_FL_INTERFACE_LINK logic to link creation
Instead of flagging an interface link as MEDIA_LNK_FL_INTERFACE_LINK only when returning to userspace, do it at link creation time. That would allow using such flag internally, and cleans up a little bit the code for G_TOPOLOGY ioctl. [mchehab@osg.samsung.com: folded with a fixup from Dan Carpenter, replacing & by &&] Suggested-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Diffstat (limited to 'drivers/media/media-device.c')
-rw-r--r--drivers/media/media-device.c3
1 files changed, 0 insertions, 3 deletions
diff --git a/drivers/media/media-device.c b/drivers/media/media-device.c
index 6406914a9bf5..c12481c753a0 100644
--- a/drivers/media/media-device.c
+++ b/drivers/media/media-device.c
@@ -361,9 +361,6 @@ static long __media_device_get_topology(struct media_device *mdev,
klink.sink_id = link->gobj1->id;
klink.flags = link->flags;
- if (media_type(link->gobj0) != MEDIA_GRAPH_PAD)
- klink.flags |= MEDIA_LNK_FL_INTERFACE_LINK;
-
if (copy_to_user(ulink, &klink, sizeof(klink)))
ret = -EFAULT;
ulink++;