[media] media-entity: must check media_create_pad_link()
authorMauro Carvalho Chehab <mchehab@osg.samsung.com>
Fri, 4 Sep 2015 19:08:24 +0000 (16:08 -0300)
committerMauro Carvalho Chehab <mchehab@osg.samsung.com>
Mon, 11 Jan 2016 14:19:00 +0000 (12:19 -0200)
Drivers should check if media_create_pad_link() actually
worked.

Acked-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
include/media/media-entity.h

index 7128d3b0b848526ca2120c22c8dab885851d6928..0c7390d2edaed445935655cb028a778b372c3b79 100644 (file)
@@ -351,8 +351,9 @@ int media_entity_init(struct media_entity *entity, u16 num_pads,
                      struct media_pad *pads);
 void media_entity_cleanup(struct media_entity *entity);
 
-int media_create_pad_link(struct media_entity *source, u16 source_pad,
-               struct media_entity *sink, u16 sink_pad, u32 flags);
+__must_check int media_create_pad_link(struct media_entity *source,
+                       u16 source_pad, struct media_entity *sink,
+                       u16 sink_pad, u32 flags);
 void __media_entity_remove_links(struct media_entity *entity);
 void media_entity_remove_links(struct media_entity *entity);