linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* ARM1176 register writes are in reverse?
@ 2009-10-06 12:10 Nicholas Van Orton
  2009-10-06 12:56 ` Steve Chen
  2009-10-06 13:12 ` Ben Dooks
  0 siblings, 2 replies; 4+ messages in thread
From: Nicholas Van Orton @ 2009-10-06 12:10 UTC (permalink / raw)
  To: linux-arm-kernel

Hi,

I noticed that register writes to ARM1176 need to be in the reverse
order. That is, lets say I need to write 0xABCD to a register. But in
the actual write using __raw_writel() the value needs to be changed to
0xCDAB. Why is this so? The Davinci or OMAP on the other hand for
example, which is an ARM 926 does not need any such manipulation. Why
is the ARM1176 an exception?

Thanks,
Nicholas

^ permalink raw reply	[flat|nested] 4+ messages in thread

* ARM1176 register writes are in reverse?
  2009-10-06 12:10 ARM1176 register writes are in reverse? Nicholas Van Orton
@ 2009-10-06 12:56 ` Steve Chen
  2009-10-06 13:12 ` Ben Dooks
  1 sibling, 0 replies; 4+ messages in thread
From: Steve Chen @ 2009-10-06 12:56 UTC (permalink / raw)
  To: linux-arm-kernel

On Tue, 2009-10-06 at 17:40 +0530, Nicholas Van Orton wrote:
> Hi,
> 
> I noticed that register writes to ARM1176 need to be in the reverse
> order. That is, lets say I need to write 0xABCD to a register. But in
> the actual write using __raw_writel() the value needs to be changed to
> 0xCDAB. Why is this so? The Davinci or OMAP on the other hand for
> example, which is an ARM 926 does not need any such manipulation. Why
> is the ARM1176 an exception?
> 

Are you working with TI Puma5?  I suspect that reverse order is probably
due to specific hardware endianness implementation rather than generic
difference between ARM1176 and ARM926.

Regards,

Steve

^ permalink raw reply	[flat|nested] 4+ messages in thread

* ARM1176 register writes are in reverse?
  2009-10-06 12:10 ARM1176 register writes are in reverse? Nicholas Van Orton
  2009-10-06 12:56 ` Steve Chen
@ 2009-10-06 13:12 ` Ben Dooks
  2009-10-06 13:28   ` Nicholas Van Orton
  1 sibling, 1 reply; 4+ messages in thread
From: Ben Dooks @ 2009-10-06 13:12 UTC (permalink / raw)
  To: linux-arm-kernel

On Tue, Oct 06, 2009 at 05:40:36PM +0530, Nicholas Van Orton wrote:
> Hi,
> 
> I noticed that register writes to ARM1176 need to be in the reverse
> order. That is, lets say I need to write 0xABCD to a register. But in
> the actual write using __raw_writel() the value needs to be changed to
> 0xCDAB. Why is this so? The Davinci or OMAP on the other hand for
> example, which is an ARM 926 does not need any such manipulation. Why
> is the ARM1176 an exception?

No, works fine for all the Samsung ARM11 chips. Sounds like either you're
running the core big-endian, or part of your bus is big-endian?

-- 
Ben

Q:      What's a light-year?
A:      One-third less calories than a regular year.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* ARM1176 register writes are in reverse?
  2009-10-06 13:12 ` Ben Dooks
@ 2009-10-06 13:28   ` Nicholas Van Orton
  0 siblings, 0 replies; 4+ messages in thread
From: Nicholas Van Orton @ 2009-10-06 13:28 UTC (permalink / raw)
  To: linux-arm-kernel

On Tue, Oct 6, 2009 at 6:42 PM, Ben Dooks <ben-linux@fluff.org> wrote:
> On Tue, Oct 06, 2009 at 05:40:36PM +0530, Nicholas Van Orton wrote:
>> Hi,
>>
>> I noticed that register writes to ARM1176 need to be in the reverse
>> order. That is, lets say I need to write 0xABCD to a register. But in
>> the actual write using __raw_writel() the value needs to be changed to
>> 0xCDAB. Why is this so? The Davinci or OMAP on the other hand for
>> example, which is an ARM 926 does not need any such manipulation. Why
>> is the ARM1176 an exception?
>
> No, works fine for all the Samsung ARM11 chips. Sounds like either you're
> running the core big-endian, or part of your bus is big-endian?
>

Thank you for the mail. Yes, that was the case. I had set the ARM core
to bigendian (and forgot about it), works as expected when that code
was removed. So this was really much ado about nothing. Sorry for the
trouble :-(

Regards,
Nicholas

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2009-10-06 13:28 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-10-06 12:10 ARM1176 register writes are in reverse? Nicholas Van Orton
2009-10-06 12:56 ` Steve Chen
2009-10-06 13:12 ` Ben Dooks
2009-10-06 13:28   ` Nicholas Van Orton

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).