[PATCH 5/5] arm: boot: store ATAGs structure into DT "/chosen/linux,atags" entry
Russell King - ARM Linux
linux at arm.linux.org.uk
Tue Dec 15 04:20:38 PST 2015
On Tue, Dec 15, 2015 at 10:33:25AM +0100, Pali Rohár wrote:
> So am I understand correctly that solution would be to hack
> arch/arm/mm/mmu.c to not overwrite page at PHYS_OFFSET?
That's completely unnecessary: there are enough platform hooks to cope
with whatever the platform requires.
If you want to reserve the memory, then you have the ->reserve callback,
where you can call:
memblock_reserve(PHYS_OFFSET, PAGE_SIZE);
if you wish to prevent the first page being overwritten. You're then
responsible for freeing this page later in the boot sequence, or you
could just keep it around and refer to the atags in that page directly.
You could also just save_atags() in there, with a comment saying that
this is a work-around for N900 which needs the ATAGs saved, and this
is allowed in ->reserve as a special exception.
--
RMK's Patch system: http://www.arm.linux.org.uk/developer/patches/
FTTC broadband for 0.8mile line: currently at 9.6Mbps down 400kbps up
according to speedtest.net.
More information about the linux-arm-kernel
mailing list