diff options
author | Archit Taneja <architt@codeaurora.org> | 2017-07-28 06:47:00 -0400 |
---|---|---|
committer | Rob Clark <robdclark@gmail.com> | 2017-08-01 18:50:00 -0400 |
commit | d0538f5048fafe5633c58f25c3332f67739cdeb4 (patch) | |
tree | 3d399f7afc993b10d59bef1115d1772d0980df4f | |
parent | b0e77fd87cf302351e537881c8daf8d1c69cf541 (diff) |
drm/msm/mdp5: Drop clock names with "_clk" suffix
We have upstream bindings (msm8916) that have the "_clk" suffix in the
clock names. The downstream bindings also require it.
We want to drop the "_clk" suffix and at the same time support existing
bindings. Update the MDP5 code with the the msm_clk_get() helper to
support both old and new clock names.
Signed-off-by: Archit Taneja <architt@codeaurora.org>
Signed-off-by: Rob Clark <robdclark@gmail.com>
-rw-r--r-- | drivers/gpu/drm/msm/mdp/mdp5/mdp5_kms.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/drivers/gpu/drm/msm/mdp/mdp5/mdp5_kms.c b/drivers/gpu/drm/msm/mdp/mdp5/mdp5_kms.c index 5d13fa5381ee..1c603aef3c59 100644 --- a/drivers/gpu/drm/msm/mdp/mdp5/mdp5_kms.c +++ b/drivers/gpu/drm/msm/mdp/mdp5/mdp5_kms.c | |||
@@ -502,7 +502,7 @@ static int get_clk(struct platform_device *pdev, struct clk **clkp, | |||
502 | const char *name, bool mandatory) | 502 | const char *name, bool mandatory) |
503 | { | 503 | { |
504 | struct device *dev = &pdev->dev; | 504 | struct device *dev = &pdev->dev; |
505 | struct clk *clk = devm_clk_get(dev, name); | 505 | struct clk *clk = msm_clk_get(pdev, name); |
506 | if (IS_ERR(clk) && mandatory) { | 506 | if (IS_ERR(clk) && mandatory) { |
507 | dev_err(dev, "failed to get %s (%ld)\n", name, PTR_ERR(clk)); | 507 | dev_err(dev, "failed to get %s (%ld)\n", name, PTR_ERR(clk)); |
508 | return PTR_ERR(clk); | 508 | return PTR_ERR(clk); |
@@ -887,21 +887,21 @@ static int mdp5_init(struct platform_device *pdev, struct drm_device *dev) | |||
887 | } | 887 | } |
888 | 888 | ||
889 | /* mandatory clocks: */ | 889 | /* mandatory clocks: */ |
890 | ret = get_clk(pdev, &mdp5_kms->axi_clk, "bus_clk", true); | 890 | ret = get_clk(pdev, &mdp5_kms->axi_clk, "bus", true); |
891 | if (ret) | 891 | if (ret) |
892 | goto fail; | 892 | goto fail; |
893 | ret = get_clk(pdev, &mdp5_kms->ahb_clk, "iface_clk", true); | 893 | ret = get_clk(pdev, &mdp5_kms->ahb_clk, "iface", true); |
894 | if (ret) | 894 | if (ret) |
895 | goto fail; | 895 | goto fail; |
896 | ret = get_clk(pdev, &mdp5_kms->core_clk, "core_clk", true); | 896 | ret = get_clk(pdev, &mdp5_kms->core_clk, "core", true); |
897 | if (ret) | 897 | if (ret) |
898 | goto fail; | 898 | goto fail; |
899 | ret = get_clk(pdev, &mdp5_kms->vsync_clk, "vsync_clk", true); | 899 | ret = get_clk(pdev, &mdp5_kms->vsync_clk, "vsync", true); |
900 | if (ret) | 900 | if (ret) |
901 | goto fail; | 901 | goto fail; |
902 | 902 | ||
903 | /* optional clocks: */ | 903 | /* optional clocks: */ |
904 | get_clk(pdev, &mdp5_kms->lut_clk, "lut_clk", false); | 904 | get_clk(pdev, &mdp5_kms->lut_clk, "lut", false); |
905 | 905 | ||
906 | /* we need to set a default rate before enabling. Set a safe | 906 | /* we need to set a default rate before enabling. Set a safe |
907 | * rate first, then figure out hw revision, and then set a | 907 | * rate first, then figure out hw revision, and then set a |