From: Petar Jovanovic Date: Wed, 27 Nov 2019 12:22:46 +0000 (+0000) Subject: mips: enable sloppyXcheck for mips32 and mips64 X-Git-Tag: VALGRIND_3_16_0~193 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7c2e222b118f6168211f20c028b8debcb3023c45;p=thirdparty%2Fvalgrind.git mips: enable sloppyXcheck for mips32 and mips64 Newer mips kernels (post 4.7.0) assign execute permissions to loadable program segments which originally did not have them as per the information provided in the elf file itself. Include mips32/mips64 in the list of architectures for which the address space manager should allow the kernel to report execute permissions in sync_check_mapping_callback. Patch by Stefan Maksimovic. --- diff --git a/coregrind/m_aspacemgr/aspacemgr-linux.c b/coregrind/m_aspacemgr/aspacemgr-linux.c index 7ddef30775..7c4c4eb734 100644 --- a/coregrind/m_aspacemgr/aspacemgr-linux.c +++ b/coregrind/m_aspacemgr/aspacemgr-linux.c @@ -818,7 +818,8 @@ static void sync_check_mapping_callback ( Addr addr, SizeT len, UInt prot, have a sloppyXcheck mode which we enable on x86 and s390 - in this mode we allow the kernel to report execute permission when we weren't expecting it but not vice versa. */ -# if defined(VGA_x86) || defined (VGA_s390x) +# if defined(VGA_x86) || defined (VGA_s390x) || \ + defined(VGA_mips32) || defined(VGA_mips64) sloppyXcheck = True; # else sloppyXcheck = False;