]> git.baikalelectronics.ru Git - kernel.git/commit
drm/stm: ltdc: add mode_valid()
authorPhilippe CORNU <philippe.cornu@st.com>
Tue, 17 Apr 2018 11:40:26 +0000 (13:40 +0200)
committerPhilippe Cornu <philippe.cornu@st.com>
Fri, 27 Apr 2018 08:58:06 +0000 (10:58 +0200)
commitf2f73e31429f6424674cc0e5309bb122350f0bed
tree4814e894220e54da2e3e13a9bab0b5a4d0b0554d
parentf98614368ca61632ca94675077f148fd8f934262
drm/stm: ltdc: add mode_valid()

Add mode_valid() function to filter modes according to available
pll clock values and "preferred" modes. It is particularly
useful for hdmi modes that require precise pixel clocks.

Note that "preferred" modes are always accepted:
- this is important for panels because panel clock tolerances are
  bigger than hdmi ones and there is no reason to not accept them
  (the fps may vary a little but it is not a problem).
- the hdmi preferred mode will be accepted too, but userland will
  be able to use others hdmi "valid" modes if necessary.

Signed-off-by: Philippe Cornu <philippe.cornu@st.com>
Reviewed-by: Yannick Fertré <yannick.fertre@st.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20180417114026.8709-1-philippe.cornu@st.com
drivers/gpu/drm/stm/ltdc.c