Re: [PATCH RFC 2/2] MIPS: dt: Explicitly specify native endian behaviour for syscon

From: Johannes Berg
Date: Wed Jan 27 2016 - 05:46:11 EST


On Wed, 2016-01-27 at 11:33 +0100, Jonas Gorski wrote:
>Â
> > +++ b/arch/mips/boot/dts/brcm/bcm6368.dtsi
> > @@ -54,7 +54,7 @@
> > ÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂperiph_cntl: syscon@10000000 {
> > ÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂcompatible = "syscon";
> > ÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂreg = <0x10000000 0x14>;
> > -ÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂlittle-endian;
> > +ÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂnative-endian;
>
> But native-endian == big-endian usually for bcm63xx, so is this
> actually a bugfix?
>

It's complicated :)

These were originally specified as little-endian because it _worked_,
but that was only because of an issue with the code - it was getting
byteswapped twice.

This was "fixed" in commitÂ29bb45f25ff3051354ed330c0d0f10418a2b8c7c,
and I assume this DT file was created/copied before that commit and
didn't get that update due to merge delays. So after that commit, this
file couldn't have worked, but that's how it got to this point.

johannes