From 06013a66758e7c8e83dba4f81a92682c53a93d41 Mon Sep 17 00:00:00 2001 From: Laurent Pinchart Date: Thu, 21 Oct 2010 16:37:07 +0200 Subject: Update to the latest media kernel API The media kernel API has seen many changes during the review process, update the media-ctl application accordingly. Signed-off-by: Laurent Pinchart --- main.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'main.c') diff --git a/main.c b/main.c index 96b4573..9952a60 100644 --- a/main.c +++ b/main.c @@ -390,7 +390,7 @@ static int setup_format(struct media_device *media, const char *p, char **endp) return -EINVAL; } - if (pad->type == MEDIA_PAD_TYPE_OUTPUT) { + if (pad->flags & MEDIA_PAD_FLAG_OUTPUT) { ret = set_crop(pad, &crop); if (ret < 0) return ret; @@ -400,7 +400,7 @@ static int setup_format(struct media_device *media, const char *p, char **endp) if (ret < 0) return ret; - if (pad->type == MEDIA_PAD_TYPE_INPUT) { + if (pad->flags & MEDIA_PAD_FLAG_INPUT) { ret = set_crop(pad, &crop); if (ret < 0) return ret; @@ -414,7 +414,7 @@ static int setup_format(struct media_device *media, const char *p, char **endp) /* If the pad is an output pad, automatically set the same format on * the remote subdev input pads, if any. */ - if (pad->type == MEDIA_PAD_TYPE_OUTPUT) { + if (pad->flags & MEDIA_PAD_FLAG_OUTPUT) { for (i = 0; i < pad->entity->info.links; ++i) { struct media_entity_link *link = &pad->entity->links[i]; struct v4l2_mbus_framefmt remote_format; -- cgit v1.2.3