add flash/nor/core.[ch]
commitc65d94f7d0e0c511794ea1f42ddf01e66f97e236
authorZachary T Welch <zw@superlucidity.net>
Fri, 4 Dec 2009 01:14:07 +0000 (3 17:14 -0800)
committerZachary T Welch <zw@superlucidity.net>
Fri, 4 Dec 2009 11:34:33 +0000 (4 03:34 -0800)
tree5e827fb66fb6b67ea505b9b34d614cc67d4956c2
parent3cb0b56005059314c8d09d2f8574042a4352dab4
add flash/nor/core.[ch]

The newly moved flash TCL routines access the internals of the module
too much.  Fix the layering issues by adding new core NOR flash APIs:

<flash/nor/core.h>:
  - flash_driver_find_by_name() - self-descriptive

<flash/nor/imp.h>:
  - flash_bank_add()            - encapsulates adding banks to bank list
  - flash_bank_list()           - encapsulates retreiving bank list

This allows the externs in flash/nor/imp.h to be removed, and
these mechanisms may now be re-used by other flash module code.
src/flash/nor/Makefile.am
src/flash/nor/core.c [copied from src/flash/nor/imp.h with 66% similarity]
src/flash/nor/core.h [copied from src/flash/nor/imp.h with 82% similarity]
src/flash/nor/imp.h
src/flash/nor/tcl.c