diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-18 18:50:03 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-18 18:50:03 +0000 |
commit | 01a69402cf9d38ff180345d55c2ee51c7e89fbc7 (patch) | |
tree | b406c5242a088c4f59c6e4b719b783f43aca6ae9 /drivers/pmdomain/imx | |
parent | Adding upstream version 6.7.12. (diff) | |
download | linux-01a69402cf9d38ff180345d55c2ee51c7e89fbc7.tar.xz linux-01a69402cf9d38ff180345d55c2ee51c7e89fbc7.zip |
Adding upstream version 6.8.9.upstream/6.8.9
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'drivers/pmdomain/imx')
-rw-r--r-- | drivers/pmdomain/imx/gpc.c | 28 | ||||
-rw-r--r-- | drivers/pmdomain/imx/gpcv2.c | 6 | ||||
-rw-r--r-- | drivers/pmdomain/imx/imx8m-blk-ctrl.c | 6 | ||||
-rw-r--r-- | drivers/pmdomain/imx/imx8mp-blk-ctrl.c | 16 | ||||
-rw-r--r-- | drivers/pmdomain/imx/imx93-blk-ctrl.c | 6 | ||||
-rw-r--r-- | drivers/pmdomain/imx/imx93-pd.c | 6 |
6 files changed, 30 insertions, 38 deletions
diff --git a/drivers/pmdomain/imx/gpc.c b/drivers/pmdomain/imx/gpc.c index 7d81e3171d..9517cce93d 100644 --- a/drivers/pmdomain/imx/gpc.c +++ b/drivers/pmdomain/imx/gpc.c @@ -212,7 +212,7 @@ genpd_err: return ret; } -static int imx_pgc_power_domain_remove(struct platform_device *pdev) +static void imx_pgc_power_domain_remove(struct platform_device *pdev) { struct imx_pm_domain *domain = pdev->dev.platform_data; @@ -221,8 +221,6 @@ static int imx_pgc_power_domain_remove(struct platform_device *pdev) pm_genpd_remove(&domain->base); imx_pgc_put_clocks(domain); } - - return 0; } static const struct platform_device_id imx_pgc_power_domain_id[] = { @@ -235,7 +233,7 @@ static struct platform_driver imx_pgc_power_domain_driver = { .name = "imx-pgc-pd", }, .probe = imx_pgc_power_domain_probe, - .remove = imx_pgc_power_domain_remove, + .remove_new = imx_pgc_power_domain_remove, .id_table = imx_pgc_power_domain_id, }; builtin_platform_driver(imx_pgc_power_domain_driver) @@ -511,7 +509,7 @@ static int imx_gpc_probe(struct platform_device *pdev) return 0; } -static int imx_gpc_remove(struct platform_device *pdev) +static void imx_gpc_remove(struct platform_device *pdev) { struct device_node *pgc_node; int ret; @@ -521,7 +519,7 @@ static int imx_gpc_remove(struct platform_device *pdev) /* bail out if DT too old and doesn't provide the necessary info */ if (!of_property_read_bool(pdev->dev.of_node, "#power-domain-cells") && !pgc_node) - return 0; + return; /* * If the old DT binding is used the toplevel driver needs to @@ -531,16 +529,20 @@ static int imx_gpc_remove(struct platform_device *pdev) of_genpd_del_provider(pdev->dev.of_node); ret = pm_genpd_remove(&imx_gpc_domains[GPC_PGC_DOMAIN_PU].base); - if (ret) - return ret; + if (ret) { + dev_err(&pdev->dev, "Failed to remove PU power domain (%pe)\n", + ERR_PTR(ret)); + return; + } imx_pgc_put_clocks(&imx_gpc_domains[GPC_PGC_DOMAIN_PU]); ret = pm_genpd_remove(&imx_gpc_domains[GPC_PGC_DOMAIN_ARM].base); - if (ret) - return ret; + if (ret) { + dev_err(&pdev->dev, "Failed to remove ARM power domain (%pe)\n", + ERR_PTR(ret)); + return; + } } - - return 0; } static struct platform_driver imx_gpc_driver = { @@ -549,6 +551,6 @@ static struct platform_driver imx_gpc_driver = { .of_match_table = imx_gpc_dt_ids, }, .probe = imx_gpc_probe, - .remove = imx_gpc_remove, + .remove_new = imx_gpc_remove, }; builtin_platform_driver(imx_gpc_driver) diff --git a/drivers/pmdomain/imx/gpcv2.c b/drivers/pmdomain/imx/gpcv2.c index fbd3d92f8c..4b828d74a6 100644 --- a/drivers/pmdomain/imx/gpcv2.c +++ b/drivers/pmdomain/imx/gpcv2.c @@ -1373,7 +1373,7 @@ out_domain_unmap: return ret; } -static int imx_pgc_domain_remove(struct platform_device *pdev) +static void imx_pgc_domain_remove(struct platform_device *pdev) { struct imx_pgc_domain *domain = pdev->dev.platform_data; @@ -1385,8 +1385,6 @@ static int imx_pgc_domain_remove(struct platform_device *pdev) domain->bits.map, 0); pm_runtime_disable(domain->dev); - - return 0; } #ifdef CONFIG_PM_SLEEP @@ -1430,7 +1428,7 @@ static struct platform_driver imx_pgc_domain_driver = { .pm = &imx_pgc_domain_pm_ops, }, .probe = imx_pgc_domain_probe, - .remove = imx_pgc_domain_remove, + .remove_new = imx_pgc_domain_remove, .id_table = imx_pgc_domain_id, }; builtin_platform_driver(imx_pgc_domain_driver) diff --git a/drivers/pmdomain/imx/imx8m-blk-ctrl.c b/drivers/pmdomain/imx/imx8m-blk-ctrl.c index cc5ef6e2f0..1341a707f6 100644 --- a/drivers/pmdomain/imx/imx8m-blk-ctrl.c +++ b/drivers/pmdomain/imx/imx8m-blk-ctrl.c @@ -330,7 +330,7 @@ cleanup_pds: return ret; } -static int imx8m_blk_ctrl_remove(struct platform_device *pdev) +static void imx8m_blk_ctrl_remove(struct platform_device *pdev) { struct imx8m_blk_ctrl *bc = dev_get_drvdata(&pdev->dev); int i; @@ -347,8 +347,6 @@ static int imx8m_blk_ctrl_remove(struct platform_device *pdev) dev_pm_genpd_remove_notifier(bc->bus_power_dev); dev_pm_domain_detach(bc->bus_power_dev, true); - - return 0; } #ifdef CONFIG_PM_SLEEP @@ -888,7 +886,7 @@ MODULE_DEVICE_TABLE(of, imx8m_blk_ctrl_of_match); static struct platform_driver imx8m_blk_ctrl_driver = { .probe = imx8m_blk_ctrl_probe, - .remove = imx8m_blk_ctrl_remove, + .remove_new = imx8m_blk_ctrl_remove, .driver = { .name = "imx8m-blk-ctrl", .pm = &imx8m_blk_ctrl_pm_ops, diff --git a/drivers/pmdomain/imx/imx8mp-blk-ctrl.c b/drivers/pmdomain/imx/imx8mp-blk-ctrl.c index c6ac32c1a8..a56f7f92d0 100644 --- a/drivers/pmdomain/imx/imx8mp-blk-ctrl.c +++ b/drivers/pmdomain/imx/imx8mp-blk-ctrl.c @@ -55,7 +55,7 @@ struct imx8mp_blk_ctrl_domain_data { const char *gpc_name; }; -#define DOMAIN_MAX_CLKS 2 +#define DOMAIN_MAX_CLKS 3 #define DOMAIN_MAX_PATHS 3 struct imx8mp_blk_ctrl_domain { @@ -457,8 +457,8 @@ static const struct imx8mp_blk_ctrl_domain_data imx8mp_hdmi_domain_data[] = { }, [IMX8MP_HDMIBLK_PD_LCDIF] = { .name = "hdmiblk-lcdif", - .clk_names = (const char *[]){ "axi", "apb" }, - .num_clks = 2, + .clk_names = (const char *[]){ "axi", "apb", "fdcc" }, + .num_clks = 3, .gpc_name = "lcdif", .path_names = (const char *[]){"lcdif-hdmi"}, .num_paths = 1, @@ -483,8 +483,8 @@ static const struct imx8mp_blk_ctrl_domain_data imx8mp_hdmi_domain_data[] = { }, [IMX8MP_HDMIBLK_PD_HDMI_TX] = { .name = "hdmiblk-hdmi-tx", - .clk_names = (const char *[]){ "apb", "ref_266m" }, - .num_clks = 2, + .clk_names = (const char *[]){ "apb", "ref_266m", "fdcc" }, + .num_clks = 3, .gpc_name = "hdmi-tx", }, [IMX8MP_HDMIBLK_PD_HDMI_TX_PHY] = { @@ -760,7 +760,7 @@ cleanup_pds: return ret; } -static int imx8mp_blk_ctrl_remove(struct platform_device *pdev) +static void imx8mp_blk_ctrl_remove(struct platform_device *pdev) { struct imx8mp_blk_ctrl *bc = dev_get_drvdata(&pdev->dev); int i; @@ -777,8 +777,6 @@ static int imx8mp_blk_ctrl_remove(struct platform_device *pdev) dev_pm_genpd_remove_notifier(bc->bus_power_dev); dev_pm_domain_detach(bc->bus_power_dev, true); - - return 0; } #ifdef CONFIG_PM_SLEEP @@ -856,7 +854,7 @@ MODULE_DEVICE_TABLE(of, imx8mp_blk_ctrl_of_match); static struct platform_driver imx8mp_blk_ctrl_driver = { .probe = imx8mp_blk_ctrl_probe, - .remove = imx8mp_blk_ctrl_remove, + .remove_new = imx8mp_blk_ctrl_remove, .driver = { .name = "imx8mp-blk-ctrl", .pm = &imx8mp_blk_ctrl_pm_ops, diff --git a/drivers/pmdomain/imx/imx93-blk-ctrl.c b/drivers/pmdomain/imx/imx93-blk-ctrl.c index 40bd90f8b9..904ffa55b8 100644 --- a/drivers/pmdomain/imx/imx93-blk-ctrl.c +++ b/drivers/pmdomain/imx/imx93-blk-ctrl.c @@ -306,7 +306,7 @@ cleanup_pds: return ret; } -static int imx93_blk_ctrl_remove(struct platform_device *pdev) +static void imx93_blk_ctrl_remove(struct platform_device *pdev) { struct imx93_blk_ctrl *bc = dev_get_drvdata(&pdev->dev); int i; @@ -318,8 +318,6 @@ static int imx93_blk_ctrl_remove(struct platform_device *pdev) pm_genpd_remove(&domain->genpd); } - - return 0; } static const struct imx93_blk_ctrl_domain_data imx93_media_blk_ctl_domain_data[] = { @@ -438,7 +436,7 @@ MODULE_DEVICE_TABLE(of, imx93_blk_ctrl_of_match); static struct platform_driver imx93_blk_ctrl_driver = { .probe = imx93_blk_ctrl_probe, - .remove = imx93_blk_ctrl_remove, + .remove_new = imx93_blk_ctrl_remove, .driver = { .name = "imx93-blk-ctrl", .of_match_table = imx93_blk_ctrl_of_match, diff --git a/drivers/pmdomain/imx/imx93-pd.c b/drivers/pmdomain/imx/imx93-pd.c index b9e60d1368..1e94b499c1 100644 --- a/drivers/pmdomain/imx/imx93-pd.c +++ b/drivers/pmdomain/imx/imx93-pd.c @@ -83,7 +83,7 @@ static int imx93_pd_off(struct generic_pm_domain *genpd) return 0; }; -static int imx93_pd_remove(struct platform_device *pdev) +static void imx93_pd_remove(struct platform_device *pdev) { struct imx93_power_domain *domain = platform_get_drvdata(pdev); struct device *dev = &pdev->dev; @@ -94,8 +94,6 @@ static int imx93_pd_remove(struct platform_device *pdev) of_genpd_del_provider(np); pm_genpd_remove(&domain->genpd); - - return 0; } static int imx93_pd_probe(struct platform_device *pdev) @@ -167,7 +165,7 @@ static struct platform_driver imx93_power_domain_driver = { .of_match_table = imx93_pd_ids, }, .probe = imx93_pd_probe, - .remove = imx93_pd_remove, + .remove_new = imx93_pd_remove, }; module_platform_driver(imx93_power_domain_driver); |