get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 2226060,
    "url": "http://patchwork.ozlabs.org/api/patches/2226060/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/uboot/patch/20260422065910.5398-1-briansune@gmail.com/",
    "project": {
        "id": 18,
        "url": "http://patchwork.ozlabs.org/api/projects/18/?format=api",
        "name": "U-Boot",
        "link_name": "uboot",
        "list_id": "u-boot.lists.denx.de",
        "list_email": "u-boot@lists.denx.de",
        "web_url": null,
        "scm_url": null,
        "webscm_url": null,
        "list_archive_url": "",
        "list_archive_url_format": "",
        "commit_url_format": ""
    },
    "msgid": "<20260422065910.5398-1-briansune@gmail.com>",
    "list_archive_url": null,
    "date": "2026-04-22T06:59:10",
    "name": "[v5] Improve handoff prepare on SoCFPGA",
    "commit_ref": null,
    "pull_url": null,
    "state": "new",
    "archived": false,
    "hash": "62a4e5310262f4512b643ef3d9be734cb008d2eb",
    "submitter": {
        "id": 91590,
        "url": "http://patchwork.ozlabs.org/api/people/91590/?format=api",
        "name": "Brian Sune",
        "email": "briansune@gmail.com"
    },
    "delegate": null,
    "mbox": "http://patchwork.ozlabs.org/project/uboot/patch/20260422065910.5398-1-briansune@gmail.com/mbox/",
    "series": [
        {
            "id": 500930,
            "url": "http://patchwork.ozlabs.org/api/series/500930/?format=api",
            "web_url": "http://patchwork.ozlabs.org/project/uboot/list/?series=500930",
            "date": "2026-04-22T06:59:10",
            "name": "[v5] Improve handoff prepare on SoCFPGA",
            "version": 5,
            "mbox": "http://patchwork.ozlabs.org/series/500930/mbox/"
        }
    ],
    "comments": "http://patchwork.ozlabs.org/api/patches/2226060/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/2226060/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<u-boot-bounces@lists.denx.de>",
        "X-Original-To": "incoming@patchwork.ozlabs.org",
        "Delivered-To": "patchwork-incoming@legolas.ozlabs.org",
        "Authentication-Results": [
            "legolas.ozlabs.org;\n\tdkim=pass (2048-bit key;\n unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256\n header.s=20251104 header.b=CTjWscCp;\n\tdkim-atps=neutral",
            "legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de\n (client-ip=2a01:238:438b:c500:173d:9f52:ddab:ee01; helo=phobos.denx.de;\n envelope-from=u-boot-bounces@lists.denx.de; receiver=patchwork.ozlabs.org)",
            "phobos.denx.de;\n dmarc=pass (p=none dis=none) header.from=gmail.com",
            "phobos.denx.de;\n spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de",
            "phobos.denx.de;\n\tdkim=pass (2048-bit key;\n unprotected) header.d=gmail.com header.i=@gmail.com header.b=\"CTjWscCp\";\n\tdkim-atps=neutral",
            "phobos.denx.de;\n dmarc=pass (p=none dis=none) header.from=gmail.com",
            "phobos.denx.de;\n spf=pass smtp.mailfrom=briansune@gmail.com"
        ],
        "Received": [
            "from phobos.denx.de (phobos.denx.de\n [IPv6:2a01:238:438b:c500:173d:9f52:ddab:ee01])\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 4g0qpT0VZjz1yCv\n\tfor <incoming@patchwork.ozlabs.org>; Wed, 22 Apr 2026 16:59:28 +1000 (AEST)",
            "from h2850616.stratoserver.net (localhost [IPv6:::1])\n\tby phobos.denx.de (Postfix) with ESMTP id E28128352B;\n\tWed, 22 Apr 2026 08:59:20 +0200 (CEST)",
            "by phobos.denx.de (Postfix, from userid 109)\n id A020B83936; Wed, 22 Apr 2026 08:59:19 +0200 (CEST)",
            "from mail-pf1-x434.google.com (mail-pf1-x434.google.com\n [IPv6:2607:f8b0:4864:20::434])\n (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits))\n (No client certificate requested)\n by phobos.denx.de (Postfix) with ESMTPS id 5CD0B801A9\n for <u-boot@lists.denx.de>; Wed, 22 Apr 2026 08:59:17 +0200 (CEST)",
            "by mail-pf1-x434.google.com with SMTP id\n d2e1a72fcca58-82faf871346so2539326b3a.0\n for <u-boot@lists.denx.de>; Tue, 21 Apr 2026 23:59:17 -0700 (PDT)",
            "from intel-VirtualBox.. ([185.213.82.94])\n by smtp.gmail.com with ESMTPSA id\n d2e1a72fcca58-82f8ebb3f8asm16608273b3a.36.2026.04.21.23.59.13\n (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n Tue, 21 Apr 2026 23:59:15 -0700 (PDT)"
        ],
        "X-Spam-Checker-Version": "SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de",
        "X-Spam-Level": "",
        "X-Spam-Status": "No, score=-1.1 required=5.0 tests=BAYES_00,DKIM_SIGNED,\n DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FORGED_GMAIL_RCVD,FREEMAIL_FROM,\n RCVD_IN_DNSWL_BLOCKED,SPF_HELO_NONE,SPF_PASS autolearn=no\n autolearn_force=no version=3.4.2",
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=gmail.com; s=20251104; t=1776841156; x=1777445956; darn=lists.denx.de;\n h=content-transfer-encoding:mime-version:message-id:date:subject:cc\n :to:from:from:to:cc:subject:date:message-id:reply-to;\n bh=IwQkiCjzOtZWKf4ivwxlsBZco2dFj2anJmf3fUxAKno=;\n b=CTjWscCpf2CaihZ8XDOU6xoeLme+nOrK5Z0VIe/hhJiWiyruOGDlSg15Qfaf1SvnmI\n Doe+gPYijVnO8UPuMG7YEJJcoXsraXWkQUbKiXmDp446rK4cFGJL3SCIZPscU6Z/csy/\n 9BFv4THgFPx5SnX2+eQt4OTcvh+A/WjH0WgI49lMUAweuS36DIOVtiY5e5gQHlnroa+r\n 1QQw7cv76JjS/CGJwUhzFhdlVObLmQkr1G8bPnZC0gqmWF52cPUXFkF4b7VHvAg3MwnB\n 3scgVDOO6Vex6Ergrw9qVdxqTUxV3kTr4ujWzx6iwt2eHQHgM6xIYmCniZP7+fGislTL\n fk/A==",
        "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=1e100.net; s=20251104; t=1776841156; x=1777445956;\n h=content-transfer-encoding:mime-version:message-id:date:subject:cc\n :to:from:x-gm-gg:x-gm-message-state:from:to:cc:subject:date\n :message-id:reply-to;\n bh=IwQkiCjzOtZWKf4ivwxlsBZco2dFj2anJmf3fUxAKno=;\n b=WZgbCu8A88Td1ntIQDdDtbbP/rI8OdbmAxrXTtR5XLqqsw5DVBnxy+l7tCD0P8Rjip\n 5YUVijsAyENt4o0YaZaz1D+ZVpRqcVI6Pl5qIDPMqa7bcqNhzw+NWSiRuxuqngmvnv8F\n OeCN1jcfywV1fx7WksIdGrVcCzmehIpFoOiiKKWU4TLE83+fIyc/SPyz7N5ZEuQKX+qz\n +A0DJ7sxhzYEozn0r3CEeAykOCsXjPBvo2b8GEqMEwSlx6gx9/zUBC456EngSUfMITxO\n b6DaGj8Q02ymcG6CXalhZrhQbZzLf63IX312LT9jU0e6vZarVT4z8J2KEu4FC8bpIHhG\n 4t3w==",
        "X-Gm-Message-State": "AOJu0Ywvfg+mWw3kXUO4vpUK6reZC+AvO93W86Fn0MDUsyyPvfRlFvsT\n 9yeM8J1eBxD/nz8YsjL6584fxpOtkzY4hk6FtSp7ViDlTKboIx7PiD/3NOnhcQP4Y8c=",
        "X-Gm-Gg": "AeBDietho/X7IpThGj9aBrhBmd8Ei27ukLCK2TXTzKAK3vMWGN0QfJmPkKBoQhjGSUN\n evXfA/GlOqh71dLFU7oRIsuuWOnbokiDr4SaSy9G27X6S49fzOF4uOQPrF3zieN/f8YcoC2uPm1\n IOhZuQhqXcM2bQOLSJm8GKlLU17G6zLmXFXA5yIgXDQqLLSNJIhO2DffaR4OFWK9NqXMfTpXaV1\n GiaEZVo7HSE2uUxBFS9Kuop3EXl16EKRaan7ekWRf6IMTMeqRSHdSlwX/Jq2V1g6lLW7jJGrQ1G\n oS+1NZP/2qSsQFhN7cSmF5ZlqMPN5Egc1V37qRSfGoHrN8n7EP57LdDrM81rbABLa2HPzchyYbi\n Yzb9jZ4+J6WYNMK/oA/FOSOA2mIiVD+vzL1LUdJ/iaT4nlP0PmDWuyeHo4K/pegZYcZQ9Eh3XRd\n Vwli7h6Hhe7fbdaEzAwdZhUuE+FoWnkDBRYpXGE6O9X1sU3MjYiocBIWY=",
        "X-Received": "by 2002:a05:6a00:3c86:b0:82d:1faf:7748 with SMTP id\n d2e1a72fcca58-82f8c8e8bc0mr23550746b3a.33.1776841155567;\n Tue, 21 Apr 2026 23:59:15 -0700 (PDT)",
        "From": "Brian Sune <briansune@gmail.com>",
        "To": "u-boot@lists.denx.de, Tom Rini <trini@konsulko.com>,\n Chee Tien Fong <tien.fong.chee@altera.com>, Simon Glass <sjg@chromium.org>",
        "Cc": "Brian Sune <briansune@gmail.com>",
        "Subject": "[PATCH v5] Improve handoff prepare on SoCFPGA",
        "Date": "Wed, 22 Apr 2026 14:59:10 +0800",
        "Message-Id": "<20260422065910.5398-1-briansune@gmail.com>",
        "X-Mailer": "git-send-email 2.34.1",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "X-BeenThere": "u-boot@lists.denx.de",
        "X-Mailman-Version": "2.1.39",
        "Precedence": "list",
        "List-Id": "U-Boot discussion <u-boot.lists.denx.de>",
        "List-Unsubscribe": "<https://lists.denx.de/options/u-boot>,\n <mailto:u-boot-request@lists.denx.de?subject=unsubscribe>",
        "List-Archive": "<https://lists.denx.de/pipermail/u-boot/>",
        "List-Post": "<mailto:u-boot@lists.denx.de>",
        "List-Help": "<mailto:u-boot-request@lists.denx.de?subject=help>",
        "List-Subscribe": "<https://lists.denx.de/listinfo/u-boot>,\n <mailto:u-boot-request@lists.denx.de?subject=subscribe>",
        "Errors-To": "u-boot-bounces@lists.denx.de",
        "Sender": "\"U-Boot\" <u-boot-bounces@lists.denx.de>",
        "X-Virus-Scanned": "clamav-milter 0.103.8 at phobos.denx.de",
        "X-Virus-Status": "Clean"
    },
    "content": "Ensure qts folder header files are properly updated by isolating\nthe Python execution environment. This prevents partial or failed\nscript runs from corrupting the target directory.\n\nChangelog v4 -> v5:\n- Change HANDOFF_KEEP condition to if [ 2501{HANDOFF_KEEP:-0} != 0 ]\n- Add HANDOFF_KEEP and HANDOFF_PATH comments in config.mk\n\nChanges:\n- Implement a temp folder for Python script execution.\n- Clean temp folder automatically despite execution failures.\n- Gate the file replacement process on the successful exit of\n  the Python scripts.\n- Execute the replacement (with or without keep) only upon script\n  success via the NEW HANDOFF_KEEP=xxx variable.\n- Rename old files to .h.handoff_backup.<timestamp> when the\n  keep option is selected.\n\nSigned-off-by: Brian Sune <briansune@gmail.com>\n---\n arch/arm/mach-socfpga/config.mk | 38 ++++++++++++++++++++++++++++++---\n 1 file changed, 35 insertions(+), 3 deletions(-)",
    "diff": "diff --git a/arch/arm/mach-socfpga/config.mk b/arch/arm/mach-socfpga/config.mk\nindex 1ca1d33cb16..e777b95b528 100644\n--- a/arch/arm/mach-socfpga/config.mk\n+++ b/arch/arm/mach-socfpga/config.mk\n@@ -1,6 +1,17 @@\n # SPDX-License-Identifier: GPL-2.0+\n #\n # Brian Sune <briansune@gmail.com>\n+#\n+# HANDOFF_PATH\n+# ------------\n+# Unset - Board path where qts locates and \"hps_isw_handoff\" should be placed.\n+# Set   - Custom path points to \"hps_isw_handoff\" folder.\n+#\n+# HANDOFF_KEEP\n+# ------------\n+# Unset - HANDOFF_KEEP= , Clean header files.\n+# Set   - HANDOFF_KEEP=0, Clean header files.\n+#         HANDOFF_KEEP=1, Backup header files and rename to \".h.handoff_backup.<timestamp>\".\n \n ifeq ($(CONFIG_ARCH_SOCFPGA_CYCLONE5),y)\n archprepare: socfpga_g5_handoff_prepare\n@@ -43,6 +54,27 @@ socfpga_g5_handoff_prepare:\n \t\t\texit 0; \\\n \t\tfi; \\\n \t\techo \"[INFO] Found hiof file: $$HIOF_FILE\"; \\\n-\t\techo \"[INFO] Running BSP generator...\"; \\\n-\t\tpython3 $(srctree)/tools/cv_bsp_generator/cv_bsp_generator.py -i \"$$HANDOFF_PATH\" -o \"$$BOARD_DIR/qts\" || echo \"[WARN] BSP generator failed, continuing...\"; \\\n-\t\techo \"[DONE] SoCFPGA QTS handoff conversion complete.\"\n+\t\techo \"[INFO] Try BSP generator...\"; \\\n+\t\tTEMP_DIR=$$(mktemp -dp \"$$BOARD_DIR/\"); \\\n+\t\ttrap 'rm -rf \"$$TEMP_DIR\"' EXIT; \\\n+\t\tif python3 $(srctree)/tools/cv_bsp_generator/cv_bsp_generator.py -i \"$$HANDOFF_PATH\" -o \"$$TEMP_DIR\"; then \\\n+\t\t\tif [ \"$${HANDOFF_KEEP:-0}\" != \"0\" ]; then \\\n+\t\t\t\techo \"[INFO] Preserving old BSP files...\"; \\\n+\t\t\t\tTIMESTAMP=$$(date +%Y%m%d_%H%M%S); \\\n+\t\t\t\tfor f in \"$$BOARD_DIR\"/qts/*.h; do \\\n+\t\t\t\t\t[ -e \"$$f\" ] || continue; \\\n+\t\t\t\t\techo \"[INFO] $$f -> $${f%.h}.h.handoff_backup.$$TIMESTAMP\"; \\\n+\t\t\t\t\tmv \"$$f\" \"$${f%.h}.h.handoff_backup.$$TIMESTAMP\"; \\\n+\t\t\t\tdone; \\\n+\t\t\telse \\\n+\t\t\t\techo \"[INFO] Clean old BSP files...\"; \\\n+\t\t\t\tif ls \"$$BOARD_DIR/qts\"/*.h >/dev/null 2>&1; then \\\n+\t\t\t\t\trm \"$$BOARD_DIR/qts\"/*.h; \\\n+\t\t\t\t\techo \"[INFO] Removed old BSP files...\"; \\\n+\t\t\t\tfi; \\\n+\t\t\tfi; \\\n+\t\t\tmv \"$$TEMP_DIR\"/*.h \"$$BOARD_DIR\"/qts; \\\n+\t\t\techo \"[INFO] SoCFPGA QTS handoff conversion complete.\"; \\\n+\t\telse \\\n+\t\t\techo \"[WARN] BSP generator failed!\"; \\\n+\t\tfi;\n",
    "prefixes": [
        "v5"
    ]
}