From: Sasha Levin <sashal@kernel.org>
To: stable@vger.kernel.org, chenlinxuan@deepin.org
Cc: Sasha Levin <sashal@kernel.org>
Subject: Re: [PATCH] lib/buildid: Handle memfd_secret() files in build_id_parse()
Date: Thu, 6 Mar 2025 14:11:22 -0500 [thread overview]
Message-ID: <20250306132554-d2172677109d9d8c@stable.kernel.org> (raw)
In-Reply-To: <0E394E84CB1C5456+20250306050701.314895-1-chenlinxuan@deepin.org>
[ Sasha's backport helper bot ]
Hi,
Summary of potential issues:
❌ Build failures detected
⚠️ Found matching upstream commit but patch is missing proper reference to it
Found matching upstream commit: 5ac9b4e935dfc6af41eee2ddc21deb5c36507a9f
WARNING: Author mismatch between patch and found commit:
Backport author: Chen Linxuan<chenlinxuan@deepin.org>
Commit author: Andrii Nakryiko<andrii@kernel.org>
Status in newer kernel trees:
6.6.y | Not found
Note: The patch differs from the upstream commit:
---
Failed to apply patch cleanly.
---
Results of testing on various branches:
| Branch | Patch Apply | Build Test |
|---------------------------|-------------|------------|
| stable/linux-6.13.y | Failed | N/A |
| stable/linux-6.12.y | Failed | N/A |
| stable/linux-6.6.y | Success | Failed |
| stable/linux-6.1.y | Success | Success |
| stable/linux-5.15.y | Success | Success |
| stable/linux-5.10.y | Failed | N/A |
| stable/linux-5.4.y | Failed | N/A |
Build Errors:
Patch failed to apply on stable/linux-6.13.y. Reject:
diff a/lib/buildid.c b/lib/buildid.c (rejected hunks)
@@ -157,6 +157,12 @@ int build_id_parse(struct vm_area_struct *vma, unsigned char *build_id,
if (!vma->vm_file)
return -EINVAL;
+#ifdef CONFIG_SECRETMEM
+ /* reject secretmem folios created with memfd_secret() */
+ if (vma->vm_file->f_mapping->a_ops == &secretmem_aops)
+ return -EFAULT;
+#endif
+
page = find_get_page(vma->vm_file->f_mapping, 0);
if (!page)
return -EFAULT; /* page not mapped */
Patch failed to apply on stable/linux-6.12.y. Reject:
diff a/lib/buildid.c b/lib/buildid.c (rejected hunks)
@@ -157,6 +157,12 @@ int build_id_parse(struct vm_area_struct *vma, unsigned char *build_id,
if (!vma->vm_file)
return -EINVAL;
+#ifdef CONFIG_SECRETMEM
+ /* reject secretmem folios created with memfd_secret() */
+ if (vma->vm_file->f_mapping->a_ops == &secretmem_aops)
+ return -EFAULT;
+#endif
+
page = find_get_page(vma->vm_file->f_mapping, 0);
if (!page)
return -EFAULT; /* page not mapped */
Build error for stable/linux-6.6.y:
lib/buildid.c: In function 'build_id_parse':
lib/buildid.c:162:48: error: 'secretmem_aops' undeclared (first use in this function)
162 | if (vma->vm_file->f_mapping->a_ops == &secretmem_aops)
| ^~~~~~~~~~~~~~
lib/buildid.c:162:48: note: each undeclared identifier is reported only once for each function it appears in
make[3]: *** [scripts/Makefile.build:243: lib/buildid.o] Error 1
lib/test_dhry.o: warning: objtool: dhry() falls through to next function dhry_run_set.cold()
make[3]: Target 'lib/' not remade because of errors.
make[2]: *** [scripts/Makefile.build:480: lib] Error 2
make[2]: Target './' not remade because of errors.
make[1]: *** [/home/sasha/build/linus-next/Makefile:1916: .] Error 2
make[1]: Target '__all' not remade because of errors.
make: *** [Makefile:234: __sub-make] Error 2
make: Target '__all' not remade because of errors.
Patch failed to apply on stable/linux-5.10.y but no reject information available.
Patch failed to apply on stable/linux-5.4.y but no reject information available.
next prev parent reply other threads:[~2025-03-06 19:11 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-03-06 5:06 [PATCH] lib/buildid: Handle memfd_secret() files in build_id_parse() Chen Linxuan
2025-03-06 9:42 ` Jiri Olsa
2025-03-06 19:11 ` Sasha Levin [this message]
2025-03-06 23:08 ` Andrew Morton
2025-03-10 3:32 ` Chen Linxuan
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20250306132554-d2172677109d9d8c@stable.kernel.org \
--to=sashal@kernel.org \
--cc=chenlinxuan@deepin.org \
--cc=stable@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.