|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] [PATCH 45/45] xen: arm: skanky "appended kernel" option
I'm using this with the ARMv8 Foundation model:
./Foundation_v8pkg/Foundation_v8 \
--image xen-unstable/xen/xen-arm64 \
--data guest.img@0x80400000
where guest.img is a zImage.
(disabled by default edit config.h to enable)
Mostly throwing this out there in case others find it useful.
Signed-off-by: Ian Campbell <ian.campbell@xxxxxxxxxx>
---
xen/arch/arm/setup.c | 14 ++++++++++++++
xen/include/asm-arm/config.h | 2 ++
2 files changed, 16 insertions(+), 0 deletions(-)
diff --git a/xen/arch/arm/setup.c b/xen/arch/arm/setup.c
index e867ae7..2f99575 100644
--- a/xen/arch/arm/setup.c
+++ b/xen/arch/arm/setup.c
@@ -368,6 +368,20 @@ void __init start_xen(unsigned long boot_phys_offset,
+ (fdt_paddr & ((1 << SECOND_SHIFT) - 1));
fdt_size = device_tree_early_init(fdt);
+#ifdef CONFIG_KERNEL_APPEND
+ early_info.modules.module[1].start = boot_phys_offset + (uintptr_t)_end;
+ early_info.modules.module[1].start += (2<<20)-1;
+ early_info.modules.module[1].start &= ~((2<<20)-1);
+
+ early_info.modules.module[1].size = 4<<20;
+ early_info.modules.nr_mods = 1;
+ early_printk("assuming kernel is appended at "
+ "%"PRIpaddr"-%"PRIpaddr"\n",
+ early_info.modules.module[1].start,
+ early_info.modules.module[1].start
+ + early_info.modules.module[1].size);
+#endif
+
cpus = smp_get_max_cpus();
cmdline_parse(device_tree_bootargs(fdt));
diff --git a/xen/include/asm-arm/config.h b/xen/include/asm-arm/config.h
index ffa2fcb..e78f5ca 100644
--- a/xen/include/asm-arm/config.h
+++ b/xen/include/asm-arm/config.h
@@ -34,6 +34,8 @@
#define CONFIG_DOMAIN_PAGE 1
+//#define CONFIG_KERNEL_APPEND 1
+
#define OPT_CONSOLE_STR "com1"
#ifdef MAX_PHYS_CPUS
--
1.7.2.5
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |