aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/media/video/v4l2-ioctl.c14
1 files changed, 10 insertions, 4 deletions
diff --git a/drivers/media/video/v4l2-ioctl.c b/drivers/media/video/v4l2-ioctl.c
index aa8f66c63364..c32e67608ad4 100644
--- a/drivers/media/video/v4l2-ioctl.c
+++ b/drivers/media/video/v4l2-ioctl.c
@@ -42,6 +42,12 @@
42 printk(KERN_DEBUG "%s: " fmt, vfd->name, ## arg);\ 42 printk(KERN_DEBUG "%s: " fmt, vfd->name, ## arg);\
43 } while (0) 43 } while (0)
44 44
45#define dbgarg3(fmt, arg...) \
46 do { \
47 if (vfd->debug & V4L2_DEBUG_IOCTL_ARG) \
48 printk(KERN_CONT "%s: " fmt, vfd->name, ## arg);\
49 } while (0)
50
45/* Zero out the end of the struct pointed to by p. Everthing after, but 51/* Zero out the end of the struct pointed to by p. Everthing after, but
46 * not including, the specified field is cleared. */ 52 * not including, the specified field is cleared. */
47#define CLEAR_AFTER_FIELD(p, field) \ 53#define CLEAR_AFTER_FIELD(p, field) \
@@ -1735,20 +1741,20 @@ static long __video_do_ioctl(struct file *file,
1735 p->type); 1741 p->type);
1736 switch (p->type) { 1742 switch (p->type) {
1737 case V4L2_FRMSIZE_TYPE_DISCRETE: 1743 case V4L2_FRMSIZE_TYPE_DISCRETE:
1738 printk("width = %d, height=%d\n", 1744 dbgarg3("width = %d, height=%d\n",
1739 p->discrete.width, p->discrete.height); 1745 p->discrete.width, p->discrete.height);
1740 break; 1746 break;
1741 case V4L2_FRMSIZE_TYPE_STEPWISE: 1747 case V4L2_FRMSIZE_TYPE_STEPWISE:
1742 printk("min %dx%d, max %dx%d, step %dx%d\n", 1748 dbgarg3("min %dx%d, max %dx%d, step %dx%d\n",
1743 p->stepwise.min_width, p->stepwise.min_height, 1749 p->stepwise.min_width, p->stepwise.min_height,
1744 p->stepwise.step_width, p->stepwise.step_height, 1750 p->stepwise.step_width, p->stepwise.step_height,
1745 p->stepwise.max_width, p->stepwise.max_height); 1751 p->stepwise.max_width, p->stepwise.max_height);
1746 break; 1752 break;
1747 case V4L2_FRMSIZE_TYPE_CONTINUOUS: 1753 case V4L2_FRMSIZE_TYPE_CONTINUOUS:
1748 printk("continuous\n"); 1754 dbgarg3("continuous\n");
1749 break; 1755 break;
1750 default: 1756 default:
1751 printk("- Unknown type!\n"); 1757 dbgarg3("- Unknown type!\n");
1752 } 1758 }
1753 1759
1754 break; 1760 break;