Re: [PATCH] clean up access to locomo registers | |
| [Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] | |
On Thu, Jul 24, 2008 at 04:57:52AM +0800, eric miao wrote:
> On Thu, Jul 24, 2008 at 2:48 AM, Russell King - ARM Linux
> <linux@xxxxxxxxxxxxxxxx> wrote:
> > On Wed, Jul 23, 2008 at 04:17:11PM +0200, Thomas Kunze wrote:
> >> the locomo registers are accessed through ioremaped memory. Currently register read/writes
> >> use the locomo_readl/writel macros defined in include/asm-arm/hardware/locomo.h. This patch
> >> replaces the nonstandard locomo_readl/locomo_writel with the standard ioread16/iowrite16
> >> calls. The conversion to 16 bit access is intended. The locomo registers have a size of 16 bit.
> >
> > As I've said elsewhere, the readw/writew interfaces aren't deprecated.
> > If you only support MMIO (which, if you're using only ioremap on
> > resources, that's the case) then there's absolutely no point using
> > io{read,write}*.
> >
>
> Unfortunately, it looks like some such code has already been
> stuffed somehow into the mainline (I remember scoop to be
> such an example).
Oh great. One wonders why I bother...
> Yet I don't think scoop is supposed to be used on architectures
> featuring individual I/O space (like x86), where io{read,write}*
> becomes handy to use.
However, it seems to depend on headers only present on ARM (those
being asm/hardware.h and asm/hardware/locomo.h).
> Apart from that, it looks to me the architectural issue is more
> severe than the coding style ones. Esp. since now the new
> bus type is not encouraged any more, we may need to work it
> out in another way.
I see no reason to deprecate bus types. Deprecating them will just
lead to people implementing their own method of device creation and
driver binding, or inappropriately reusing platform devices (like
we're already seeing with people trying to wrap platform devices.)
-------------------------------------------------------------------
List admin: http://lists.arm.linux.org.uk/mailman/listinfo/linux-arm-kernel
FAQ: http://www.arm.linux.org.uk/mailinglists/faq.php
Etiquette: http://www.arm.linux.org.uk/mailinglists/etiquette.php
[Site Home] [Linux Arm] [Fedora ARM] [Gcc Help] [Git] [DCCP] [IETF Announce] [Security] [PDAs] [Linux] [Linux Book List] [Linux MIPS] [Yosemite Campsites] [Photos]
![]() |
|