2022-11-05 19:32:58

by Samuel Holland

[permalink] [raw]
Subject: [PATCH 1/2] bus: sunxi-rsb: Remove shutdown callback

Shutting down the RSB controller prevents communicating with a PMIC
inside pm_power_off(), so it breaks system poweroff on some boards.

Reported-by: Ivaylo Dimitrov <[email protected]>
Fixes: 843107498f91 ("bus: sunxi-rsb: Implement suspend/resume/shutdown callbacks")
Signed-off-by: Samuel Holland <[email protected]>
---

drivers/bus/sunxi-rsb.c | 9 ---------
1 file changed, 9 deletions(-)

diff --git a/drivers/bus/sunxi-rsb.c b/drivers/bus/sunxi-rsb.c
index 4cd2e127946e..17343cd75338 100644
--- a/drivers/bus/sunxi-rsb.c
+++ b/drivers/bus/sunxi-rsb.c
@@ -812,14 +812,6 @@ static int sunxi_rsb_remove(struct platform_device *pdev)
return 0;
}

-static void sunxi_rsb_shutdown(struct platform_device *pdev)
-{
- struct sunxi_rsb *rsb = platform_get_drvdata(pdev);
-
- pm_runtime_disable(&pdev->dev);
- sunxi_rsb_hw_exit(rsb);
-}
-
static const struct dev_pm_ops sunxi_rsb_dev_pm_ops = {
SET_RUNTIME_PM_OPS(sunxi_rsb_runtime_suspend,
sunxi_rsb_runtime_resume, NULL)
@@ -835,7 +827,6 @@ MODULE_DEVICE_TABLE(of, sunxi_rsb_of_match_table);
static struct platform_driver sunxi_rsb_driver = {
.probe = sunxi_rsb_probe,
.remove = sunxi_rsb_remove,
- .shutdown = sunxi_rsb_shutdown,
.driver = {
.name = RSB_CTRL_NAME,
.of_match_table = sunxi_rsb_of_match_table,
--
2.37.3



2022-11-05 19:48:46

by Jernej Škrabec

[permalink] [raw]
Subject: Re: [PATCH 1/2] bus: sunxi-rsb: Remove shutdown callback

Dne sobota, 05. november 2022 ob 20:19:52 CET je Samuel Holland napisal(a):
> Shutting down the RSB controller prevents communicating with a PMIC
> inside pm_power_off(), so it breaks system poweroff on some boards.
>
> Reported-by: Ivaylo Dimitrov <[email protected]>
> Fixes: 843107498f91 ("bus: sunxi-rsb: Implement suspend/resume/shutdown
> callbacks") Signed-off-by: Samuel Holland <[email protected]>

Acked-by: Jernej Skrabec <[email protected]>

Best regards,
Jernej

> ---
>
> drivers/bus/sunxi-rsb.c | 9 ---------
> 1 file changed, 9 deletions(-)
>
> diff --git a/drivers/bus/sunxi-rsb.c b/drivers/bus/sunxi-rsb.c
> index 4cd2e127946e..17343cd75338 100644
> --- a/drivers/bus/sunxi-rsb.c
> +++ b/drivers/bus/sunxi-rsb.c
> @@ -812,14 +812,6 @@ static int sunxi_rsb_remove(struct platform_device
> *pdev) return 0;
> }
>
> -static void sunxi_rsb_shutdown(struct platform_device *pdev)
> -{
> - struct sunxi_rsb *rsb = platform_get_drvdata(pdev);
> -
> - pm_runtime_disable(&pdev->dev);
> - sunxi_rsb_hw_exit(rsb);
> -}
> -
> static const struct dev_pm_ops sunxi_rsb_dev_pm_ops = {
> SET_RUNTIME_PM_OPS(sunxi_rsb_runtime_suspend,
> sunxi_rsb_runtime_resume, NULL)
> @@ -835,7 +827,6 @@ MODULE_DEVICE_TABLE(of, sunxi_rsb_of_match_table);
> static struct platform_driver sunxi_rsb_driver = {
> .probe = sunxi_rsb_probe,
> .remove = sunxi_rsb_remove,
> - .shutdown = sunxi_rsb_shutdown,
> .driver = {
> .name = RSB_CTRL_NAME,
> .of_match_table = sunxi_rsb_of_match_table,





2022-11-06 08:09:30

by Ivaylo Dimitrov

[permalink] [raw]
Subject: Re: [PATCH 1/2] bus: sunxi-rsb: Remove shutdown callback

On 5.11.22 г. 21:29 ч., Jernej Škrabec wrote:
> Dne sobota, 05. november 2022 ob 20:19:52 CET je Samuel Holland napisal(a):
>> Shutting down the RSB controller prevents communicating with a PMIC
>> inside pm_power_off(), so it breaks system poweroff on some boards.
>>
>> Reported-by: Ivaylo Dimitrov <[email protected]>
>> Fixes: 843107498f91 ("bus: sunxi-rsb: Implement suspend/resume/shutdown
>> callbacks") Signed-off-by: Samuel Holland <[email protected]>
>
> Acked-by: Jernej Skrabec <[email protected]>
>

Tested-by: Ivaylo Dimitrov <[email protected]>

Thanks,
Ivo

> Best regards,
> Jernej
>
>> ---
>>
>> drivers/bus/sunxi-rsb.c | 9 ---------
>> 1 file changed, 9 deletions(-)
>>
>> diff --git a/drivers/bus/sunxi-rsb.c b/drivers/bus/sunxi-rsb.c
>> index 4cd2e127946e..17343cd75338 100644
>> --- a/drivers/bus/sunxi-rsb.c
>> +++ b/drivers/bus/sunxi-rsb.c
>> @@ -812,14 +812,6 @@ static int sunxi_rsb_remove(struct platform_device
>> *pdev) return 0;
>> }
>>
>> -static void sunxi_rsb_shutdown(struct platform_device *pdev)
>> -{
>> - struct sunxi_rsb *rsb = platform_get_drvdata(pdev);
>> -
>> - pm_runtime_disable(&pdev->dev);
>> - sunxi_rsb_hw_exit(rsb);
>> -}
>> -
>> static const struct dev_pm_ops sunxi_rsb_dev_pm_ops = {
>> SET_RUNTIME_PM_OPS(sunxi_rsb_runtime_suspend,
>> sunxi_rsb_runtime_resume, NULL)
>> @@ -835,7 +827,6 @@ MODULE_DEVICE_TABLE(of, sunxi_rsb_of_match_table);
>> static struct platform_driver sunxi_rsb_driver = {
>> .probe = sunxi_rsb_probe,
>> .remove = sunxi_rsb_remove,
>> - .shutdown = sunxi_rsb_shutdown,
>> .driver = {
>> .name = RSB_CTRL_NAME,
>> .of_match_table = sunxi_rsb_of_match_table,
>
>
>
>