Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/1.0/patches/2175745/?format=api
{ "id": 2175745, "url": "http://patchwork.ozlabs.org/api/1.0/patches/2175745/?format=api", "project": { "id": 28, "url": "http://patchwork.ozlabs.org/api/1.0/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 }, "msgid": "<9564052.CDJkKcVGEf@rafael.j.wysocki>", "date": "2025-12-18T20:41:42", "name": "[v1,7/8] ACPI: bus: Adjust feature mask creation for \\_SB._OSC", "commit_ref": null, "pull_url": null, "state": "new", "archived": false, "hash": "e3a9d1a9238c8b01b41c1007f8f15626f440db8e", "submitter": { "id": 64267, "url": "http://patchwork.ozlabs.org/api/1.0/people/64267/?format=api", "name": "Rafael J. Wysocki", "email": "rafael@kernel.org" }, "delegate": null, "mbox": "http://patchwork.ozlabs.org/project/linux-pci/patch/9564052.CDJkKcVGEf@rafael.j.wysocki/mbox/", "series": [ { "id": 485914, "url": "http://patchwork.ozlabs.org/api/1.0/series/485914/?format=api", "date": "2025-12-18T20:37:36", "name": "ACPI: bus: Rework of the \\_SB._OSC handling", "version": 1, "mbox": "http://patchwork.ozlabs.org/series/485914/mbox/" } ], "check": "pending", "checks": "http://patchwork.ozlabs.org/api/patches/2175745/checks/", "tags": {}, "headers": { "Return-Path": "\n <linux-pci+bounces-43328-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 (2048-bit key;\n unprotected) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256\n header.s=k20201202 header.b=P9nb3+U2;\n\tdkim-atps=neutral", "legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=vger.kernel.org\n (client-ip=172.105.105.114; helo=tor.lore.kernel.org;\n envelope-from=linux-pci+bounces-43328-incoming=patchwork.ozlabs.org@vger.kernel.org;\n receiver=patchwork.ozlabs.org)", "smtp.subspace.kernel.org;\n\tdkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org\n header.b=\"P9nb3+U2\"", "smtp.subspace.kernel.org;\n arc=none smtp.client-ip=10.30.226.201" ], "Received": [ "from tor.lore.kernel.org (tor.lore.kernel.org [172.105.105.114])\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 4dXNF219q4z1xty\n\tfor <incoming@patchwork.ozlabs.org>; Fri, 19 Dec 2025 07:53:58 +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 2EBFC3043069\n\tfor <incoming@patchwork.ozlabs.org>; Thu, 18 Dec 2025 20:52:52 +0000 (UTC)", "from localhost.localdomain (localhost.localdomain [127.0.0.1])\n\tby smtp.subspace.kernel.org (Postfix) with ESMTP id 079E63446B6;\n\tThu, 18 Dec 2025 20:43:14 +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 D1F5C3446A7;\n\tThu, 18 Dec 2025 20:43:13 +0000 (UTC)", "by smtp.kernel.org (Postfix) with ESMTPSA id 84BABC4CEFB;\n\tThu, 18 Dec 2025 20:43:12 +0000 (UTC)" ], "ARC-Seal": "i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116;\n\tt=1766090593; cv=none;\n b=cQafOY7PE3o0gNi3ecxbQboXEgigNFA+iPhiB6g9VOkV1xQYzCfQr8vO7t0ruivJfay+oyZGvW3r4zYXLn16HOQXKK8AQAx2nSHNsCLfGjccXEWagJgrIUuvp2tQMVHbsCQuhJyFoJ8ois3PZFAFGNyxZrzqXVvV5FPI/h6YULA=", "ARC-Message-Signature": "i=1; a=rsa-sha256; d=subspace.kernel.org;\n\ts=arc-20240116; t=1766090593; c=relaxed/simple;\n\tbh=Lcf7BVQg7WTokVLfksIKdaxed9Ric8tew5QW57OhuX4=;\n\th=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References:\n\t MIME-Version:Content-Type;\n b=h1zpv+N3SnyzrCEIXHGlzNsLgpsDS/Rh7gbbjGNUOqCm9083/jvdaROZdNcXHfPOR3I21t0ITR9HQMeQsTG/Bxy8mUmyHazcEfMzXqLQc1ZcyKkg+iQ5qZ3mgj/AfLzRjwvGWgQDWFSwgmlq7hlSK4t8KbeH7Yths+nldqlr19c=", "ARC-Authentication-Results": "i=1; smtp.subspace.kernel.org;\n dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org\n header.b=P9nb3+U2; 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=1766090593;\n\tbh=Lcf7BVQg7WTokVLfksIKdaxed9Ric8tew5QW57OhuX4=;\n\th=From:To:Cc:Subject:Date:In-Reply-To:References:From;\n\tb=P9nb3+U2ZfEKaDhK6oBjs3pFCHcxjdF5OM/S3Z9AIT4o7l52zUOlc34Gtw/T0BFkL\n\t YSrRsl+TZgf64GBYryltrd6ODcPOCQKi3Hdt8LPbiRhrvkedmlEvZCuyOlFeqQfQHj\n\t HLzVOnYpr1uMokHQFi8Zp/zgvvf6E7wRMPXr8Ifem4hQrPz30zE5nDmXk0pEhS3LWV\n\t vq0XWzc+PZdeMlHuxev31tePwi8fk/Z6GcnzYaf007U8mBcCfhNE1XQT8frRdtBO1M\n\t MyQ3K4PiUumRAS6pvKGSMHeCppDzutBPAuFCoCLSOjZjMYRD8B/s65rLJeLFPEmoSr\n\t sU+4HD/ly/8mQ==", "From": "\"Rafael J. Wysocki\" <rafael@kernel.org>", "To": "Linux ACPI <linux-acpi@vger.kernel.org>", "Cc": "LKML <linux-kernel@vger.kernel.org>,\n Linux PCI <linux-pci@vger.kernel.org>, Bjorn Helgaas <helgaas@kernel.org>,\n Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>,\n Hans de Goede <hansg@kernel.org>,\n Mario Limonciello <mario.limonciello@amd.com>", "Subject": "[PATCH v1 7/8] ACPI: bus: Adjust feature mask creation for \\_SB._OSC", "Date": "Thu, 18 Dec 2025 21:41:42 +0100", "Message-ID": "<9564052.CDJkKcVGEf@rafael.j.wysocki>", "Organization": "Linux Kernel Development", "In-Reply-To": "<5049211.GXAFRqVoOG@rafael.j.wysocki>", "References": "<5049211.GXAFRqVoOG@rafael.j.wysocki>", "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-Transfer-Encoding": "7Bit", "Content-Type": "text/plain; charset=\"UTF-8\"" }, "content": "From: Rafael J. Wysocki <rafael.j.wysocki@intel.com>\n\nThe feature mask creation for \\_SB._OSC platform features is messy\nand hard to follow, so clean it up and make all of the CPPC-related\nfeatures depend on CONFIG_ACPI_CPPC_LIB as they will not work if it\nis not set anyway.\n\nAlso make acpi_bus_osc_negotiate_platform_control() print a message\nincluding a bit mask representing the features for which control has\nbeen granted.\n\nSigned-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>\n---\n drivers/acpi/bus.c | 83 ++++++++++++++++++++++++-----------------------------\n 1 file changed, 39 insertions(+), 44 deletions(-)", "diff": "--- a/drivers/acpi/bus.c\n+++ b/drivers/acpi/bus.c\n@@ -418,73 +418,68 @@ bool osc_sb_cppc2_support_acked;\n static void acpi_bus_osc_negotiate_platform_control(void)\n {\n \tstatic const u8 sb_uuid_str[] = \"0811B06E-4A27-44F9-8D60-3CBBC22E7B48\";\n-\tu32 capbuf[2];\n+\tu32 capbuf[2], feature_mask;\n \tstruct acpi_buffer cap = {\n \t\t.pointer = capbuf,\n \t\t.length = sizeof(capbuf),\n \t};\n \tacpi_handle handle;\n \n-\tcapbuf[OSC_SUPPORT_DWORD] = OSC_SB_PR3_SUPPORT; /* _PR3 is in use */\n+\tfeature_mask = OSC_SB_PR3_SUPPORT | OSC_SB_HOTPLUG_OST_SUPPORT |\n+\t\t\tOSC_SB_PCLPI_SUPPORT | OSC_SB_OVER_16_PSTATES_SUPPORT |\n+\t\t\tOSC_SB_GED_SUPPORT | OSC_SB_IRQ_RESOURCE_SOURCE_SUPPORT;\n+\n+\tif (IS_ENABLED(CONFIG_ARM64) || IS_ENABLED(CONFIG_X86))\n+\t\tfeature_mask |= OSC_SB_GENERIC_INITIATOR_SUPPORT;\n+\n+\tif (IS_ENABLED(CONFIG_ACPI_CPPC_LIB)) {\n+\t\tfeature_mask |= OSC_SB_CPC_SUPPORT | OSC_SB_CPCV2_SUPPORT |\n+\t\t\t\tOSC_SB_CPC_FLEXIBLE_ADR_SPACE;\n+\t\tif (IS_ENABLED(CONFIG_SCHED_MC_PRIO))\n+\t\t\tfeature_mask |= OSC_SB_CPC_DIVERSE_HIGH_SUPPORT;\n+\t}\n+\n \tif (IS_ENABLED(CONFIG_ACPI_PROCESSOR_AGGREGATOR))\n-\t\tcapbuf[OSC_SUPPORT_DWORD] |= OSC_SB_PAD_SUPPORT;\n+\t\tfeature_mask |= OSC_SB_PAD_SUPPORT;\n+\n \tif (IS_ENABLED(CONFIG_ACPI_PROCESSOR))\n-\t\tcapbuf[OSC_SUPPORT_DWORD] |= OSC_SB_PPC_OST_SUPPORT;\n+\t\tfeature_mask |= OSC_SB_PPC_OST_SUPPORT;\n+\n \tif (IS_ENABLED(CONFIG_ACPI_THERMAL))\n-\t\tcapbuf[OSC_SUPPORT_DWORD] |= OSC_SB_FAST_THERMAL_SAMPLING_SUPPORT;\n+\t\tfeature_mask |= OSC_SB_FAST_THERMAL_SAMPLING_SUPPORT;\n+\n \tif (IS_ENABLED(CONFIG_ACPI_BATTERY))\n-\t\tcapbuf[OSC_SUPPORT_DWORD] |= OSC_SB_BATTERY_CHARGE_LIMITING_SUPPORT;\n+\t\tfeature_mask |= OSC_SB_BATTERY_CHARGE_LIMITING_SUPPORT;\n \n-\tcapbuf[OSC_SUPPORT_DWORD] |= OSC_SB_HOTPLUG_OST_SUPPORT;\n-\tcapbuf[OSC_SUPPORT_DWORD] |= OSC_SB_PCLPI_SUPPORT;\n-\tcapbuf[OSC_SUPPORT_DWORD] |= OSC_SB_OVER_16_PSTATES_SUPPORT;\n-\tcapbuf[OSC_SUPPORT_DWORD] |= OSC_SB_GED_SUPPORT;\n-\tcapbuf[OSC_SUPPORT_DWORD] |= OSC_SB_IRQ_RESOURCE_SOURCE_SUPPORT;\n \tif (IS_ENABLED(CONFIG_ACPI_PRMT))\n-\t\tcapbuf[OSC_SUPPORT_DWORD] |= OSC_SB_PRM_SUPPORT;\n-\tif (IS_ENABLED(CONFIG_ACPI_FFH))\n-\t\tcapbuf[OSC_SUPPORT_DWORD] |= OSC_SB_FFH_OPR_SUPPORT;\n-\n-#ifdef CONFIG_ARM64\n-\tcapbuf[OSC_SUPPORT_DWORD] |= OSC_SB_GENERIC_INITIATOR_SUPPORT;\n-#endif\n-#ifdef CONFIG_X86\n-\tcapbuf[OSC_SUPPORT_DWORD] |= OSC_SB_GENERIC_INITIATOR_SUPPORT;\n-#endif\n-\n-#ifdef CONFIG_ACPI_CPPC_LIB\n-\tcapbuf[OSC_SUPPORT_DWORD] |= OSC_SB_CPC_SUPPORT;\n-\tcapbuf[OSC_SUPPORT_DWORD] |= OSC_SB_CPCV2_SUPPORT;\n-#endif\n+\t\tfeature_mask |= OSC_SB_PRM_SUPPORT;\n \n-\tcapbuf[OSC_SUPPORT_DWORD] |= OSC_SB_CPC_FLEXIBLE_ADR_SPACE;\n-\n-\tif (IS_ENABLED(CONFIG_SCHED_MC_PRIO))\n-\t\tcapbuf[OSC_SUPPORT_DWORD] |= OSC_SB_CPC_DIVERSE_HIGH_SUPPORT;\n+\tif (IS_ENABLED(CONFIG_ACPI_FFH))\n+\t\tfeature_mask |= OSC_SB_FFH_OPR_SUPPORT;\n \n \tif (IS_ENABLED(CONFIG_USB4))\n-\t\tcapbuf[OSC_SUPPORT_DWORD] |= OSC_SB_NATIVE_USB4_SUPPORT;\n+\t\tfeature_mask |= OSC_SB_NATIVE_USB4_SUPPORT;\n \n \tif (!ghes_disable)\n-\t\tcapbuf[OSC_SUPPORT_DWORD] |= OSC_SB_APEI_SUPPORT;\n+\t\tfeature_mask |= OSC_SB_APEI_SUPPORT;\n+\n \tif (ACPI_FAILURE(acpi_get_handle(NULL, \"\\\\_SB\", &handle)))\n \t\treturn;\n \n+\tcapbuf[OSC_SUPPORT_DWORD] = feature_mask;\n+\n \tif (acpi_osc_handshake(handle, sb_uuid_str, 1, &cap))\n \t\treturn;\n \n-#ifdef CONFIG_ACPI_CPPC_LIB\n-\tosc_sb_cppc2_support_acked = capbuf[OSC_SUPPORT_DWORD] & OSC_SB_CPCV2_SUPPORT;\n-#endif\n-\n-\tosc_sb_apei_support_acked =\n-\t\t\tcapbuf[OSC_SUPPORT_DWORD] & OSC_SB_APEI_SUPPORT;\n-\tosc_pc_lpi_support_confirmed =\n-\t\t\tcapbuf[OSC_SUPPORT_DWORD] & OSC_SB_PCLPI_SUPPORT;\n-\tosc_sb_native_usb4_support_confirmed =\n-\t\t\tcapbuf[OSC_SUPPORT_DWORD] & OSC_SB_NATIVE_USB4_SUPPORT;\n-\tosc_cpc_flexible_adr_space_confirmed =\n-\t\t\tcapbuf[OSC_SUPPORT_DWORD] & OSC_SB_CPC_FLEXIBLE_ADR_SPACE;\n+\tfeature_mask = capbuf[OSC_SUPPORT_DWORD];\n+\n+\tacpi_handle_info(handle, \"platform _OSC feature mask [%08x]\\n\", feature_mask);\n+\n+\tosc_sb_cppc2_support_acked = feature_mask & OSC_SB_CPCV2_SUPPORT;\n+\tosc_sb_apei_support_acked = feature_mask & OSC_SB_APEI_SUPPORT;\n+\tosc_pc_lpi_support_confirmed = feature_mask & OSC_SB_PCLPI_SUPPORT;\n+\tosc_sb_native_usb4_support_confirmed = feature_mask & OSC_SB_NATIVE_USB4_SUPPORT;\n+\tosc_cpc_flexible_adr_space_confirmed = feature_mask & OSC_SB_CPC_FLEXIBLE_ADR_SPACE;\n }\n \n /*\n", "prefixes": [ "v1", "7/8" ] }