[MTD] [NAND] pxa3xx: fix non-page-aligned reads
authorMatt Reimer <mreimer@vpop.net>
Tue, 18 Nov 2008 18:47:42 +0000 (10:47 -0800)
committerDavid Woodhouse <David.Woodhouse@intel.com>
Mon, 5 Jan 2009 12:02:42 +0000 (13:02 +0100)
commit7f9938d0fd6c778bd0ce296a3e3b50266de2b892
tree25425680b8a1c53d12e6995aac6b9afb8b579ee6
parenta5cce42f357b3106fb0eacd85edec5ae31288956
[MTD] [NAND] pxa3xx: fix non-page-aligned reads

Reads from non-page-aligned addresses were broken because while the
address to read from was correctly written to NDCB*, a full page was
always read. Fix this by ignoring the column and only using the page
address.

I suspect this whole-page behavior is due to the controller's need to
read the entire page in order to generate correct ECC. In the non-ECC
case this could be optimized to use the column address, and to set the
read length to what is being requested rather than the length of an
entire page.

Signed-off-by: Matt Reimer <mreimer@vpop.net>
Signed-off-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
drivers/mtd/nand/pxa3xx_nand.c