OpenCloudOS-Kernel/drivers/gpu/drm/rockchip
John Keeping b0a45fec59 drm/rockchip: dw-mipi-dsi: improve PLL configuration
The multiplication ratio for the PLL is required to be even due to the
use of a "by 2 pre-scaler".  Currently we are likely to end up with an
odd multiplier even though there is an equivalent set of parameters with
an even multiplier.

For example, using the 324MHz bit rate with a reference clock of 24MHz
we end up with M = 27, N = 2 whereas the example in the PHY databook
gives M = 54, N = 4 for this bit rate and reference clock.

By walking down through the available multiplier instead of up we are
more likely to hit an even multiplier.  With the above example we do now
get M = 54, N = 4 as given by the databook.

While doing this, change the loop limits to encode the actual limits on
the divisor, which are:

	40MHz >= (pllref / N) >= 5MHz

Signed-off-by: John Keeping <john@metanate.com>
Reviewed-by: Sean Paul <seanpaul@chromium.org>
Signed-off-by: Sean Paul <seanpaul@chromium.org>
Link: http://patchwork.freedesktop.org/patch/msgid/20170224125506.21533-18-john@metanate.com
2017-03-01 14:48:56 -05:00
..
Kconfig drm/rockchip: cdn-dp: add cdn DP support for rk3399 2017-02-05 16:29:29 +08:00
Makefile drm/rockchip: cdn-dp: add cdn DP support for rk3399 2017-02-05 16:29:29 +08:00
analogix_dp-rockchip.c drm/rockchip: analogix_dp: Refuse to enable PSR if panel doesn't support it 2016-10-04 08:23:17 +02:00
cdn-dp-core.c drm/rockchip: cdn-dp: don't configure hardware in mode_set 2017-02-05 16:30:11 +08:00
cdn-dp-core.h drm/rockchip: cdn-dp: retry to check sink count 2017-02-05 16:30:04 +08:00
cdn-dp-reg.c drm/rockchip: cdn-dp: fix cdn-dp complie warning 2017-02-07 11:06:01 +08:00
cdn-dp-reg.h drm/rockchip: cdn-dp: add cdn DP support for rk3399 2017-02-05 16:29:29 +08:00
dw-mipi-dsi.c drm/rockchip: dw-mipi-dsi: improve PLL configuration 2017-03-01 14:48:56 -05:00
dw_hdmi-rockchip.c drm: bridge: dw-hdmi: Move IRQ and IO resource allocation to common code 2017-01-18 09:29:32 +05:30
inno_hdmi.c drm: rockchip: Rely on the default ->best_encoder() behavior 2016-06-10 17:24:37 +02:00
inno_hdmi.h drm/rockchip: hdmi: add Innosilicon HDMI support 2016-02-18 13:56:43 +08:00
rockchip_drm_drv.c Merge airlied/drm-next into drm-misc-next 2017-02-26 21:34:42 +01:00
rockchip_drm_drv.h Merge airlied/drm-next into drm-misc-next 2017-02-26 21:34:42 +01:00
rockchip_drm_fb.c Merge airlied/drm-next into drm-misc-next 2017-02-26 21:34:42 +01:00
rockchip_drm_fb.h drm: Pass the user drm_mode_fb_cmd2 as const to .fb_create() 2015-11-24 11:47:38 +01:00
rockchip_drm_fbdev.c drm/fb-helper: Automatically clean up fb_info 2017-02-07 21:36:28 +01:00
rockchip_drm_fbdev.h drm/rockchip: respect CONFIG_DRM_FBDEV_EMULATION 2016-01-22 08:45:31 +08:00
rockchip_drm_gem.c drm/rockchip: Do not use DMA mapping API if attached to IOMMU domain 2017-02-15 08:52:13 +08:00
rockchip_drm_gem.h drm/rockchip: Do not use DMA mapping API if attached to IOMMU domain 2017-02-15 08:52:13 +08:00
rockchip_drm_psr.c drm/rockchip: Fix up bug in psr state machine 2016-09-21 06:55:49 -07:00
rockchip_drm_psr.h drm/rockchip: Don't key off vblank for psr 2016-09-21 06:55:47 -07:00
rockchip_drm_vop.c Merge airlied/drm-next into drm-misc-next 2017-02-26 21:34:42 +01:00
rockchip_drm_vop.h drm/rockchip: cdn-dp: add cdn DP support for rk3399 2017-02-05 16:29:29 +08:00
rockchip_vop_reg.c drm/rockchip: cdn-dp: add cdn DP support for rk3399 2017-02-05 16:29:29 +08:00
rockchip_vop_reg.h drm/rockchip: vop: add rk3399 vop support 2016-08-23 11:44:29 -04:00