get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

GET /api/1.1/patches/2230825/?format=api
HTTP 200 OK
Allow: GET, PUT, PATCH, HEAD, OPTIONS
Content-Type: application/json
Vary: Accept

{
    "id": 2230825,
    "url": "http://patchwork.ozlabs.org/api/1.1/patches/2230825/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/ltp/patch/20260430051915.2178-1-wegao@suse.com/",
    "project": {
        "id": 59,
        "url": "http://patchwork.ozlabs.org/api/1.1/projects/59/?format=api",
        "name": "Linux Test Project development",
        "link_name": "ltp",
        "list_id": "ltp.lists.linux.it",
        "list_email": "ltp@lists.linux.it",
        "web_url": "",
        "scm_url": "",
        "webscm_url": ""
    },
    "msgid": "<20260430051915.2178-1-wegao@suse.com>",
    "date": "2026-04-30T05:19:07",
    "name": "[v6] fsconfig04: Check FSCONFIG_SET_PATH",
    "commit_ref": null,
    "pull_url": null,
    "state": "needs-review-ack",
    "archived": false,
    "hash": "80eb9ff7622e7d246661686e5b8481d7994bedae",
    "submitter": {
        "id": 85577,
        "url": "http://patchwork.ozlabs.org/api/1.1/people/85577/?format=api",
        "name": "Wei Gao",
        "email": "wegao@suse.com"
    },
    "delegate": null,
    "mbox": "http://patchwork.ozlabs.org/project/ltp/patch/20260430051915.2178-1-wegao@suse.com/mbox/",
    "series": [
        {
            "id": 502199,
            "url": "http://patchwork.ozlabs.org/api/1.1/series/502199/?format=api",
            "web_url": "http://patchwork.ozlabs.org/project/ltp/list/?series=502199",
            "date": "2026-04-30T05:19:07",
            "name": "[v6] fsconfig04: Check FSCONFIG_SET_PATH",
            "version": 6,
            "mbox": "http://patchwork.ozlabs.org/series/502199/mbox/"
        }
    ],
    "comments": "http://patchwork.ozlabs.org/api/patches/2230825/comments/",
    "check": "warning",
    "checks": "http://patchwork.ozlabs.org/api/patches/2230825/checks/",
    "tags": {},
    "headers": {
        "Return-Path": "<ltp-bounces+incoming=patchwork.ozlabs.org@lists.linux.it>",
        "X-Original-To": [
            "incoming@patchwork.ozlabs.org",
            "ltp@lists.linux.it"
        ],
        "Delivered-To": [
            "patchwork-incoming@legolas.ozlabs.org",
            "ltp@picard.linux.it"
        ],
        "Authentication-Results": [
            "legolas.ozlabs.org;\n\tdkim=pass (1024-bit key;\n unprotected) header.d=lists.linux.it header.i=@lists.linux.it\n header.a=rsa-sha256 header.s=picard header.b=T0W9MNXi;\n\tdkim=fail reason=\"signature verification failed\" (2048-bit key;\n unprotected) header.d=suse.com header.i=@suse.com header.a=rsa-sha256\n header.s=google header.b=XjjFHO1R;\n\tdkim-atps=neutral",
            "legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=lists.linux.it\n (client-ip=2001:1418:10:5::2; helo=picard.linux.it;\n envelope-from=ltp-bounces+incoming=patchwork.ozlabs.org@lists.linux.it;\n receiver=patchwork.ozlabs.org)"
        ],
        "Received": [
            "from picard.linux.it (picard.linux.it [IPv6:2001:1418:10:5::2])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\t key-exchange x25519 server-signature ECDSA (secp384r1) server-digest SHA384)\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4g5jCL2BvWz1yHv\n\tfor <incoming@patchwork.ozlabs.org>; Thu, 30 Apr 2026 15:19:26 +1000 (AEST)",
            "from picard.linux.it (localhost [IPv6:::1])\n\tby picard.linux.it (Postfix) with ESMTP id 688CF3E1A52\n\tfor <incoming@patchwork.ozlabs.org>; Thu, 30 Apr 2026 07:19:23 +0200 (CEST)",
            "from in-3.smtp.seeweb.it (in-3.smtp.seeweb.it [217.194.8.3])\n (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n key-exchange X25519 server-signature ECDSA (secp384r1))\n (No client certificate requested)\n by picard.linux.it (Postfix) with ESMTPS id CD7AB3C5ED7\n for <ltp@lists.linux.it>; Thu, 30 Apr 2026 07:19:19 +0200 (CEST)",
            "from mail-wm1-x332.google.com (mail-wm1-x332.google.com\n [IPv6:2a00:1450:4864:20::332])\n (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)\n key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest\n SHA256)\n (No client certificate requested)\n by in-3.smtp.seeweb.it (Postfix) with ESMTPS id AC3FD1A0037B\n for <ltp@lists.linux.it>; Thu, 30 Apr 2026 07:19:18 +0200 (CEST)",
            "by mail-wm1-x332.google.com with SMTP id\n 5b1f17b1804b1-48374014a77so5062055e9.3\n for <ltp@lists.linux.it>; Wed, 29 Apr 2026 22:19:18 -0700 (PDT)",
            "from localhost ([2a07:de40:b240:0:2ad6:ed42:2ad6:ed42])\n by smtp.gmail.com with UTF8SMTPSA id\n 5b1f17b1804b1-48a81b99127sm36825955e9.0.2026.04.29.22.19.17\n (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n Wed, 29 Apr 2026 22:19:17 -0700 (PDT)"
        ],
        "DKIM-Signature": [
            "v=1; a=rsa-sha256; c=relaxed/simple; d=lists.linux.it;\n i=@lists.linux.it; q=dns/txt; s=picard; t=1777526363; h=to : date :\n message-id : in-reply-to : references : mime-version : subject :\n list-id : list-unsubscribe : list-archive : list-post : list-help :\n list-subscribe : from : reply-to : content-type :\n content-transfer-encoding : sender : from;\n bh=Ua9fsL7nXJp07DtC6J87sJizvSWw/S78X0RR2aM9ND0=;\n b=T0W9MNXioW+wDjJd0oPZMSdhkCJKynwUkgUuVC4A/BoJf3sMvk6Uh5GIDD/Dt676tRP3E\n 8ppdksgO2ERIunsfOKfO3Vrj/SNPeivL2xL4xh6nIFwuaDfVaFf0IDCKCJtWRf/7HkkzdEH\n BztY8SSE3RltM6XhkPM0IDa/iJRs1b0=",
            "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=suse.com; s=google; t=1777526358; x=1778131158; darn=lists.linux.it;\n h=content-transfer-encoding:mime-version:references:in-reply-to\n :message-id:date:subject:cc:to:from:from:to:cc:subject:date\n :message-id:reply-to;\n bh=0jA69VNxe8pEXVQ7AIskqtx3z4p7+0nq7Ms+dDhJCMA=;\n b=XjjFHO1R3Z339Y/q1REMJGcrSPVmw8Y+qs6dIbQON065zbqDiLkMDaTaQoeIFYYmoY\n JVhOEhdXqIeqXQszF4JGbCSFk/gySaHsDePoMK6qJTOoEq7NnvL97/rh4RQQOtHbklmR\n Ba1QGIJIBl4+yYJFCQ0oTvoawu4j+lEnHej8rXQXyZiY12crhZui07O2mJsaJq7sVkc/\n uJAtmwPBfkgjIeHt4iH3rs0i1P8SwqSteDzLRKofJEqoIVQ0KQ3mzSO4GhPUDJXnqCch\n 0yyTWNtnTU0cunpyUK55G0W/cxdrzzvXjgVXRHluR01N4kskkVvPwhZQWkn2/fcpi5do\n 9EsQ=="
        ],
        "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=1e100.net; s=20251104; t=1777526358; x=1778131158;\n h=content-transfer-encoding:mime-version:references:in-reply-to\n :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from\n :to:cc:subject:date:message-id:reply-to;\n bh=0jA69VNxe8pEXVQ7AIskqtx3z4p7+0nq7Ms+dDhJCMA=;\n b=fpEeu5RTrw9kfvI0VbMUFDQbq69DpROcKC8HRoD6eDeYTCo8Jhc7F7iaf9plwsA+t+\n f3Dmq/NMhq+MNba/hiKV5RgBziOz6dClDpJQEqC2hPTihargH2lBZyvVoHnYz1YMN1Uk\n mAymK+JQbj/pzyem0znHZUIETqK4naCGdGXYvnI7y9QMFJcITF8s5LrkW4iNltUuVntm\n GBs8zofm4pNxYhEZhqKhP2N4kvP8Nu57fSc2z9UCJ7ycqzQ4IUU5pMmwTTosxhCYMSxI\n 0yHMtjIb3nuwjowwyKXiaar39SBBHVDtYtj+zs5vTjpxJuMHabASOqW0N0wKkOJ9u3QC\n k+MQ==",
        "X-Gm-Message-State": "AOJu0YyE4koPzJQFSMwAluDLwpegNw5k5fWvAE+MjTVD/vk3TsCUdfVP\n aBSsyrdcX3CCZz/nk+HwFiJ1Y3W4UDdDhH90Wp5nQHdpwrInaBQleWO5BUF4qf17vwdt1H8AZOr\n SEy8=",
        "X-Gm-Gg": "AeBDiesiWuxN41f/YAz9Lxbz/xR4PfLm4fhIrMg2Vz1rLRE5MObyD4NQyQWchpWWNho\n k/F2yD/BVB4y1XINqLBWO7Y6PxbDoJXbFlKLoLAGkxczLM6ESdaOvIJLLom4QPi3mNDS/9fHdBv\n JkUvFiFdstsLgxf2LEFt3h/AYeKyPbOeOxAsYXpLdmFR5I/bxyHdq8sq48NXdC9G9dTt2o0klGm\n qegWkCHqWaUFmDyBOM2YUDXGmuLVOJmuSwlZXK30gj6Wb3imDpIjpr4qKyKkbd5Eiw15m0I2+pR\n xNLmEKkFSAe46aUddLUB9S6ORHgb2DkAd5Bdg1g/5Srp3lOJOOmjEAV6hOK/F9CYH/imkF+Y81G\n c7h0Y6xvtzZObvxY41i8gyaygBrWIO8YEhakcLxBLYZg+f5cjuOxzpnYDGZdNRAEgnKEP1h5dRJ\n NaJRZnNGF6v3pjM91LHNzg4Q==",
        "X-Received": "by 2002:a05:600c:6285:b0:483:709e:f238 with SMTP id\n 5b1f17b1804b1-48a84486f35mr23637445e9.29.1777526357648;\n Wed, 29 Apr 2026 22:19:17 -0700 (PDT)",
        "To": "ltp@lists.linux.it",
        "Date": "Thu, 30 Apr 2026 05:19:07 +0000",
        "Message-ID": "<20260430051915.2178-1-wegao@suse.com>",
        "X-Mailer": "git-send-email 2.43.0",
        "In-Reply-To": "<20260416112611.23057-1-wegao@suse.com>",
        "References": "<20260416112611.23057-1-wegao@suse.com>",
        "MIME-Version": "1.0",
        "X-Spam-Status": "No, score=0.1 required=7.0 tests=DKIM_SIGNED,DKIM_VALID,\n DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS shortcircuit=no\n autolearn=disabled version=4.0.1",
        "X-Spam-Checker-Version": "SpamAssassin 4.0.1 (2024-03-25) on in-3.smtp.seeweb.it",
        "X-Virus-Scanned": "clamav-milter 1.0.9 at in-3.smtp.seeweb.it",
        "X-Virus-Status": "Clean",
        "Subject": "[LTP] [PATCH v6] fsconfig04: Check FSCONFIG_SET_PATH",
        "X-BeenThere": "ltp@lists.linux.it",
        "X-Mailman-Version": "2.1.29",
        "Precedence": "list",
        "List-Id": "Linux Test Project <ltp.lists.linux.it>",
        "List-Unsubscribe": "<https://lists.linux.it/options/ltp>,\n <mailto:ltp-request@lists.linux.it?subject=unsubscribe>",
        "List-Archive": "<http://lists.linux.it/pipermail/ltp/>",
        "List-Post": "<mailto:ltp@lists.linux.it>",
        "List-Help": "<mailto:ltp-request@lists.linux.it?subject=help>",
        "List-Subscribe": "<https://lists.linux.it/listinfo/ltp>,\n <mailto:ltp-request@lists.linux.it?subject=subscribe>",
        "From": "Wei Gao via ltp <ltp@lists.linux.it>",
        "Reply-To": "Wei Gao <wegao@suse.com>",
        "Content-Type": "text/plain; charset=\"us-ascii\"",
        "Content-Transfer-Encoding": "7bit",
        "Errors-To": "ltp-bounces+incoming=patchwork.ozlabs.org@lists.linux.it",
        "Sender": "\"ltp\" <ltp-bounces+incoming=patchwork.ozlabs.org@lists.linux.it>"
    },
    "content": "The fsconfig01.c does not test if FSCONFIG_SET_PATH have any effect,\nmost of the calls there just set dummy \"sync\" parameter. This test\ncase aims to verify if the FSCONFIG_SET_PATH operation can be used\nto dynamically change the external journal device of ext3 or ext4\nfilesystem.\n\nFixes: https://github.com/linux-test-project/ltp/issues/1169\nSigned-off-by: Wei Gao <wegao@suse.com>\n---\nv5->v6:\n- use `tst_find_free_loopdev()` + `tst_attach_device()` from\n`tst_device.h` instead of pulling in a legacy header.\n\n runtest/syscalls                              |   1 +\n testcases/kernel/syscalls/fsconfig/.gitignore |   1 +\n .../kernel/syscalls/fsconfig/fsconfig04.c     | 172 ++++++++++++++++++\n 3 files changed, 174 insertions(+)\n create mode 100644 testcases/kernel/syscalls/fsconfig/fsconfig04.c",
    "diff": "diff --git a/runtest/syscalls b/runtest/syscalls\nindex 5025b259f..84adf4fad 100644\n--- a/runtest/syscalls\n+++ b/runtest/syscalls\n@@ -422,6 +422,7 @@ fremovexattr02 fremovexattr02\n fsconfig01 fsconfig01\n fsconfig02 fsconfig02\n fsconfig03 fsconfig03\n+fsconfig04 fsconfig04\n \n fsmount01 fsmount01\n fsmount02 fsmount02\ndiff --git a/testcases/kernel/syscalls/fsconfig/.gitignore b/testcases/kernel/syscalls/fsconfig/.gitignore\nindex cfedae5f7..bd3754c34 100644\n--- a/testcases/kernel/syscalls/fsconfig/.gitignore\n+++ b/testcases/kernel/syscalls/fsconfig/.gitignore\n@@ -1,3 +1,4 @@\n /fsconfig01\n /fsconfig02\n /fsconfig03\n+/fsconfig04\ndiff --git a/testcases/kernel/syscalls/fsconfig/fsconfig04.c b/testcases/kernel/syscalls/fsconfig/fsconfig04.c\nnew file mode 100644\nindex 000000000..f00ce88e4\n--- /dev/null\n+++ b/testcases/kernel/syscalls/fsconfig/fsconfig04.c\n@@ -0,0 +1,172 @@\n+// SPDX-License-Identifier: GPL-2.0-or-later\n+/*\n+ * Copyright (c) 2026 Wei Gao <wegao@suse.com>\n+ */\n+\n+/*\\\n+ * This test aims to validate the functionality of fsconfig(FSCONFIG_SET_PATH) in\n+ * dynamically altering the external journal device of a ext3 or ext4 filesystem.\n+ * Case acquires three loop devices (dev0, dev1, dev2), it formats dev1 and dev2\n+ * as external journal devices using the -O journal_dev option and assigns them\n+ * the same UUID. Then formats dev0 (the main filesystem) multiple times, first\n+ * associating it with dev1, then change to dev2, finally back to dev1 again as\n+ * an external journal using the -J device= option.\n+ *\n+ * 2 Implementation notes in this case need mention:\n+ *\n+ * - To avoid \"journal UUID does not match\" error when switch external journal device\n+ *   we have to assign same UUID to dev1/dev2\n+ * - Before fsconfig test we have to format dev0 associating to dev1->dev2->dev1,\n+ *   this will make sure both dev1/2's super block contain correct content. Otherwise\n+ *   you will encounter error such as \"EXT4-fs (loop0): External journal has more than\n+ *   one user (unsupported) - 0\" when switch external journal device using fsconfig.\n+ */\n+\n+#include \"tst_test.h\"\n+#include \"tst_safe_stdio.h\"\n+#include \"lapi/fsmount.h\"\n+\n+#define MNTPOINT\t\"mntpoint\"\n+#define LOOP_DEV_SIZE 10\n+#define UUID \"d73c9e5e-97e4-4a9c-b17e-75a931b02660\"\n+\n+static int fd = -1;\n+static char dev0[PATH_MAX];\n+static char dev1[PATH_MAX];\n+static char dev2[PATH_MAX];\n+\n+static void cleanup(void)\n+{\n+\tif (fd != -1)\n+\t\tSAFE_CLOSE(fd);\n+\n+\tif (dev1[0])\n+\t\ttst_detach_device(dev1);\n+\n+\tif (dev2[0])\n+\t\ttst_detach_device(dev2);\n+}\n+\n+static void setup(void)\n+{\n+\tstrcpy(dev0, tst_device->dev);\n+\n+\tif (tst_prealloc_file(\"dev1_file\", 1024 * 1024, LOOP_DEV_SIZE))\n+\t\ttst_brk(TBROK, \"Failed to create dev1_file\");\n+\n+\tif (tst_find_free_loopdev(dev1, sizeof(dev1)) == -1)\n+\t\ttst_brk(TBROK, \"No free loop device found for dev1\");\n+\n+\tif (tst_attach_device(dev1, \"dev1_file\"))\n+\t\ttst_brk(TBROK, \"Failed to attach dev1_file to %s\", dev1);\n+\n+\tif (tst_prealloc_file(\"dev2_file\", 1024 * 1024, LOOP_DEV_SIZE))\n+\t\ttst_brk(TBROK, \"Failed to create dev2_file\");\n+\n+\tif (tst_find_free_loopdev(dev2, sizeof(dev2)) == -1)\n+\t\ttst_brk(TBROK, \"No free loop device found for dev2\");\n+\n+\tif (tst_attach_device(dev2, \"dev2_file\"))\n+\t\ttst_brk(TBROK, \"Failed to attach dev2_file to %s\", dev2);\n+\n+\tconst char *const *mkfs_opts_set_UUID;\n+\tconst char *const *mkfs_opts_set_journal_dev1;\n+\tconst char *const *mkfs_opts_set_journal_dev2;\n+\n+\tmkfs_opts_set_UUID = (const char *const []) {\"-F\", \"-U\", UUID,\n+\t\t\"-O\", \"journal_dev\", NULL};\n+\n+\tchar device_option_dev1[PATH_MAX];\n+\tchar device_option_dev2[PATH_MAX];\n+\n+\tsnprintf(device_option_dev1, sizeof(device_option_dev1), \"device=%s\", dev1);\n+\tsnprintf(device_option_dev2, sizeof(device_option_dev2), \"device=%s\", dev2);\n+\n+\tmkfs_opts_set_journal_dev1 = (const char *const []) {\"-F\", \"-J\",\n+\t\tdevice_option_dev1, NULL};\n+\n+\tmkfs_opts_set_journal_dev2 = (const char *const []) {\"-F\", \"-J\",\n+\t\tdevice_option_dev2, NULL};\n+\n+\tSAFE_MKFS(dev1, tst_device->fs_type, mkfs_opts_set_UUID, NULL);\n+\tSAFE_MKFS(dev2, tst_device->fs_type, mkfs_opts_set_UUID, NULL);\n+\tSAFE_MKFS(dev0, tst_device->fs_type, mkfs_opts_set_journal_dev1, NULL);\n+\tSAFE_MKFS(dev0, tst_device->fs_type, mkfs_opts_set_journal_dev2, NULL);\n+\tSAFE_MKFS(dev0, tst_device->fs_type, mkfs_opts_set_journal_dev1, NULL);\n+}\n+\n+static void run(void)\n+{\n+\tTEST(fd = fsopen(tst_device->fs_type, 0));\n+\tif (fd == -1)\n+\t\ttst_brk(TBROK | TTERRNO, \"fsopen() failed\");\n+\n+\tTEST(fsconfig(fd, FSCONFIG_SET_STRING, \"source\", dev0, 0));\n+\tif (TST_RET == -1)\n+\t\ttst_brk(TFAIL | TTERRNO, \"fsconfig(FSCONFIG_SET_STRING) failed\");\n+\n+\tTEST(fsconfig(fd, FSCONFIG_SET_PATH, \"journal_path\", dev2, 0));\n+\tif (TST_RET == -1) {\n+\t\tif (TST_ERR == EOPNOTSUPP)\n+\t\t\ttst_brk(TCONF, \"fsconfig(FSCONFIG_SET_PATH) not supported\");\n+\t\telse\n+\t\t\ttst_brk(TFAIL | TTERRNO, \"fsconfig(FSCONFIG_SET_PATH) failed\");\n+\t}\n+\n+\tTEST(fsconfig(fd, FSCONFIG_CMD_CREATE, NULL, NULL, 0));\n+\tif (TST_RET == -1)\n+\t\ttst_brk(TFAIL | TTERRNO, \"fsconfig(FSCONFIG_CMD_CREATE) failed\");\n+\n+\tchar loop_name[NAME_MAX];\n+\tchar path[PATH_MAX];\n+\tchar device_str[NAME_MAX];\n+\tunsigned int major, minor, device_num;\n+\tunsigned int found = 0;\n+\n+\tSAFE_SSCANF(dev2, \"/dev/%s\", loop_name);\n+\n+\tsnprintf(path, sizeof(path), \"/sys/block/%s/dev\", loop_name);\n+\tSAFE_FILE_SCANF(path, \"%u:%u\", &major, &minor);\n+\tdevice_num = (major << 8) | minor;\n+\tsnprintf(device_str, sizeof(device_str), \"0x%04x\", device_num);\n+\n+\tchar line[PATH_MAX];\n+\tFILE *tune2fs;\n+\n+\tsnprintf(path, sizeof(path), \"tune2fs -l %s 2>&1\", dev0);\n+\ttune2fs = SAFE_POPEN(path, \"r\");\n+\n+\twhile (fgets(line, PATH_MAX, tune2fs)) {\n+\t\tif (*line && strstr(line, \"Journal device:\") && strstr(line, device_str)) {\n+\t\t\tfound = 1;\n+\t\t\tbreak;\n+\t\t}\n+\t}\n+\n+\tif (found == 1)\n+\t\ttst_res(TPASS, \"Device found in journal\");\n+\telse\n+\t\ttst_res(TFAIL, \"Device not found in journal\");\n+\n+\tpclose(tune2fs);\n+\tSAFE_CLOSE(fd);\n+}\n+\n+static struct tst_test test = {\n+\t.test_all = run,\n+\t.setup = setup,\n+\t.cleanup = cleanup,\n+\t.needs_root = 1,\n+\t.needs_tmpdir = 1,\n+\t.format_device = 1,\n+\t.mntpoint = MNTPOINT,\n+\t.needs_cmds = (struct tst_cmd []) {\n+\t\t{.cmd = \"tune2fs\"},\n+\t\t{}\n+\t},\n+\t.filesystems = (struct tst_fs []) {\n+\t\t{.type = \"ext3\"},\n+\t\t{.type = \"ext4\"},\n+\t\t{}\n+\t},\n+};\n",
    "prefixes": [
        "v6"
    ]
}