scripts/runqemu: Fix memory limits for qemux86-64

When setting memory to 4GB, qemu is only running with 2GB for x86_64.
Avoid this by removing the mem= option to the kernel and letting the
qemu configuration handle it for x86 in a similar way to mips.

(From OE-Core rev: 2fd53417eba354c31c058c4bb066bb882e098add)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
Richard Purdie 2022-03-14 13:35:00 +00:00
parent c41e58279a
commit d38868cfff

View File

@ -814,7 +814,7 @@ class BaseConfig(object):
self.set('QB_MEM', qb_mem) self.set('QB_MEM', qb_mem)
mach = self.get('MACHINE') mach = self.get('MACHINE')
if not mach.startswith('qemumips'): if not mach.startswith(('qemumips', 'qemux86')):
self.kernel_cmdline_script += ' mem=%s' % self.get('QB_MEM').replace('-m','').strip() + 'M' self.kernel_cmdline_script += ' mem=%s' % self.get('QB_MEM').replace('-m','').strip() + 'M'
self.qemu_opt_script += ' %s' % self.get('QB_MEM') self.qemu_opt_script += ' %s' % self.get('QB_MEM')