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
9c6c0b9e
Commit
9c6c0b9e
authored
Mar 28, 2003
by
Dave Jones
Committed by
Dave Jones
Mar 28, 2003
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[AGPGART] sanitise agp mode input on setup ioctl.
parent
1e464de0
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
3 deletions
+11
-3
drivers/char/agp/frontend.c
drivers/char/agp/frontend.c
+11
-3
No files found.
drivers/char/agp/frontend.c
View file @
9c6c0b9e
...
...
@@ -805,11 +805,19 @@ static int agpioc_setup_wrap(agp_file_private * priv, unsigned long arg)
{
agp_setup
mode
;
if
(
copy_from_user
(
&
mode
,
(
void
*
)
arg
,
sizeof
(
agp_setup
)))
{
if
(
copy_from_user
(
&
mode
,
(
void
*
)
arg
,
sizeof
(
agp_setup
)))
return
-
EFAULT
;
}
switch
(
mode
.
agp_mode
)
{
case
1
:
case
2
:
case
4
:
case
8
:
agp_enable
(
mode
.
agp_mode
);
return
0
;
default:
;
}
return
-
EINVAL
;
}
static
int
agpioc_reserve_wrap
(
agp_file_private
*
priv
,
unsigned
long
arg
)
...
...
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