<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body text="#000000" bgcolor="#FFFFFF">
<div class="moz-cite-prefix">On 2017年12月06日 10:46, Hongxu Jia wrote:<br>
</div>
<blockquote type="cite"
cite="mid:1512528404-110242-1-git-send-email-hongxu.jia@windriver.com">
<pre wrap="">OE uses qemumips to simulate a Malta board by default.
As upstream qemu introduced:
<a class="moz-txt-link-freetext" href="https://git.qemu.org/?p=qemu.git;a=commit;h=94c2b6aff43cdfcfdfb552773a6b6b973a72ef0b">https://git.qemu.org/?p=qemu.git;a=commit;h=94c2b6aff43cdfcfdfb552773a6b6b973a72ef0b</a>
The Malta board can support up to 2GiB of RAM which should
be able to boot a Linux kernel built with CONFIG_HIGHMEM
enabled and passing "-m 2048" to QEMU and appending the
following kernel parameters:</pre>
</blockquote>
<br>
Hi Ross, <br>
<br>
I have sent another fix to linux-yocto to enable CONFIG_HIGHMEM<br>
for qemumips (<span style="color: rgb(51, 51, 51); font-family:
Arial, sans-serif; font-size: 14px; font-style: normal;
font-variant-ligatures: normal; font-variant-caps: normal;
font-weight: 400; letter-spacing: normal; orphans: 2; text-align:
start; text-indent: 0px; text-transform: none; white-space:
normal; widows: 2; word-spacing: 0px; -webkit-text-stroke-width:
0px; background-color: rgb(255, 255, 255); text-decoration-style:
initial; text-decoration-color: initial; display: inline
!important; float: none;">mti-malta32</span>).<br>
<br>
//Hongxu<br>
<br>
<blockquote type="cite"
cite="mid:1512528404-110242-1-git-send-email-hongxu.jia@windriver.com">
<pre wrap="">
...
mem=256M@0x0 mem=256M@0x90000000 mem=1536M@0x20000000
...
But the following commit in kernel broke above mem=X@Y setting
which added the memory as reserved memory area.
<a class="moz-txt-link-freetext" href="https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=73fbc1eba7ffa3bf0ad12486232a8a1edb4e4411">https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=73fbc1eba7ffa3bf0ad12486232a8a1edb4e4411</a>
...
commit 73fbc1eba7ffa3bf0ad12486232a8a1edb4e4411
Author: Marcin Nowakowski <a class="moz-txt-link-rfc2396E" href="mailto:marcin.nowakowski@imgtec.com"><marcin.nowakowski@imgtec.com></a>
Date: Wed Nov 23 14:43:49 2016 +0100
MIPS: fix mem=X@Y commandline processing
...
So remove `mem=*' to disable user-defined physical RAM map
which let kernel itself caculates memory ranges.
Signed-off-by: Hongxu Jia <a class="moz-txt-link-rfc2396E" href="mailto:hongxu.jia@windriver.com"><hongxu.jia@windriver.com></a>
---
scripts/runqemu | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/scripts/runqemu b/scripts/runqemu
index f2b4b3c..0ae2f85 100755
--- a/scripts/runqemu
+++ b/scripts/runqemu
@@ -658,7 +658,10 @@ class BaseConfig(object):
logger.info('QB_MEM is not set, use 512M by default')
self.set('QB_MEM', '-m 512')
- self.kernel_cmdline_script += ' mem=%s' % self.get('QB_MEM').replace('-m','').strip() + 'M'
+ mach = self.get('MACHINE')
+ if mach != 'qemumips':
+ self.kernel_cmdline_script += ' mem=%s' % self.get('QB_MEM').replace('-m','').strip() + 'M'
+
self.qemu_opt_script += ' %s' % self.get('QB_MEM')
def check_tcpserial(self):
</pre>
</blockquote>
<p><br>
</p>
</body>
</html>