diff options
| author | Li Jun <lijun01@kylinos.cn> | 2026-09-08 17:49:01 +0800 |
|---|---|---|
| committer | Niklas Cassel <cassel@kernel.org> | 2026-09-08 13:39:24 +0200 |
| commit | f091e60fc986eb12ff632f682848b88da824bccb (patch) | |
| tree | f9dd72c1c266d71689075358cf0269b7946223be | |
| parent | bd46a0b22933fb45f4ff009fa4a3836124df34b3 (diff) | |
| download | linux-next-f091e60fc986eb12ff632f682848b88da824bccb.tar.gz linux-next-f091e60fc986eb12ff632f682848b88da824bccb.zip | |
ata: ahci_da850: switch to DEFINE_SIMPLE_DEV_PM_OPS
Replace the deprecated SIMPLE_DEV_PM_OPS macro with the recommended
DEFINE_SIMPLE_DEV_PM_OPS. Use pm_ptr(&ahci_da850_pm_ops) to complete
the API migration and allow the structure to be correctly dropped
when CONFIG_PM_SLEEP=n.
Signed-off-by: Li Jun <lijun01@kylinos.cn>
Reviewed-by: Damien Le Moal <dlemoal@kernel.org>
Link: https://lore.kernel.org/r/20260908094901.2527974-1-lijun01@kylinos.cn
Signed-off-by: Niklas Cassel <cassel@kernel.org>
| -rw-r--r-- | drivers/ata/ahci_da850.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/ata/ahci_da850.c b/drivers/ata/ahci_da850.c index 4e53ff96d712..59b9ca26fd44 100644 --- a/drivers/ata/ahci_da850.c +++ b/drivers/ata/ahci_da850.c @@ -218,8 +218,8 @@ disable_resources: return rc; } -static SIMPLE_DEV_PM_OPS(ahci_da850_pm_ops, ahci_platform_suspend, - ahci_platform_resume); +static DEFINE_SIMPLE_DEV_PM_OPS(ahci_da850_pm_ops, ahci_platform_suspend, + ahci_platform_resume); static const struct of_device_id ahci_da850_of_match[] = { { .compatible = "ti,da850-ahci", }, @@ -233,7 +233,7 @@ static struct platform_driver ahci_da850_driver = { .driver = { .name = DRV_NAME, .of_match_table = ahci_da850_of_match, - .pm = &ahci_da850_pm_ops, + .pm = pm_sleep_ptr(&ahci_da850_pm_ops), }, }; module_platform_driver(ahci_da850_driver); |
