]> git.baikalelectronics.ru Git - kernel.git/commit
drm/sun4i: request exact rates to our parents
authorMaxime Ripard <maxime.ripard@free-electrons.com>
Sat, 2 Apr 2016 10:30:11 +0000 (12:30 +0200)
committerMaxime Ripard <maxime.ripard@free-electrons.com>
Mon, 30 May 2016 06:28:33 +0000 (08:28 +0200)
commitf69437fc6abbbfd1d7e5b0c61d8a11065789a9cb
tree4c83197a5bfba781e0246a27efc505888127c79a
parentc573480ec2b1d8b6fe52fd09637c27e7740b10a6
drm/sun4i: request exact rates to our parents

Our pixel clock currently only tries to deal with the current parent rate.

While that works when the resolution is the same than the one already
program, or when we can compute directly the rate from the current parent
rate, it cannot work in most situation when we want to change the
frequency, and we end up with an improper pixel clock rate, which obviously
doesn't work as expected.

Ask our parent for all the possible dividers if it can reach that
frequency, and return the best parent rate to the clock framework so that
we can use it.

Fixes: 19f0a1ddb467 ("drm: Add Allwinner A10 Display Engine support")
Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
drivers/gpu/drm/sun4i/sun4i_dotclock.c