diff options
author | Øyvind Harboe <oyvind.harboe@zylin.com> | 2010-09-28 15:37:56 +0200 |
---|---|---|
committer | Øyvind Harboe <oyvind.harboe@zylin.com> | 2010-09-29 08:43:27 +0200 |
commit | 3a693ef526575633cc350a69aa1a5d1f08e64c46 (patch) | |
tree | 6af64277137ac59254bf20d7d3ca175728a709bd /src/flash/nand | |
parent | ecad76061f6edff5db67ad05e6514dff6cd6efc7 (diff) | |
download | openocd_libswd-3a693ef526575633cc350a69aa1a5d1f08e64c46.tar.gz openocd_libswd-3a693ef526575633cc350a69aa1a5d1f08e64c46.tar.bz2 openocd_libswd-3a693ef526575633cc350a69aa1a5d1f08e64c46.tar.xz openocd_libswd-3a693ef526575633cc350a69aa1a5d1f08e64c46.zip |
fileio: refactor struct fileio to be an opaque structure
Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
Diffstat (limited to 'src/flash/nand')
-rw-r--r-- | src/flash/nand/fileio.c | 2 | ||||
-rw-r--r-- | src/flash/nand/tcl.c | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/src/flash/nand/fileio.c b/src/flash/nand/fileio.c index 3e397ebd..0a006fc0 100644 --- a/src/flash/nand/fileio.c +++ b/src/flash/nand/fileio.c @@ -180,7 +180,7 @@ COMMAND_HELPER(nand_fileio_parse_args, struct nand_fileio_state *state, return retval; if (!need_size) - state->size = state->fileio.size; + state->size = fileio_size(&state->fileio); *dev = nand; diff --git a/src/flash/nand/tcl.c b/src/flash/nand/tcl.c index 57bbe00e..a54f8ea8 100644 --- a/src/flash/nand/tcl.c +++ b/src/flash/nand/tcl.c @@ -389,8 +389,8 @@ COMMAND_HANDLER(handle_nand_dump_command) if (nand_fileio_finish(&s) == ERROR_OK) { command_print(CMD_CTX, "dumped %ld bytes in %fs (%0.3f KiB/s)", - (long)s.fileio.size, duration_elapsed(&s.bench), - duration_kbps(&s.bench, s.fileio.size)); + (long)fileio_size(&s.fileio), duration_elapsed(&s.bench), + duration_kbps(&s.bench, fileio_size(&s.fileio))); } return ERROR_OK; } |