summaryrefslogtreecommitdiff
path: root/arch/x86/include/asm/arch-qemu/qemu.h
diff options
context:
space:
mode:
authorBin Meng <bmeng.cn@gmail.com>2019-08-29 02:53:05 -0700
committerBin Meng <bmeng.cn@gmail.com>2019-09-10 14:19:39 +0800
commitea67d549b89dbfee2bc78ba75c5b1406950f5e46 (patch)
treeead0dec3dc4a0c41b7dc3450236020f678e6f5ed /arch/x86/include/asm/arch-qemu/qemu.h
parentf4c0030074544e8d3105bc9e4debb82e964ab126 (diff)
x86: qemu: Support getting high memory size
At present only size of memory that is below 4GiB is retrieved from QEMU. Add a function that gets size of memory that is above 4GiB. Signed-off-by: Bin Meng <bmeng.cn@gmail.com> Reviewed-by: Aiden Park <aiden.park@intel.com>
Diffstat (limited to 'arch/x86/include/asm/arch-qemu/qemu.h')
-rw-r--r--arch/x86/include/asm/arch-qemu/qemu.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/arch/x86/include/asm/arch-qemu/qemu.h b/arch/x86/include/asm/arch-qemu/qemu.h
index c98deb2cd2..061735b298 100644
--- a/arch/x86/include/asm/arch-qemu/qemu.h
+++ b/arch/x86/include/asm/arch-qemu/qemu.h
@@ -32,6 +32,10 @@
#define LOW_RAM_ADDR 0x34
#define HIGH_RAM_ADDR 0x35
+#define LOW_HIGHRAM_ADDR 0x5b
+#define MID_HIGHRAM_ADDR 0x5c
+#define HIGH_HIGHRAM_ADDR 0x5d
+
/* PM registers */
#define PMBA 0x40
#define PMREGMISC 0x80
@@ -44,4 +48,11 @@
*/
u32 qemu_get_low_memory_size(void);
+/**
+ * qemu_get_high_memory_size() - Get high memory size
+ *
+ * @return: size of memory above 4GiB
+ */
+u64 qemu_get_high_memory_size(void);
+
#endif /* _ARCH_QEMU_H_ */