Skip to content

Commit

Permalink
mtd: pxa3xx_nand: Fix PIO data transfer
Browse files Browse the repository at this point in the history
The shift operator used here to convert from bytes to 32-bit words is
backwards.

Signed-off-by: David Hunter <hunterd42@gmail.com>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
  • Loading branch information
David Hunter authored and David Woodhouse committed Nov 30, 2009
1 parent 6b0d9a8 commit 98ecc91
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/mtd/nand/pxa3xx_nand.c
Original file line number Diff line number Diff line change
Expand Up @@ -489,7 +489,7 @@ static int handle_data_pio(struct pxa3xx_nand_info *info)
switch (info->state) {
case STATE_PIO_WRITING:
__raw_writesl(info->mmio_base + NDDB, info->data_buff,
info->data_size << 2);
info->data_size >> 2);

enable_int(info, NDSR_CS0_BBD | NDSR_CS0_CMDD);

Expand All @@ -501,7 +501,7 @@ static int handle_data_pio(struct pxa3xx_nand_info *info)
break;
case STATE_PIO_READING:
__raw_readsl(info->mmio_base + NDDB, info->data_buff,
info->data_size << 2);
info->data_size >> 2);
break;
default:
printk(KERN_ERR "%s: invalid state %d\n", __func__,
Expand Down

0 comments on commit 98ecc91

Please sign in to comment.