soc: fsl: enable acpi support in RCPM driver
PATCH v4 1/1 soc: fsl: enable acpi support in RCPM driver
From: Peng Ma <[email protected]>
This patch enables ACPI support in RCPM driver.
Signed-off-by Peng Ma <[email protected]>
Signed-off-by Ran Wang <[email protected]>
---
Change in v4:
- Make commit subject more accurate
- Remove unrelated new blank line
Change in v3:
- Add #ifdef CONFIG_ACPI for acpi_device_id
- Rename rcpm_acpi_imx_ids to rcpm_acpi_ids
Change in v2:
- Update acpi_device_id to fix conflict with other driver
drivers/soc/fsl/rcpm.c | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-)
drivers/soc/fsl/rcpm.c +11 -1
@@ -2,7 +2,7 @@// // rcpm.c - Freescale QorIQ RCPM driver // -// Copyright 2019 NXP +// Copyright 2019-2020 NXP // // Author: Ran Wang <[email protected]>
@@ -13,6 +13,7 @@#include <linux/slab.h> #include <linux/suspend.h> #include <linux/kernel.h> +#include <linux/acpi.h> #define RCPM_WAKEUP_CELL_MAX_SIZE 7
@@ -139,10 +140,19 @@ static const struct of_device_id rcpm_of_match[] = { };MODULE_DEVICE_TABLE (of, rcpm_of_match); +#ifdef CONFIG_ACPI +static const struct acpi_device_id rcpm_acpi_ids[] = { + {"NXP0015" ,}, + { } +}; +MODULE_DEVICE_TABLE (acpi, rcpm_acpi_ids); +#endif +static struct platform_driver rcpm_driver = { .driver = { .name ="rcpm" , .of_match_table = rcpm_of_match, + .acpi_match_table =ACPI_PTR (rcpm_acpi_ids), .pm = &rcpm_pm_ops, }, .probe = rcpm_probe,
Signature · 1 line
2.7.4