Commit 62d4f4365341576f5a5307b2b205a5aa2e3c6be6

Authored by Harald Welte
Committed by Wolfgang Denk
1 parent f540c42d95

Re-introduce the 'nand read.oob' and 'nand write.oob' commands

that used to exist with the legacy NAND code

Signed-off-by: Harald Welte <laforge@openmoko.org>

Showing 1 changed file with 8 additions and 0 deletions Side-by-side Diff

... ... @@ -347,6 +347,14 @@
347 347 opts.quiet = quiet;
348 348 ret = nand_write_opts(nand, &opts);
349 349 }
  350 + } else if (s != NULL && !strcmp(s, ".oob")) {
  351 + /* read out-of-band data */
  352 + if (read)
  353 + ret = nand->read_oob(nand, off, size, &size,
  354 + (u_char *) addr);
  355 + else
  356 + ret = nand->write_oob(nand, off, size, &size,
  357 + (u_char *) addr);
350 358 } else {
351 359 if (read)
352 360 ret = nand_read(nand, off, &size, (u_char *)addr);