From patchwork Mon Jul 29 12:35:32 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrew Davis X-Patchwork-Id: 13744829 Received: from fllv0015.ext.ti.com (fllv0015.ext.ti.com [198.47.19.141]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 86CB214882B for ; Mon, 29 Jul 2024 12:36:04 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=198.47.19.141 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1722256566; cv=none; b=OHrjnxYqtvw+c79HchDHoUpSUNdbfwzyYkE3VL1dAeMGBfzAFLD9uBKuH5n6GFYX4BGGYzNQytkVvelzYi8GrkjITvnJw6vNgHg2EpdP8z3siYJP2i5hHgKTOMA+ZY0j4sLAFt6ST4jcFIxkpxzSvWlI68fz5NvVGJKKG35IPDg= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1722256566; c=relaxed/simple; bh=stLoQqO8Cd+PyhnH0MVB+z/fey6dor2CcmaPnD/Sw/Y=; h=From:To:CC:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=eq0sPyaUFkvg2UZybihC8PBDOMcOnyvML6iS4yenG3BImI3PlGqQHSKtwHu0B8mbD7t4o1jSYjP8+MRcuSCjIyTsk5+6lICbm5HX985fI4i98VLkb/j0mxlC12NfYTRX6zdCdCuTrDIZ56uxeIILsIhbXu8OB9ZRAcQ93POZ3iQ= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=ti.com; spf=pass smtp.mailfrom=ti.com; dkim=pass (1024-bit key) header.d=ti.com header.i=@ti.com header.b=TmpERbou; arc=none smtp.client-ip=198.47.19.141 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=ti.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=ti.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=ti.com header.i=@ti.com header.b="TmpERbou" Received: from fllv0035.itg.ti.com ([10.64.41.0]) by fllv0015.ext.ti.com (8.15.2/8.15.2) with ESMTP id 46TCZfbe080637; Mon, 29 Jul 2024 07:35:41 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1722256541; bh=P6d498xP36XXy4X2j2XNBIV3J80KTeTFWEpSStPLVgY=; h=From:To:CC:Subject:Date:In-Reply-To:References; b=TmpERbou3D6wNmMKA6rD+qvku1gez2o9p2zA4OJr0nIFHxIo5DGwhD5XfvLkQEQv+ mUjTaraygmcoyRgHf/2XyduoKDYj3A6+u0peoxrGldLffSq3dYSNibDKbJwvlkSK7A l+2NCCrgn6D7G4wQwAU/IIZHTH4uiWVtPEsOcnYk= Received: from DFLE112.ent.ti.com (dfle112.ent.ti.com [10.64.6.33]) by fllv0035.itg.ti.com (8.15.2/8.15.2) with ESMTPS id 46TCZfTd017797 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Mon, 29 Jul 2024 07:35:41 -0500 Received: from DFLE107.ent.ti.com (10.64.6.28) by DFLE112.ent.ti.com (10.64.6.33) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23; Mon, 29 Jul 2024 07:35:41 -0500 Received: from lelvsmtp5.itg.ti.com (10.180.75.250) by DFLE107.ent.ti.com (10.64.6.28) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23 via Frontend Transport; Mon, 29 Jul 2024 07:35:40 -0500 Received: from fllvsmtp7.itg.ti.com ([10.249.42.149]) by lelvsmtp5.itg.ti.com (8.15.2/8.15.2) with ESMTP id 46TCZd0i128014; Mon, 29 Jul 2024 07:35:40 -0500 From: Andrew Davis To: Andre Przywara , Russell King , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam , Andrew Lunn , Sebastian Hesselbarth , Gregory Clement , Daniel Mack , Haojian Zhuang , Robert Jarzmik CC: , , , Andrew Davis Subject: [PATCH v2 1/7] ARM: highbank: Switch to new sys-off handler API Date: Mon, 29 Jul 2024 07:35:32 -0500 Message-ID: <20240729123538.175704-2-afd@ti.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240729123538.175704-1-afd@ti.com> References: <20240729123538.175704-1-afd@ti.com> Precedence: bulk X-Mailing-List: imx@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 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 --- arch/arm/mach-highbank/highbank.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm/mach-highbank/highbank.c b/arch/arm/mach-highbank/highbank.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 = of_iomap(np, 0); WARN_ON(!sregs_base); - pm_power_off = highbank_power_off; + register_platform_power_off(highbank_power_off); highbank_pm_init(); bus_register_notifier(&platform_bus_type, &highbank_platform_nb); From patchwork Mon Jul 29 12:35:33 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrew Davis X-Patchwork-Id: 13744826 Received: from lelv0142.ext.ti.com (lelv0142.ext.ti.com [198.47.23.249]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 9EF281487EF for ; Mon, 29 Jul 2024 12:36:03 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=198.47.23.249 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1722256565; cv=none; b=cTy5Sb1jOdrmdfwERDASqw+Qx/V4oojMgGdK8lkA/I709sS4T6CxK8hkuwotgAzLm82Yaacf6hOEE1FaQa/6xsBklF74srf4dAJMiLDuQQq4xgKZMGrznwiPDDReKFxgx66dE4lolfXc9SJkvlgXOeLdsdsf0AL0O/OerXk6jZI= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1722256565; c=relaxed/simple; bh=nuJrTRgLsjQExs+N87GmazFylclUiz4XenNuLHwBWV4=; h=From:To:CC:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=N1wNtwTchHtNJMmXfM3jv9bnW8z3lNiwmI4zFqM3f9mm+616NBhfMUyPeFvlokDM5XAtB32UlOkfI7btVeo7S1n8+uoDYK9zIcjThcblWcrJ+2xgxZtpvEn1JV30cGYq4pz4ZhgO1FpatWdA6PhBo7AqTCxNmNiA6oS0tad1ZHM= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=ti.com; spf=pass smtp.mailfrom=ti.com; dkim=pass (1024-bit key) header.d=ti.com header.i=@ti.com header.b=wvU/R4JI; arc=none smtp.client-ip=198.47.23.249 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=ti.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=ti.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=ti.com header.i=@ti.com header.b="wvU/R4JI" Received: from fllv0035.itg.ti.com ([10.64.41.0]) by lelv0142.ext.ti.com (8.15.2/8.15.2) with ESMTP id 46TCZfes067690; Mon, 29 Jul 2024 07:35:41 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1722256542; bh=E1t2slHF8kd+FV4537/57jAGsLGmbZ2/z9jipE7qiaU=; h=From:To:CC:Subject:Date:In-Reply-To:References; b=wvU/R4JI26/NgeSr5ZzUGuJlYHB8SLtbT2u4bPVRYGgGcTzLskOhgO4/ruHJ35w77 bjZd+ARzwIV0Aqw3iSgcG2FsFuZxDY47G4rsVU+QzVzGkitMwZEOsndFo1EKcYCnK5 9cabEDDKskcXWUueTGRmXug1lkUmoBVXxDGiyiHM= Received: from DLEE109.ent.ti.com (dlee109.ent.ti.com [157.170.170.41]) by fllv0035.itg.ti.com (8.15.2/8.15.2) with ESMTPS id 46TCZfKK017807 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Mon, 29 Jul 2024 07:35:41 -0500 Received: from DLEE110.ent.ti.com (157.170.170.21) by DLEE109.ent.ti.com (157.170.170.41) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23; Mon, 29 Jul 2024 07:35:41 -0500 Received: from lelvsmtp5.itg.ti.com (10.180.75.250) by DLEE110.ent.ti.com (157.170.170.21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23 via Frontend Transport; Mon, 29 Jul 2024 07:35:41 -0500 Received: from fllvsmtp7.itg.ti.com ([10.249.42.149]) by lelvsmtp5.itg.ti.com (8.15.2/8.15.2) with ESMTP id 46TCZd0j128014; Mon, 29 Jul 2024 07:35:40 -0500 From: Andrew Davis To: Andre Przywara , Russell King , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam , Andrew Lunn , Sebastian Hesselbarth , Gregory Clement , Daniel Mack , Haojian Zhuang , Robert Jarzmik CC: , , , Andrew Davis Subject: [PATCH v2 2/7] ARM: imx: Switch to new sys-off handler API Date: Mon, 29 Jul 2024 07:35:33 -0500 Message-ID: <20240729123538.175704-3-afd@ti.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240729123538.175704-1-afd@ti.com> References: <20240729123538.175704-1-afd@ti.com> Precedence: bulk X-Mailing-List: imx@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 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 Acked-by: Shawn Guo --- arch/arm/mach-imx/pm-imx6.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/arch/arm/mach-imx/pm-imx6.c b/arch/arm/mach-imx/pm-imx6.c index b36f05b54cc76..a671ca498f887 100644 --- a/arch/arm/mach-imx/pm-imx6.c +++ b/arch/arm/mach-imx/pm-imx6.c @@ -634,13 +634,11 @@ static void imx6_pm_stby_poweroff(void) static int imx6_pm_stby_poweroff_probe(void) { - if (pm_power_off) { - pr_warn("%s: pm_power_off already claimed %p %ps!\n", - __func__, pm_power_off, pm_power_off); + if (register_platform_power_off(imx6_pm_stby_poweroff)) { + pr_warn("%s: platform power off already claimed!\n", __func__); return -EBUSY; } - pm_power_off = imx6_pm_stby_poweroff; return 0; } From patchwork Mon Jul 29 12:35:34 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrew Davis X-Patchwork-Id: 13744828 Received: from lelv0142.ext.ti.com (lelv0142.ext.ti.com [198.47.23.249]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 034FA1487D6 for ; Mon, 29 Jul 2024 12:36:03 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=198.47.23.249 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1722256565; cv=none; b=bKb6jV9rIuy0cGRxz7vV7mEEXHChXcEg8touAVgnOrEv/YJwAtLRpATKQK9w3J0M8xqC8WRdDUnk9muceH66858+J6QlnrAqqA+mgVKQMzXx2z0kzGkLIWq/4iTwu543WppHCNuTJMmXmnp51pgbzTTUjFGhMD9C+MvI7swazTg= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1722256565; c=relaxed/simple; bh=uiEO0Dju308lklBeGzCuHN4gSe5vgB9T3cqLAAXa5uA=; h=From:To:CC:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=L5IWUIAcmB00vdfIpTFDURp8H2qs5VZPTipUkBr3yx1ju0DiEPqX+NbJs3St3jLxeU+I5D70PI7UD9qX7zhEFznCyj2Stoy7xsvE/Vo8WixaSSZ2/7XWNFPZv0y3kBCD1M1IaQIjfrLbSUaXXNOC/eDfI6r7a6Cy6U8oMgTsk/g= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=ti.com; spf=pass smtp.mailfrom=ti.com; dkim=pass (1024-bit key) header.d=ti.com header.i=@ti.com header.b=jWkToxhw; arc=none smtp.client-ip=198.47.23.249 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=ti.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=ti.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=ti.com header.i=@ti.com header.b="jWkToxhw" Received: from fllv0035.itg.ti.com ([10.64.41.0]) by lelv0142.ext.ti.com (8.15.2/8.15.2) with ESMTP id 46TCZg92067695; Mon, 29 Jul 2024 07:35:42 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1722256542; bh=IHHLMYLPXlJTwZ74ezUXfOeK/Ir/Gto4KNINqzOs7pk=; h=From:To:CC:Subject:Date:In-Reply-To:References; b=jWkToxhwycHIOfUlzSsrY/Q/u41Xfc29lqeYbqw0QOiTLNQ3ChfyjCjmy2zAz8XNH JKVwWFRAdaPkk3pW7+HgVG4QiO+fDzJUc2sw4w1ayMhlusDamhJXWi5x5sDoSVHL/i /dzUw9fKAGKDk+7feuA4b04nNrETmYyYTHg4QEkc= Received: from DFLE114.ent.ti.com (dfle114.ent.ti.com [10.64.6.35]) by fllv0035.itg.ti.com (8.15.2/8.15.2) with ESMTPS id 46TCZgOp017815 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Mon, 29 Jul 2024 07:35:42 -0500 Received: from DFLE103.ent.ti.com (10.64.6.24) by DFLE114.ent.ti.com (10.64.6.35) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23; Mon, 29 Jul 2024 07:35:42 -0500 Received: from lelvsmtp5.itg.ti.com (10.180.75.250) by DFLE103.ent.ti.com (10.64.6.24) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23 via Frontend Transport; Mon, 29 Jul 2024 07:35:42 -0500 Received: from fllvsmtp7.itg.ti.com ([10.249.42.149]) by lelvsmtp5.itg.ti.com (8.15.2/8.15.2) with ESMTP id 46TCZd0k128014; Mon, 29 Jul 2024 07:35:41 -0500 From: Andrew Davis To: Andre Przywara , Russell King , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam , Andrew Lunn , Sebastian Hesselbarth , Gregory Clement , Daniel Mack , Haojian Zhuang , Robert Jarzmik CC: , , , Andrew Davis Subject: [PATCH v2 3/7] ARM: orion5x: Switch to new sys-off handler API Date: Mon, 29 Jul 2024 07:35:34 -0500 Message-ID: <20240729123538.175704-4-afd@ti.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240729123538.175704-1-afd@ti.com> References: <20240729123538.175704-1-afd@ti.com> Precedence: bulk X-Mailing-List: imx@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 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: Andrew Lunn --- arch/arm/mach-orion5x/board-mss2.c | 2 +- arch/arm/mach-orion5x/dns323-setup.c | 6 +++--- arch/arm/mach-orion5x/kurobox_pro-setup.c | 2 +- arch/arm/mach-orion5x/mv2120-setup.c | 2 +- arch/arm/mach-orion5x/net2big-setup.c | 2 +- arch/arm/mach-orion5x/terastation_pro2-setup.c | 2 +- arch/arm/mach-orion5x/ts209-setup.c | 2 +- arch/arm/mach-orion5x/ts409-setup.c | 2 +- 8 files changed, 10 insertions(+), 10 deletions(-) diff --git a/arch/arm/mach-orion5x/board-mss2.c b/arch/arm/mach-orion5x/board-mss2.c index b0f16d223adf5..9e3d69891d2f6 100644 --- a/arch/arm/mach-orion5x/board-mss2.c +++ b/arch/arm/mach-orion5x/board-mss2.c @@ -82,5 +82,5 @@ static void mss2_power_off(void) void __init mss2_init(void) { /* register mss2 specific power-off method */ - pm_power_off = mss2_power_off; + register_platform_power_off(mss2_power_off); } diff --git a/arch/arm/mach-orion5x/dns323-setup.c b/arch/arm/mach-orion5x/dns323-setup.c index 062109efa0ecc..fcd38ff7ca459 100644 --- a/arch/arm/mach-orion5x/dns323-setup.c +++ b/arch/arm/mach-orion5x/dns323-setup.c @@ -700,7 +700,7 @@ static void __init dns323_init(void) if (gpio_request(DNS323_GPIO_POWER_OFF, "POWEROFF") != 0 || gpio_direction_output(DNS323_GPIO_POWER_OFF, 0) != 0) pr_err("DNS-323: failed to setup power-off GPIO\n"); - pm_power_off = dns323a_power_off; + register_platform_power_off(dns323a_power_off); break; case DNS323_REV_B1: /* 5182 built-in SATA init */ @@ -717,7 +717,7 @@ static void __init dns323_init(void) if (gpio_request(DNS323_GPIO_POWER_OFF, "POWEROFF") != 0 || gpio_direction_output(DNS323_GPIO_POWER_OFF, 0) != 0) pr_err("DNS-323: failed to setup power-off GPIO\n"); - pm_power_off = dns323b_power_off; + register_platform_power_off(dns323b_power_off); break; case DNS323_REV_C1: /* 5182 built-in SATA init */ @@ -727,7 +727,7 @@ static void __init dns323_init(void) if (gpio_request(DNS323C_GPIO_POWER_OFF, "POWEROFF") != 0 || gpio_direction_output(DNS323C_GPIO_POWER_OFF, 0) != 0) pr_err("DNS-323: failed to setup power-off GPIO\n"); - pm_power_off = dns323c_power_off; + register_platform_power_off(dns323c_power_off); /* Now, -this- should theoretically be done by the sata_mv driver * once I figure out what's going on there. Maybe the behaviour diff --git a/arch/arm/mach-orion5x/kurobox_pro-setup.c b/arch/arm/mach-orion5x/kurobox_pro-setup.c index acba066180801..339b10891808f 100644 --- a/arch/arm/mach-orion5x/kurobox_pro-setup.c +++ b/arch/arm/mach-orion5x/kurobox_pro-setup.c @@ -373,7 +373,7 @@ static void __init kurobox_pro_init(void) i2c_register_board_info(0, &kurobox_pro_i2c_rtc, 1); /* register Kurobox Pro specific power-off method */ - pm_power_off = kurobox_pro_power_off; + register_platform_power_off(kurobox_pro_power_off); } #ifdef CONFIG_MACH_KUROBOX_PRO diff --git a/arch/arm/mach-orion5x/mv2120-setup.c b/arch/arm/mach-orion5x/mv2120-setup.c index b7327a6128353..5b0249f109cde 100644 --- a/arch/arm/mach-orion5x/mv2120-setup.c +++ b/arch/arm/mach-orion5x/mv2120-setup.c @@ -238,7 +238,7 @@ static void __init mv2120_init(void) if (gpio_request(MV2120_GPIO_POWER_OFF, "POWEROFF") != 0 || gpio_direction_output(MV2120_GPIO_POWER_OFF, 1) != 0) pr_err("mv2120: failed to setup power-off GPIO\n"); - pm_power_off = mv2120_power_off; + register_platform_power_off(mv2120_power_off); } /* Warning: HP uses a wrong mach-type (=526) in their bootloader */ diff --git a/arch/arm/mach-orion5x/net2big-setup.c b/arch/arm/mach-orion5x/net2big-setup.c index 6ad9740b426b6..4afd9b4c71a94 100644 --- a/arch/arm/mach-orion5x/net2big-setup.c +++ b/arch/arm/mach-orion5x/net2big-setup.c @@ -423,7 +423,7 @@ static void __init net2big_init(void) if (gpio_request(NET2BIG_GPIO_POWER_OFF, "power-off") == 0 && gpio_direction_output(NET2BIG_GPIO_POWER_OFF, 0) == 0) - pm_power_off = net2big_power_off; + register_platform_power_off(net2big_power_off); else pr_err("net2big: failed to configure power-off GPIO\n"); diff --git a/arch/arm/mach-orion5x/terastation_pro2-setup.c b/arch/arm/mach-orion5x/terastation_pro2-setup.c index 23a5521c68336..a9f01859d1012 100644 --- a/arch/arm/mach-orion5x/terastation_pro2-setup.c +++ b/arch/arm/mach-orion5x/terastation_pro2-setup.c @@ -349,7 +349,7 @@ static void __init tsp2_init(void) i2c_register_board_info(0, &tsp2_i2c_rtc, 1); /* register Terastation Pro II specific power-off method */ - pm_power_off = tsp2_power_off; + register_platform_power_off(tsp2_power_off); } MACHINE_START(TERASTATION_PRO2, "Buffalo Terastation Pro II/Live") diff --git a/arch/arm/mach-orion5x/ts209-setup.c b/arch/arm/mach-orion5x/ts209-setup.c index bab8ba0e01ab9..de9092e992c56 100644 --- a/arch/arm/mach-orion5x/ts209-setup.c +++ b/arch/arm/mach-orion5x/ts209-setup.c @@ -314,7 +314,7 @@ static void __init qnap_ts209_init(void) i2c_register_board_info(0, &qnap_ts209_i2c_rtc, 1); /* register tsx09 specific power-off method */ - pm_power_off = qnap_tsx09_power_off; + register_platform_power_off(qnap_tsx09_power_off); } MACHINE_START(TS209, "QNAP TS-109/TS-209") diff --git a/arch/arm/mach-orion5x/ts409-setup.c b/arch/arm/mach-orion5x/ts409-setup.c index 8131982c10d97..725688aa5cba7 100644 --- a/arch/arm/mach-orion5x/ts409-setup.c +++ b/arch/arm/mach-orion5x/ts409-setup.c @@ -312,7 +312,7 @@ static void __init qnap_ts409_init(void) platform_device_register(&ts409_leds); /* register tsx09 specific power-off method */ - pm_power_off = qnap_tsx09_power_off; + register_platform_power_off(qnap_tsx09_power_off); } MACHINE_START(TS409, "QNAP TS-409") From patchwork Mon Jul 29 12:35:35 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrew Davis X-Patchwork-Id: 13744827 Received: from lelv0142.ext.ti.com (lelv0142.ext.ti.com [198.47.23.249]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 1113B148823 for ; Mon, 29 Jul 2024 12:36:03 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=198.47.23.249 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1722256565; cv=none; b=A8WpgShEFKXU/RAbm768lWUPR5tp9WFY8fSMK5ENGOQMKS8F95kXQrUdR3Y1/VfB0c3ODFHtGdMAf469rl7HdWpOd+2LSC+AYsDBQ9YMq8oI/YZFbEinWc9jnt4Bc840S+Pbd9E0o7u68qiL8xYUp+M6enJPx89xTlzRWORovS0= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1722256565; c=relaxed/simple; bh=OrOOVZOi7hgZ+QYb0v+8cUzWivlrkTyEsuHguCWPCxE=; h=From:To:CC:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=eiBH0QRiZUBXLBSjYtLJEwoysDunowzW0wE/4YEnUfQRJmR2j0dGD+7nT1oyGHJfFr0Vh0TcEkImRDiasR5J3LpVL4+H7NIZTfKmN9csuwydmgJhuHb4BVaN/vvFflvQpxDVmgZEwndrx0pa/Z49mb9I6FlVMU+PKYffHI3rYPk= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=ti.com; spf=pass smtp.mailfrom=ti.com; dkim=pass (1024-bit key) header.d=ti.com header.i=@ti.com header.b=JkT0KEzE; arc=none smtp.client-ip=198.47.23.249 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=ti.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=ti.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=ti.com header.i=@ti.com header.b="JkT0KEzE" Received: from lelv0265.itg.ti.com ([10.180.67.224]) by lelv0142.ext.ti.com (8.15.2/8.15.2) with ESMTP id 46TCZh46067703; Mon, 29 Jul 2024 07:35:43 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1722256543; bh=K/+qRdkVMeBzBovWVEq3ErsEaf52H0JO+RGDHvNB1ZI=; h=From:To:CC:Subject:Date:In-Reply-To:References; b=JkT0KEzEeet4VIor7VndB/WoEfokTyMuLnc/8UFrJzW9IHoipRnhprM963Bgp9/GI wdAFKEPnPEaEBGu5OgQNjegPhUK+TLBnBNz69+CzBGXdv4P6lJV3SjJtEq+WPcHJSn R5LK2ovP8uXNIIySG2n8QHBRvu8awGWjJ00D/kM0= Received: from DLEE115.ent.ti.com (dlee115.ent.ti.com [157.170.170.26]) by lelv0265.itg.ti.com (8.15.2/8.15.2) with ESMTPS id 46TCZhl3011553 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Mon, 29 Jul 2024 07:35:43 -0500 Received: from DLEE108.ent.ti.com (157.170.170.38) by DLEE115.ent.ti.com (157.170.170.26) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23; Mon, 29 Jul 2024 07:35:42 -0500 Received: from lelvsmtp5.itg.ti.com (10.180.75.250) by DLEE108.ent.ti.com (157.170.170.38) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23 via Frontend Transport; Mon, 29 Jul 2024 07:35:42 -0500 Received: from fllvsmtp7.itg.ti.com ([10.249.42.149]) by lelvsmtp5.itg.ti.com (8.15.2/8.15.2) with ESMTP id 46TCZd0l128014; Mon, 29 Jul 2024 07:35:42 -0500 From: Andrew Davis To: Andre Przywara , Russell King , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam , Andrew Lunn , Sebastian Hesselbarth , Gregory Clement , Daniel Mack , Haojian Zhuang , Robert Jarzmik CC: , , , Andrew Davis Subject: [PATCH v2 4/7] ARM: pxa: Switch to new sys-off handler API Date: Mon, 29 Jul 2024 07:35:35 -0500 Message-ID: <20240729123538.175704-5-afd@ti.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240729123538.175704-1-afd@ti.com> References: <20240729123538.175704-1-afd@ti.com> Precedence: bulk X-Mailing-List: imx@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 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 --- arch/arm/mach-pxa/spitz.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm/mach-pxa/spitz.c b/arch/arm/mach-pxa/spitz.c index 452bf7aac1fad..c8db4eec59465 100644 --- a/arch/arm/mach-pxa/spitz.c +++ b/arch/arm/mach-pxa/spitz.c @@ -1041,7 +1041,7 @@ static void __init spitz_init(void) software_node_register(&spitz_scoop_2_gpiochip_node); init_gpio_reset(SPITZ_GPIO_ON_RESET, 1, 0); - pm_power_off = spitz_poweroff; + register_platform_power_off(spitz_poweroff); PMCR = 0x00; From patchwork Mon Jul 29 12:35:36 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrew Davis X-Patchwork-Id: 13744825 Received: from lelv0142.ext.ti.com (lelv0142.ext.ti.com [198.47.23.249]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 3B60A1487C1 for ; Mon, 29 Jul 2024 12:36:02 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=198.47.23.249 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1722256564; cv=none; b=A1SOjGQgGROILN8fHSz5ef7nH+8++qKI/c8TRm0S/V6Wg/7QkAIp14ga15/ZSn+KkwjUqrZU8alh+xodQWro8RMP4n/haV54yqH/oOdtjNiGQr0d/HiJILDL528zZol8vP4+IrWAOveKY3vpUvKgou1JbdCm5kYzXEUqoav280U= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1722256564; c=relaxed/simple; bh=F1JZZ3VxwsSKTg2LjGq0rUIE/gVME8qmJ40fxossfJc=; h=From:To:CC:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=XrROFZrNoRRQk9KzftdNuAUMhDlUP/PyBcDWgNYZ+TOM94ydtfNkc7dvB1mXGEvBpWow4l0Su0Rw8/uIeZL+YzMPYDSNvAftbfwieVp9jrLaee+Pzo7x7af5yDghQ2UQPrBkeW0MM5FNUMvs8JEeDJsXtViDO+n1aFjSMGAXGJ0= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=ti.com; spf=pass smtp.mailfrom=ti.com; dkim=pass (1024-bit key) header.d=ti.com header.i=@ti.com header.b=wK1EcbJk; arc=none smtp.client-ip=198.47.23.249 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=ti.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=ti.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=ti.com header.i=@ti.com header.b="wK1EcbJk" Received: from fllv0035.itg.ti.com ([10.64.41.0]) by lelv0142.ext.ti.com (8.15.2/8.15.2) with ESMTP id 46TCZhLS067707; Mon, 29 Jul 2024 07:35:43 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1722256543; bh=8gIz69rx+O7g3l2dUBVUwaQsvlZ4QBJNSMujzHzSCeo=; h=From:To:CC:Subject:Date:In-Reply-To:References; b=wK1EcbJksvvv8QlXaTWe6V1cHbusdhpC5D2jQhy/OXwO4hGjdXpANdj1zZEYI80CK twCmoZf7cHEKOfu54KFGZ+3viRAe/6Gl3ArJ/1kgRu0u8MGo88aNFRRX3YheABpeRA L3NeEXpBrabQxYTjR0SmNm+FDbQKw4rLKu4tZFvY= Received: from DLEE115.ent.ti.com (dlee115.ent.ti.com [157.170.170.26]) by fllv0035.itg.ti.com (8.15.2/8.15.2) with ESMTPS id 46TCZhTB017830 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Mon, 29 Jul 2024 07:35:43 -0500 Received: from DLEE113.ent.ti.com (157.170.170.24) by DLEE115.ent.ti.com (157.170.170.26) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23; Mon, 29 Jul 2024 07:35:43 -0500 Received: from lelvsmtp5.itg.ti.com (10.180.75.250) by DLEE113.ent.ti.com (157.170.170.24) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23 via Frontend Transport; Mon, 29 Jul 2024 07:35:43 -0500 Received: from fllvsmtp7.itg.ti.com ([10.249.42.149]) by lelvsmtp5.itg.ti.com (8.15.2/8.15.2) with ESMTP id 46TCZd0m128014; Mon, 29 Jul 2024 07:35:42 -0500 From: Andrew Davis To: Andre Przywara , Russell King , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam , Andrew Lunn , Sebastian Hesselbarth , Gregory Clement , Daniel Mack , Haojian Zhuang , Robert Jarzmik CC: , , , Andrew Davis Subject: [PATCH v2 5/7] ARM: sa1100: Switch to new sys-off handler API Date: Mon, 29 Jul 2024 07:35:36 -0500 Message-ID: <20240729123538.175704-6-afd@ti.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240729123538.175704-1-afd@ti.com> References: <20240729123538.175704-1-afd@ti.com> Precedence: bulk X-Mailing-List: imx@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 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 --- arch/arm/mach-sa1100/generic.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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[] __initdata = { static int __init sa1100_init(void) { struct resource wdt_res = DEFINE_RES_MEM(0x90000000, 0x20); - pm_power_off = sa1100_power_off; + register_platform_power_off(sa1100_power_off); regulator_has_full_constraints(); From patchwork Mon Jul 29 12:35:37 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrew Davis X-Patchwork-Id: 13744830 Received: from fllv0016.ext.ti.com (fllv0016.ext.ti.com [198.47.19.142]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id AD4EC1482FE for ; Mon, 29 Jul 2024 12:36:04 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=198.47.19.142 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1722256566; cv=none; b=jGGnWK+D8OXkFMsiXgY+9xtzzzwqNR2hplYClL1kzJuctvSSM8ggipci64JqB+OpsCycnxnQuyTkx57HsUD85Mjkc337P+KyK+xySf/PaNPgBK0GzkUlcxTXd/26arlmFTq9XySijT8TH6PXBSOr/EYgx5YoYymXgXIjs1giPWA= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1722256566; c=relaxed/simple; bh=bM81m61bwS2UN2Svbu/r1zfl/LDb+tjGoL6u8SEWQWE=; h=From:To:CC:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=K0GS1s0gMMlDpTdXAwsGD0K2MUC7XVdaPOgitDsc5r6DkPcaFNKWZgshTNYbLEEUqdJSP9F6uN1pkFMkNltEYFP+81gpmThI/wMCx0XvD/xKsjOp93aS/xmLrkpGVTCwYIatmL4rHAaJ9rJjcFSDH5NvHI+myLQbRlXUvgf1fi0= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=ti.com; spf=pass smtp.mailfrom=ti.com; dkim=pass (1024-bit key) header.d=ti.com header.i=@ti.com header.b=TTZOhrw8; arc=none smtp.client-ip=198.47.19.142 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=ti.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=ti.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=ti.com header.i=@ti.com header.b="TTZOhrw8" Received: from lelv0266.itg.ti.com ([10.180.67.225]) by fllv0016.ext.ti.com (8.15.2/8.15.2) with ESMTP id 46TCZiAx086627; Mon, 29 Jul 2024 07:35:44 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1722256544; bh=UUkIu/8Qmux6+/va5NpKSfNIFMGEqp8ObO5jfrobR38=; h=From:To:CC:Subject:Date:In-Reply-To:References; b=TTZOhrw8C6MHha8/UdLdfCUNQKQxB6barVxrwvhT6lvAH+EwgqKMwEl3mmOCc1WLz 6FcR5CrAl1PgMIJv7Skbd6DYYUCpd4LUGAOSu1+DsFYhfUCLGQJKD8rGAsSw0UmNpK BYfTdIkQAXf+l1VydHqxxVTT3xvbKUTCL2HAEpeM= Received: from DFLE113.ent.ti.com (dfle113.ent.ti.com [10.64.6.34]) by lelv0266.itg.ti.com (8.15.2/8.15.2) with ESMTPS id 46TCZiit040006 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Mon, 29 Jul 2024 07:35:44 -0500 Received: from DFLE100.ent.ti.com (10.64.6.21) by DFLE113.ent.ti.com (10.64.6.34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23; Mon, 29 Jul 2024 07:35:44 -0500 Received: from lelvsmtp5.itg.ti.com (10.180.75.250) by DFLE100.ent.ti.com (10.64.6.21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23 via Frontend Transport; Mon, 29 Jul 2024 07:35:44 -0500 Received: from fllvsmtp7.itg.ti.com ([10.249.42.149]) by lelvsmtp5.itg.ti.com (8.15.2/8.15.2) with ESMTP id 46TCZd0n128014; Mon, 29 Jul 2024 07:35:43 -0500 From: Andrew Davis To: Andre Przywara , Russell King , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam , Andrew Lunn , Sebastian Hesselbarth , Gregory Clement , Daniel Mack , Haojian Zhuang , Robert Jarzmik CC: , , , Andrew Davis Subject: [PATCH v2 6/7] ARM: vt8500: Switch to new sys-off handler API Date: Mon, 29 Jul 2024 07:35:37 -0500 Message-ID: <20240729123538.175704-7-afd@ti.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240729123538.175704-1-afd@ti.com> References: <20240729123538.175704-1-afd@ti.com> Precedence: bulk X-Mailing-List: imx@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 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 --- arch/arm/mach-vt8500/vt8500.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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 = &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__); } From patchwork Mon Jul 29 12:35:38 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrew Davis X-Patchwork-Id: 13744832 Received: from fllv0016.ext.ti.com (fllv0016.ext.ti.com [198.47.19.142]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 5BF611487EF for ; Mon, 29 Jul 2024 12:36:05 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=198.47.19.142 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1722256566; cv=none; b=pfSoE/nsLonXzgaZNrF8Bsxc8dq7C+NAns7csHOZzFPDYGT6T+W8iDtjlDyOltPOUtJzw4UoEXSpiknZhYwrNgLZUlU8P4FhOCvbK0SytZ8tGjKsRmaVZhxkzmbqoI/EkBOxuQQN8hUsRuWPO2erVg0dUd7bcUiZN9PPpySIEW4= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1722256566; c=relaxed/simple; bh=5M6ZDjw0MU4A/OwviHm+a622lr9vP5tFcBVBN7fGyS8=; h=From:To:CC:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=RIClGT4Mj657dG2R5A/U8AbgEopyjKcp7zaPFFBediVczZu1A51emWB+F+eFVfacxd5G5SxHEgh8xRldNa8DcgUwCiPiPVfbx3cCExzSeJLgPAO4oJwYfhZtW1xtk6pfubnO88dDIUDkO/zh41iHrpN9q1m/os4uigbwKgY+9Hw= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=ti.com; spf=pass smtp.mailfrom=ti.com; dkim=pass (1024-bit key) header.d=ti.com header.i=@ti.com header.b=DJVZ3QRW; arc=none smtp.client-ip=198.47.19.142 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=ti.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=ti.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=ti.com header.i=@ti.com header.b="DJVZ3QRW" Received: from lelv0266.itg.ti.com ([10.180.67.225]) by fllv0016.ext.ti.com (8.15.2/8.15.2) with ESMTP id 46TCZjC3086633; Mon, 29 Jul 2024 07:35:45 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1722256545; bh=wQeXaz16g8BvuxKa6rSagWr4SkeKW522Qc0ciOgW77o=; h=From:To:CC:Subject:Date:In-Reply-To:References; b=DJVZ3QRWxZsKT3wDN386/fzx0b4esRkZ8XhvtFQ7gS3baqsKB9mC778BuoAvTSiM2 lGk3mx5HhQkpKFLzRA5p5O9Ti84x5t7Yw/u+eGmaWW87l4uLTYyzkkB9NhCLjHaanK Z9TUl/nIxbUB48nrOCFq8LJd/sOwSAJ3NEbBWVrg= Received: from DFLE114.ent.ti.com (dfle114.ent.ti.com [10.64.6.35]) by lelv0266.itg.ti.com (8.15.2/8.15.2) with ESMTPS id 46TCZjTE040013 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Mon, 29 Jul 2024 07:35:45 -0500 Received: from DFLE103.ent.ti.com (10.64.6.24) by DFLE114.ent.ti.com (10.64.6.35) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23; Mon, 29 Jul 2024 07:35:44 -0500 Received: from lelvsmtp5.itg.ti.com (10.180.75.250) by DFLE103.ent.ti.com (10.64.6.24) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23 via Frontend Transport; Mon, 29 Jul 2024 07:35:44 -0500 Received: from fllvsmtp7.itg.ti.com ([10.249.42.149]) by lelvsmtp5.itg.ti.com (8.15.2/8.15.2) with ESMTP id 46TCZd0o128014; Mon, 29 Jul 2024 07:35:44 -0500 From: Andrew Davis To: Andre Przywara , Russell King , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam , Andrew Lunn , Sebastian Hesselbarth , Gregory Clement , Daniel Mack , Haojian Zhuang , Robert Jarzmik CC: , , , Andrew Davis Subject: [PATCH v2 7/7] arm/xen: Switch to new sys-off handler API Date: Mon, 29 Jul 2024 07:35:38 -0500 Message-ID: <20240729123538.175704-8-afd@ti.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240729123538.175704-1-afd@ti.com> References: <20240729123538.175704-1-afd@ti.com> Precedence: bulk X-Mailing-List: imx@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 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 --- arch/arm/xen/enlighten.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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; - pm_power_off = xen_power_off; + register_platform_power_off(xen_power_off); register_restart_handler(&xen_restart_nb); if (!xen_initial_domain()) { struct timespec64 ts;