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
Kirill Smelkov
linux
Commits
1e9188c2
Commit
1e9188c2
authored
Jun 03, 2004
by
Alexander Viro
Committed by
Linus Torvalds
Jun 03, 2004
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[PATCH] sparse: mroute annotation
parent
d75b0fd4
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
7 additions
and
7 deletions
+7
-7
include/linux/mroute.h
include/linux/mroute.h
+1
-1
net/ipv4/ipmr.c
net/ipv4/ipmr.c
+5
-5
net/ipv4/raw.c
net/ipv4/raw.c
+1
-1
No files found.
include/linux/mroute.h
View file @
1e9188c2
...
...
@@ -130,7 +130,7 @@ struct igmpmsg
extern
int
ip_mroute_setsockopt
(
struct
sock
*
,
int
,
char
__user
*
,
int
);
extern
int
ip_mroute_getsockopt
(
struct
sock
*
,
int
,
char
__user
*
,
int
__user
*
);
extern
int
ipmr_ioctl
(
struct
sock
*
sk
,
int
cmd
,
unsigned
long
arg
);
extern
int
ipmr_ioctl
(
struct
sock
*
sk
,
int
cmd
,
void
__user
*
arg
);
extern
void
ip_mr_init
(
void
);
...
...
net/ipv4/ipmr.c
View file @
1e9188c2
...
...
@@ -1008,7 +1008,7 @@ int ip_mroute_getsockopt(struct sock *sk,int optname,char __user *optval,int __u
* The IP multicast ioctl support routines.
*/
int
ipmr_ioctl
(
struct
sock
*
sk
,
int
cmd
,
unsigned
long
arg
)
int
ipmr_ioctl
(
struct
sock
*
sk
,
int
cmd
,
void
__user
*
arg
)
{
struct
sioc_sg_req
sr
;
struct
sioc_vif_req
vr
;
...
...
@@ -1018,7 +1018,7 @@ int ipmr_ioctl(struct sock *sk, int cmd, unsigned long arg)
switch
(
cmd
)
{
case
SIOCGETVIFCNT
:
if
(
copy_from_user
(
&
vr
,
(
void
*
)
arg
,
sizeof
(
vr
)))
if
(
copy_from_user
(
&
vr
,
arg
,
sizeof
(
vr
)))
return
-
EFAULT
;
if
(
vr
.
vifi
>=
maxvif
)
return
-
EINVAL
;
...
...
@@ -1031,14 +1031,14 @@ int ipmr_ioctl(struct sock *sk, int cmd, unsigned long arg)
vr
.
obytes
=
vif
->
bytes_out
;
read_unlock
(
&
mrt_lock
);
if
(
copy_to_user
(
(
void
*
)
arg
,
&
vr
,
sizeof
(
vr
)))
if
(
copy_to_user
(
arg
,
&
vr
,
sizeof
(
vr
)))
return
-
EFAULT
;
return
0
;
}
read_unlock
(
&
mrt_lock
);
return
-
EADDRNOTAVAIL
;
case
SIOCGETSGCNT
:
if
(
copy_from_user
(
&
sr
,
(
void
*
)
arg
,
sizeof
(
sr
)))
if
(
copy_from_user
(
&
sr
,
arg
,
sizeof
(
sr
)))
return
-
EFAULT
;
read_lock
(
&
mrt_lock
);
...
...
@@ -1049,7 +1049,7 @@ int ipmr_ioctl(struct sock *sk, int cmd, unsigned long arg)
sr
.
wrong_if
=
c
->
mfc_un
.
res
.
wrong_if
;
read_unlock
(
&
mrt_lock
);
if
(
copy_to_user
(
(
void
*
)
arg
,
&
sr
,
sizeof
(
sr
)))
if
(
copy_to_user
(
arg
,
&
sr
,
sizeof
(
sr
)))
return
-
EFAULT
;
return
0
;
}
...
...
net/ipv4/raw.c
View file @
1e9188c2
...
...
@@ -647,7 +647,7 @@ static int raw_ioctl(struct sock *sk, int cmd, unsigned long arg)
default:
#ifdef CONFIG_IP_MROUTE
return
ipmr_ioctl
(
sk
,
cmd
,
arg
);
return
ipmr_ioctl
(
sk
,
cmd
,
(
void
__user
*
)
arg
);
#else
return
-
ENOIOCTLCMD
;
#endif
...
...
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