aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/mtd/nand
Commit message (Collapse)AuthorAgeFilesLines
* [PATCH] mtd/nand/cafe.c missing include of dma-mapping.hAl Viro2007-01-301-0/+1
| | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* [MTD] NAND: Support for 16-bit bus-width on AT91.Andrew Victor2006-12-081-0/+3
| | | | | | | | | | | | Add support for 16-bit NAND bus-width for the AT91 NAND driver. The 16-bit NAND is found on the Atmel AT91SAM9260-EK and AT91SAM9261-EK boards. Orignal Patch from Patrice Vilchez Signed-off-by: Andrew Victor <andrew@sanpeople.com> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
* [MTD] nandsim: bugfix in page addressingArtem Bityutskiy2006-12-081-2/+2
| | | | | | | Number of address bytes for 64-128 MiB NANDs is 4, not 5. Signed-off-by: Artem Bityutskiy <dedekind@infradead.org> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
* [MTD] NAND: use SmartMedia ECC byte order for ndfcTimo Lindhorst2006-12-051-0/+1
| | | | | | | | | | | | Select MTD_NAND_ECC_SMC (ECC byte order according to the Smart Media Specification) if MTD_NAND_NDFC is used. Using the wrong byte order causes fatal, unnoticed data damage. For further information see: http://lists.infradead.org/pipermail/linux-mtd/2006-November/016920.html Signed-off-by: Timo Lindhorst <lindhors@linux.vnet.ibm.com> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
* [MTD] [NAND] Compile fix in rfc_from4.cMariusz Kozlowski2006-12-011-1/+1
| | | | | | Signed-off-by: Mariusz Kozlowski <m.kozlowski@tuxland.pl> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
* Merge branch 'master' of ↵David Woodhouse2006-12-011-0/+1
|\ | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6
| * [PATCH] silence 'make xmldocs' warning by adding missing description of ↵Jesper Juhl2006-10-271-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | 'raw' in nand_base.c:1485 Add description of 'raw' in comments for drivers/mtd/nand/nand_base.c::nand_write_page_syndrome() so 'make xmldocs' will not spew a warning at us. Signed-off-by: Jesper Juhl <jesper.juhl@gmail.com> Acked-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* | [MTD] Remove trailing whitespaceDavid Woodhouse2006-11-304-535/+534
| | | | | | | | | | | | | | The newly-added cafe_ecc.c had a lot of it because of the way the lookup table was auto-generated; clean up the other files too while we're at it. Signed-off-by: David Woodhouse <dwmw2@infradead.org>
* | [MTD] NAND: add subpage write supportThomas Gleixner2006-11-291-9/+44
| | | | | | | | | | | | | | Many SLC NANDs support up to 4 writes at one NAND page. Add support of this feature. Signed-off-by: Artem Bityutskiy <dedekind@infradead.org>
* | [MTD] Tidy bitrev usage in rtc_from4.cAndrew Morton2006-11-291-1/+1
| | | | | | | | | | Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
* | [MTD] [NAND] fix ifdef option in nand_ecc.cTimo Lindhorst2006-11-291-2/+2
| | | | | | | | | | | | | | Fix up the config option in the #ifdef statements in nand_ecc.c Signed-off-by: Timo Lindhorst <lindhors@linux.vnet.ibm.com> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
* | [MTD] [NAND] Update CAFÉ driver interrupt handler prototypeDavid Woodhouse2006-11-291-1/+1
| | | | | | | | Signed-off-by: David Woodhouse <dwmw2@infradead.org>
* | [MTD] replace kmalloc+memset with kzallocBurman Yan2006-11-283-9/+4
| | | | | | | | | | Signed-off-by: Yan Burman <yan_952@hotmail.com> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
* | Merge git://git.infradead.org/~dwmw2/cafe-2.6David Woodhouse2006-11-284-1/+2162
|\ \
| * | [MTD] NAND: Fix ECC settings in CAFÉ controller driver.David Woodhouse2006-11-011-7/+3
| | | | | | | | | | | | | | | | | | | | | | | | We were resetting cafe->ctl2 to zero after an erase (and also during a write, but it was correctly reset after that). This meant that ECC reads after an erase were failing. Doh. Signed-off-by: David Woodhouse <dwmw2@infradead.org>
| * | [MTD] NAND: Add register debugging spew option to CAFÉ driverDavid Woodhouse2006-10-311-13/+13
| | | | | | | | | | | | Signed-off-by: David Woodhouse <dwmw2@infradead.org>
| * | [MTD] NAND: Use register #defines throughout CAFÉ driver, not numbersDavid Woodhouse2006-10-311-55/+63
| | | | | | | | | | | | | | | | | | | | | Also use cafe_readl() and cafe_writel() abstraction to make code slightly cleaner -- especially if we want to use it in PIO mode. Signed-off-by: David Woodhouse <dwmw2@infradead.org>
| * | [MTD] NAND: Fix timing calculation in CAFÉ debugging messageDavid Woodhouse2006-10-281-1/+2
| | | | | | | | | | | | Signed-off-by: David Woodhouse <dwmw2@infradead.org>
| * | [MTD] NAND: Remove empty block ECC workaroundDavid Woodhouse2006-10-271-27/+1
| | | | | | | | | | | | | | | | | | | | | They fixed the hardware so that ECC doesn't fail on reading an empty block. Signed-off-by: David Woodhouse <dwmw2@infradead.org>
| * | [MTD] NAND: Add ECC debugging for CAFÉDavid Woodhouse2006-10-271-3/+36
| | | | | | | | | | | | Signed-off-by: David Woodhouse <dwmw2@infradead.org>
| * | [MTD] CAFÉ NAND: Add 'slowtiming' parameter, default usedma and checkecc onDavid Woodhouse2006-10-271-11/+15
| | | | | | | | | | | | Signed-off-by: David Woodhouse <dwmw2@infradead.org>
| * | [MTD] NAND: Reset Café controller before initialising.David Woodhouse2006-10-271-0/+4
| | | | | | | | | | | | | | | | | | Fixes http://dev.laptop.org/ticket/237 Signed-off-by: David Woodhouse <dwmw2@infradead.org>
| * | [MTD] NAND: Café ECC -- remove spurious BUG_ON() in err_pos()David Woodhouse2006-10-271-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | Being a value which isn't in the table is a case we explicitly check for in the caller. Don't BUG_ON() because it does actually happen in practice. Signed-off-by: David Woodhouse <dwmw2@infradead.org>
| * | [MTD] NAND: Disable ECC checking on CAFÉ since it's broken for nowDavid Woodhouse2006-10-231-2/+5
| | | | | | | | | | | | Signed-off-by: David Woodhouse <dwmw2@infradead.org>
| * | [MTD] NAND: CAFÉ NAND driver cleanup, fix ECC on reading empty flashDavid Woodhouse2006-10-223-48/+109
| | | | | | | | | | | | Signed-off-by: David Woodhouse <dwmw2@infradead.org>
| * | [MTD] NAND: Add hardware ECC correction support to CAFÉ NAND driverDavid Woodhouse2006-10-222-13/+1385
| | | | | | | | | | | | Signed-off-by: David Woodhouse <dwmw2@infradead.org>
| * | Merge git://git.infradead.org/~dwmw2/cafe-2.6David Woodhouse2006-10-223-0/+706
| |\ \ | | | | | | | | | | | | | | | | | | | | Conflicts: drivers/mtd/nand/Kconfig
| | * | [MTD NAND] OLPC CAFÉ driver updateDavid Woodhouse2006-10-201-36/+99
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Fix OOB handling, bad block table marker placement - Some cleanups, enable runtime-optional debugging - Allow BBT stuff to be skipped Signed-off-by: David Woodhouse <dwmw2@infradead.org>
| | * | [MTD NAND] Initial import of CAFÉ NAND driver.David Woodhouse2006-10-063-0/+643
| | | | | | | | | | | | | | | | Signed-off-by: David Woodhouse <dwmw2@infradead.org>
* | | | [MTD] [NAND] remove len/ooblen confusion.Vitaly Wool2006-11-282-19/+37
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | As was discussed between Ricard Wanderlöf, David Woodhouse, Artem Bityutskiy and me, the current API for reading/writing OOB is confusing. The thing that introduces confusion is the need to specify ops.len together with ops.ooblen for reads/writes that concern only OOB not data area. So, ops.len is overloaded: when ops.datbuf != NULL it serves to specify the length of the data read, and when ops.datbuf == NULL, it serves to specify the full OOB read length. The patch inlined below is the slightly updated version of the previous patch serving the same purpose, but with the new Artem's comments taken into account. Artem, BTW, thanks a lot for your valuable input! Signed-off-by: Vitaly Wool <vwool@ru.mvista.com> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
* | | | [MTD] [NAND] Fix endianess bug in ndfc.cStefan Roese2006-11-281-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The writel() call accidentally clears all bits in the NDFC_CCR register (endianess problem). Now __raw_writel() is used instead. Tested on Bamboo with NAND on chip select 0 and chip select 1. Signed-off-by: Stefan Roese <sr@denx.de> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
* | | | [MTD] [NAND] rtc_from4.c: use lib/bitrev.cAdrian Bunk2006-11-282-42/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch converts drivers/mtd/nand/rtc_from4.c to use the new lib/bitrev.c Signed-off-by: Adrian Bunk <bunk@stusta.de> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
* | | | [MTD] NAND: Fix nand_default_mark_blockbad() when flash-based BBT disabledRicard Wanderlöf2006-10-261-1/+1
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When a flash-based BBT is not used, nand_default_mark_blockbad() is supposed to mark the block bad in the oob. However, it sets the wrong length variable so that no bad block marker is in fact written. This patch attempts to rectify that. (As note, it seems to be that logically, it shouldn't be necessary to set both length variables, as one appears to be for the main buffer, and one for the oob buffer, but this is how it is done in several places, including the code for the mtd character device MEMWRITEOOB and MEMREADOOB ioctls. I'm not sure if this is a temporary solution during some rework of the mtd infrastructure, or whether there is a deeper thought here.) Signed-off-by: Ricard Wanderlöf <ricardw@axis.com> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
* | | [MTD] NAND: Correct setting of chip->oob_poi OOB bufferDavid Woodhouse2006-10-221-1/+1
| | | | | | | | | | | | Signed-off-by: David Woodhouse <dwmw2@infradead.org>
* | | [MTD] NAND: Combined oob buffer so it's contiguous with dataDavid Woodhouse2006-10-211-10/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Ditch the separate oobrbuf and oobwbuf fields from the chip buffers, and use only a single buffer immediately after the data. This accommodates NAND controllers such as the OLPC CAFÉ chip, which can't do scatter/gather DMA so needs the OOB buffer to be contiguous with the data, for both read and write. Signed-off-by: David Woodhouse <dwmw2@infradead.org>
* | | Merge branch 'master' of ↵David Woodhouse2006-10-211-1/+1
|\ \ \ | | |/ | |/| | | | git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6
| * | [PATCH] mtd: remove several bogus casts to void * in iounmap() argumentAl Viro2006-10-101-1/+1
| | | | | | | | | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* | | [MTD] NAND: nandsim: support subpage writeArtem Bityutskiy2006-10-211-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | As flash cannot do 0->1 bit transitions when programming, do not do this in the simulator too. This makes nandsim able to accept subpage writes. Signed-off-by: Artem Bityutskiy <dedekind@infradead.org> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
* | | [MTD] core: trivial comments fixArtem Bityutskiy2006-10-211-6/+6
| | | | | | | | | | | | | | | Signed-off-by: Artem Bityutskiy <dedekind@infradead.org> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
* | | [MTD] NAND: nandsim coding style fixVijay Kumar2006-10-211-38/+19
| | | | | | | | | | | | | | | | | | | | | | | | Removes line break after return type in function definitions, to be consistent with the Linux coding style. Signed-off-by: Vijay Kumar <vijaykumar@bravegnu.org> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
* | | [MTD] NAND: nandsim page-wise allocation (2/2)Vijay Kumar2006-10-211-24/+138
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For page wise allocation, an array of flash page pointers is allocated during initialization. The flash pages are themselves allocated when a write occurs to the page. The flash pages are deallocated when they are erased. Signed-off-by: Vijay Kumar <vijaykumar@bravegnu.org> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
* | | [MTD] NAND: nandsim page-wise allocation (1/2)Vijay Kumar2006-10-211-22/+0
| | | | | | | | | | | | | | | | | | | | | | | | This patch removes code that does chip mapping. The chip mapping code is no longer used. Signed-off-by: Vijay Kumar <vijaykumar@bravegnu.org> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
* | | [MTD] NAND: AT91 NAND driverAndrew Victor2006-10-213-0/+228
|/ / | | | | | | | | | | | | | | | | | | This version only differs from version posted by Savin Zlobec (20 Jun 2006) in that the AT91RM9200-specific chip-select / bus setup code has been moved from the at91_nand.c driver into the processor-specific file. From: Savin Zlobec <savin@epico.si> Signed-off-by: Andrew Victor <andrew@sanpeople.com> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
* | Fix several typos in drivers/Matt LaPlante2006-10-031-1/+1
| | | | | | | | Signed-off-by: Adrian Bunk <bunk@stusta.de>
* | [MTD] Cleanup of 'ioremap balanced with iounmap for drivers/mtd subsystem'Amol Lad2006-10-021-1/+1
|/ | | | | | | | | | Updated version of patch, in response to comments from Francois Romieu <romieu@fr.zoreil.com> Remove gratuitous casts from iounmap and initialisation of variables. Signed-off-by: Amol Lad <amol@verismonetworks.com> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
* [MTD NAND] Allow override of page read and write functions.David Woodhouse2006-09-251-23/+21
| | | | | | | | - allow high-level nand_write_page() function to be overridden - likewise low-level write_page_raw() and read_page_raw() functions - Clean up the abuse of chip->ecc.{write,read}_page() with MTD_OOB_RAW Signed-off-by: David Woodhouse <dwmw2@infradead.org>
* [MTD NAND] Allocate chip->buffers separately to allow it to be overriddenDavid Woodhouse2006-09-252-15/+22
| | | | | | In particular, the board driver might need it to be DMAable. Signed-off-by: David Woodhouse <dwmw2@infradead.org>
* [MTD NAND] Split nand_scan() into two parts; allow board driver to interveneDavid Woodhouse2006-09-251-25/+65
| | | | Signed-off-by: David Woodhouse <dwmw2@infradead.org>
* [MTD NAND] Export nand_wait_ready() for use by board driversDavid Woodhouse2006-09-251-1/+2
| | | | Signed-off-by: David Woodhouse <dwmw2@infradead.org>
* [MTD NAND] Fix in typo ndfc.c causing wrong ECC layoutFrank Haverkamp2006-09-221-1/+1
| | | | | | | Due to this typo, a wrong ECC layout table is chosen. Signed-off-by: Frank Haverkamp <haver@vnet.ibm.com> Signed-off-by: David Woodhouse <dwmw2@infradead.org>