diff options
| author | Kamal Dasu <kdasu.kdev@gmail.com> | 2014-05-01 20:51:19 -0400 |
|---|---|---|
| committer | Brian Norris <computersforpeace@gmail.com> | 2014-05-20 19:35:32 -0400 |
| commit | 66507c7bc8895f0da6b4ad87e96d61a9f7d7a118 (patch) | |
| tree | a011e33764deec5b848280f3f2ed386f60967929 /include/linux/mtd | |
| parent | 6e5221558d35563dc656833a021543fba8185c41 (diff) | |
mtd: nand: Add support to use nand_base poi databuf as bounce buffer
nand_base can be passed a kmap()'d buffers from highmem by
filesystems like jffs2. This results in failure to map the
physical address of the DMA buffer on various contoller
driver on different platforms. This change adds a chip option
to use preallocated databuf as bounce buffers used in
nand_do_read_ops() and nand_do_write_ops().
This allows for specific nand controller driver to set this
option as needed.
Signed-off-by: Kamal Dasu <kdasu.kdev@gmail.com>
Signed-off-by: Brian Norris <computersforpeace@gmail.com>
Diffstat (limited to 'include/linux/mtd')
| -rw-r--r-- | include/linux/mtd/nand.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/include/linux/mtd/nand.h b/include/linux/mtd/nand.h index 7a922e6c4e4b..2f0af2891f0f 100644 --- a/include/linux/mtd/nand.h +++ b/include/linux/mtd/nand.h | |||
| @@ -176,6 +176,11 @@ typedef enum { | |||
| 176 | /* Chip may not exist, so silence any errors in scan */ | 176 | /* Chip may not exist, so silence any errors in scan */ |
| 177 | #define NAND_SCAN_SILENT_NODEV 0x00040000 | 177 | #define NAND_SCAN_SILENT_NODEV 0x00040000 |
| 178 | /* | 178 | /* |
| 179 | * This option could be defined by controller drivers to protect against | ||
| 180 | * kmap'ed, vmalloc'ed highmem buffers being passed from upper layers | ||
| 181 | */ | ||
| 182 | #define NAND_USE_BOUNCE_BUFFER 0x00080000 | ||
| 183 | /* | ||
| 179 | * Autodetect nand buswidth with readid/onfi. | 184 | * Autodetect nand buswidth with readid/onfi. |
| 180 | * This suppose the driver will configure the hardware in 8 bits mode | 185 | * This suppose the driver will configure the hardware in 8 bits mode |
| 181 | * when calling nand_scan_ident, and update its configuration | 186 | * when calling nand_scan_ident, and update its configuration |
