Nandctl

From embeddedTS Manuals
Revision as of 15:27, 10 August 2011 by Mark (talk | contribs) (Created page with "= Overview = The utility sdctl allows manipulation of the FPGA XNAND core. This allows to you read/write data, and present a network block device to the OS. = Usage = == He...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Overview

The utility sdctl allows manipulation of the FPGA XNAND core. This allows to you read/write data, and present a network block device to the OS.

Usage

Help

General options:
  -R, --read=N            Read N blocks of flash to stdout
  -W, --write=N           Write N blocks to flash
  -x, --writeset=BYTE     Write BYTE as value (default 0)
  -i, --writeimg=FILE     Use FILE as file to write to NAND
  -t, --writetest         Run write speed test
  -r, --readtest          Run read speed test
  -n, --random=SEED       Do random seeks for tests
  -z, --blocksize=SZ      Use SZ bytes each read/write call
  -k, --seek=SECTOR       Seek to 512b sector number SECTOR
  -e, --erase=NSECTORS    Erase NSECTORS 512b sectors
  -d, --nbdserver=NBDSPEC Run NBD userspace block driver server
  -I, --bind=IPADDR       Bind NBD server to IPADDR
  -Q, --stats             Print NBD server stats
  -f, --foreground        Run NBD server in foreground
  -l, --lun=N             Use chip number N
  -X, --xnand             Use XNAND RAID layer
  -A, --autormw           Use AUTORMW layer
  -s, --stress=BLOCK      Stress block BLOCK until it breaks
  -H, --hwtest=BLOCK      Hardware profile block BLOCK
  -b, --break=SECTOR      Erase sector SECTOR for testing
  -I, --xnandinit=NSECT   Initialize flash chip for XNAND RAID
  -L, --listbb            List all factory bad blocks
  -a, --audit             Check integrity of XNAND data
  -Y, --yes               Answer yes to all audit repairs
  -N, --no                Answer no to all audit repairs
  -v, --verbose           Be verbose (-vv for maximum)
  -P, --printmbr          Print MBR and partition table
  -M, --setmbr            Write MBR from environment variables
  -h, --help              This help

When running a NBD server, NBDSPEC is a comma separated list of
devices and partitions for the NBD servers starting at port 7525.
e.g. "lun0:part1,lun1:disc" corresponds to 2 NBD servers, one at port
7525 serving the first partition of chip #0, and the other at TCP
port 7526 serving the whole disc device of chip #1.