drm/vc4: Correct DSI divider calculations
authorDave Stevenson <dave.stevenson@raspberrypi.com>
Fri, 18 Jun 2021 20:52:28 +0000 (21:52 +0100)
committerDom Cobley <popcornmix@gmail.com>
Mon, 21 Mar 2022 16:04:21 +0000 (16:04 +0000)
commit5a7c189e5f2fa37df21a3a3ca166cf2b91700983
tree35cea40ace3947d150e4cb7a2546b15dec0e14f4
parenta23acf4b3d6e2965c2636b589455a52e84cc56be
drm/vc4: Correct DSI divider calculations

The divider calculations tried to find the divider
just faster than the clock requested. However if
it required a divider of 7 then the for loop
aborted without handling the "error" case, and could
end up with a clock lower than requested.

Correct the loop so that we always have a clock greater
than requested.

Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com>
drivers/gpu/drm/vc4/vc4_dsi.c