RFC: figuring out bus behaviour on these mips32r2 chips
Warner Losh
imp at bsdimp.com
Thu Jan 8 22:55:29 UTC 2015
> On Jan 7, 2015, at 6:03 PM, Adrian Chadd <adrian at FreeBSD.org> wrote:
>
> Hi,
>
> I found that the new QCA955x chip (and some of the QCA934x things in
> shipping products versus what I have on my desk at home) behave poorly
> unless I do ye olde "write to register; read from register to flush"
> paradigm.
>
> In this specific instance, it's the MDIO controller on each MAC - if I
> do a read-after-write to those registers, everything is peachy.
> Without it - and even with a call to wmb() - it still barfs.
>
> Now, I went digging through the mips code, and wmb() -> mips_sync() ->
> just a sync operation. It doesn't do any other kind of barrier.
>
> So - what's the mips32r2 spec require us to do for ensuring device IO
> has made it out to devices and we enforce ordering? Are we missing
> something in our mips_sync() implementation?
SYNC is supposed to be SYNC. An absolute barrier, but that may have weakened to being merely a strong ordering instruction such that all writes before it happen before all writes after it.
Warner
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 842 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: <http://lists.freebsd.org/pipermail/freebsd-mips/attachments/20150108/d78668b2/attachment.sig>
More information about the freebsd-mips
mailing list