[PATCH v3 14/15] mtd: nand: pxa3xx: Increase data buffer size

Brian Norris computersforpeace at gmail.com
Sat Aug 10 23:30:45 EDT 2013


On Sat, Aug 10, 2013 at 04:35:04PM -0300, Ezequiel Garcia wrote:
> Devices with 4 KiB pages (plus OOB data) can be detected, so we increase
> the data buffer size. A better solution would be to allocate a buffer
> depending on the detected page size, but that's not possible given
> we need the buffer prior to the device detection.

Another possibility (for future work, maybe) is that you allocate a
smaller buffer that fits what you need for "device detection" (I presume
it's just for ONFI parameter page commands?), then reallocate the buffer
between nand_scan_ident() and nand_scan_tail() according to page size.
There are some other similar buffers throughout NAND that use a fixed
NAND_MAX_OOBSIZE and NAND_MAX_PAGESIZE.

> Signed-off-by: Ezequiel Garcia <ezequiel.garcia at free-electrons.com>
> Tested-by: Daniel Mack <zonque at gmail.com>

...

Brian



More information about the linux-mtd mailing list