get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 2218437,
    "url": "http://patchwork.ozlabs.org/api/patches/2218437/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/linux-pci/patch/20260401081640.26875-8-fengchengwen@huawei.com/",
    "project": {
        "id": 28,
        "url": "http://patchwork.ozlabs.org/api/projects/28/?format=api",
        "name": "Linux PCI development",
        "link_name": "linux-pci",
        "list_id": "linux-pci.vger.kernel.org",
        "list_email": "linux-pci@vger.kernel.org",
        "web_url": null,
        "scm_url": null,
        "webscm_url": null,
        "list_archive_url": "",
        "list_archive_url_format": "",
        "commit_url_format": ""
    },
    "msgid": "<20260401081640.26875-8-fengchengwen@huawei.com>",
    "list_archive_url": null,
    "date": "2026-04-01T08:16:39",
    "name": "[RESEND,v10,7/8] ACPI: PPTT: Use acpi_get_cpu_uid() and remove get_acpi_id_for_cpu()",
    "commit_ref": null,
    "pull_url": null,
    "state": "new",
    "archived": false,
    "hash": "5fae8e8e9f82b42b68c70efd0fa28e9eb5b19cc5",
    "submitter": {
        "id": 92756,
        "url": "http://patchwork.ozlabs.org/api/people/92756/?format=api",
        "name": "fengchengwen",
        "email": "fengchengwen@huawei.com"
    },
    "delegate": null,
    "mbox": "http://patchwork.ozlabs.org/project/linux-pci/patch/20260401081640.26875-8-fengchengwen@huawei.com/mbox/",
    "series": [
        {
            "id": 498292,
            "url": "http://patchwork.ozlabs.org/api/series/498292/?format=api",
            "web_url": "http://patchwork.ozlabs.org/project/linux-pci/list/?series=498292",
            "date": "2026-04-01T08:16:32",
            "name": "ACPI: Unify CPU UID interface and fix ARM64 TPH steer-tag issue",
            "version": 10,
            "mbox": "http://patchwork.ozlabs.org/series/498292/mbox/"
        }
    ],
    "comments": "http://patchwork.ozlabs.org/api/patches/2218437/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/2218437/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "\n <linux-pci+bounces-51657-incoming=patchwork.ozlabs.org@vger.kernel.org>",
        "X-Original-To": [
            "incoming@patchwork.ozlabs.org",
            "linux-pci@vger.kernel.org"
        ],
        "Delivered-To": "patchwork-incoming@legolas.ozlabs.org",
        "Authentication-Results": [
            "legolas.ozlabs.org;\n\tdkim=pass (1024-bit key;\n unprotected) header.d=huawei.com header.i=@huawei.com header.a=rsa-sha256\n header.s=dkim header.b=ypbclQg4;\n\tdkim-atps=neutral",
            "legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=vger.kernel.org\n (client-ip=2600:3c04:e001:36c::12fc:5321; helo=tor.lore.kernel.org;\n envelope-from=linux-pci+bounces-51657-incoming=patchwork.ozlabs.org@vger.kernel.org;\n receiver=patchwork.ozlabs.org)",
            "smtp.subspace.kernel.org;\n\tdkim=pass (1024-bit key) header.d=huawei.com header.i=@huawei.com\n header.b=\"ypbclQg4\"",
            "smtp.subspace.kernel.org;\n arc=none smtp.client-ip=113.46.200.219",
            "smtp.subspace.kernel.org;\n dmarc=pass (p=quarantine dis=none) header.from=huawei.com",
            "smtp.subspace.kernel.org;\n spf=pass smtp.mailfrom=huawei.com"
        ],
        "Received": [
            "from tor.lore.kernel.org (tor.lore.kernel.org\n [IPv6:2600:3c04:e001:36c::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 legolas.ozlabs.org (Postfix) with ESMTPS id 4flyb63DjFz1xtJ\n\tfor <incoming@patchwork.ozlabs.org>; Wed, 01 Apr 2026 19:20:02 +1100 (AEDT)",
            "from smtp.subspace.kernel.org (conduit.subspace.kernel.org\n [100.90.174.1])\n\tby tor.lore.kernel.org (Postfix) with ESMTP id 4851630DCD4B\n\tfor <incoming@patchwork.ozlabs.org>; Wed,  1 Apr 2026 08:17:46 +0000 (UTC)",
            "from localhost.localdomain (localhost.localdomain [127.0.0.1])\n\tby smtp.subspace.kernel.org (Postfix) with ESMTP id 3C0733B27EA;\n\tWed,  1 Apr 2026 08:17:05 +0000 (UTC)",
            "from canpmsgout04.his.huawei.com (canpmsgout04.his.huawei.com\n [113.46.200.219])\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 E57B33AEF4C;\n\tWed,  1 Apr 2026 08:17:00 +0000 (UTC)",
            "from mail.maildlp.com (unknown [172.19.163.0])\n\tby canpmsgout04.his.huawei.com (SkyGuard) with ESMTPS id 4flyNQ3F6jz1prLN;\n\tWed,  1 Apr 2026 16:10:46 +0800 (CST)",
            "from kwepemk500009.china.huawei.com (unknown [7.202.194.94])\n\tby mail.maildlp.com (Postfix) with ESMTPS id 093EB40537;\n\tWed,  1 Apr 2026 16:16:59 +0800 (CST)",
            "from localhost.localdomain (10.50.163.32) by\n kwepemk500009.china.huawei.com (7.202.194.94) with Microsoft SMTP Server\n (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id\n 15.2.1544.11; Wed, 1 Apr 2026 16:16:57 +0800"
        ],
        "ARC-Seal": "i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116;\n\tt=1775031425; cv=none;\n b=f2kubieYGWRdbpeP0bGdiMfOUIxvOKaUSh7ZxxWz1HKmrt19pG0PbZnk+hjN4UjOApM1ysfQUYz1deT8DgZrWEChCYNAQqCpYNX2q2noh2yqXpDAwBfG/eVRM1mSeBQ+Uaah7zDAATliyh8DP2rtQME/+z1uzfSPhAeU6LrCoK0=",
        "ARC-Message-Signature": "i=1; a=rsa-sha256; d=subspace.kernel.org;\n\ts=arc-20240116; t=1775031425; c=relaxed/simple;\n\tbh=XYhm17CwRJDrJ/8Bt5up3GMk66J2ridw/7IXlx8exkk=;\n\th=From:To:CC:Subject:Date:Message-ID:In-Reply-To:References:\n\t MIME-Version:Content-Type;\n b=Yggx/AB0/1GjFpHNO2IGxOCnr6iIyJT4GiY/6/djJP9o5d7JBZwuMUXeiJHMeVeVRjrkP9TFXgtblAgtaNB4OI9CAWTY0X45Didh6AxM7bJmq5G8aOcKS5vlKKNJ8sgMfdgsoKxEM5FZy6GbjXKuZ5dIwxu8XQrgputjriLvtCE=",
        "ARC-Authentication-Results": "i=1; smtp.subspace.kernel.org;\n dmarc=pass (p=quarantine dis=none) header.from=huawei.com;\n spf=pass smtp.mailfrom=huawei.com;\n dkim=pass (1024-bit key) header.d=huawei.com header.i=@huawei.com\n header.b=ypbclQg4; arc=none smtp.client-ip=113.46.200.219",
        "dkim-signature": "v=1; a=rsa-sha256; d=huawei.com; s=dkim;\n\tc=relaxed/relaxed; q=dns/txt;\n\th=From;\n\tbh=/eBsZSTPYF/YtxnkPhtkEULxH4VEHo0dKDplLzt2h+U=;\n\tb=ypbclQg4Iukdlkqpoizb0I/F7L+DePAd+M0//lXkMgfo2Tebtl3dWlIRb5T+BpmkoHuv3dAUf\n\tq4obfVRqfYA+w4THr01Bmp7st54V9VWVLRFBbSiDcMjxC61DIiVgmZCmNOX7nmSXAg0dF57r5Ul\n\tC2JQqU6Aei7BxV0EFNUv0ls=",
        "From": "Chengwen Feng <fengchengwen@huawei.com>",
        "To": "Bjorn Helgaas <bhelgaas@google.com>, Catalin Marinas\n\t<catalin.marinas@arm.com>, Will Deacon <will@kernel.org>, \"Rafael J .\n Wysocki\" <rafael@kernel.org>",
        "CC": "Jonathan Corbet <corbet@lwn.net>, WANG Xuerui <kernel@xen0n.name>, Thomas\n Gleixner <tglx@kernel.org>, Dave Hansen <dave.hansen@linux.intel.com>, \"H .\n Peter Anvin\" <hpa@zytor.com>, Juergen Gross <jgross@suse.com>, Boris\n Ostrovsky <boris.ostrovsky@oracle.com>, Len Brown <lenb@kernel.org>, Sunil V\n L <sunilvl@ventanamicro.com>, Mark Rutland <mark.rutland@arm.com>, Jonathan\n Cameron <jonathan.cameron@huawei.com>, Kees Cook <kees@kernel.org>, Yanteng\n Si <si.yanteng@linux.dev>, Sean Christopherson <seanjc@google.com>, Kai Huang\n\t<kai.huang@intel.com>, Tom Lendacky <thomas.lendacky@amd.com>, Thomas Huth\n\t<thuth@redhat.com>, Thorsten Blum <thorsten.blum@linux.dev>, Kevin Loughlin\n\t<kevinloughlin@google.com>, Zheyun Shen <szy0127@sjtu.edu.cn>, Peter Zijlstra\n\t<peterz@infradead.org>, Pawan Gupta <pawan.kumar.gupta@linux.intel.com>, Xin\n Li <xin@zytor.com>, \"Ahmed S . Darwish\" <darwi@linutronix.de>, Sohil Mehta\n\t<sohil.mehta@intel.com>, Ilkka Koskinen <ilkka@os.amperecomputing.com>, Robin\n Murphy <robin.murphy@arm.com>, James Clark <james.clark@linaro.org>, Besar\n Wicaksono <bwicaksono@nvidia.com>, Ma Ke <make24@iscas.ac.cn>, Wei Huang\n\t<wei.huang2@amd.com>, Andy Gospodarek <andrew.gospodarek@broadcom.com>,\n\tSomnath Kotur <somnath.kotur@broadcom.com>, <punit.agrawal@oss.qualcomm.com>,\n\t<guohanjun@huawei.com>, <suzuki.poulose@arm.com>, <ryan.roberts@arm.com>,\n\t<chenl311@chinatelecom.cn>, <masahiroy@kernel.org>,\n\t<wangyuquan1236@phytium.com.cn>, <anshuman.khandual@arm.com>,\n\t<heinrich.schuchardt@canonical.com>, <Eric.VanTassell@amd.com>,\n\t<wangzhou1@hisilicon.com>, <wanghuiqiang@huawei.com>,\n\t<liuyonglong@huawei.com>, <fengchengwen@huawei.com>,\n\t<linux-pci@vger.kernel.org>, <linux-doc@vger.kernel.org>,\n\t<linux-kernel@vger.kernel.org>, <linux-arm-kernel@lists.infradead.org>,\n\t<loongarch@lists.linux.dev>, <linux-riscv@lists.infradead.org>,\n\t<xen-devel@lists.xenproject.org>, <linux-acpi@vger.kernel.org>,\n\t<linux-perf-users@vger.kernel.org>, <stable@vger.kernel.org>,\n\t<x86@kernel.org>",
        "Subject": "[PATCH RESEND v10 7/8] ACPI: PPTT: Use acpi_get_cpu_uid() and remove\n get_acpi_id_for_cpu()",
        "Date": "Wed, 1 Apr 2026 16:16:39 +0800",
        "Message-ID": "<20260401081640.26875-8-fengchengwen@huawei.com>",
        "X-Mailer": "git-send-email 2.17.1",
        "In-Reply-To": "<20260401081640.26875-1-fengchengwen@huawei.com>",
        "References": "<20260401081640.26875-1-fengchengwen@huawei.com>",
        "Precedence": "bulk",
        "X-Mailing-List": "linux-pci@vger.kernel.org",
        "List-Id": "<linux-pci.vger.kernel.org>",
        "List-Subscribe": "<mailto:linux-pci+subscribe@vger.kernel.org>",
        "List-Unsubscribe": "<mailto:linux-pci+unsubscribe@vger.kernel.org>",
        "MIME-Version": "1.0",
        "Content-Type": "text/plain",
        "X-ClientProxiedBy": "kwepems200001.china.huawei.com (7.221.188.67) To\n kwepemk500009.china.huawei.com (7.202.194.94)"
    },
    "content": "Update acpi/pptt.c to use acpi_get_cpu_uid() and remove unused\nget_acpi_id_for_cpu() from arm64/loongarch/riscv, completing PPTT's\nmigration to the unified ACPI CPU UID interface\n\nCc: stable@vger.kernel.org\nSigned-off-by: Chengwen Feng <fengchengwen@huawei.com>\nReviewed-by: Jonathan Cameron <jonathan.cameron@huawei.com>\n---\n arch/arm64/include/asm/acpi.h     |  4 ---\n arch/loongarch/include/asm/acpi.h |  5 ----\n arch/riscv/include/asm/acpi.h     |  4 ---\n drivers/acpi/pptt.c               | 50 +++++++++++++++++++++++--------\n 4 files changed, 37 insertions(+), 26 deletions(-)",
    "diff": "diff --git a/arch/arm64/include/asm/acpi.h b/arch/arm64/include/asm/acpi.h\nindex bdb0ecf95b5c..8a54ca6ba602 100644\n--- a/arch/arm64/include/asm/acpi.h\n+++ b/arch/arm64/include/asm/acpi.h\n@@ -114,10 +114,6 @@ static inline bool acpi_has_cpu_in_madt(void)\n }\n \n struct acpi_madt_generic_interrupt *acpi_cpu_get_madt_gicc(int cpu);\n-static inline u32 get_acpi_id_for_cpu(unsigned int cpu)\n-{\n-\treturn\tacpi_cpu_get_madt_gicc(cpu)->uid;\n-}\n int get_cpu_for_acpi_id(u32 uid);\n \n static inline void arch_fix_phys_package_id(int num, u32 slot) { }\ndiff --git a/arch/loongarch/include/asm/acpi.h b/arch/loongarch/include/asm/acpi.h\nindex 7376840fa9f7..eda9d4d0a493 100644\n--- a/arch/loongarch/include/asm/acpi.h\n+++ b/arch/loongarch/include/asm/acpi.h\n@@ -40,11 +40,6 @@ extern struct acpi_madt_core_pic acpi_core_pic[MAX_CORE_PIC];\n \n extern int __init parse_acpi_topology(void);\n \n-static inline u32 get_acpi_id_for_cpu(unsigned int cpu)\n-{\n-\treturn acpi_core_pic[cpu_logical_map(cpu)].processor_id;\n-}\n-\n #endif /* !CONFIG_ACPI */\n \n #define ACPI_TABLE_UPGRADE_MAX_PHYS ARCH_LOW_ADDRESS_LIMIT\ndiff --git a/arch/riscv/include/asm/acpi.h b/arch/riscv/include/asm/acpi.h\nindex 6e13695120bc..26ab37c171bc 100644\n--- a/arch/riscv/include/asm/acpi.h\n+++ b/arch/riscv/include/asm/acpi.h\n@@ -61,10 +61,6 @@ static inline void arch_fix_phys_package_id(int num, u32 slot) { }\n \n void acpi_init_rintc_map(void);\n struct acpi_madt_rintc *acpi_cpu_get_madt_rintc(int cpu);\n-static inline u32 get_acpi_id_for_cpu(int cpu)\n-{\n-\treturn acpi_cpu_get_madt_rintc(cpu)->uid;\n-}\n \n int acpi_get_riscv_isa(struct acpi_table_header *table,\n \t\t       unsigned int cpu, const char **isa);\ndiff --git a/drivers/acpi/pptt.c b/drivers/acpi/pptt.c\nindex de5f8c018333..7bd5bc1f225a 100644\n--- a/drivers/acpi/pptt.c\n+++ b/drivers/acpi/pptt.c\n@@ -459,11 +459,14 @@ static void cache_setup_acpi_cpu(struct acpi_table_header *table,\n {\n \tstruct acpi_pptt_cache *found_cache;\n \tstruct cpu_cacheinfo *this_cpu_ci = get_cpu_cacheinfo(cpu);\n-\tu32 acpi_cpu_id = get_acpi_id_for_cpu(cpu);\n+\tu32 acpi_cpu_id;\n \tstruct cacheinfo *this_leaf;\n \tunsigned int index = 0;\n \tstruct acpi_pptt_processor *cpu_node = NULL;\n \n+\tif (acpi_get_cpu_uid(cpu, &acpi_cpu_id) != 0)\n+\t\treturn;\n+\n \twhile (index < get_cpu_cacheinfo(cpu)->num_leaves) {\n \t\tthis_leaf = this_cpu_ci->info_list + index;\n \t\tfound_cache = acpi_find_cache_node(table, acpi_cpu_id,\n@@ -546,7 +549,10 @@ static int topology_get_acpi_cpu_tag(struct acpi_table_header *table,\n \t\t\t\t     unsigned int cpu, int level, int flag)\n {\n \tstruct acpi_pptt_processor *cpu_node;\n-\tu32 acpi_cpu_id = get_acpi_id_for_cpu(cpu);\n+\tu32 acpi_cpu_id;\n+\n+\tif (acpi_get_cpu_uid(cpu, &acpi_cpu_id) != 0)\n+\t\treturn -ENOENT;\n \n \tcpu_node = acpi_find_processor_node(table, acpi_cpu_id);\n \tif (cpu_node) {\n@@ -614,18 +620,22 @@ static int find_acpi_cpu_topology_tag(unsigned int cpu, int level, int flag)\n  *\n  * Check the node representing a CPU for a given flag.\n  *\n- * Return: -ENOENT if the PPTT doesn't exist, the CPU cannot be found or\n- *\t   the table revision isn't new enough.\n+ * Return: -ENOENT if can't get CPU's ACPI Processor UID, the PPTT doesn't\n+ *\t   exist, the CPU cannot be found or the table revision isn't new\n+ *\t   enough.\n  *\t   1, any passed flag set\n  *\t   0, flag unset\n  */\n static int check_acpi_cpu_flag(unsigned int cpu, int rev, u32 flag)\n {\n \tstruct acpi_table_header *table;\n-\tu32 acpi_cpu_id = get_acpi_id_for_cpu(cpu);\n+\tu32 acpi_cpu_id;\n \tstruct acpi_pptt_processor *cpu_node = NULL;\n \tint ret = -ENOENT;\n \n+\tif (acpi_get_cpu_uid(cpu, &acpi_cpu_id) != 0)\n+\t\treturn -ENOENT;\n+\n \ttable = acpi_get_pptt();\n \tif (!table)\n \t\treturn -ENOENT;\n@@ -651,7 +661,8 @@ static int check_acpi_cpu_flag(unsigned int cpu, int rev, u32 flag)\n  * in the PPTT. Errors caused by lack of a PPTT table, or otherwise, return 0\n  * indicating we didn't find any cache levels.\n  *\n- * Return: -ENOENT if no PPTT table or no PPTT processor struct found.\n+ * Return: -ENOENT if no PPTT table, can't get CPU's ACPI Process UID or no PPTT\n+ *\t   processor struct found.\n  *\t   0 on success.\n  */\n int acpi_get_cache_info(unsigned int cpu, unsigned int *levels,\n@@ -671,7 +682,9 @@ int acpi_get_cache_info(unsigned int cpu, unsigned int *levels,\n \n \tpr_debug(\"Cache Setup: find cache levels for CPU=%d\\n\", cpu);\n \n-\tacpi_cpu_id = get_acpi_id_for_cpu(cpu);\n+\tif (acpi_get_cpu_uid(cpu, &acpi_cpu_id))\n+\t\treturn -ENOENT;\n+\n \tcpu_node = acpi_find_processor_node(table, acpi_cpu_id);\n \tif (!cpu_node)\n \t\treturn -ENOENT;\n@@ -780,8 +793,9 @@ int find_acpi_cpu_topology_package(unsigned int cpu)\n  * It may not exist in single CPU systems. In simple multi-CPU systems,\n  * it may be equal to the package topology level.\n  *\n- * Return: -ENOENT if the PPTT doesn't exist, the CPU cannot be found\n- * or there is no toplogy level above the CPU..\n+ * Return: -ENOENT if the PPTT doesn't exist, can't get CPU's ACPI\n+ * Processor UID, the CPU cannot be found or there is no toplogy level\n+ * above the CPU.\n  * Otherwise returns a value which represents the package for this CPU.\n  */\n \n@@ -797,7 +811,9 @@ int find_acpi_cpu_topology_cluster(unsigned int cpu)\n \tif (!table)\n \t\treturn -ENOENT;\n \n-\tacpi_cpu_id = get_acpi_id_for_cpu(cpu);\n+\tif (acpi_get_cpu_uid(cpu, &acpi_cpu_id) != 0)\n+\t\treturn -ENOENT;\n+\n \tcpu_node = acpi_find_processor_node(table, acpi_cpu_id);\n \tif (!cpu_node || !cpu_node->parent)\n \t\treturn -ENOENT;\n@@ -872,7 +888,9 @@ static void acpi_pptt_get_child_cpus(struct acpi_table_header *table_hdr,\n \tcpumask_clear(cpus);\n \n \tfor_each_possible_cpu(cpu) {\n-\t\tacpi_id = get_acpi_id_for_cpu(cpu);\n+\t\tif (acpi_get_cpu_uid(cpu, &acpi_id) != 0)\n+\t\t\tcontinue;\n+\n \t\tcpu_node = acpi_find_processor_node(table_hdr, acpi_id);\n \n \t\twhile (cpu_node) {\n@@ -966,10 +984,13 @@ int find_acpi_cache_level_from_id(u32 cache_id)\n \tfor_each_possible_cpu(cpu) {\n \t\tbool empty;\n \t\tint level = 1;\n-\t\tu32 acpi_cpu_id = get_acpi_id_for_cpu(cpu);\n+\t\tu32 acpi_cpu_id;\n \t\tstruct acpi_pptt_cache *cache;\n \t\tstruct acpi_pptt_processor *cpu_node;\n \n+\t\tif (acpi_get_cpu_uid(cpu, &acpi_cpu_id) != 0)\n+\t\t\tcontinue;\n+\n \t\tcpu_node = acpi_find_processor_node(table, acpi_cpu_id);\n \t\tif (!cpu_node)\n \t\t\tcontinue;\n@@ -1030,10 +1051,13 @@ int acpi_pptt_get_cpumask_from_cache_id(u32 cache_id, cpumask_t *cpus)\n \tfor_each_possible_cpu(cpu) {\n \t\tbool empty;\n \t\tint level = 1;\n-\t\tu32 acpi_cpu_id = get_acpi_id_for_cpu(cpu);\n+\t\tu32 acpi_cpu_id;\n \t\tstruct acpi_pptt_cache *cache;\n \t\tstruct acpi_pptt_processor *cpu_node;\n \n+\t\tif (acpi_get_cpu_uid(cpu, &acpi_cpu_id) != 0)\n+\t\t\tcontinue;\n+\n \t\tcpu_node = acpi_find_processor_node(table, acpi_cpu_id);\n \t\tif (!cpu_node)\n \t\t\tcontinue;\n",
    "prefixes": [
        "RESEND",
        "v10",
        "7/8"
    ]
}