[linux-yocto] [linux-yocto/linux-yocto-dev 4.18][PATCH] perf arm64: Fix generate system call table failed with /tmp mounted with noexec

Hongxu Jia hongxu.jia at windriver.com
Thu Oct 18 02:12:50 PDT 2018

Which /tmp mounted with noexec, generate system call table failed.
/tmp/create-table-6VGPSt: Permission denied

Add variable TMPDIR as prefix dir of the temporary file, if it is set,
replace default /tmp

Fixes: 2b5882435606 ("perf arm64: Generate system call table from asm/unistd.h")

Signed-off-by: Hongxu Jia <hongxu.jia at windriver.com>
 tools/perf/arch/arm64/entry/syscalls/mksyscalltbl | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tools/perf/arch/arm64/entry/syscalls/mksyscalltbl b/tools/perf/arch/arm64/entry/syscalls/mksyscalltbl
index 2dbb8cad..c88fd32 100755
--- a/tools/perf/arch/arm64/entry/syscalls/mksyscalltbl
+++ b/tools/perf/arch/arm64/entry/syscalls/mksyscalltbl
@@ -23,7 +23,7 @@ create_table_from_c()
 	local sc nr last_sc
-	create_table_exe=`mktemp /tmp/create-table-XXXXXX`
+	create_table_exe=`mktemp ${TMPDIR:-/tmp}/create-table-XXXXXX`

More information about the linux-yocto mailing list