aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/cpia2/cpia2_v4l.c
diff options
context:
space:
mode:
authorRobert P. J. Day <rpjday@mindspring.com>2007-06-05 04:20:56 -0400
committerMauro Carvalho Chehab <mchehab@infradead.org>2007-07-18 13:23:52 -0400
commit0c71bf1c3065e80cc3ab91293829169bdeda2c42 (patch)
treed38b375f6d8cb7cb5acc8eb80bb93539b6fb2909 /drivers/media/video/cpia2/cpia2_v4l.c
parente0099e9edabd855bf83d3f57b1843f0b06bfb19d (diff)
V4L/DVB (5739): Replace C code with calls to ARRAY_SIZE macro.
Signed-off-by: Robert P. J. Day <rpjday@mindspring.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media/video/cpia2/cpia2_v4l.c')
-rw-r--r--drivers/media/video/cpia2/cpia2_v4l.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/media/video/cpia2/cpia2_v4l.c b/drivers/media/video/cpia2/cpia2_v4l.c
index 1bda7ad9de1..92778cd1d73 100644
--- a/drivers/media/video/cpia2/cpia2_v4l.c
+++ b/drivers/media/video/cpia2/cpia2_v4l.c
@@ -105,7 +105,7 @@ static struct control_menu_info framerate_controls[] =
105 { CPIA2_VP_FRAMERATE_25, "25 fps" }, 105 { CPIA2_VP_FRAMERATE_25, "25 fps" },
106 { CPIA2_VP_FRAMERATE_30, "30 fps" }, 106 { CPIA2_VP_FRAMERATE_30, "30 fps" },
107}; 107};
108#define NUM_FRAMERATE_CONTROLS (sizeof(framerate_controls)/sizeof(framerate_controls[0])) 108#define NUM_FRAMERATE_CONTROLS (ARRAY_SIZE(framerate_controls))
109 109
110static struct control_menu_info flicker_controls[] = 110static struct control_menu_info flicker_controls[] =
111{ 111{
@@ -113,7 +113,7 @@ static struct control_menu_info flicker_controls[] =
113 { FLICKER_50, "50 Hz" }, 113 { FLICKER_50, "50 Hz" },
114 { FLICKER_60, "60 Hz" }, 114 { FLICKER_60, "60 Hz" },
115}; 115};
116#define NUM_FLICKER_CONTROLS (sizeof(flicker_controls)/sizeof(flicker_controls[0])) 116#define NUM_FLICKER_CONTROLS (ARRAY_SIZE(flicker_controls))
117 117
118static struct control_menu_info lights_controls[] = 118static struct control_menu_info lights_controls[] =
119{ 119{
@@ -122,7 +122,7 @@ static struct control_menu_info lights_controls[] =
122 { 128, "Bottom" }, 122 { 128, "Bottom" },
123 { 192, "Both" }, 123 { 192, "Both" },
124}; 124};
125#define NUM_LIGHTS_CONTROLS (sizeof(lights_controls)/sizeof(lights_controls[0])) 125#define NUM_LIGHTS_CONTROLS (ARRAY_SIZE(lights_controls))
126#define GPIO_LIGHTS_MASK 192 126#define GPIO_LIGHTS_MASK 192
127 127
128static struct v4l2_queryctrl controls[] = { 128static struct v4l2_queryctrl controls[] = {
@@ -235,7 +235,7 @@ static struct v4l2_queryctrl controls[] = {
235 .default_value = 0, 235 .default_value = 0,
236 }, 236 },
237}; 237};
238#define NUM_CONTROLS (sizeof(controls)/sizeof(controls[0])) 238#define NUM_CONTROLS (ARRAY_SIZE(controls))
239 239
240 240
241/****************************************************************************** 241/******************************************************************************