Skip to contentSkip to conversation

3.11-rc7 big endian - atags and bootloader updates

DISCUSSION Ben Dooks 1 participant 1 message Sep 3, 2013 1 message not in the archive

lore
Share & tools
lore

Ben Dooks

author
#1 lore raw
In reply to a message not in the archive
Quoted 10 lines · Dave Martin
Quoted 5 lines · Ben Dooks

This series is to better support older bootloaders, especially the ones that still pass some information in the ATAGS structure used by pre-fdt booting. The series is available at:

	git://git.baserock.org/delta/linux baserock/311-rc7/be/atags-v2

This seems a good idea, but it is a change to the boot protocol which may break any existing BE bootloader today. Are you sure this won't cause problems for anyone?

You have to manually select it, so not really.

Quoted 6 lines

One partial solution could be to make the ATAGs endianness-agnostic.

Since the ATAGs start with ATAG core, we know that the word at offset <atags base + 4> must have the value 0x54410001. If we see a backwards value, we know the ATAGs are wrong-endian and every word must must be swabbed.

That would be possible, I will look into that.

Quoted 4 lines

What to do about the zImage magic is less clear. Up to this point, BE kernels have always had backwards magic. Changing the magic might upset existing bootloaders, but I've never used a BE be bootloader, so I can't really comment on that...

This series uses a specific configuration to change both the ATAG and magic if the system is meant to be big-endian, but booted on a little-endian system.

Quoted 4 lines

Documentation/arm/Booting should also be updated to reflect any change. In fact, what's already there could use clarification, since there is no statement about endianness at all yet.

Ok, good idea.

Signature · 2 lines
Ben Dooks				http://www.codethink.co.uk/
Senior Engineer				Codethink - Providing Genius