Commit 7722d1df authored by Bartlomiej Zolnierkiewicz's avatar Bartlomiej Zolnierkiewicz Committed by Linus Torvalds

[PATCH] ide: remove /proc/ide/hd?/settings:ide-scsi & HDIO_SET_IDE_SCSI ioctl

As noticed by Alan Cox:

"It doesn't work now so it clearly isnt being used 8). We hold the lock
because its a proc function and we then replace the proc functions in the
attach method -> deadlock. It is also incredibly hard to fix without a
major rewrite."

The same is true for HDIO_SET_IDE_SCSI ioctl.

Both were broken 18 months ago in 2.5.63 as a side-effect of locking fixes.
Signed-off-by: default avatarBartlomiej Zolnierkiewicz <bzolnier@elka.pw.edu.pl>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent b19d7ad9
......@@ -1348,23 +1348,6 @@ static int set_xfer_rate (ide_drive_t *drive, int arg)
return err;
}
int ide_atapi_to_scsi (ide_drive_t *drive, int arg)
{
if (drive->media == ide_disk) {
drive->scsi = 0;
return 0;
}
if (DRIVER(drive)->cleanup(drive)) {
drive->scsi = 0;
return 0;
}
drive->scsi = (u8) arg;
ata_attach(drive);
return 0;
}
void ide_add_generic_settings (ide_drive_t *drive)
{
/*
......@@ -1379,8 +1362,6 @@ void ide_add_generic_settings (ide_drive_t *drive)
ide_add_setting(drive, "init_speed", SETTING_RW, -1, -1, TYPE_BYTE, 0, 70, 1, 1, &drive->init_speed, NULL);
ide_add_setting(drive, "current_speed", SETTING_RW, -1, -1, TYPE_BYTE, 0, 70, 1, 1, &drive->current_speed, set_xfer_rate);
ide_add_setting(drive, "number", SETTING_RW, -1, -1, TYPE_BYTE, 0, 3, 1, 1, &drive->dn, NULL);
if (drive->media != ide_disk)
ide_add_setting(drive, "ide-scsi", SETTING_RW, -1, HDIO_SET_IDE_SCSI, TYPE_BYTE, 0, 1, 1, 1, &drive->scsi, ide_atapi_to_scsi);
}
int system_bus_clock (void)
......
......@@ -449,9 +449,8 @@ enum {
/* hd/ide ctl's that pass (arg) ptrs to user space are numbered 0x033n/0x033n */
/* 0x330 is reserved - used to be HDIO_GETGEO_BIG */
/* 0x331 is reserved - used to be HDIO_GETGEO_BIG_RAW */
#define HDIO_SET_IDE_SCSI 0x0338
#define HDIO_SET_SCSI_IDE 0x0339
/* 0x338 is reserved - used to be HDIO_SET_IDE_SCSI */
/* 0x339 is reserved - used to be HDIO_SET_SCSI_IDE */
#define __NEW_HD_DRIVE_ID
......
......@@ -756,8 +756,8 @@ typedef struct ide_drive_s {
* 2=48-bit doing 28-bit
* 3=64-bit
*/
unsigned scsi : 1; /* 0=default, 1=ide-scsi emulation */
u8 scsi; /* 0=default, 1=skip current ide-subdriver for ide-scsi emulation */
u8 quirk_list; /* considered quirky, set for a specific host */
u8 suspend_reset; /* drive suspend mode flag, soft-reset recovers */
u8 init_speed; /* transfer rate set at boot */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment