From: Peter Korsgaard <jacmet@sunsite•dk>
To: Paul Mackerras <paulus@samba•org>
Cc: linuxppc-dev@ozlabs•org, sfr@canb•auug.org.au
Subject: Re: Recently removed io accessors
Date: Sat, 14 Oct 2006 13:57:03 +0200 [thread overview]
Message-ID: <8764ent8j4.fsf@sleipner.barco.com> (raw)
In-Reply-To: <17712.7972.493547.357685@cargo.ozlabs.ibm.com> (Paul Mackerras's message of "Sat, 14 Oct 2006 09:20:04 +1000")
>>>>> "PM" == Paul Mackerras <paulus@samba•org> writes:
Hi,
>> Endian register set to little endian (default at powerup):
RedBoot> x -b 0x8e000064 -2 -l 4
>> 8E000064: 4321 8765
RedBoot> x -b 0x8e000064 -4 -l 4
>> 8E000064: 43218765
PM> Which is neither big-endian nor little-endian, but something more
PM> like vax-endian (or pdp11-endian), but not exactly that either -
PM> vax-endian would be 65872143. What a mess.
Yes :/
PM> Clearly the "big endian" bit on the chip doesn't actually switch
PM> between little-endian and big-endian at all, but just acts to
PM> invert the 0x2 bit of the address...
Exactly.
PM> So the two hardware bogosities taken together leave you with only
PM> one combination that is anything like usable. I suggest that you
PM> code up a loop of readw (or equivalent) in the driver with a big
PM> comment explaining why you need to do it that way.
It doesn't have to be readw (16bit accesses). Enabling the BE mode and
using _outsl/_insl (32bit access with byteswap) works fine.
Let me repeat my question:
Could I get _outsl/_insl re-added to kernel/misc.S or do I have to
reimplement it somewhere else (platform file or smc911x.h)?
--
Bye, Peter Korsgaard
next prev parent reply other threads:[~2006-10-14 11:57 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-10-12 15:44 Recently removed io accessors Peter Korsgaard
2006-10-13 0:04 ` Benjamin Herrenschmidt
2006-10-13 6:56 ` Peter Korsgaard
2006-10-13 7:31 ` Benjamin Herrenschmidt
2006-10-13 8:43 ` Peter Korsgaard
2006-10-13 9:30 ` Benjamin Herrenschmidt
2006-10-13 9:55 ` Peter Korsgaard
2006-10-13 12:18 ` Benjamin Herrenschmidt
2006-10-13 12:38 ` Peter Korsgaard
2006-10-13 23:20 ` Paul Mackerras
2006-10-14 11:57 ` Peter Korsgaard [this message]
2006-10-16 16:51 ` Linas Vepstas
2006-10-16 18:54 ` Peter Korsgaard
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=8764ent8j4.fsf@sleipner.barco.com \
--to=jacmet@sunsite$(echo .)dk \
--cc=linuxppc-dev@ozlabs$(echo .)org \
--cc=paulus@samba$(echo .)org \
--cc=sfr@canb$(echo .)auug.org.au \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox