Skip to contentSkip to conversation

Regression test for 49ccf2c3cafb

PATCH Applied Andrea Cervesato 4 participants 6 messages Jul 15

lore
Share & tools
lore
#0 lore raw

cover Regression test for 49ccf2c3cafb

---
Andrea Cervesato (2):
lapi: add PROT_MTE fallback
hugemmap35: add regression test for 49ccf2c3cafb

 include/lapi/mman.h                                |   4 +
 runtest/hugetlb                                    |   1 +
 testcases/kernel/mem/.gitignore                    |   1 +
 testcases/kernel/mem/hugetlb/hugemmap/hugemmap35.c | 105 +++++++++++++++++++++
 4 files changed, 111 insertions(+)

---
base-commit: d139524b04d360c4dabaee61a6066a9a52b0e454
change-id: 20260715-hugemmap35-fdc484ee4bbf

Best regards,

Signature · 5 lines
Andrea Cervesato <[email protected]>


-- 
Mailing list info: https://lists.linux.it/listinfo/ltp
#1 lore raw

PATCH 1/2 lapi: add PROT_MTE fallback

From: Andrea Cervesato <[email protected]>

---
 include/lapi/mman.h | 4 ++++
 1 file changed, 4 insertions(+)
include/lapi/mman.h +4 -0
index edd517c6e0ebad98f01530b9ac2a7c90cdcaced8..ca72ffd484129b9e8c9165816544da0d8d0ea06a 100644
@@ -11,6 +11,10 @@
 #include "config.h"
 #include "lapi/syscalls.h"
 
+#ifndef PROT_MTE
+# define PROT_MTE 0x20
+#endif
+
 #ifndef HAVE_STRUCT_CACHESTAT_RANGE
 struct cachestat_range {
 	uint64_t off;
Signature · 5 lines
2.51.0


-- 
Mailing list info: https://lists.linux.it/listinfo/ltp
#2 lore raw

Re: [LTP] lapi: add PROT_MTE fallback

Hi Andrea,

Quoted 1 line · Andrea Cervesato

lapi: add PROT_MTE fallback

Verdict - Reviewed

---
Note:

The agent can sometimes produce false positives although often its findings are genuine. If you find issues with the review, please comment this email or ignore the suggestions.

Regards,
LTP AI Reviewer

Signature · 1 line
Mailing list info: https://lists.linux.it/listinfo/ltp
#3 lore raw

PATCH 2/2 hugemmap35: add regression test for 49ccf2c3cafb

In reply to Andrea Cervesato

From: Andrea Cervesato <[email protected]>

Add a regression test verifying that a hugetlbfs file can be mapped with PROT_MTE even when MAP_HUGETLB is not set in the mmap() flags.

Before the referenced commit, VM_MTE_ALLOWED was not set early enough for hugetlbfs file mappings, so such an mmap() was wrongly rejected.

---
 runtest/hugetlb                                    |   1 +
 testcases/kernel/mem/.gitignore                    |   1 +
 testcases/kernel/mem/hugetlb/hugemmap/hugemmap35.c | 105 +++++++++++++++++++++
 3 files changed, 107 insertions(+)
runtest/hugetlb +1 -0
index 0896d3c941f068628f53c31197b293906c4ecba6..8ee0e6f828cb1954e03d67d40fe691d6521361bf 100644
@@ -36,6 +36,7 @@ hugemmap30 hugemmap30
 hugemmap31 hugemmap31
 hugemmap32 hugemmap32
 hugemmap34 hugemmap34
+hugemmap35 hugemmap35
 hugemmap05_1 hugemmap05 -m
 hugemmap05_2 hugemmap05 -s
 hugemmap05_3 hugemmap05 -s -m
testcases/kernel/mem/.gitignore +1 -0
index b4455de51d6d6a9cc3d8b7ff392fc3ea9e95890a..0e59035dfdcf759aa16c069575bb1f4eb58f321c 100644
@@ -36,6 +36,7 @@
 /hugetlb/hugemmap/hugemmap31
 /hugetlb/hugemmap/hugemmap32
 /hugetlb/hugemmap/hugemmap34
+/hugetlb/hugemmap/hugemmap35
 /hugetlb/hugeshmat/hugeshmat01
 /hugetlb/hugeshmat/hugeshmat02
 /hugetlb/hugeshmat/hugeshmat03
testcases/kernel/mem/hugetlb/hugemmap/hugemmap35.c new file +105 -0

105 lines not on this page · raw message

Signature · 5 lines
2.51.0


-- 
Mailing list info: https://lists.linux.it/listinfo/ltp