diff options
author | Huang Shijie <b32955@freescale.com> | 2012-03-11 22:22:18 -0400 |
---|---|---|
committer | David Woodhouse <David.Woodhouse@intel.com> | 2012-03-26 19:56:52 -0400 |
commit | 09ef90d965fff295da8d5359ac21e54c02236dba (patch) | |
tree | e13b620b0413f71954eb53390ed2c5461d31265a /drivers/mtd | |
parent | 6a918bade9dab40aaef80559bd1169c69e8d69cb (diff) |
mtd: gpmi: fix the wrong DMA command.
The last DMA command of ECC read page is used to disable the BCH module.
But the original code missed to set the pio[2] which is used to set the
GPMI_HW_GPMI_ECCCTRL register. fix it now.
Signed-off-by: Huang Shijie <b32955@freescale.com>
Signed-off-by: Artem Bityutskiy <artem.bityutskiy@linux.intel.com>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Diffstat (limited to 'drivers/mtd')
-rw-r--r-- | drivers/mtd/nand/gpmi-nand/gpmi-lib.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/mtd/nand/gpmi-nand/gpmi-lib.c b/drivers/mtd/nand/gpmi-nand/gpmi-lib.c index 5e3c5051e6a2..c34dab17682e 100644 --- a/drivers/mtd/nand/gpmi-nand/gpmi-lib.c +++ b/drivers/mtd/nand/gpmi-nand/gpmi-lib.c | |||
@@ -1061,8 +1061,9 @@ int gpmi_read_page(struct gpmi_nand_data *this, | |||
1061 | | BF_GPMI_CTRL0_ADDRESS(address) | 1061 | | BF_GPMI_CTRL0_ADDRESS(address) |
1062 | | BF_GPMI_CTRL0_XFER_COUNT(geo->page_size); | 1062 | | BF_GPMI_CTRL0_XFER_COUNT(geo->page_size); |
1063 | pio[1] = 0; | 1063 | pio[1] = 0; |
1064 | pio[2] = 0; /* clear GPMI_HW_GPMI_ECCCTRL, disable the BCH. */ | ||
1064 | desc = channel->device->device_prep_slave_sg(channel, | 1065 | desc = channel->device->device_prep_slave_sg(channel, |
1065 | (struct scatterlist *)pio, 2, | 1066 | (struct scatterlist *)pio, 3, |
1066 | DMA_TRANS_NONE, | 1067 | DMA_TRANS_NONE, |
1067 | DMA_PREP_INTERRUPT | DMA_CTRL_ACK); | 1068 | DMA_PREP_INTERRUPT | DMA_CTRL_ACK); |
1068 | if (!desc) { | 1069 | if (!desc) { |