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
02db3c55
Commit
02db3c55
authored
May 24, 2003
by
Geert Uytterhoeven
Committed by
Linus Torvalds
May 24, 2003
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[PATCH] Ataflop fix
Ataflop: fix breakage after recent cleanups
parent
e356a58d
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
5 deletions
+5
-5
drivers/block/ataflop.c
drivers/block/ataflop.c
+5
-5
No files found.
drivers/block/ataflop.c
View file @
02db3c55
...
@@ -1571,7 +1571,7 @@ static int fd_ioctl(struct inode *inode, struct file *filp,
...
@@ -1571,7 +1571,7 @@ static int fd_ioctl(struct inode *inode, struct file *filp,
*/
*/
/* get the parameters from user space */
/* get the parameters from user space */
if
(
p
->
ref
!=
1
&&
p
->
ref
!=
-
1
)
if
(
floppy
->
ref
!=
1
&&
floppy
->
ref
!=
-
1
)
return
-
EBUSY
;
return
-
EBUSY
;
if
(
copy_from_user
(
&
setprm
,
(
void
*
)
param
,
sizeof
(
setprm
)))
if
(
copy_from_user
(
&
setprm
,
(
void
*
)
param
,
sizeof
(
setprm
)))
return
-
EFAULT
;
return
-
EFAULT
;
...
@@ -1618,7 +1618,7 @@ static int fd_ioctl(struct inode *inode, struct file *filp,
...
@@ -1618,7 +1618,7 @@ static int fd_ioctl(struct inode *inode, struct file *filp,
printk
(
KERN_INFO
"floppy%d: setting %s %p!
\n
"
,
printk
(
KERN_INFO
"floppy%d: setting %s %p!
\n
"
,
drive
,
dtp
->
name
,
dtp
);
drive
,
dtp
->
name
,
dtp
);
UDT
=
dtp
;
UDT
=
dtp
;
set_capacity
(
p
->
disk
,
UDT
->
blocks
);
set_capacity
(
floppy
->
disk
,
UDT
->
blocks
);
if
(
cmd
==
FDDEFPRM
)
{
if
(
cmd
==
FDDEFPRM
)
{
/* save settings as permanent default type */
/* save settings as permanent default type */
...
@@ -1664,7 +1664,7 @@ static int fd_ioctl(struct inode *inode, struct file *filp,
...
@@ -1664,7 +1664,7 @@ static int fd_ioctl(struct inode *inode, struct file *filp,
}
}
UDT
=
dtp
;
UDT
=
dtp
;
set_capacity
(
p
->
disk
,
UDT
->
blocks
);
set_capacity
(
floppy
->
disk
,
UDT
->
blocks
);
return
0
;
return
0
;
case
FDMSGON
:
case
FDMSGON
:
...
@@ -1678,7 +1678,7 @@ static int fd_ioctl(struct inode *inode, struct file *filp,
...
@@ -1678,7 +1678,7 @@ static int fd_ioctl(struct inode *inode, struct file *filp,
case
FDFMTBEG
:
case
FDFMTBEG
:
return
0
;
return
0
;
case
FDFMTTRK
:
case
FDFMTTRK
:
if
(
p
->
ref
!=
1
&&
p
->
ref
!=
-
1
)
if
(
floppy
->
ref
!=
1
&&
floppy
->
ref
!=
-
1
)
return
-
EBUSY
;
return
-
EBUSY
;
if
(
copy_from_user
(
&
fmt_desc
,
(
void
*
)
param
,
sizeof
(
fmt_desc
)))
if
(
copy_from_user
(
&
fmt_desc
,
(
void
*
)
param
,
sizeof
(
fmt_desc
)))
return
-
EFAULT
;
return
-
EFAULT
;
...
@@ -1687,7 +1687,7 @@ static int fd_ioctl(struct inode *inode, struct file *filp,
...
@@ -1687,7 +1687,7 @@ static int fd_ioctl(struct inode *inode, struct file *filp,
UDT
=
NULL
;
UDT
=
NULL
;
/* MSch: invalidate default_params */
/* MSch: invalidate default_params */
default_params
[
drive
].
blocks
=
0
;
default_params
[
drive
].
blocks
=
0
;
set_capacity
(
p
->
disk
,
MAX_DISK_SIZE
*
2
);
set_capacity
(
floppy
->
disk
,
MAX_DISK_SIZE
*
2
);
case
FDFMTEND
:
case
FDFMTEND
:
case
FDFLUSH
:
case
FDFLUSH
:
/* invalidate the buffer track to force a reread */
/* invalidate the buffer track to force a reread */
...
...
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