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
7b3cbc4a
Commit
7b3cbc4a
authored
Nov 25, 2002
by
Dave Jones
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[PATCH] Remove unneeded verify_area from sg.c
Makes the code simpler..
parent
92d03b14
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
3 deletions
+1
-3
drivers/scsi/sg.c
drivers/scsi/sg.c
+1
-3
No files found.
drivers/scsi/sg.c
View file @
7b3cbc4a
...
@@ -474,9 +474,7 @@ sg_new_read(Sg_fd * sfp, char *buf, size_t count, Sg_request * srp)
...
@@ -474,9 +474,7 @@ sg_new_read(Sg_fd * sfp, char *buf, size_t count, Sg_request * srp)
sb_len
=
(
hp
->
mx_sb_len
>
sb_len
)
?
sb_len
:
hp
->
mx_sb_len
;
sb_len
=
(
hp
->
mx_sb_len
>
sb_len
)
?
sb_len
:
hp
->
mx_sb_len
;
len
=
8
+
(
int
)
srp
->
sense_b
[
7
];
/* Additional sense length field */
len
=
8
+
(
int
)
srp
->
sense_b
[
7
];
/* Additional sense length field */
len
=
(
len
>
sb_len
)
?
sb_len
:
len
;
len
=
(
len
>
sb_len
)
?
sb_len
:
len
;
if
((
err
=
verify_area
(
VERIFY_WRITE
,
hp
->
sbp
,
len
)))
if
(
copy_to_user
(
hp
->
sbp
,
srp
->
sense_b
,
len
))
{
goto
err_out
;
if
(
__copy_to_user
(
hp
->
sbp
,
srp
->
sense_b
,
len
))
{
err
=
-
EFAULT
;
err
=
-
EFAULT
;
goto
err_out
;
goto
err_out
;
}
}
...
...
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