OpenCloudOS-Kernel/drivers/gpu/drm
Mario Kleiner 73d4c23f53 drm/radeon: Slightly more robust flip completion handling for < DCE-4
Pre DCE4 hardware doesn't have (reliable) pageflip completion
irqs, therefore we have to use the old polling method for flip
completion handling in vblank irq.

As vblank irqs fire a bit before start of vblank (when the
linebuffer fifo read position reaches end of scanout), we
have some fudge for flip completion handling in the last
lines of active scanout. Old code assumed the threshold to
be 99% of active scanout height, a ballpark estimate which
worked ok. Since we know since a while how to calculate the
actual threshold from linebuffer size, lets make use of it
to get a more accurate threshold.

This completion path is still prone to some races in corner
cases, especially on pre-AVIVO hardware, so document them
a bit better in the code comments.

Acked-by: Michel Dänzer <michel.daenzer@amd.com>
Signed-off-by: Mario Kleiner <mario.kleiner.de@gmail.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2016-10-04 11:15:58 -04:00
..
amd Merge branch 'drm-next-4.9' of git://people.freedesktop.org/~agd5f/linux into drm-next 2016-09-30 13:21:02 +10:00
arc drm: Don't swallow error codes in drm_dev_alloc() 2016-09-22 04:03:48 -07:00
arm drm: Don't swallow error codes in drm_dev_alloc() 2016-09-22 04:03:48 -07:00
armada drm: drop DRIVER_HAVE_IRQ flag for some drivers 2016-08-16 14:07:43 +02:00
ast drm: use drm_file to tag vm-bos 2016-09-19 11:22:08 +02:00
atmel-hlcdc Linux 4.8-rc8 2016-09-28 12:08:49 +10:00
bochs bugfixes for qemu (bochs, qxl and virtio-gpu) drm drivers 2016-09-28 13:23:07 +10:00
bridge Merge tag 'topic/drm-misc-2016-09-25' of git://anongit.freedesktop.org/drm-intel into drm-next 2016-09-28 10:28:23 +10:00
cirrus drm: use drm_file to tag vm-bos 2016-09-19 11:22:08 +02:00
etnaviv Merge branch 'drm-etnaviv-next' of git://git.pengutronix.de/git/lst/linux into drm-next 2016-09-28 11:24:05 +10:00
exynos drm/exynos: g2d: simplify g2d_free_runqueue_node() 2016-10-01 00:39:42 +09:00
fsl-dcu Merge tag 'topic/drm-misc-2016-09-25' of git://anongit.freedesktop.org/drm-intel into drm-next 2016-09-28 10:28:23 +10:00
gma500 drm/gma500: remove unnecessary config_enabled() guard 2016-08-24 07:43:42 +02:00
hisilicon drm: Don't swallow error codes in drm_dev_alloc() 2016-09-22 04:03:48 -07:00
i2c Revert "drm/i2c: tda998x: don't register the connector" 2016-09-23 03:29:50 -07:00
i810 drm: Mark up legacy/dri1 drivers with DRM_LEGACY 2016-08-08 10:05:22 +02:00
i915 Linux 4.8-rc8 2016-09-28 12:08:49 +10:00
imx Linux 4.8-rc8 2016-09-28 12:08:49 +10:00
mediatek Linux 4.8-rc8 2016-09-28 12:08:49 +10:00
mga drm: Mark up legacy/dri1 drivers with DRM_LEGACY 2016-08-08 10:05:22 +02:00
mgag200 drm: use drm_file to tag vm-bos 2016-09-19 11:22:08 +02:00
msm Linux 4.8-rc8 2016-09-28 12:08:49 +10:00
nouveau Linux 4.8-rc8 2016-09-28 12:08:49 +10:00
omapdrm drm/atomic-helper: Add NO_DISABLE_AFTER_MODESET flag support for plane commit 2016-08-29 11:29:37 +02:00
panel drm/panel: Add JDI LT070ME05000 WUXGA DSI Panel 2016-09-16 17:32:48 +02:00
qxl bugfixes for qemu (bochs, qxl and virtio-gpu) drm drivers 2016-09-28 13:23:07 +10:00
r128 drm: Mark up legacy/dri1 drivers with DRM_LEGACY 2016-08-08 10:05:22 +02:00
radeon drm/radeon: Slightly more robust flip completion handling for < DCE-4 2016-10-04 11:15:58 -04:00
rcar-du drm: Don't swallow error codes in drm_dev_alloc() 2016-09-22 04:03:48 -07:00
rockchip Merge branch 'for-next' of ssh://people.freedesktop.org/~seanpaul/dogwood into drm-next 2016-09-28 11:22:27 +10:00
savage GPU-DRM-Savage: Use memdup_user() rather than duplicating 2016-08-19 10:58:55 +02:00
shmobile drm/shmobile: make fbdev support really optional 2016-07-18 09:11:37 +02:00
sis drm: Mark up legacy/dri1 drivers with DRM_LEGACY 2016-08-08 10:05:22 +02:00
sti Merge branch 'sti-drm-next-2016-09-20' of https://github.com/vinceab/linux into drm-next 2016-09-28 11:14:58 +10:00
sun4i Allwinner sun4i DRM fixes for 4.9 2016-09-28 11:23:15 +10:00
tdfx drm: Mark up legacy/dri1 drivers with DRM_LEGACY 2016-08-08 10:05:22 +02:00
tegra drm/tegra: Changes for v4.9-rc1 2016-09-30 13:00:36 +10:00
tilcdc Second attempt for 3rd drm/tilcdc pull request for v4.9. 2016-09-28 11:17:26 +10:00
ttm drm/ttm: remove cpu_address member from ttm_tt 2016-09-16 15:53:05 -04:00
udl drm: Don't swallow error codes in drm_dev_alloc() 2016-09-22 04:03:48 -07:00
vc4 Linux 4.8-rc8 2016-09-28 12:08:49 +10:00
vgem drm: Don't swallow error codes in drm_dev_alloc() 2016-09-22 04:03:48 -07:00
via drm: Mark up legacy/dri1 drivers with DRM_LEGACY 2016-08-08 10:05:22 +02:00
virtio drm: virtio: reinstate drm_virtio_set_busid() 2016-10-04 13:10:30 +10:00
vmwgfx Merge branch 'drm-next-4.9' of git://people.freedesktop.org/~agd5f/linux into drm-next 2016-09-20 06:17:38 +10:00
Kconfig Revert "drm: make DRI1 drivers depend on BROKEN" 2016-09-01 06:16:12 +10:00
Makefile drm: Extract drm_color_mgmt.[hc] 2016-09-22 00:04:02 -07:00
ati_pcigart.c
drm_agpsupport.c drm: Used DRM_LEGACY for all legacy functions 2016-08-08 10:05:23 +02:00
drm_atomic.c Linux 4.8-rc8 2016-09-28 12:08:49 +10:00
drm_atomic_helper.c drm/atomic-helper: Fix sparse warnings 2016-09-19 16:44:36 +02:00
drm_auth.c drm: Used DRM_LEGACY for all legacy functions 2016-08-08 10:05:23 +02:00
drm_blend.c drm/doc: Polish plane composition property docs 2016-09-22 00:04:02 -07:00
drm_bridge.c drm: Extract drm_bridge.h 2016-09-19 15:04:15 +02:00
drm_bufs.c GPU-DRM: Replace a kzalloc() call by kcalloc() in drm_legacy_addbufs_sg() 2016-09-21 13:24:27 +02:00
drm_cache.c
drm_color_mgmt.c drm/doc: Document color space handling 2016-09-22 00:04:03 -07:00
drm_connector.c drm: document drm_display_info 2016-08-16 18:49:47 +02:00
drm_context.c drm: Used DRM_LEGACY for all legacy functions 2016-08-08 10:05:23 +02:00
drm_crtc.c drm: Extract drm_color_mgmt.[hc] 2016-09-22 00:04:02 -07:00
drm_crtc_helper.c drm/kms-helpers: Extract drm_modeset_helper.[hc] 2016-08-16 16:10:19 +02:00
drm_crtc_helper_internal.h drm/fb-helper: Fix sparse warnings 2016-09-19 16:45:15 +02:00
drm_crtc_internal.h drm: Extract drm_color_mgmt.[hc] 2016-09-22 00:04:02 -07:00
drm_debugfs.c
drm_dma.c drm: Used DRM_LEGACY for all legacy functions 2016-08-08 10:05:23 +02:00
drm_dp_aux_dev.c drm: Don't export dp-aux devnode functions 2016-08-16 18:49:26 +02:00
drm_dp_dual_mode_helper.c
drm_dp_helper.c Merge tag 'topic/drm-misc-2016-09-25' of git://anongit.freedesktop.org/drm-intel into drm-next 2016-09-28 10:28:23 +10:00
drm_dp_mst_topology.c drm/dp-mst: Missing kernel doc 2016-07-19 10:31:53 +02:00
drm_drv.c drm: Don't swallow error codes in drm_dev_alloc() 2016-09-22 04:03:48 -07:00
drm_edid.c drm/edid: CEA mode 64 1080p100 vsync pulse width incorrect 2016-08-18 09:37:10 -07:00
drm_edid_load.c
drm_encoder.c drm: Fix typo in encoder docs 2016-09-21 13:33:50 +02:00
drm_encoder_slave.c
drm_fb_cma_helper.c
drm_fb_helper.c Linux 4.8-rc8 2016-09-28 12:08:49 +10:00
drm_flip_work.c
drm_fops.c drm: remove redundant drm_file->uid 2016-09-19 11:21:42 +02:00
drm_fourcc.c drm: move drm_mode_legacy_fb_format to drm_fourcc.c 2016-08-29 15:37:28 +02:00
drm_framebuffer.c drm: Extract drm_plane.[hc] 2016-09-22 00:01:56 -07:00
drm_gem.c drm: use drm_file to tag vm-bos 2016-09-19 11:22:08 +02:00
drm_gem_cma_helper.c
drm_global.c drm: modify drm_global_item_ref to avoid two times of writing ref->object 2016-09-14 15:10:29 -04:00
drm_hashtab.c drm: fix signed integer overflow 2016-09-06 13:56:41 -04:00
drm_info.c drm: remove redundant drm_file->uid 2016-09-19 11:21:42 +02:00
drm_internal.h drm: drop obsolete drm_core.h 2016-09-19 13:57:38 +02:00
drm_ioc32.c drm: drop obsolete drm_core.h 2016-09-19 13:57:38 +02:00
drm_ioctl.c drm: drop obsolete drm_core.h 2016-09-19 13:57:38 +02:00
drm_irq.c drm/doc: Fix more kerneldoc/sphinx warnings 2016-08-16 16:09:58 +02:00
drm_kms_helper_common.c drm: Don't export dp-aux devnode functions 2016-08-16 18:49:26 +02:00
drm_legacy.h
drm_lock.c drm: Used DRM_LEGACY for all legacy functions 2016-08-08 10:05:23 +02:00
drm_memory.c
drm_mipi_dsi.c drm/dsi: Implement DCS set/get display brightness 2016-08-24 13:34:00 +02:00
drm_mm.c drm: Declare that create drm_mm nodes with size 0 is illegal 2016-08-08 10:05:21 +02:00
drm_mode_object.c drm: Move property validation to a helper, v2. 2016-09-12 10:32:49 -04:00
drm_modes.c drm: update kerneldoc for changes introduced by commits "16fadc2568e9" and "9671e228fb78" 2016-08-16 17:32:08 +02:00
drm_modeset_helper.c drm/kms-helpers: Extract drm_modeset_helper.[hc] 2016-08-16 16:10:19 +02:00
drm_modeset_lock.c
drm_of.c
drm_panel.c
drm_pci.c drm: Don't swallow error codes in drm_dev_alloc() 2016-09-22 04:03:48 -07:00
drm_plane.c drm: Undo damage to page_flip_ioctl 2016-10-04 12:53:12 +10:00
drm_plane_helper.c drm: Fix kerneldoc in drm_plane_helper.c 2016-08-16 18:50:04 +02:00
drm_platform.c drm: Don't swallow error codes in drm_dev_alloc() 2016-09-22 04:03:48 -07:00
drm_prime.c
drm_probe_helper.c drm: drm_probe_helper: Fix output_poll_work scheduling 2016-08-31 13:23:30 +02:00
drm_property.c Revert "drm: Unify handling of blob and object properties" 2016-09-07 13:24:22 +03:00
drm_rect.c drm: Warn about negative sizes when calculating scale factor 2016-08-08 14:17:56 -04:00
drm_scatter.c drm: Used DRM_LEGACY for all legacy functions 2016-08-08 10:05:23 +02:00
drm_simple_kms_helper.c drm: simple_kms_helper: add support for bridges 2016-08-29 09:15:37 +05:30
drm_sysfs.c drm: drop obsolete drm_core.h 2016-09-19 13:57:38 +02:00
drm_trace.h
drm_trace_points.c
drm_vm.c
drm_vma_manager.c drm: use drm_file to tag vm-bos 2016-09-19 11:22:08 +02:00