]> nv-tegra.nvidia Code Review - linux-3.10.git/blobdiff - drivers/scsi/sym53c8xx_2/sym_glue.c
[SCSI] correct the sym2 period setting routines
[linux-3.10.git] / drivers / scsi / sym53c8xx_2 / sym_glue.c
index 5ff83d214f128eed2ca780cf50fbc8f12a6fa07e..5b07c6ec3eccbc2845216d1fa1c1dce63039739d 100644 (file)
@@ -2038,8 +2038,9 @@ static void sym2_set_period(struct scsi_target *starget, int period)
        struct sym_hcb *np = sym_get_hcb(shost);
        struct sym_tcb *tp = &np->target[starget->id];
 
-       /* have to have DT for these transfers */
-       if (period <= np->minsync)
+       /* have to have DT for these transfers, but DT will also
+        * set width, so check that this is allowed */
+       if (period <= np->minsync && spi_width(starget))
                tp->tgoal.dt = 1;
 
        tp->tgoal.period = period;