Skip to content

Commit

Permalink
[PATCH] libata: fix ata_xfer_tbl termination
Browse files Browse the repository at this point in the history
ata_xfer_tbl is terminated by entry with -1 as ->shift.  However,
->shift was unsigned int making the termination condition bogus.  This
patch converts ->shift and ->bits to int.

Signed-off-by: Tejun Heo <htejun@gmail.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
  • Loading branch information
Tejun Heo authored and Jeff Garzik committed Mar 31, 2006
1 parent 8e0e694 commit be9a50c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/scsi/libata-core.c
Original file line number Diff line number Diff line change
Expand Up @@ -278,7 +278,7 @@ static void ata_unpack_xfermask(unsigned int xfer_mask,
}

static const struct ata_xfer_ent {
unsigned int shift, bits;
int shift, bits;
u8 base;
} ata_xfer_tbl[] = {
{ ATA_SHIFT_PIO, ATA_BITS_PIO, XFER_PIO_0 },
Expand Down

0 comments on commit be9a50c

Please sign in to comment.