[U-Boot] [RFC] [PATCH V1 0/4] make egiga common to kirkwood and orion5x

Albert Aribaud albert.aribaud at free.fr
Sat Jun 26 00:01:14 CEST 2010


This patchset, based on the current u-boot.git master, is not intended
for inclusion in the upcoming v2010.06, as it is way too intrusive to
be safely integrated quickly; even though I have tested it on both an
orion5x-based ED Mini V2 for functionality and a kirkwood-based OpenRD
Client for regression avoidance, it will require testing on other
kirkwood-based boards which I do not have.

SHORT STORY

This patchset separates egiga from kirkwood then adds orion5x support
in egiga. It has been duly, and successfully, tested on an OpenRD-Client
after each of the four commits and on an EDMini V2 after the last commit.

LONG STORY

This is a set of four atomic commits.

the first commit separates the file renames from the content changes;
the second one removes functional dependencies; the third one deals
with cosmetic changes by removing any "KIRKWOOD", "KW", "kirkwood" or
"kw" from egiga symbols which are not actually kirkwood-related.

These three commits together perform the separation of egiga from
kirkwood.

The last commit adds the actual orion5s support. Note that it contains
an important change to egiga: the addition of the 'volatile' qualifier
to members of the structs representing egiga registers and descriptors.

This was needed on orion5x, as without the volatile qualifiers, reads
and writes th these structs could happen in unexpected order; in
egiga_send() this caused the egiga DMA engine to get started before
the DMA TX descriptor was actually filled in, with the effect that
the actual sent packet was all zeroes. I cannot explain why this did
not happen on kirkwood, except that maybe the CPU speed difference
made it possible for the core to finish writing the descriptor before
the DMA engine could start.

All comments welcome.

Albert Aribaud (4):
  ARM: Rename kirkwood_egiga driver to egiga
  egiga: Remove functional dependency on kirkwood
  egiga: remove references to kirkwood SoC
  egiga: add support for orion5x

 arch/arm/cpu/arm926ejs/kirkwood/cpu.c         |    4 +-
 arch/arm/cpu/arm926ejs/orion5x/cpu.c          |   18 +
 arch/arm/include/asm/arch-kirkwood/cpu.h      |    2 +-
 arch/arm/include/asm/arch-kirkwood/kirkwood.h |    7 +-
 arch/arm/include/asm/arch-orion5x/orion5x.h   |    5 +-
 board/LaCie/edminiv2/edminiv2.c               |   36 ++
 board/LaCie/edminiv2/edminiv2.h               |   41 ++
 drivers/net/Makefile                          |    2 +-
 drivers/net/egiga.c                           |  728 +++++++++++++++++++++++++
 drivers/net/egiga.h                           |  505 +++++++++++++++++
 drivers/net/kirkwood_egiga.c                  |  719 ------------------------
 drivers/net/kirkwood_egiga.h                  |  505 -----------------
 include/configs/edminiv2.h                    |   32 +-
 include/configs/guruplug.h                    |    4 +-
 include/configs/km_arm.h                      |    4 +-
 include/configs/mv88f6281gtw_ge.h             |    4 +-
 include/configs/openrd_base.h                 |    4 +-
 include/configs/rd6281a.h                     |    4 +-
 include/configs/sheevaplug.h                  |    4 +-
 include/netdev.h                              |    2 +-
 20 files changed, 1379 insertions(+), 1251 deletions(-)
 create mode 100644 board/LaCie/edminiv2/edminiv2.h
 create mode 100644 drivers/net/egiga.c
 create mode 100644 drivers/net/egiga.h
 delete mode 100644 drivers/net/kirkwood_egiga.c
 delete mode 100644 drivers/net/kirkwood_egiga.h



More information about the U-Boot mailing list