|
@@ -2038,11 +2038,9 @@ static int idefloppy_ioctl(struct inode *inode, struct file *file,
|
|
struct ide_floppy_obj *floppy = ide_floppy_g(bdev->bd_disk);
|
|
struct ide_floppy_obj *floppy = ide_floppy_g(bdev->bd_disk);
|
|
ide_drive_t *drive = floppy->drive;
|
|
ide_drive_t *drive = floppy->drive;
|
|
void __user *argp = (void __user *)arg;
|
|
void __user *argp = (void __user *)arg;
|
|
- int err = generic_ide_ioctl(drive, file, bdev, cmd, arg);
|
|
|
|
|
|
+ int err;
|
|
int prevent = (arg) ? 1 : 0;
|
|
int prevent = (arg) ? 1 : 0;
|
|
idefloppy_pc_t pc;
|
|
idefloppy_pc_t pc;
|
|
- if (err != -EINVAL)
|
|
|
|
- return err;
|
|
|
|
|
|
|
|
switch (cmd) {
|
|
switch (cmd) {
|
|
case CDROMEJECT:
|
|
case CDROMEJECT:
|
|
@@ -2094,7 +2092,7 @@ static int idefloppy_ioctl(struct inode *inode, struct file *file,
|
|
case IDEFLOPPY_IOCTL_FORMAT_GET_PROGRESS:
|
|
case IDEFLOPPY_IOCTL_FORMAT_GET_PROGRESS:
|
|
return idefloppy_get_format_progress(drive, argp);
|
|
return idefloppy_get_format_progress(drive, argp);
|
|
}
|
|
}
|
|
- return -EINVAL;
|
|
|
|
|
|
+ return generic_ide_ioctl(drive, file, bdev, cmd, arg);
|
|
}
|
|
}
|
|
|
|
|
|
static int idefloppy_media_changed(struct gendisk *disk)
|
|
static int idefloppy_media_changed(struct gendisk *disk)
|