OpenOCD
flash/nand/fileio.c File Reference
Include dependency graph for flash/nand/fileio.c:

Go to the source code of this file.

Functions

 COMMAND_HELPER (nand_fileio_parse_args, struct nand_fileio_state *state, struct nand_device **dev, enum fileio_access filemode, bool need_size, bool sw_ecc)
 
int nand_fileio_cleanup (struct nand_fileio_state *state)
 
int nand_fileio_finish (struct nand_fileio_state *state)
 
void nand_fileio_init (struct nand_fileio_state *state)
 
int nand_fileio_read (struct nand_device *nand, struct nand_fileio_state *s)
 
int nand_fileio_start (struct command_invocation *cmd, struct nand_device *nand, const char *filename, int filemode, struct nand_fileio_state *state)
 

Variables

static struct nand_ecclayout nand_oob_16
 
static struct nand_ecclayout nand_oob_64
 

Function Documentation

◆ COMMAND_HELPER()

◆ nand_fileio_cleanup()

int nand_fileio_cleanup ( struct nand_fileio_state state)

Definition at line 86 of file flash/nand/fileio.c.

References ERROR_OK, fileio_close(), NULL, and state.

Referenced by COMMAND_HANDLER(), and nand_fileio_finish().

◆ nand_fileio_finish()

int nand_fileio_finish ( struct nand_fileio_state state)

Definition at line 98 of file flash/nand/fileio.c.

References duration_measure(), nand_fileio_cleanup(), and state.

Referenced by COMMAND_HANDLER().

◆ nand_fileio_init()

void nand_fileio_init ( struct nand_fileio_state state)

Definition at line 40 of file flash/nand/fileio.c.

References NAND_OOB_NONE, and state.

Referenced by COMMAND_HANDLER(), and COMMAND_HELPER().

◆ nand_fileio_read()

int nand_fileio_read ( struct nand_device nand,
struct nand_fileio_state s 
)

◆ nand_fileio_start()

int nand_fileio_start ( struct command_invocation cmd,
struct nand_device nand,
const char *  filename,
int  filemode,
struct nand_fileio_state state 
)

Variable Documentation

◆ nand_oob_16

struct nand_ecclayout nand_oob_16
static
Initial value:
= {
.eccbytes = 6,
.eccpos = {0, 1, 2, 3, 6, 7},
.oobfree = {
{.offset = 8,
.length = 8}
}
}

Definition at line 1 of file flash/nand/fileio.c.

Referenced by nand_fileio_start().

◆ nand_oob_64

struct nand_ecclayout nand_oob_64
static
Initial value:
= {
.eccbytes = 24,
.eccpos = {
40, 41, 42, 43, 44, 45, 46, 47,
48, 49, 50, 51, 52, 53, 54, 55,
56, 57, 58, 59, 60, 61, 62, 63
},
.oobfree = {
{.offset = 2,
.length = 38}
}
}

Definition at line 1 of file flash/nand/fileio.c.

Referenced by nand_fileio_start().