From nobody Wed Oct 8 19:57:27 2025 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) client-ip=192.237.175.120; envelope-from=xen-devel-bounces@lists.xenproject.org; helo=lists.xenproject.org; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=pass(p=quarantine dis=none) header.from=ti.com ARC-Seal: i=1; a=rsa-sha256; t=1750790621; cv=none; d=zohomail.com; s=zohoarc; b=NdP7Yu5CohVluAJ6kdfS/eI5MwkRcVP41tL/rkou1j9PPrJ7XvpPV2p7XO24c80hNESKEyE6Xave8mxTV44C5pxQphYQmxxu26vpBgfLY4c7TTY7tHej4UfokEbZr7BeN027T1kI6NJztjt73X/SWMbi4LaRgecm3NAhY55AEqQ= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1750790621; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:List-Subscribe:List-Post:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=d7RyoS9Xq2SqZl1k6ym5o4fjIiCYNNVYuTiU+w0N+C0=; b=mSyhEXEMIyiiBe0iYdSUNGvnJTv0O2Q4PLOuVFhlFkreJkvy5gKnf3MTK8hJ00eSkLjapxRcaXOCPathqITSdyrVjly/ms+7FmRiRC4Vt5+eEJNa2YrC8voe2gpfQMaN+En9vkdCMx9jEMg8YQ/EM3YsKem+Phph1F+DmifkRWE= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=pass header.from= (p=quarantine dis=none) Return-Path: Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) by mx.zohomail.com with SMTPS id 1750790621493837.0100715176152; Tue, 24 Jun 2025 11:43:41 -0700 (PDT) Received: from list by lists.xenproject.org with outflank-mailman.1024032.1400088 (Exim 4.92) (envelope-from ) id 1uU8c4-0002GR-0o; Tue, 24 Jun 2025 18:43:20 +0000 Received: by outflank-mailman (output) from mailman id 1024032.1400088; Tue, 24 Jun 2025 18:43:19 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1uU8c3-0002GK-U8; Tue, 24 Jun 2025 18:43:19 +0000 Received: by outflank-mailman (input) for mailman id 1024032; Tue, 24 Jun 2025 18:43:18 +0000 Received: from se1-gles-flk1-in.inumbo.com ([94.247.172.50] helo=se1-gles-flk1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1uU8c2-0002Fs-MI for xen-devel@lists.xenproject.org; Tue, 24 Jun 2025 18:43:18 +0000 Received: from lelvem-ot01.ext.ti.com (lelvem-ot01.ext.ti.com [198.47.23.234]) by se1-gles-flk1.inumbo.com (Halon) with ESMTPS id 14f5406f-512b-11f0-b894-0df219b8e170; Tue, 24 Jun 2025 20:43:14 +0200 (CEST) Received: from lelvem-sh01.itg.ti.com ([10.180.77.71]) by lelvem-ot01.ext.ti.com (8.15.2/8.15.2) with ESMTP id 55OIglKf1238390; Tue, 24 Jun 2025 13:42:47 -0500 Received: from DLEE114.ent.ti.com (dlee114.ent.ti.com [157.170.170.25]) by lelvem-sh01.itg.ti.com (8.18.1/8.18.1) with ESMTPS id 55OIgluT1799620 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA256 bits=128 verify=FAIL); Tue, 24 Jun 2025 13:42:47 -0500 Received: from DLEE104.ent.ti.com (157.170.170.34) by DLEE114.ent.ti.com (157.170.170.25) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.55; Tue, 24 Jun 2025 13:42:47 -0500 Received: from lelvem-mr06.itg.ti.com (10.180.75.8) by DLEE104.ent.ti.com (157.170.170.34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.55 via Frontend Transport; Tue, 24 Jun 2025 13:42:46 -0500 Received: from lelvem-mr05.itg.ti.com ([10.249.42.149]) by lelvem-mr06.itg.ti.com (8.18.1/8.18.1) with ESMTP id 55OIgkxh1989825; Tue, 24 Jun 2025 13:42:46 -0500 X-Outflank-Mailman: Message body and most headers restored to incoming version X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 14f5406f-512b-11f0-b894-0df219b8e170 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1750790567; bh=d7RyoS9Xq2SqZl1k6ym5o4fjIiCYNNVYuTiU+w0N+C0=; h=From:To:CC:Subject:Date; b=nAAHio8ZNDbgN+CYEXlSX8ptbbLOIUV6HwBmawy1Tb5LqOjTZyTThqn9KBwzs0vJw 5Xit6sT2Nz66hLxFPPfb+0zrNEE5Pwz9STdGo0+4IXBT+JxmV2UAcMsLP6d6/nR5F2 7hCnBVlC1srj0C2ojrFRhd6buTHEga2/CVW9o7D4= From: Andrew Davis To: Arnd Bergmann , Andre Przywara , Russell King , Daniel Mack , Haojian Zhuang , Robert Jarzmik , Alexey Charkov , Krzysztof Kozlowski , Stefano Stabellini CC: , , , , Andrew Davis Subject: [PATCH v6] ARM: Switch to new sys-off handler API Date: Tue, 24 Jun 2025 13:42:45 -0500 Message-ID: <20250624184245.343657-1-afd@ti.com> X-Mailer: git-send-email 2.39.2 MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-C2ProcessedOrg: 333ef613-75bf-4e12-a4b1-8e3623f5dcea X-ZohoMail-DKIM: pass (identity @ti.com) X-ZM-MESSAGEID: 1750790622967116600 Content-Type: text/plain; charset="utf-8" Kernel now supports chained power-off handlers. Use register_platform_power_off() that registers a platform level power-off handler. Legacy pm_power_off() will be removed once all drivers and archs are converted to the new sys-off API. Signed-off-by: Andrew Davis Reviewed-by: Andre Przywara Acked-by: Alexey Charkov --- Changes for v6: - Rebased on v6.16-rc3 - Squashed series and sent to soc@lists.linux.dev as suggested by Arnd Changes for v5: - Rebase on v6.15-rc1 Changes for v4: - Drop already taken patches - Rebase on latest master Changes for v3: - Rebase on v6.12-rc1 Changes for v2: - Collect Reviewed/Acked-bys - Rebase on v6.11-rc1 arch/arm/mach-highbank/highbank.c | 2 +- arch/arm/mach-pxa/spitz.c | 2 +- arch/arm/mach-sa1100/generic.c | 2 +- arch/arm/mach-vt8500/vt8500.c | 2 +- arch/arm/xen/enlighten.c | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/arch/arm/mach-highbank/highbank.c b/arch/arm/mach-highbank/hig= hbank.c index 5d4f977ac7d2a..47335c7dadf8d 100644 --- a/arch/arm/mach-highbank/highbank.c +++ b/arch/arm/mach-highbank/highbank.c @@ -143,7 +143,7 @@ static void __init highbank_init(void) sregs_base =3D of_iomap(np, 0); WARN_ON(!sregs_base); =20 - pm_power_off =3D highbank_power_off; + register_platform_power_off(highbank_power_off); highbank_pm_init(); =20 bus_register_notifier(&platform_bus_type, &highbank_platform_nb); diff --git a/arch/arm/mach-pxa/spitz.c b/arch/arm/mach-pxa/spitz.c index 33533e35720f8..c0b1f7e6be874 100644 --- a/arch/arm/mach-pxa/spitz.c +++ b/arch/arm/mach-pxa/spitz.c @@ -1096,7 +1096,7 @@ static void __init spitz_init(void) software_node_register(&spitz_scoop_2_gpiochip_node); =20 init_gpio_reset(SPITZ_GPIO_ON_RESET, 1, 0); - pm_power_off =3D spitz_poweroff; + register_platform_power_off(spitz_poweroff); =20 PMCR =3D 0x00; =20 diff --git a/arch/arm/mach-sa1100/generic.c b/arch/arm/mach-sa1100/generic.c index 0c586047d130f..5383a26f51169 100644 --- a/arch/arm/mach-sa1100/generic.c +++ b/arch/arm/mach-sa1100/generic.c @@ -298,7 +298,7 @@ static struct platform_device *sa11x0_devices[] __initd= ata =3D { static int __init sa1100_init(void) { struct resource wdt_res =3D DEFINE_RES_MEM(0x90000000, 0x20); - pm_power_off =3D sa1100_power_off; + register_platform_power_off(sa1100_power_off); =20 regulator_has_full_constraints(); =20 diff --git a/arch/arm/mach-vt8500/vt8500.c b/arch/arm/mach-vt8500/vt8500.c index 0ab40087ae1cc..1d294255d7083 100644 --- a/arch/arm/mach-vt8500/vt8500.c +++ b/arch/arm/mach-vt8500/vt8500.c @@ -141,7 +141,7 @@ static void __init vt8500_init(void) pr_err("%s:ioremap(power_off) failed\n", __func__); } if (pmc_base) - pm_power_off =3D &vt8500_power_off; + register_platform_power_off(vt8500_power_off); else pr_err("%s: PMC Hibernation register could not be remapped, not enabling= power off!\n", __func__); } diff --git a/arch/arm/xen/enlighten.c b/arch/arm/xen/enlighten.c index a395b6c0aae2a..8655bc3d36347 100644 --- a/arch/arm/xen/enlighten.c +++ b/arch/arm/xen/enlighten.c @@ -541,7 +541,7 @@ static int __init xen_late_init(void) if (!xen_domain()) return -ENODEV; =20 - pm_power_off =3D xen_power_off; + register_platform_power_off(xen_power_off); register_restart_handler(&xen_restart_nb); if (!xen_initial_domain()) { struct timespec64 ts; --=20 2.39.2