summaryrefslogtreecommitdiffstats
path: root/drivers/media/video
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@redhat.com>2008-11-13 22:12:43 +0100
committerMauro Carvalho Chehab <mchehab@redhat.com>2008-11-14 17:24:45 +0100
commitc6241b6c64dbe759e0eccaee913bdcf4d7960367 (patch)
tree0e1fa8bb36df7f01b70c812f2adb16d827d07b8e /drivers/media/video
parentV4L/DVB (9622): tvaudio: Improve comments and remove a unneeded prototype (diff)
downloadlinux-c6241b6c64dbe759e0eccaee913bdcf4d7960367.tar.xz
linux-c6241b6c64dbe759e0eccaee913bdcf4d7960367.zip
V4L/DVB (9623): tvaudio: Improve debug msg by printing something more human
Before the patch, the used ioctl were printed as an hexadecimal code, hard to be understand without consulting the way _IO macros work. Instead, use the V4L default handler for printing such errors into a way that would be easier to understand. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video')
-rw-r--r--drivers/media/video/tvaudio.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/drivers/media/video/tvaudio.c b/drivers/media/video/tvaudio.c
index 779ce7f865c3..fb46ce4a1090 100644
--- a/drivers/media/video/tvaudio.c
+++ b/drivers/media/video/tvaudio.c
@@ -34,6 +34,7 @@
#include <media/tvaudio.h>
#include <media/v4l2-common.h>
+#include <media/v4l2-ioctl.h>
#include <media/v4l2-chip-ident.h>
#include <media/v4l2-i2c-drv-legacy.h>
@@ -1732,7 +1733,10 @@ static int chip_command(struct i2c_client *client,
struct CHIPSTATE *chip = i2c_get_clientdata(client);
struct CHIPDESC *desc = chip->desc;
- v4l_dbg(1, debug, chip->c, "%s: chip_command 0x%x\n", chip->c->name, cmd);
+ if (debug > 0) {
+ v4l_i2c_print_ioctl(chip->c, cmd);
+ printk("\n");
+ }
switch (cmd) {
case AUDC_SET_RADIO: