Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
53c4e955
Commit
53c4e955
authored
Mar 29, 2007
by
Mauro Carvalho Chehab
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
V4L/DVB (5479): Use ARRAY_SIZE instead of a magic number
Signed-off-by:
Mauro Carvalho Chehab
<
mchehab@infradead.org
>
parent
5b9c4e6d
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
6 additions
and
5 deletions
+6
-5
drivers/media/video/bt8xx/bttv-i2c.c
drivers/media/video/bt8xx/bttv-i2c.c
+1
-1
drivers/media/video/cx88/cx88-i2c.c
drivers/media/video/cx88/cx88-i2c.c
+2
-1
drivers/media/video/em28xx/em28xx-i2c.c
drivers/media/video/em28xx/em28xx-i2c.c
+1
-1
drivers/media/video/ir-kbd-i2c.c
drivers/media/video/ir-kbd-i2c.c
+1
-1
drivers/media/video/saa7134/saa7134-i2c.c
drivers/media/video/saa7134/saa7134-i2c.c
+1
-1
No files found.
drivers/media/video/bt8xx/bttv-i2c.c
View file @
53c4e955
...
...
@@ -412,7 +412,7 @@ static void do_i2c_scan(char *name, struct i2c_client *c)
unsigned
char
buf
;
int
i
,
rc
;
for
(
i
=
0
;
i
<
128
;
i
++
)
{
for
(
i
=
0
;
i
<
ARRAY_SIZE
(
i2c_devs
)
;
i
++
)
{
c
->
addr
=
i
;
rc
=
i2c_master_recv
(
c
,
&
buf
,
0
);
if
(
rc
<
0
)
...
...
drivers/media/video/cx88/cx88-i2c.c
View file @
53c4e955
/*
cx88-i2c.c -- all the i2c code is here
...
...
@@ -195,7 +196,7 @@ static void do_i2c_scan(char *name, struct i2c_client *c)
unsigned
char
buf
;
int
i
,
rc
;
for
(
i
=
0
;
i
<
128
;
i
++
)
{
for
(
i
=
0
;
i
<
ARRAY_SIZE
(
i2c_devs
)
;
i
++
)
{
c
->
addr
=
i
;
rc
=
i2c_master_recv
(
c
,
&
buf
,
0
);
if
(
rc
<
0
)
...
...
drivers/media/video/em28xx/em28xx-i2c.c
View file @
53c4e955
...
...
@@ -523,7 +523,7 @@ static void do_i2c_scan(char *name, struct i2c_client *c)
unsigned
char
buf
;
int
i
,
rc
;
for
(
i
=
0
;
i
<
128
;
i
++
)
{
for
(
i
=
0
;
i
<
ARRAY_SIZE
(
i2c_devs
)
;
i
++
)
{
c
->
addr
=
i
;
rc
=
i2c_master_recv
(
c
,
&
buf
,
0
);
if
(
rc
<
0
)
...
...
drivers/media/video/ir-kbd-i2c.c
View file @
53c4e955
...
...
@@ -173,7 +173,7 @@ static int get_key_pinnacle(struct IR_i2c *ir, u32 *ir_key, u32 *ir_raw,
return
-
EIO
;
}
for
(
start
=
0
;
start
<
4
;
start
++
)
{
for
(
start
=
0
;
start
<
ARRAY_SIZE
(
b
)
;
start
++
)
{
if
(
b
[
start
]
==
marker
)
{
code
=
b
[(
start
+
parity_offset
+
1
)
%
4
];
parity
=
b
[(
start
+
parity_offset
)
%
4
];
...
...
drivers/media/video/saa7134/saa7134-i2c.c
View file @
53c4e955
...
...
@@ -447,7 +447,7 @@ static void do_i2c_scan(char *name, struct i2c_client *c)
unsigned
char
buf
;
int
i
,
rc
;
for
(
i
=
0
;
i
<
128
;
i
++
)
{
for
(
i
=
0
;
i
<
ARRAY_SIZE
(
i2c_devs
)
;
i
++
)
{
c
->
addr
=
i
;
rc
=
i2c_master_recv
(
c
,
&
buf
,
0
);
if
(
rc
<
0
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment