asm/io.h; why does writel() write an le32 on ppc?

3 messages, 3 authors, 2001-03-06 · open the first message on its own page

asm/io.h; why does writel() write an le32 on ppc?

From: Brad Parker <hidden>
Date: 2001-03-06 23:15:01

Sorry to be daft, but why does writel() write an le32 on the ppc?

in asm/io.h it uses out_le32, unless the machine is an APUS, in which
case it just writes big endian...

(is PCI defined as little endian?)

-brad


** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/

Re: asm/io.h; why does writel() write an le32 on ppc?

From: Gabriel Paubert <hidden>
Date: 2001-03-06 23:23:13

On Tue, 6 Mar 2001, Brad Parker wrote:
Sorry to be daft, but why does writel() write an le32 on the ppc?

in asm/io.h it uses out_le32, unless the machine is an APUS, in which
case it just writes big endian...

(is PCI defined as little endian?)
Sadly, yes.

	Gabriel.


** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/

Re: asm/io.h; why does writel() write an le32 on ppc?

From: Jeff Garzik <hidden>
Date: 2001-03-06 23:30:15

Brad Parker wrote:
Sorry to be daft, but why does writel() write an le32 on the ppc?
(is PCI defined as little endian?)
Yes.  But there is always __raw_{read,write}[bwl].  That is part of the
API too.

Caveat programmer, though: IIRC there are other differences besides
endian when using __raw_xxx.  I think there might be a lack of flushing,
etc., too.

--
Jeff Garzik       | "You see, in this world there's two kinds of
Building 1024     |  people, my friend: Those with loaded guns
MandrakeSoft      |  and those who dig. You dig."  --Blondie

** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help