From: Maxime Ripard Date: Fri, 15 Apr 2022 13:26:07 +0000 (+0200) Subject: rpivid: Use clk_get_max_rate() X-Git-Tag: accepted/tizen/unified/20230118.172025~640 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=ba69dce89d41b0e8c38dbfd70ee34b66443635e5;p=platform%2Fkernel%2Flinux-rpi.git rpivid: Use clk_get_max_rate() The driver was using clk_round_rate() to figure out the maximum clock rate that was allowed for the HEVC clock. Since we have a function to return it directly now, let's use it. Signed-off-by: Maxime Ripard --- diff --git a/drivers/staging/media/rpivid/rpivid_video.c b/drivers/staging/media/rpivid/rpivid_video.c index 8007c4d..bab3ed3 100644 --- a/drivers/staging/media/rpivid/rpivid_video.c +++ b/drivers/staging/media/rpivid/rpivid_video.c @@ -558,7 +558,7 @@ static int start_clock(struct rpivid_dev *dev, struct rpivid_ctx *ctx) long max_hevc_clock; int rv; - max_hevc_clock = clk_round_rate(dev->clock, ULONG_MAX); + max_hevc_clock = clk_get_max_rate(dev->clock); rv = clk_set_min_rate(dev->clock, max_hevc_clock); if (rv) {