Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d6a451dd authored by Roel Kluin's avatar Roel Kluin Committed by James Bottomley
Browse files

[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: default avatarRoel Kluin <12o3l@tiscali.nl>
Signed-off-by: default avatarJames Bottomley <James.Bottomley@HansenPartnership.com>
parent 62e9f5c4
Loading
Loading
Loading
Loading
+1 −1
Original line number Original line Diff line number Diff line
@@ -1216,7 +1216,7 @@ static void scsi_to_dev_dir(unsigned int i, unsigned int j) {
      cpp->xdir = DTD_IN;
      cpp->xdir = DTD_IN;
      return;
      return;
      }
      }
   else if (SCpnt->sc_data_direction == DMA_FROM_DEVICE) {
   else if (SCpnt->sc_data_direction == DMA_TO_DEVICE) {
      cpp->xdir = DTD_OUT;
      cpp->xdir = DTD_OUT;
      return;
      return;
      }
      }