From: Paul Mundt <lethal@linux-sh.org>
To: linux-sh@vger.kernel.org
Subject: Re: iomap API and big endian interactivity
Date: Tue, 03 Apr 2012 00:18:32 +0000 [thread overview]
Message-ID: <20120403001831.GA23761@linux-sh.org> (raw)
In-Reply-To: <20120329074038.GZ26543@linux-sh.org>
Hi Phil,
On Mon, Apr 02, 2012 at 01:20:33PM +0100, phil.edworthy@renesas.com wrote:
> > On Wed, Oct 12, 2011 at 09:03:24AM +0100, Phil Edworthy wrote:
> > > Commit 37b7a97884ba64bf7d403351ac2a9476ab4f1bba makes all ioread/iowrite
> > > functions treat registers as little endian. For SH2 this is not the case,
> > > they are big endian.
> > >
> > Ok, it looks like we're finally going to have to bite the bullet and
> > support I/O swabbing for the platforms that need it. I dislike this for
> > the reasons that the I/O accessors are supposed to be little endian and
> > in the PCI case we can deal with CPU vs host controller endianness
> > mismatches just fine, ensuring a consistent little endian space.
> ...
> >
> > Hopefully this will be all that's necessary for fixing up the SH-2(A) and
> > SH-4A big endian use cases. Boards can of course override the swabbing
> > behaviour where necessary, though I don't forsee much need to deviate
> > from the generic implementation any time soon given that we've ripped out
> > the address swizzling (in which case we could probably just inline it in
> > io.h directly).
>
> Works for me on sh7264 (sh2a).
>
Great, thanks for testing.
> Would you like me to add SWAP_IO_SPACE to all the sh2 defconfigs?
>
> One minor comment, this option won't show up in a config menu. Is that ok
> for devices that can be used as either big or little endian?
>
We can conditionalize that in the Kconfig language. So, something like:
select SWAP_IO_SPACE if CPU_BIG_ENDIAN
should do what you want.
prev parent reply other threads:[~2012-04-03 0:18 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-03-29 7:40 iomap API and big endian interactivity Paul Mundt
2012-04-02 13:08 ` phil.edworthy
2012-04-03 0:18 ` Paul Mundt [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20120403001831.GA23761@linux-sh.org \
--to=lethal@linux-sh.org \
--cc=linux-sh@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.