diff options
author | Mauro Carvalho Chehab <mchehab@osg.samsung.com> | 2015-08-14 10:42:05 -0300 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@osg.samsung.com> | 2016-01-11 12:18:40 -0200 |
commit | fa762394fd85c838ade769990478bc4e01fd95e8 (patch) | |
tree | 426b044963d02003fb341dd29fbc1fa4d6213f8d /include/media/media-entity.h | |
parent | 20fe0319de9aca71ba45e2f93c4a2a73dabde4da (diff) | |
download | linux-fa762394fd85c838ade769990478bc4e01fd95e8.tar.bz2 |
[media] media: create a macro to get entity ID
Instead of accessing directly entity.id, let's create a macro,
as this field will be moved into a common struct later on.
Acked-by: Hans Verkuil <hans.verkuil@cisco.com>
Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Diffstat (limited to 'include/media/media-entity.h')
-rw-r--r-- | include/media/media-entity.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/include/media/media-entity.h b/include/media/media-entity.h index b92366317aee..57881758927e 100644 --- a/include/media/media-entity.h +++ b/include/media/media-entity.h @@ -113,6 +113,11 @@ static inline u32 media_entity_subtype(struct media_entity *entity) return entity->type & MEDIA_ENT_SUBTYPE_MASK; } +static inline u32 media_entity_id(struct media_entity *entity) +{ + return entity->id; +} + #define MEDIA_ENTITY_ENUM_MAX_DEPTH 16 #define MEDIA_ENTITY_ENUM_MAX_ID 64 |