Skip to content

Commit

Permalink
[SCSI] aic79xx: use tcq functions
Browse files Browse the repository at this point in the history
This patch converts aic79xx to use the midlayer-supplied tcq
functions.

We also set the queuedepth to '1' if tcq is disabled; the
aic79xx driver gets confused otherwise. Will set it back to
'2' once I figure out how to queue requests in the driver.

Signed-off-by: Hannes Reinecke <hare@suse.de>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
  • Loading branch information
Hannes Reinecke authored and James Bottomley committed Mar 12, 2006
1 parent 7b22da3 commit 0aa800d
Showing 1 changed file with 5 additions and 9 deletions.
14 changes: 5 additions & 9 deletions drivers/scsi/aic7xxx/aic79xx_osm.c
Original file line number Diff line number Diff line change
Expand Up @@ -1336,14 +1336,12 @@ ahd_platform_set_tags(struct ahd_softc *ahd, struct ahd_devinfo *devinfo,

switch ((dev->flags & (AHD_DEV_Q_BASIC|AHD_DEV_Q_TAGGED))) {
case AHD_DEV_Q_BASIC:
scsi_adjust_queue_depth(sdev,
MSG_SIMPLE_TASK,
dev->openings + dev->active);
scsi_set_tag_type(sdev, MSG_SIMPLE_TASK);
scsi_activate_tcq(sdev, dev->openings + dev->active);
break;
case AHD_DEV_Q_TAGGED:
scsi_adjust_queue_depth(sdev,
MSG_ORDERED_TASK,
dev->openings + dev->active);
scsi_set_tag_type(sdev, MSG_ORDERED_TASK);
scsi_activate_tcq(sdev, dev->openings + dev->active);
break;
default:
/*
Expand All @@ -1352,9 +1350,7 @@ ahd_platform_set_tags(struct ahd_softc *ahd, struct ahd_devinfo *devinfo,
* serially on the controller/device. This should
* remove some latency.
*/
scsi_adjust_queue_depth(sdev,
/*NON-TAGGED*/0,
/*queue depth*/2);
scsi_deactivate_tcq(sdev, 1);
break;
}
}
Expand Down

0 comments on commit 0aa800d

Please sign in to comment.