summaryrefslogtreecommitdiff
path: root/linux/drivers/media/video/em28xx
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@redhat.com>2008-11-29 00:46:43 -0200
committerMauro Carvalho Chehab <mchehab@redhat.com>2008-11-29 00:46:43 -0200
commitfd418b6a655b77600b58eca51b4e373e03bf6e26 (patch)
treea38fc3785e1d8e44796e260338d42c58f698d0cd /linux/drivers/media/video/em28xx
parent1396809fc70840b729f6bdc9ef62e6bcb60825c7 (diff)
downloadmediapointer-dvb-s2-fd418b6a655b77600b58eca51b4e373e03bf6e26.tar.gz
mediapointer-dvb-s2-fd418b6a655b77600b58eca51b4e373e03bf6e26.tar.bz2
em28xx: improve board description messages
Print manufacturer/product info from USB device and also card entry. From: Mauro Carvalho Chehab <mchehab@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'linux/drivers/media/video/em28xx')
-rw-r--r--linux/drivers/media/video/em28xx/em28xx-cards.c3
-rw-r--r--linux/drivers/media/video/em28xx/em28xx-video.c15
2 files changed, 16 insertions, 2 deletions
diff --git a/linux/drivers/media/video/em28xx/em28xx-cards.c b/linux/drivers/media/video/em28xx/em28xx-cards.c
index fe14ecc05..d38b3ba72 100644
--- a/linux/drivers/media/video/em28xx/em28xx-cards.c
+++ b/linux/drivers/media/video/em28xx/em28xx-cards.c
@@ -1427,7 +1427,8 @@ void em28xx_pre_card_setup(struct em28xx *dev)
em28xx_set_model(dev);
- em28xx_info("Found %s\n", dev->board.name);
+ em28xx_info("Identified as %s (card=%d)\n",
+ dev->board.name, dev->model);
/* Set the default GPO/GPIO for legacy devices */
dev->reg_gpo_num = EM2880_R04_GPO;
diff --git a/linux/drivers/media/video/em28xx/em28xx-video.c b/linux/drivers/media/video/em28xx/em28xx-video.c
index 23507ac4e..00d49c45f 100644
--- a/linux/drivers/media/video/em28xx/em28xx-video.c
+++ b/linux/drivers/media/video/em28xx/em28xx-video.c
@@ -2259,6 +2259,7 @@ static int em28xx_usb_probe(struct usb_interface *interface,
int retval = -ENODEV;
int i, nr, ifnum, isoc_pipe;
char *speed;
+ char descr[255] = "";
udev = usb_get_dev(interface_to_usbdev(interface));
ifnum = interface->altsetting[0].desc.bInterfaceNumber;
@@ -2331,8 +2332,20 @@ static int em28xx_usb_probe(struct usb_interface *interface,
speed = "unknown";
}
- printk(DRIVER_NAME ": New video device @ %s Mbps "
+ if (udev->manufacturer)
+ strlcpy(descr, udev->manufacturer, sizeof(descr));
+
+ if (udev->product) {
+ if (*descr)
+ strlcat(descr, " ", sizeof(descr));
+ strlcat(descr, udev->product, sizeof(descr));
+ }
+ if (*descr)
+ strlcat(descr, " ", sizeof(descr));
+
+ printk(DRIVER_NAME ": New device %s@ %s Mbps "
"(%04x:%04x, interface %d, class %d)\n",
+ descr,
speed,
le16_to_cpu(udev->descriptor.idVendor),
le16_to_cpu(udev->descriptor.idProduct),