Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/2228760/?format=api
{ "id": 2228760, "url": "http://patchwork.ozlabs.org/api/patches/2228760/?format=api", "web_url": "http://patchwork.ozlabs.org/project/linux-ext4/patch/4777ecd14815b92c9e8577ed4d073d0f999e51ef.1777281778.git.asj@kernel.org/", "project": { "id": 8, "url": "http://patchwork.ozlabs.org/api/projects/8/?format=api", "name": "Linux ext4 filesystem development", "link_name": "linux-ext4", "list_id": "linux-ext4.vger.kernel.org", "list_email": "linux-ext4@vger.kernel.org", "web_url": null, "scm_url": null, "webscm_url": null, "list_archive_url": "", "list_archive_url_format": "", "commit_url_format": "" }, "msgid": "<4777ecd14815b92c9e8577ed4d073d0f999e51ef.1777281778.git.asj@kernel.org>", "list_archive_url": null, "date": "2026-04-27T10:19:36", "name": "[v3,4/9] fstests: verify fanotify isolation on cloned filesystems", "commit_ref": null, "pull_url": null, "state": "new", "archived": false, "hash": "91a531ac0e89b5a03c887de9473206fb132d9897", "submitter": { "id": 92722, "url": "http://patchwork.ozlabs.org/api/people/92722/?format=api", "name": "Anand Jain", "email": "asj@kernel.org" }, "delegate": null, "mbox": "http://patchwork.ozlabs.org/project/linux-ext4/patch/4777ecd14815b92c9e8577ed4d073d0f999e51ef.1777281778.git.asj@kernel.org/mbox/", "series": [ { "id": 501620, "url": "http://patchwork.ozlabs.org/api/series/501620/?format=api", "web_url": "http://patchwork.ozlabs.org/project/linux-ext4/list/?series=501620", "date": "2026-04-27T10:19:32", "name": "fstests: add test coverage for cloned filesystem ids", "version": 3, "mbox": "http://patchwork.ozlabs.org/series/501620/mbox/" } ], "comments": "http://patchwork.ozlabs.org/api/patches/2228760/comments/", "check": "pending", "checks": "http://patchwork.ozlabs.org/api/patches/2228760/checks/", "tags": {}, "related": [], "headers": { "Return-Path": "\n <SRS0=CFyM=C2=vger.kernel.org=linux-ext4+bounces-16111-patchwork-incoming=ozlabs.org@ozlabs.org>", "X-Original-To": [ "incoming@patchwork.ozlabs.org", "linux-ext4@vger.kernel.org" ], "Delivered-To": [ "patchwork-incoming@legolas.ozlabs.org", "patchwork-incoming@ozlabs.org" ], "Authentication-Results": [ "legolas.ozlabs.org;\n\tdkim=pass (2048-bit key;\n unprotected) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256\n header.s=k20201202 header.b=tZDQq6a3;\n\tdkim-atps=neutral", "legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=ozlabs.org\n (client-ip=2404:9400:2221:ea00::3; helo=mail.ozlabs.org;\n envelope-from=srs0=cfym=c2=vger.kernel.org=linux-ext4+bounces-16111-patchwork-incoming=ozlabs.org@ozlabs.org;\n receiver=patchwork.ozlabs.org)", "gandalf.ozlabs.org;\n arc=pass smtp.remote-ip=\"2600:3c09:e001:a7::12fc:5321\"\n arc.chain=subspace.kernel.org", "gandalf.ozlabs.org;\n dmarc=pass (p=quarantine dis=none) header.from=kernel.org", "gandalf.ozlabs.org;\n\tdkim=pass (2048-bit key;\n unprotected) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256\n header.s=k20201202 header.b=tZDQq6a3;\n\tdkim-atps=neutral", "gandalf.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=vger.kernel.org\n (client-ip=2600:3c09:e001:a7::12fc:5321; helo=sto.lore.kernel.org;\n envelope-from=linux-ext4+bounces-16111-patchwork-incoming=ozlabs.org@vger.kernel.org;\n receiver=ozlabs.org)", "smtp.subspace.kernel.org;\n\tdkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org\n header.b=\"tZDQq6a3\"", "smtp.subspace.kernel.org;\n arc=none smtp.client-ip=10.30.226.201" ], "Received": [ "from mail.ozlabs.org (mail.ozlabs.org [IPv6:2404:9400:2221:ea00::3])\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 4g403g0T8bz1xvV\n\tfor <incoming@patchwork.ozlabs.org>; Mon, 27 Apr 2026 20:21:51 +1000 (AEST)", "from mail.ozlabs.org (mail.ozlabs.org [IPv6:2404:9400:2221:ea00::3])\n\tby gandalf.ozlabs.org (Postfix) with ESMTP id 4g403f6yKJz4wKQ\n\tfor <incoming@patchwork.ozlabs.org>; Mon, 27 Apr 2026 20:21:50 +1000 (AEST)", "by gandalf.ozlabs.org (Postfix)\n\tid 4g403f6t6hz4wHs; Mon, 27 Apr 2026 20:21:50 +1000 (AEST)", "from sto.lore.kernel.org (sto.lore.kernel.org\n [IPv6:2600:3c09:e001:a7::12fc:5321])\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 gandalf.ozlabs.org (Postfix) with ESMTPS id 4g403b24HMz4wKR\n\tfor <patchwork-incoming@ozlabs.org>; Mon, 27 Apr 2026 20:21:47 +1000 (AEST)", "from smtp.subspace.kernel.org (conduit.subspace.kernel.org\n [100.90.174.1])\n\tby sto.lore.kernel.org (Postfix) with ESMTP id C5E003018B6A\n\tfor <patchwork-incoming@ozlabs.org>; Mon, 27 Apr 2026 10:20:10 +0000 (UTC)", "from localhost.localdomain (localhost.localdomain [127.0.0.1])\n\tby smtp.subspace.kernel.org (Postfix) with ESMTP id 30B093B2FCE;\n\tMon, 27 Apr 2026 10:20:04 +0000 (UTC)", "from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org\n [10.30.226.201])\n\t(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))\n\t(No client certificate requested)\n\tby smtp.subspace.kernel.org (Postfix) with ESMTPS id E044630595B;\n\tMon, 27 Apr 2026 10:20:03 +0000 (UTC)", "by smtp.kernel.org (Postfix) with ESMTPSA id 28A65C19425;\n\tMon, 27 Apr 2026 10:20:02 +0000 (UTC)" ], "ARC-Seal": [ "i=2; a=rsa-sha256; d=ozlabs.org; s=201707; t=1777285310; cv=pass;\n\tb=k1wcQSA/s3ByjEtvwZmuqqVG5v0bWGy42rXl2dt7C4N6MGmuHzHYKD33Seyi5RXRKgs5sTK19s460urRtiDd7wB7GozgNQUra8ximppXuckpnqQ3+AfsJgrbPmaiqBHWcvn8pttnrylLAAokWh4KptPXRkg7P1sPXGx6YDdY2rEAcEp3rmjJQtleNl1a1mLmlgpn+epxGui9HJ7UAN4jLzslknPGqRZlsEg4nmcE/u9ryH2BUzvjHdvGFQbTUiMiHTzk47/KisGa02zbKG1svy2+aookjZfZOdiElXXBypTrUlqT2H3OiLKz8M7ab+wL8CJKtESJDj4gYBgbyAeBwg==", "i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116;\n\tt=1777285204; cv=none;\n b=bizjNDizQBaEFcI3gkURPrxWQ8tXbYHuZgPUEeyWJ7bMoqkymNhnvKiu0xunWtMbj7q1n+MXzE1GbK3UUUhow6cFguQFOa52eegKMhoZn/3Z7FBxMuC0bAFlKijDmu1LnDwpRBxRIEoSNgKiE0LN6Mc5w6MgPp8RPGbIY983OCk=" ], "ARC-Message-Signature": [ "i=2; a=rsa-sha256; d=ozlabs.org; s=201707;\n\tt=1777285310; c=relaxed/relaxed;\n\tbh=htAYuUBTqKpQyy7grV3sNrKdnLYXORohKZutVui3bX8=;\n\th=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References:\n\t MIME-Version;\n b=How9XNqpINC3kyWOwM5W3hVbVrD67s+YfPoa46aWNwEbb0vv8CRmcZbmrZahtEwTkPSS5CbRt/KzaGXtmRf5xbThEEIDF1JISng58Dw9xXp378MhMcRk3I63jWUW/Z50nFiWjMWS3wHKx7i/cQotNgl/tmDn8PD6bfuhTPF+ZfvsM5Heb4R+biUC/+0ll+Y6T/ALY9MZ3isW1euc+FxjCdobchiBuZk2ueGEzNA68G4s1Yx1XYuv6DDB2vJ/Kjp1kZtPG4LZyHk3w0nEAUN5W602Nr0mpprvI61j0Yk8qZYPqLUJJJ0LhwWgypeAg9N31yZXW0qn16DSLaP4z/CAzg==", "i=1; a=rsa-sha256; d=subspace.kernel.org;\n\ts=arc-20240116; t=1777285204; c=relaxed/simple;\n\tbh=AnK9/266XVBJ3UR81lpGj5Wkb9+DgFvDhivXlFWsuBM=;\n\th=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References:\n\t MIME-Version;\n b=mqI4r8ZITAuzy69+ghBMDdU3g10oaWiFwH05Ke1Q8E8noUvZGmJi442xKRgziFSJWuZQsamT2xdde6MmNlzTnIq1qSzzLxWeY9bRX2HNdbo351GaCURouz6Hj6R6lG+M8/YpaIlAI2l/ckROmKe91vRXNmnObsuwHMxwSt3vedA=" ], "ARC-Authentication-Results": [ "i=2; gandalf.ozlabs.org;\n dmarc=pass (p=quarantine dis=none) header.from=kernel.org;\n dkim=pass (2048-bit key;\n unprotected) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256\n header.s=k20201202 header.b=tZDQq6a3; dkim-atps=neutral;\n spf=pass (client-ip=2600:3c09:e001:a7::12fc:5321; helo=sto.lore.kernel.org;\n envelope-from=linux-ext4+bounces-16111-patchwork-incoming=ozlabs.org@vger.kernel.org;\n receiver=ozlabs.org) smtp.mailfrom=vger.kernel.org", "i=1; smtp.subspace.kernel.org;\n dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org\n header.b=tZDQq6a3; arc=none smtp.client-ip=10.30.226.201" ], "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org;\n\ts=k20201202; t=1777285203;\n\tbh=AnK9/266XVBJ3UR81lpGj5Wkb9+DgFvDhivXlFWsuBM=;\n\th=From:To:Cc:Subject:Date:In-Reply-To:References:From;\n\tb=tZDQq6a3NJn7EMGPgfbCC/VDPWEpLu9Tk9X/jtZslroJompKUUzr6ye3Uvh7Gq4aH\n\t peKcdadP8TIjeXubKU0oRXcPdfBRsD8EzIdTrC1a1vK1Hgp/iA3bGQHSkG2x/lxX9M\n\t TgdRtSusV9okd35RLdiyntPw14+ObBhuYwh060XCrH9u9G8/q7O8USuKkua3XmZj+K\n\t M/o0A8rtF4IQtqcs25w7xvJop33F6q3udI3MwxOWBxsFDqohqGA7nMzuLO3z0ZxnLf\n\t QjpcE03vt/16bwn6uuPWrSz8gFkZC7Frq4OtMU2RqpHeB9xDeIOBtdy0OYZgGf05bN\n\t Ck0Zt39r33YTg==", "From": "Anand Jain <asj@kernel.org>", "To": "fstests@vger.kernel.org", "Cc": "linux-btrfs@vger.kernel.org,\n\tlinux-ext4@vger.kernel.org,\n\tlinux-xfs@vger.kernel.org,\n\tlinux-f2fs@vger.kernel.org,\n\tamir73il@gmail.com,\n\tzlang@redhat.com,\n\thch@infradead.org", "Subject": "[PATCH v3 4/9] fstests: verify fanotify isolation on cloned\n filesystems", "Date": "Mon, 27 Apr 2026 18:19:36 +0800", "Message-ID": "\n <4777ecd14815b92c9e8577ed4d073d0f999e51ef.1777281778.git.asj@kernel.org>", "X-Mailer": "git-send-email 2.43.0", "In-Reply-To": "<cover.1777281778.git.asj@kernel.org>", "References": "<cover.1777281778.git.asj@kernel.org>", "Precedence": "bulk", "X-Mailing-List": "linux-ext4@vger.kernel.org", "List-Id": "<linux-ext4.vger.kernel.org>", "List-Subscribe": "<mailto:linux-ext4+subscribe@vger.kernel.org>", "List-Unsubscribe": "<mailto:linux-ext4+unsubscribe@vger.kernel.org>", "MIME-Version": "1.0", "Content-Transfer-Encoding": "8bit", "X-Spam-Status": "No, score=-1.2 required=5.0 tests=ARC_SIGNED,ARC_VALID,\n\tDKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DMARC_PASS,\n\tMAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=disabled\n\tversion=4.0.1", "X-Spam-Checker-Version": "SpamAssassin 4.0.1 (2024-03-25) on gandalf.ozlabs.org" }, "content": "Verify that fanotify events are correctly routed to the appropriate\nwatcher when cloned filesystems are mounted.\nHelps verify kernel's event notification distinguishes between devices\nsharing the same FSID/UUID.\n\nSigned-off-by: Anand Jain <asj@kernel.org>\n---\n common/config | 1 +\n tests/generic/801 | 115 ++++++++++++++++++++++++++++++++++++++++++\n tests/generic/801.out | 7 +++\n 3 files changed, 123 insertions(+)\n create mode 100644 tests/generic/801\n create mode 100644 tests/generic/801.out", "diff": "diff --git a/common/config b/common/config\nindex 605a57947a40..1588bdcb1aa1 100644\n--- a/common/config\n+++ b/common/config\n@@ -243,6 +243,7 @@ export PARTED_PROG=\"$(type -P parted)\"\n export XFS_PROPERTY_PROG=\"$(type -P xfs_property)\"\n export FSCRYPTCTL_PROG=\"$(type -P fscryptctl)\"\n export INOTIFYWAIT_PROG=\"$(type -P inotifywait)\"\n+export FSNOTIFYWAIT_PROG=\"$(type -P fsnotifywait)\"\n \n # udev wait functions.\n #\ndiff --git a/tests/generic/801 b/tests/generic/801\nnew file mode 100644\nindex 000000000000..3f64e4de2206\n--- /dev/null\n+++ b/tests/generic/801\n@@ -0,0 +1,115 @@\n+#! /bin/bash\n+# SPDX-License-Identifier: GPL-2.0\n+# Copyright (c) 2026 Anand Jain <asj@kernel.org>. All Rights Reserved.\n+#\n+# FS QA Test 801\n+# Verify fanotify FID functionality on cloned filesystems by setting up\n+# watchers and making sure notifications are in the correct logs files.\n+\n+. ./common/preamble\n+\n+_begin_fstest auto quick mount clone\n+\n+_require_test\n+_require_loop\n+_require_command \"$FSNOTIFYWAIT_PROG\" fsnotifywait\n+\n+[ \"$FSTYP\" = \"ext4\" ] && _fixed_by_kernel_commit xxxxxxxxxxxx \\\n+\t\"ext4: derive f_fsid from block device to avoid collisions\"\n+\n+_cleanup()\n+{\n+\tcd /\n+\t[[ -n $pid1 ]] && { kill -TERM \"$pid1\" 2> /dev/null; wait $pid1; }\n+\t[[ -n $pid2 ]] && { kill -TERM \"$pid2\" 2> /dev/null; wait $pid2; }\n+\tumount $mnt1 $mnt2 2>/dev/null\n+\t_loop_image_destroy \"${devs[@]}\" 2> /dev/null\n+\trm -r -f $tmp.*\n+}\n+\n+monitor_fanotify()\n+{\n+\tlocal mmnt=$1\n+\texec stdbuf -oL $FSNOTIFYWAIT_PROG -m -F -S -e create \"$mmnt\" 2>&1\n+}\n+\n+fsid_to_fid_parts()\n+{\n+\tlocal fsid=$1\n+\t# Pad to 16 hex chars (64-bit), then split into two 32-bit halves\n+\tlocal padded=$(printf '%016x' \"0x${fsid}\")\n+\tlocal hi=$(printf '%x' \"0x${padded:0:8}\") # strips leading zeros\n+\tlocal lo=$(printf '%x' \"0x${padded:8:8}\") # strips leading zeros\n+\techo \"${hi}.${lo}\"\n+}\n+\n+devs=()\n+_loop_image_create_clone devs\n+mkdir -p $TEST_DIR/$seq\n+mnt1=$TEST_DIR/$seq/mnt1\n+mnt2=$TEST_DIR/$seq/mnt2\n+mkdir -p $mnt1\n+mkdir -p $mnt2\n+\n+_mount $(_common_dev_mount_options) $(_clone_mount_option) ${devs[0]} $mnt1 || \\\n+\t\t\t\t\t\t_fail \"Failed to mount dev1\"\n+_mount $(_common_dev_mount_options) $(_clone_mount_option) ${devs[1]} $mnt2 || \\\n+\t\t\t\t\t\t_fail \"Failed to mount dev2\"\n+\n+fsid1=$(stat -f -c \"%i\" $mnt1)\n+fsid2=$(stat -f -c \"%i\" $mnt2)\n+\n+[[ \"$fsid1\" == \"$fsid2\" ]] && \\\n+\t_notrun \"Require clone filesystem with unique f_fsid\"\n+\n+log1=$tmp.fanotify1\n+log2=$tmp.fanotify2\n+\n+pid1=\"\"\n+pid2=\"\"\n+echo \"Setup FID fanotify watchers on both mnt1 and mnt2\"\n+( monitor_fanotify \"$mnt1\" > \"$log1\" ) &\n+pid1=$!\n+( monitor_fanotify \"$mnt2\" > \"$log2\" ) &\n+pid2=$!\n+sleep 2\n+\n+echo \"Trigger file creation on mnt1\"\n+touch $mnt1/file_on_mnt1\n+sync\n+sleep 1\n+\n+echo \"Trigger file creation on mnt2\"\n+touch $mnt2/file_on_mnt2\n+sync\n+sleep 1\n+\n+echo \"Verify fsid in the fanotify\"\n+kill $pid1 $pid2\n+wait $pid1 $pid2 2>/dev/null\n+pid1=\"\"\n+pid2=\"\"\n+\n+e_fsid1=$(fsid_to_fid_parts \"$fsid1\")\n+e_fsid2=$(fsid_to_fid_parts \"$fsid2\")\n+\n+echo $fsid1 $e_fsid1 $fsid2 $e_fsid2 >> $seqres.full\n+cat $log1 >> $seqres.full\n+cat $log2 >> $seqres.full\n+\n+if grep -qF \"$e_fsid1\" \"$log1\" && ! grep -qF \"$e_fsid2\" \"$log1\"; then\n+\techo \"SUCCESS: mnt1 events found\"\n+else\n+\t[ ! -s \"$log1\" ] && echo \" - mnt1 received no events.\"\n+\tgrep -qF \"$e_fsid2\" \"$log1\" && echo \" - mnt1 received event from mnt2.\"\n+fi\n+\n+if grep -qF \"$e_fsid2\" \"$log2\" && ! grep -qF \"$e_fsid1\" \"$log2\"; then\n+\techo \"SUCCESS: mnt2 events found\"\n+else\n+\t[ ! -s \"$log2\" ] && echo \" - mnt2 received no events.\"\n+\tgrep -qF \"$e_fsid1\" \"$log2\" && echo \" - mnt2 received event from mnt1.\"\n+fi\n+\n+status=0\n+exit\ndiff --git a/tests/generic/801.out b/tests/generic/801.out\nnew file mode 100644\nindex 000000000000..d7b318d9f27c\n--- /dev/null\n+++ b/tests/generic/801.out\n@@ -0,0 +1,7 @@\n+QA output created by 801\n+Setup FID fanotify watchers on both mnt1 and mnt2\n+Trigger file creation on mnt1\n+Trigger file creation on mnt2\n+Verify fsid in the fanotify\n+SUCCESS: mnt1 events found\n+SUCCESS: mnt2 events found\n", "prefixes": [ "v3", "4/9" ] }