diff options
author | Liu Shixin <liushixin2@huawei.com> | 2020-09-19 12:08:50 +0200 |
---|---|---|
committer | Qiang Yu <yuq825@gmail.com> | 2020-11-16 01:20:10 +0100 |
commit | 8f9d7ef38cfa46a7a8e5d079fe817802843ce0f6 (patch) | |
tree | 0e9c41b970d538b2ca7ce01708a31c072df55449 /drivers | |
parent | drm/panel: s6e63m0: Set up some display info (diff) | |
download | linux-8f9d7ef38cfa46a7a8e5d079fe817802843ce0f6.tar.xz linux-8f9d7ef38cfa46a7a8e5d079fe817802843ce0f6.zip |
drm/lima: simplify the return expression of lima_devfreq_target
Simplify the return expression.
Signed-off-by: Liu Shixin <liushixin2@huawei.com>
Signed-off-by: Qiang Yu <yuq825@gmail.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20200919100850.1639111-1-liushixin2@huawei.com
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/gpu/drm/lima/lima_devfreq.c | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/drivers/gpu/drm/lima/lima_devfreq.c b/drivers/gpu/drm/lima/lima_devfreq.c index bbe02817721b..5914442936ed 100644 --- a/drivers/gpu/drm/lima/lima_devfreq.c +++ b/drivers/gpu/drm/lima/lima_devfreq.c @@ -35,18 +35,13 @@ static int lima_devfreq_target(struct device *dev, unsigned long *freq, u32 flags) { struct dev_pm_opp *opp; - int err; opp = devfreq_recommended_opp(dev, freq, flags); if (IS_ERR(opp)) return PTR_ERR(opp); dev_pm_opp_put(opp); - err = dev_pm_opp_set_rate(dev, *freq); - if (err) - return err; - - return 0; + return dev_pm_opp_set_rate(dev, *freq); } static void lima_devfreq_reset(struct lima_devfreq *devfreq) |