Skip to content

Commit

Permalink
[PATCH] libata: ata_scsi_ioctl cleanup
Browse files Browse the repository at this point in the history
In preparation for SAS, kill some unnecessary code in ata_scsi_ioctl
to find the ATA port and device given the scsi_device. Neither local
is used in the function.

Signed-off-by: Brian King <brking@us.ibm.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
  • Loading branch information
Brian King authored and Jeff Garzik committed Mar 24, 2006
1 parent eb3f0f9 commit 2af10a8
Showing 1 changed file with 0 additions and 13 deletions.
13 changes: 0 additions & 13 deletions drivers/scsi/libata-scsi.c
Original file line number Diff line number Diff line change
Expand Up @@ -267,20 +267,8 @@ int ata_task_ioctl(struct scsi_device *scsidev, void __user *arg)

int ata_scsi_ioctl(struct scsi_device *scsidev, int cmd, void __user *arg)
{
struct ata_port *ap;
struct ata_device *dev;
int val = -EINVAL, rc = -EINVAL;

ap = (struct ata_port *) &scsidev->host->hostdata[0];
if (!ap)
goto out;

dev = ata_scsi_find_dev(ap, scsidev);
if (!dev) {
rc = -ENODEV;
goto out;
}

switch (cmd) {
case ATA_IOC_GET_IO32:
val = 0;
Expand Down Expand Up @@ -309,7 +297,6 @@ int ata_scsi_ioctl(struct scsi_device *scsidev, int cmd, void __user *arg)
break;
}

out:
return rc;
}

Expand Down

0 comments on commit 2af10a8

Please sign in to comment.