summaryrefslogtreecommitdiff
path: root/drivers/staging/board
diff options
context:
space:
mode:
authorJon Hunter <jonathanh@nvidia.com>2016-09-12 12:01:07 +0100
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2016-09-13 02:49:33 +0200
commit3468c9d9ef5cc0f5375b7bc0b2ab360b559fc1a9 (patch)
treec66f3d64a82a886ddca64981e193a459dc3dbdc9 /drivers/staging/board
parent8d68c3713aa6dcf4f65f7fa8f0b6f692ace18d07 (diff)
staging: board: Remove calls to of_genpd_get_from_provider()
Update the staging/board PM domain code to use the of_genpd_add_subdomain() and remove any calls to of_genpd_get_from_provider(). Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Acked-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'drivers/staging/board')
-rw-r--r--drivers/staging/board/board.c9
1 files changed, 1 insertions, 8 deletions
diff --git a/drivers/staging/board/board.c b/drivers/staging/board/board.c
index 45807d8287d1..86dc41101610 100644
--- a/drivers/staging/board/board.c
+++ b/drivers/staging/board/board.c
@@ -140,7 +140,6 @@ static int board_staging_add_dev_domain(struct platform_device *pdev,
const char *domain)
{
struct of_phandle_args pd_args;
- struct generic_pm_domain *pd;
struct device_node *np;
np = of_find_node_by_path(domain);
@@ -151,14 +150,8 @@ static int board_staging_add_dev_domain(struct platform_device *pdev,
pd_args.np = np;
pd_args.args_count = 0;
- pd = of_genpd_get_from_provider(&pd_args);
- if (IS_ERR(pd)) {
- pr_err("Cannot find genpd %s (%ld)\n", domain, PTR_ERR(pd));
- return PTR_ERR(pd);
- }
- pr_debug("Found genpd %s for device %s\n", pd->name, pdev->name);
- return pm_genpd_add_device(pd, &pdev->dev);
+ return of_genpd_add_device(&pd_args, &pdev->dev);
}
#else
static inline int board_staging_add_dev_domain(struct platform_device *pdev,