m68k: coldfire: create internal register access defines

Greg Ungerer <[email protected]>
Newsgroups org.kernel.vger.linux-m68k
Message-ID <[email protected]>
The readx/writex family of IO access functions for ColdFire are
non-standard. They return native endian data for multi-byte access,
which on m68k/ColdFire is big-endian byte order. A number of places
need fixing to change readx/writex to be more standard - a lot of
the CPU/SoC architecture specific code and a number of drivers.

The existing ColdFire CPU/SoC architecture code is inconsistent in
how it accesses SoC hardware module registers. Both readx/writex
and __raw_readx/__raw_writex are used across the code base. To clean
this up this set of patches moves to an internal set of access
defines for the CPU/SoC architecture code. The following are defined
and used for all internal register access:

    8 bit read  -->  mcf_read8
    8 bit write -->  mcf_write8
   16 bit read  -->  mcf_read16
   16 bit write -->  mcf_write16
   32 bit read  -->  mcf_read32
   32 bit write -->  mcf_write32

To ease review I have broken the changes up a little, grouping major
blocks together instead of one huge patch.

Signed-off-by: Greg Ungerer <[email protected]>
---
 arch/m68k/coldfire/clk.c        |    8 +-
 arch/m68k/coldfire/device.c     |    8 +-
 arch/m68k/coldfire/dma_timer.c  |   12 +--
 arch/m68k/coldfire/intc-2.c     |   30 ++++-----
 arch/m68k/coldfire/intc-5249.c  |   10 +--
 arch/m68k/coldfire/intc-525x.c  |   12 +--
 arch/m68k/coldfire/intc-5272.c  |   20 +++---
 arch/m68k/coldfire/intc-simr.c  |   38 ++++++------
 arch/m68k/coldfire/intc.c       |   28 ++++-----
 arch/m68k/coldfire/m5206.c      |    2
 arch/m68k/coldfire/m520x.c      |   26 ++++----
 arch/m68k/coldfire/m523x.c      |   12 +--
 arch/m68k/coldfire/m5249.c      |   16 ++---
 arch/m68k/coldfire/m525x.c      |   12 +--
 arch/m68k/coldfire/m5272.c      |   16 ++---
 arch/m68k/coldfire/m527x.c      |   40 ++++++-------
 arch/m68k/coldfire/m528x.c      |   28 ++++-----
 arch/m68k/coldfire/m5307.c      |    2
 arch/m68k/coldfire/m53xx.c      |  122 ++++++++++++++++++++--------------------
 arch/m68k/coldfire/m5407.c      |    2
 arch/m68k/coldfire/m5441x.c     |   12 +--
 arch/m68k/coldfire/m54xx.c      |   18 ++---
 arch/m68k/coldfire/nettel.c     |   16 ++---
 arch/m68k/coldfire/pci.c        |   56 +++++++++---------
 arch/m68k/coldfire/pit.c        |   20 +++---
 arch/m68k/coldfire/reset.c      |    4 -
 arch/m68k/coldfire/sltimers.c   |   18 ++---
 arch/m68k/coldfire/stmark2.c    |   12 +--
 arch/m68k/coldfire/timers.c     |   38 ++++++------
 arch/m68k/include/asm/io_no.h   |   16 +++++
 arch/m68k/include/asm/mcfgpio.h |   12 +--
 arch/m68k/include/asm/nettel.h  |    4 -
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.