Add arch_lmb_reserve() implemented using arch_lmb_reserve_generic().
This architecture also needs to cover U-Boot with LMB before booting
Linux.
Signed-off-by: Marek Vasut <marek.vasut+renesas@gmail.com>
Cc: Simon Goldschmidt <simon.k.r.goldschmidt@gmail.com>
Cc: Tom Rini <trini@konsulko.com>
#include <env.h>
#include <image.h>
#include <asm/byteorder.h>
+#include <asm/global_data.h>
#include <asm/zimage.h>
+DECLARE_GLOBAL_DATA_PTR;
+
#ifdef CONFIG_SYS_DEBUG
static void hexdump(unsigned char *buf, int len)
{
/* does not return */
return 1;
}
+
+static ulong get_sp(void)
+{
+ ulong ret;
+
+ asm("mov r15, %0" : "=r"(ret) : );
+ return ret;
+}
+
+void arch_lmb_reserve(struct lmb *lmb)
+{
+ arch_lmb_reserve_generic(lmb, get_sp(), gd->ram_top, 4096);
+}