diff mbox

mtd: OOPS accessing flash operations over STM flash on PXA

Message ID E913911567467945BBEB9277E27868B001494AE7@msiexch01.marvell.com
State New, archived
Headers show

Commit Message

Eric Miao Nov. 17, 2008, 9:31 a.m. UTC
Acked-by: Eric Miao <eric.miao@marvell.com>

David, please consider merge, thanks.

-----Original Message-----
From: den@sw.ru [mailto:den@sw.ru] On Behalf Of Denis V. Lunev
Sent: Monday, November 17, 2008 5:22 PM
To: dwmw2@infradead.org
Cc: linux-mtd@lists.infradead.org; Eric Miao; Denis V. Lunev
Subject: [PATCH] mtd: OOPS accessing flash operations over STM flash on
PXA

STM 2Gb flash is a large-page NAND flash. Set operations accordingly.
This field is dereferrenced without a check in several places resulting
in OOPS (seen in reality).

Signed-off-by: Denis V. Lunev <den@openvz.org>
---
 drivers/mtd/nand/pxa3xx_nand.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

 	.flash_width = 16,
diff mbox

Patch

diff --git a/drivers/mtd/nand/pxa3xx_nand.c
b/drivers/mtd/nand/pxa3xx_nand.c
index c0fa9c9..15f0a26 100644
--- a/drivers/mtd/nand/pxa3xx_nand.c
+++ b/drivers/mtd/nand/pxa3xx_nand.c
@@ -269,6 +269,7 @@  static struct pxa3xx_nand_timing stm2GbX16_timing =
{
 
 static struct pxa3xx_nand_flash stm2GbX16 = {
 	.timing = &stm2GbX16_timing,
+	.cmdset	= &largepage_cmdset,
 	.page_per_block = 64,
 	.page_size = 2048,