From f3c7150307afd2a9fff3806580ba1b283a13654b Mon Sep 17 00:00:00 2001
From: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Date: Wed, 29 Sep 2010 10:37:29 +0200
Subject: Print device bus info when opening the device

To differentiate between identically named devices, print the bus info
reported by VIDIOC_QUERYCAP.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
---
 yavta.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/yavta.c b/yavta.c
index f8dfed6..7f71fd8 100644
--- a/yavta.c
+++ b/yavta.c
@@ -127,7 +127,7 @@ static int video_open(struct device *dev, const char *devname, int no_query)
 			return -EINVAL;
 		}
 
-		printf("Device %s opened: %s.\n", devname, cap.card);
+		printf("Device %s opened: %s (%s).\n", devname, cap.card, cap.bus_info);
 	} else {
 		dev->type = V4L2_BUF_TYPE_VIDEO_CAPTURE;
 		printf("Device %s opened.\n", devname);
-- 
cgit v1.2.3