]> git.baikalelectronics.ru Git - kernel.git/commit
drm: arcpgu: Allow some clock deviation in crtc->mode_valid() callback
authorJose Abreu <Jose.Abreu@synopsys.com>
Mon, 17 Jul 2017 12:08:27 +0000 (13:08 +0100)
committerAlexey Brodkin <abrodkin@synopsys.com>
Wed, 2 Aug 2017 21:11:02 +0000 (00:11 +0300)
commit5782966ed3eb00856fef1a84ec985c26cd41b751
treeb4a1b39199e726e9e3c74be585ffd5bb5a87af82
parent39e2b17f9951e05b82f2a01b837eecc538a0078c
drm: arcpgu: Allow some clock deviation in crtc->mode_valid() callback

Currently we expect that clock driver produces the exact same value
as we are requiring. There can, and will, be some deviation
however so we need to take that into account instead of just
rejecting the mode.

According to the HDMI spec we have a max of +-0.5% for the pixel clock
frequency deviation. Lets take that into an advantage and use it to
calculate how much deviation we can support.

Signed-off-by: Jose Abreu <joabreu@synopsys.com>
Acked-by: Alexey Brodkin <abrodkin@synopsys.com>
Cc: Carlos Palminha <palminha@synopsys.com>
Cc: Alexey Brodkin <abrodkin@synopsys.com>
Cc: Daniel Vetter <daniel.vetter@intel.com>
Cc: Dave Airlie <airlied@gmail.com>
Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
drivers/gpu/drm/arc/arcpgu_crtc.c