From: Roel Kluin <12o3l@tiscali.nl> Date: Wed, 6 Feb 2008 18:21:07 +0000 (+0100) Subject: [SCSI] u14-34f: fix data direction bug X-Git-Url: http://git.cdn.openwrt.org/?a=commitdiff_plain;h=d6a451dd4d7ec805f9a21bb1994ce8ceaecc8fe6;p=openwrt%2Fstaging%2Fblogic.git [SCSI] u14-34f: fix data direction bug Direction of data transfer 'DMA_FROM_DEVICE' was tested twice. DTD_OUT means transfer from host to device. This should occur when the direction of data transfer (sc_data_direction) is 'DMA_TO_DEVICE'. Signed-off-by: Roel Kluin <12o3l@tiscali.nl> Signed-off-by: James Bottomley --- diff --git a/drivers/scsi/u14-34f.c b/drivers/scsi/u14-34f.c index 662c00451be4..58d7eee4fe81 100644 --- a/drivers/scsi/u14-34f.c +++ b/drivers/scsi/u14-34f.c @@ -1216,7 +1216,7 @@ static void scsi_to_dev_dir(unsigned int i, unsigned int j) { cpp->xdir = DTD_IN; return; } - else if (SCpnt->sc_data_direction == DMA_FROM_DEVICE) { + else if (SCpnt->sc_data_direction == DMA_TO_DEVICE) { cpp->xdir = DTD_OUT; return; }