sanity.bbclass: Check for /proc/sys/vm/mmap_min_addr to be >= 65536
PATCH v3 3/4 sanity.bbclass: Check for /proc/sys/vm/mmap_min_addr to be >= 65536
* Now qemu can handle lower values we can chnage this sanity test to check of values if less than 65536
Signed-off-by Khem Raj <[email protected]>
--- meta/classes/sanity.bbclass | 10 ++++++---- 1 files changed, 6 insertions(+), 4 deletions(-)
meta/classes/sanity.bbclass +6 -4
@@ -170,10 +170,12 @@ def check_sanity(e): # This path is no longer user-readable in modern (very recent) Linux try: if os.path.exists("/proc/sys/vm/mmap_min_addr"): - f = file("/proc/sys/vm/mmap_min_addr", "r") - if (f.read().strip() != "0"): - messages = messages + "/proc/sys/vm/mmap_min_addr is not 0. This will cause problems with qemu so please fix the value (as root).\n\nTo fix this in later reboots, set vm.mmap_min_addr = 0 in /etc/sysctl.conf.\n" - f.close() + f = open("/proc/sys/vm/mmap_min_addr", "r") + try: + if (int(f.read().strip()) < 65536): + messages = messages + "/proc/sys/vm/mmap_min_addr is not >= 65536. This will cause problems with qemu so please fix the value (as root).\n\nTo fix this in later reboots, set vm.mmap_min_addr = 65536 in /etc/sysctl.conf.\n" + finally: + f.close() except: pass
Signature · 1 line
1.7.4.1
Richard Purdie
AppliedQuoted 7 lines · Khem Raj
* Now qemu can handle lower values we can chnage this sanity test to check of values if less than 65536
Signed-off-by Khem Raj <[email protected]>--- meta/classes/sanity.bbclass | 10 ++++++---- 1 files changed, 6 insertions(+), 4 deletions(-)
Merged into master, thanks.
Richard