summaryrefslogtreecommitdiff
path: root/src/flash/nand.h
diff options
context:
space:
mode:
authorDean Glazeski <dnglaze@gmail.com>2009-11-20 00:19:39 -0600
committerDavid Brownell <dbrownell@users.sourceforge.net>2009-12-03 16:44:27 -0800
commit9a51b8b0e3d0b629915a8248e2c112a01ffc93dc (patch)
tree1ddc2a287d67c46443c4845d4625ebeef62b62a5 /src/flash/nand.h
parent7e2dffbbff2534ca5afa52aa3d811b3599d2ca77 (diff)
downloadopenocd+libswd-9a51b8b0e3d0b629915a8248e2c112a01ffc93dc.tar.gz
openocd+libswd-9a51b8b0e3d0b629915a8248e2c112a01ffc93dc.tar.bz2
openocd+libswd-9a51b8b0e3d0b629915a8248e2c112a01ffc93dc.tar.xz
openocd+libswd-9a51b8b0e3d0b629915a8248e2c112a01ffc93dc.zip
NAND page command refactoring.
Created a new function that handles sending a command and the address information for pages to a NAND device. [dbrownell@users.sourceforge.net: tweaked line lengths, name 'oob_only'] Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Diffstat (limited to 'src/flash/nand.h')
-rw-r--r--src/flash/nand.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/flash/nand.h b/src/flash/nand.h
index d73aee14..230cf508 100644
--- a/src/flash/nand.h
+++ b/src/flash/nand.h
@@ -270,6 +270,9 @@ struct nand_device *get_nand_device_by_name(const char *name);
struct nand_device *get_nand_device_by_num(int num);
+int nand_page_command(struct nand_device *nand, uint32_t page,
+ uint8_t cmd, bool oob_only);
+
int nand_read_page_raw(struct nand_device *nand, uint32_t page,
uint8_t *data, uint32_t data_size, uint8_t *oob, uint32_t oob_size);
int nand_write_page_raw(struct nand_device *nand, uint32_t page,