{"id":2223026,"url":"http://patchwork.ozlabs.org/api/patches/2223026/?format=json","web_url":"http://patchwork.ozlabs.org/project/linuxppc-dev/patch/80239ca37ad96216eb5d9768cf5373e7246626ff.1776150071.git.sayalip@linux.ibm.com/","project":{"id":2,"url":"http://patchwork.ozlabs.org/api/projects/2/?format=json","name":"Linux PPC development","link_name":"linuxppc-dev","list_id":"linuxppc-dev.lists.ozlabs.org","list_email":"linuxppc-dev@lists.ozlabs.org","web_url":"https://github.com/linuxppc/wiki/wiki","scm_url":"https://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux.git","webscm_url":"https://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux.git/","list_archive_url":"https://lore.kernel.org/linuxppc-dev/","list_archive_url_format":"https://lore.kernel.org/linuxppc-dev/{}/","commit_url_format":"https://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux.git/commit/?id={}"},"msgid":"<80239ca37ad96216eb5d9768cf5373e7246626ff.1776150071.git.sayalip@linux.ibm.com>","list_archive_url":"https://lore.kernel.org/linuxppc-dev/80239ca37ad96216eb5d9768cf5373e7246626ff.1776150071.git.sayalip@linux.ibm.com/","date":"2026-04-14T08:22:05","name":"[v5,11/14] selftests/mm: skip uffd-wp-mremap if UFFD write-protect is unsupported","commit_ref":null,"pull_url":null,"state":"handled-elsewhere","archived":false,"hash":"f770ae0d28c806a7f908cf4cd1e35fd102a676f4","submitter":{"id":92656,"url":"http://patchwork.ozlabs.org/api/people/92656/?format=json","name":"Sayali Patil","email":"sayalip@linux.ibm.com"},"delegate":null,"mbox":"http://patchwork.ozlabs.org/project/linuxppc-dev/patch/80239ca37ad96216eb5d9768cf5373e7246626ff.1776150071.git.sayalip@linux.ibm.com/mbox/","series":[{"id":499800,"url":"http://patchwork.ozlabs.org/api/series/499800/?format=json","web_url":"http://patchwork.ozlabs.org/project/linuxppc-dev/list/?series=499800","date":"2026-04-14T08:21:54","name":"selftests/mm: fix failures and robustness improvements","version":5,"mbox":"http://patchwork.ozlabs.org/series/499800/mbox/"}],"comments":"http://patchwork.ozlabs.org/api/patches/2223026/comments/","check":"pending","checks":"http://patchwork.ozlabs.org/api/patches/2223026/checks/","tags":{},"related":[],"headers":{"Return-Path":"\n <linuxppc-dev+bounces-19738-incoming=patchwork.ozlabs.org@lists.ozlabs.org>","X-Original-To":["incoming@patchwork.ozlabs.org","linuxppc-dev@lists.ozlabs.org"],"Delivered-To":"patchwork-incoming@legolas.ozlabs.org","Authentication-Results":["legolas.ozlabs.org;\n\tdkim=pass (2048-bit key;\n unprotected) header.d=ibm.com header.i=@ibm.com header.a=rsa-sha256\n header.s=pp1 header.b=b531dP+B;\n\tdkim-atps=neutral","legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=lists.ozlabs.org\n (client-ip=2404:9400:21b9:f100::1; helo=lists.ozlabs.org;\n envelope-from=linuxppc-dev+bounces-19738-incoming=patchwork.ozlabs.org@lists.ozlabs.org;\n receiver=patchwork.ozlabs.org)","lists.ozlabs.org;\n arc=none smtp.remote-ip=148.163.156.1","lists.ozlabs.org;\n dmarc=pass (p=none dis=none) header.from=linux.ibm.com","lists.ozlabs.org;\n\tdkim=pass (2048-bit key;\n unprotected) header.d=ibm.com header.i=@ibm.com header.a=rsa-sha256\n header.s=pp1 header.b=b531dP+B;\n\tdkim-atps=neutral","lists.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=linux.ibm.com\n (client-ip=148.163.156.1; helo=mx0a-001b2d01.pphosted.com;\n envelope-from=sayalip@linux.ibm.com; receiver=lists.ozlabs.org)"],"Received":["from lists.ozlabs.org (lists.ozlabs.org\n [IPv6:2404:9400:21b9:f100::1])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\t key-exchange x25519)\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4fvy3m1yLBz1y2d\n\tfor <incoming@patchwork.ozlabs.org>; Tue, 14 Apr 2026 18:24:04 +1000 (AEST)","from boromir.ozlabs.org (localhost [127.0.0.1])\n\tby lists.ozlabs.org (Postfix) with ESMTP id 4fvy340KZsz3bV6;\n\tTue, 14 Apr 2026 18:23:28 +1000 (AEST)","from mx0a-001b2d01.pphosted.com (mx0a-001b2d01.pphosted.com\n [148.163.156.1])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\t key-exchange x25519 server-signature RSA-PSS (2048 bits) server-digest\n SHA256)\n\t(No client certificate requested)\n\tby lists.ozlabs.org (Postfix) with ESMTPS id 4fvy331vtvz30dt\n\tfor <linuxppc-dev@lists.ozlabs.org>; Tue, 14 Apr 2026 18:23:27 +1000 (AEST)","from pps.filterd (m0353729.ppops.net [127.0.0.1])\n\tby mx0a-001b2d01.pphosted.com (8.18.1.11/8.18.1.11) with ESMTP id\n 63DLIX3E1842955;\n\tTue, 14 Apr 2026 08:23:14 GMT","from ppma22.wdc07v.mail.ibm.com\n (5c.69.3da9.ip4.static.sl-reverse.com [169.61.105.92])\n\tby mx0a-001b2d01.pphosted.com (PPS) with ESMTPS id 4dh89mhs8m-1\n\t(version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT);\n\tTue, 14 Apr 2026 08:23:13 +0000 (GMT)","from pps.filterd (ppma22.wdc07v.mail.ibm.com [127.0.0.1])\n\tby ppma22.wdc07v.mail.ibm.com (8.18.1.2/8.18.1.2) with ESMTP id\n 63E3XB4W031854;\n\tTue, 14 Apr 2026 08:23:12 GMT","from smtprelay07.fra02v.mail.ibm.com ([9.218.2.229])\n\tby ppma22.wdc07v.mail.ibm.com (PPS) with ESMTPS id 4dg10y8qvu-1\n\t(version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT);\n\tTue, 14 Apr 2026 08:23:12 +0000","from smtpav04.fra02v.mail.ibm.com (smtpav04.fra02v.mail.ibm.com\n [10.20.54.103])\n\tby smtprelay07.fra02v.mail.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id\n 63E8N8CL51904838\n\t(version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK);\n\tTue, 14 Apr 2026 08:23:08 GMT","from smtpav04.fra02v.mail.ibm.com (unknown [127.0.0.1])\n\tby IMSVA (Postfix) with ESMTP id 961C22004D;\n\tTue, 14 Apr 2026 08:23:08 +0000 (GMT)","from smtpav04.fra02v.mail.ibm.com (unknown [127.0.0.1])\n\tby IMSVA (Postfix) with ESMTP id 991B62004B;\n\tTue, 14 Apr 2026 08:23:04 +0000 (GMT)","from li-3f69264c-2ce6-11b2-a85c-c3f414d24014.ibm.com.com (unknown\n [9.39.26.223])\n\tby smtpav04.fra02v.mail.ibm.com (Postfix) with ESMTP;\n\tTue, 14 Apr 2026 08:23:04 +0000 (GMT)"],"ARC-Seal":"i=1; a=rsa-sha256; d=lists.ozlabs.org; s=201707; t=1776155007;\n\tcv=none;\n b=OwpM/nPGoEiXPqse0cVk7JMgBdLR5tV/HV/pJjg/hAWhpCTOBuH/a8eSkS1B7H7JWrPb4cxeM05to7pNyZ/XBdU77PaYzhpl96bHixbYUelMLByP3bZ9vMOqO4QQUoSL+kcVBWXGAqlvAguO9Rk9eo7JhowpDRZJ16FzDaZ+D4Oc+HK9PCPFHAiv1d9RLNfFq4SWJTJTIGdnhnYBcMyG1l8ebN1PEcU1Nb5aJbygavMiny40jSWHjGe4sGWS7OSVUjZXpARmQtq1KmAdxqPbDqHnoXGjP67nxkZhCbHZbvNZE2gap8bZi9chTVzB3m1fmBM5P1BfNWpVBo5cpjVH7w==","ARC-Message-Signature":"i=1; a=rsa-sha256; d=lists.ozlabs.org; s=201707;\n\tt=1776155007; c=relaxed/relaxed;\n\tbh=eEOC4G2ZWST9olhihUFWeAxxSaTnVqTcR+V7Cs8ArgY=;\n\th=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References:\n\t MIME-Version;\n b=I0+nwMcpm+BAyXJ+QUwbvDgkNq48rks9qHw3r/nL8u0qMr4k9PxG18FVF8qD5TM8p/c+xNsm4rDy8Yt9rHFlCSUGfIaADEa6wYO67k8vefx+d9TyyDV2g4zj1aDbXYnyW4FmDNt6JyILEeO7P8OwPOkVV1sB7x6sJTCvITKXx7vn/Y8qlasqANPPKRodaK+MTsXX7u6vqu8Ih0SJoQQoGmUi6APQePtIBtCuNZMmb0hKG4iLWyCGUBo9Jz30PVpU/aCfT3B5iVI7BE7KWwdraSQeUvthUYGooqfix+a8vVTkJuvhfrc3caQ6wP0kyemIQsuboyq1BFqHTXqmNP+/Bw==","ARC-Authentication-Results":"i=1; lists.ozlabs.org;\n dmarc=pass (p=none dis=none) header.from=linux.ibm.com;\n dkim=pass (2048-bit key;\n unprotected) header.d=ibm.com header.i=@ibm.com header.a=rsa-sha256\n header.s=pp1 header.b=b531dP+B; dkim-atps=neutral;\n spf=pass (client-ip=148.163.156.1; helo=mx0a-001b2d01.pphosted.com;\n envelope-from=sayalip@linux.ibm.com;\n receiver=lists.ozlabs.org) smtp.mailfrom=linux.ibm.com","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed; d=ibm.com; h=cc\n\t:content-transfer-encoding:date:from:in-reply-to:message-id\n\t:mime-version:references:subject:to; s=pp1; bh=eEOC4G2ZWST9olhih\n\tUFWeAxxSaTnVqTcR+V7Cs8ArgY=; b=b531dP+BbYC7FZT4kGjec7OBgIhyK/v1z\n\t455p0e/6o8oivRSuAhBWFRh4Lx1ded9ZQAiNqCGtSz80aJSbHFivQe3PKIKcO+oz\n\tmY9xWBMZTDnNHhxFqJafaE74T+S5+AKr1ulYfGShrjmXUJH77zVM2onT6JjBLyza\n\tleY7TeV4jdYGL53xwSeQ1m7EyCRKzPM1hBTaGBNY3UcMrVNjKc9lJYl0Y/9Re7hw\n\tk3Vc+AAvqJURJxjMf412HWgs92p1JiWEyGnp433naXwdv4xDigYdTWsvTXtovTRp\n\t0OjzKq0rBeCIMsA0m8HPz1BZYLS+vUcCvh4w3xsLyM7LHnZRsd1Fg==","From":"Sayali Patil <sayalip@linux.ibm.com>","To":"Andrew Morton <akpm@linux-foundation.org>, Shuah Khan <shuah@kernel.org>,\n        linux-mm@kvack.org, linux-kernel@vger.kernel.org,\n        linux-kselftest@vger.kernel.org,\n        Ritesh Harjani <ritesh.list@gmail.com>","Cc":"David Hildenbrand <david@kernel.org>, Zi Yan <ziy@nvidia.com>,\n        Michal Hocko <mhocko@kernel.org>, Oscar Salvador <osalvador@suse.de>,\n        Lorenzo Stoakes <lorenzo.stoakes@oracle.com>,\n        Dev Jain <dev.jain@arm.com>, Liam.Howlett@oracle.com,\n        linuxppc-dev@lists.ozlabs.org, Miaohe Lin <linmiaohe@huawei.com>,\n        Venkat Rao Bagalkote <venkat88@linux.ibm.com>,\n        Sayali Patil <sayalip@linux.ibm.com>","Subject":"[PATCH v5 11/14] selftests/mm: skip uffd-wp-mremap if UFFD\n write-protect is unsupported","Date":"Tue, 14 Apr 2026 13:52:05 +0530","Message-ID":"\n <80239ca37ad96216eb5d9768cf5373e7246626ff.1776150071.git.sayalip@linux.ibm.com>","X-Mailer":"git-send-email 2.52.0","In-Reply-To":"<cover.1776150071.git.sayalip@linux.ibm.com>","References":"<cover.1776150071.git.sayalip@linux.ibm.com>","X-Mailing-List":"linuxppc-dev@lists.ozlabs.org","List-Id":"<linuxppc-dev.lists.ozlabs.org>","List-Help":"<mailto:linuxppc-dev+help@lists.ozlabs.org>","List-Owner":"<mailto:linuxppc-dev+owner@lists.ozlabs.org>","List-Post":"<mailto:linuxppc-dev@lists.ozlabs.org>","List-Archive":"<https://lore.kernel.org/linuxppc-dev/>,\n  <https://lists.ozlabs.org/pipermail/linuxppc-dev/>","List-Subscribe":"<mailto:linuxppc-dev+subscribe@lists.ozlabs.org>,\n  <mailto:linuxppc-dev+subscribe-digest@lists.ozlabs.org>,\n  <mailto:linuxppc-dev+subscribe-nomail@lists.ozlabs.org>","List-Unsubscribe":"<mailto:linuxppc-dev+unsubscribe@lists.ozlabs.org>","Precedence":"list","MIME-Version":"1.0","Content-Transfer-Encoding":"8bit","X-TM-AS-GCONF":"00","X-Proofpoint-Reinject":"loops=2 maxloops=12","X-Proofpoint-Spam-Details-Enc":"AW1haW4tMjYwNDE0MDA3NyBTYWx0ZWRfXykIEjqTVyWb/\n JuISvs83R4ZYQpEtV9bPJD0itOU0ZbEVBY3nt1/+iTSqSgquvZ0zUlvXQWdeK13IUwtqRPXNVoy\n /K4h9/FCIRxSGnRe7NearYryVik5UgN75t/OzHC8tGDqJ9HmHXSCdUwWHXS7PUni8hztDKzbaSc\n r1fdkkj67r/IEeFIqZpTwjCctHFBvk/5Ef28ltgd6FJk37RRuuVOi4T2WxbNC2RuvSqM3uUXld0\n 2Fpi/l4iHmTxFo59QWKGRPIU/eAwOoOSmoMrTEJEApVZF9L1Jz9UwpXE1X9eODoFjoJk1+QuTWK\n G8VwvlCvS/+ek0k7sbGkwW82WxGy88O0eyh6YsMsNiX0bA691rud7QV7H3kS+gpnXdKbpBzv7rt\n Rl0V7oRHZnCmDwZ1c5JBPbk+t8tBebMY7c0i6NTPCCGUhAjt/Ivbi9bK2HTk+BkJwxZFdIG2FIY\n 2Ll3cCOc7rifTZTeP5w==","X-Authority-Analysis":"v=2.4 cv=eJ4jSnp1 c=1 sm=1 tr=0 ts=69ddf972 cx=c_pps\n a=5BHTudwdYE3Te8bg5FgnPg==:117 a=5BHTudwdYE3Te8bg5FgnPg==:17\n a=A5OVakUREuEA:10 a=VkNPw1HP01LnGYTKEx00:22 a=RnoormkPH1_aCDwRdu11:22\n a=uAbxVGIbfxUO_5tXvNgY:22 a=VnNF1IyMAAAA:8 a=njH7lnjfnPuJvX8OOgMA:9","X-Proofpoint-GUID":"tPRFCHZz-H-acC40CY2MRNnhvmCE7ieD","X-Proofpoint-ORIG-GUID":"UPHYde5pk5iv0EE12nNRx23tffbIF7hg","X-Proofpoint-Virus-Version":"vendor=baseguard\n engine=ICAP:2.0.293,Aquarius:18.0.1143,Hydra:6.1.51,FMLib:17.12.100.49\n definitions=2026-04-14_02,2026-04-13_04,2025-10-01_01","X-Proofpoint-Spam-Details":"rule=outbound_notspam policy=outbound score=0\n malwarescore=0 lowpriorityscore=0 adultscore=0 priorityscore=1501\n clxscore=1015 bulkscore=0 suspectscore=0 spamscore=0 impostorscore=0\n phishscore=0 classifier=typeunknown authscore=0 authtc= authcc=\n route=outbound adjust=0 reason=mlx scancount=1 engine=8.22.0-2604070000\n definitions=main-2604140077","X-Spam-Status":"No, score=-0.7 required=3.0 tests=DKIM_SIGNED,DKIM_VALID,\n\tRCVD_IN_DNSWL_LOW,RCVD_IN_MSPIKE_H4,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE,\n\tSPF_PASS autolearn=disabled version=4.0.1 OzLabs 8","X-Spam-Checker-Version":"SpamAssassin 4.0.1 (2024-03-25) on lists.ozlabs.org"},"content":"The uffd-wp-mremap test requires the UFFD_FEATURE_PAGEFAULT_FLAG_WP\ncapability. On systems where userfaultfd write-protect is\nnot supported, uffd_register() fails and the test reports failures.\n\nCheck for the required feature at startup and skip the test when the\nUFFD_FEATURE_PAGEFAULT_FLAG_WP capability is not present,\npreventing false failures on unsupported configurations.\n\nBefore patch:\n running ./uffd-wp-mremap\n ------------------------\n  [INFO] detected THP size: 256 KiB\n  [INFO] detected THP size: 512 KiB\n  [INFO] detected THP size: 1024 KiB\n  [INFO] detected THP size: 2048 KiB\n  [INFO] detected hugetlb page size: 2048 KiB\n  [INFO] detected hugetlb page size: 1048576 KiB\n 1..24\n  [RUN] test_one_folio(size=65536, private=false, swapout=false,\n  hugetlb=false)\n not ok 1 uffd_register() failed\n  [RUN] test_one_folio(size=65536, private=true, swapout=false,\n  hugetlb=false)\n not ok 2 uffd_register() failed\n  [RUN] test_one_folio(size=65536, private=false, swapout=true,\n  hugetlb=false)\n not ok 3 uffd_register() failed\n  [RUN] test_one_folio(size=65536, private=true, swapout=true,\n  hugetlb=false)\n not ok 4 uffd_register() failed\n  [RUN] test_one_folio(size=262144, private=false, swapout=false,\n  hugetlb=false)\n not ok 5 uffd_register() failed\n  [RUN] test_one_folio(size=524288, private=false, swapout=false,\n  hugetlb=false)\n not ok 6 uffd_register() failed\n .\n .\n .\n Bail out! 24 out of 24 tests failed\n  Totals: pass:0 fail:24 xfail:0 xpass:0 skip:0 error:0\n [FAIL]\nnot ok 1 uffd-wp-mremap # exit=1\n\nAfter patch:\n running ./uffd-wp-mremap\n ------------------------\n 1..0 # SKIP uffd-wp feature not supported\n [SKIP]\nok 1 uffd-wp-mremap # SKIP\n\nTested-by: Venkat Rao Bagalkote <venkat88@linux.ibm.com>\nSigned-off-by: Sayali Patil <sayalip@linux.ibm.com>\n---\n tools/testing/selftests/mm/uffd-wp-mremap.c | 13 +++++++++++++\n 1 file changed, 13 insertions(+)","diff":"diff --git a/tools/testing/selftests/mm/uffd-wp-mremap.c b/tools/testing/selftests/mm/uffd-wp-mremap.c\nindex 17186d4a4147..8f288484d5f5 100644\n--- a/tools/testing/selftests/mm/uffd-wp-mremap.c\n+++ b/tools/testing/selftests/mm/uffd-wp-mremap.c\n@@ -19,6 +19,17 @@ static size_t thpsizes[20];\n static int nr_hugetlbsizes;\n static size_t hugetlbsizes[10];\n \n+static void check_uffd_wp_feature_supported(void)\n+{\n+\tuint64_t features = 0;\n+\n+\tif (uffd_get_features(&features))\n+\t\tksft_exit_skip(\"failed to get available features (%d)\\n\", errno);\n+\n+\tif (!(features & UFFD_FEATURE_PAGEFAULT_FLAG_WP))\n+\t\tksft_exit_skip(\"uffd-wp feature not supported\\n\");\n+}\n+\n static int detect_thp_sizes(size_t sizes[], int max)\n {\n \tint count = 0;\n@@ -336,6 +347,8 @@ int main(int argc, char **argv)\n \tstruct thp_settings settings;\n \tint i, j, plan = 0;\n \n+\tcheck_uffd_wp_feature_supported();\n+\n \tpagesize = getpagesize();\n \tnr_thpsizes = detect_thp_sizes(thpsizes, ARRAY_SIZE(thpsizes));\n \tnr_hugetlbsizes = detect_hugetlb_page_sizes(hugetlbsizes,\n","prefixes":["v5","11/14"]}