This is a note to let you know that I've just added the patch titled revert "memfd: improve userspace warnings for missing exec-related flags". to the 6.4-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the patch is: revert-memfd-improve-userspace-warnings-for-missing-exec-related-flags.patch and it can be found in the queue-6.4 subdirectory. If you, or anyone else, feels it should not be added to the stable tree, please let <stable@xxxxxxxxxxxxxxx> know about it. >From 2562d67b1bdf91c7395b0225d60fdeb26b4bc5a0 Mon Sep 17 00:00:00 2001 From: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> Date: Sat, 2 Sep 2023 15:59:31 -0700 Subject: revert "memfd: improve userspace warnings for missing exec-related flags". From: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> commit 2562d67b1bdf91c7395b0225d60fdeb26b4bc5a0 upstream. This warning is telling userspace developers to pass MFD_EXEC and MFD_NOEXEC_SEAL to memfd_create(). Commit 434ed3350f57 ("memfd: improve userspace warnings for missing exec-related flags") made the warning more frequent and visible in the hope that this would accelerate the fixing of errant userspace. But the overall effect is to generate far too much dmesg noise. Fixes: 434ed3350f57 ("memfd: improve userspace warnings for missing exec-related flags") Reported-by: Damian Tometzki <dtometzki@xxxxxxxxxxxxxxxxx> Closes: https://lkml.kernel.org/r/ZPFzCSIgZ4QuHsSC@xxxxxxxxxxxxxxxx Cc: Aleksa Sarai <cyphar@xxxxxxxxxx> Cc: Christian Brauner <brauner@xxxxxxxxxx> Cc: Daniel Verkamp <dverkamp@xxxxxxxxxxxx> Cc: Jeff Xu <jeffxu@xxxxxxxxxx> Cc: Kees Cook <keescook@xxxxxxxxxxxx> Cc: Shuah Khan <shuah@xxxxxxxxxx> Cc: <stable@xxxxxxxxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx> --- mm/memfd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/mm/memfd.c +++ b/mm/memfd.c @@ -315,7 +315,7 @@ SYSCALL_DEFINE2(memfd_create, return -EINVAL; if (!(flags & (MFD_EXEC | MFD_NOEXEC_SEAL))) { - pr_info_ratelimited( + pr_warn_once( "%s[%d]: memfd_create() called without MFD_EXEC or MFD_NOEXEC_SEAL set\n", current->comm, task_pid_nr(current)); } Patches currently in stable-queue which might be from akpm@xxxxxxxxxxxxxxxxxxxx are queue-6.4/revert-memfd-improve-userspace-warnings-for-missing-exec-related-flags.patch queue-6.4/arm64-mm-use-ptep_clear-instead-of-pte_clear-in-clea.patch queue-6.4/selftests-memfd-error-out-test-process-when-child-te.patch queue-6.4/memfd-do-not-eacces-old-memfd_create-users-with-vm.m.patch queue-6.4/memfd-improve-userspace-warnings-for-missing-exec-re.patch queue-6.4/rcu-dump-vmalloc-memory-info-safely.patch queue-6.4/mm-memfd-sysctl-fix-memfd_noexec_scope_noexec_enforc.patch queue-6.4/multi-gen-lru-fix-per-zone-reclaim.patch queue-6.4/fs-ocfs2-namei-check-return-value-of-ocfs2_add_entry.patch queue-6.4/mm-vmalloc-add-a-safer-version-of-find_vm_area-for-debug.patch queue-6.4/scripts-gdb-fix-lx-lsmod-show-the-wrong-size.patch queue-6.4/selftests-memfd-sysctl-fix-memfd_noexec_scope_noexec.patch