Re: Sparc memcpy question

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Roland,

First things first, you're asking the wrong person. =)

This sounds like a sparc specific question, so it should really be
addressed to the sparclinux mailing list as that's where the sparc
people hang out. I've CC'd that list in this mail.

On Thu, Jul 28, 2011 at 20:40, Roland Vossen <rvossen@xxxxxxxxxxxx> wrote:
> Hello Julian,
>
> I am testing our brcm80211 driver on a sparc64 machine. When executing a
> memcpy, I encountered an exception:
>
> memcpy(fffff8001cf3f46c, fffff8001cf3f57e, 4); results in:
>
> Kernel unaligned access at TPC[10489624] brcms_c_ioctl+0x64/0x740 [brcmsmac]
>
> I was under the impression that there are no alignment requirements for the
> pointers to memcpy, but perhaps I am wrong.

There are, they just happen to be small enough that you haven't noticed.

As far as I know, every architecture has some alignment requirements.
Sparc's are the most onerous. I don't know the full details, but I
believe that it needs to be aligned to the size of any reads. (so
reading an int - 4 bytes => 4 byte alignment on the addresses)

Thanks,

-- 
Julian Calaby

Email: julian.calaby@xxxxxxxxx
Profile: http://www.google.com/profiles/julian.calaby/
.Plan: http://sites.google.com/site/juliancalaby/
--
To unsubscribe from this list: send the line "unsubscribe sparclinux" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Kernel Development]     [DCCP]     [Linux ARM Development]     [Linux]     [Photo]     [Yosemite Help]     [Linux ARM Kernel]     [Linux SCSI]     [Linux x86_64]     [Linux Hams]

  Powered by Linux