From: Dave Airlie Date: Fri, 5 May 2017 01:47:01 +0000 (+1000) Subject: Merge tag 'drm/tegra/for-4.12-rc1' of git://anongit.freedesktop.org/tegra/linux into... X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=644b4930bf7e2adeffbe842e1097f7933c6a9158;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git Merge tag 'drm/tegra/for-4.12-rc1' of git://anongit.freedesktop.org/tegra/linux into drm-next drm/tegra: Changes for v4.12-rc1 This contains various fixes to the host1x driver as well as a plug for a leak of kernel pointers to userspace. A fairly big addition this time around is the Video Image Composer (VIC) support that can be used to accelerate some 2D and image compositing operations. Furthermore the driver now supports FB modifiers, so we no longer rely on a custom IOCTL to set those. Finally this contains a few preparatory patches for Tegra186 support which unfortunately didn't quite make it this time, but will hopefully be ready for v4.13. * tag 'drm/tegra/for-4.12-rc1' of git://anongit.freedesktop.org/tegra/linux: gpu: host1x: Fix host1x driver shutdown gpu: host1x: Support module reset gpu: host1x: Sort includes alphabetically drm/tegra: Add VIC support dt-bindings: Add bindings for the Tegra VIC drm/tegra: Add falcon helper library drm/tegra: Add Tegra DRM allocation API drm/tegra: Add tiling FB modifiers drm/tegra: Don't leak kernel pointer to userspace drm/tegra: Protect IOMMU operations by mutex drm/tegra: Enable IOVA API when IOMMU support is enabled gpu: host1x: Add IOMMU support gpu: host1x: Fix potential out-of-bounds access iommu/iova: Fix compile error with CONFIG_IOMMU_IOVA=m iommu: Add dummy implementations for !IOMMU_IOVA MAINTAINERS: Add related headers to IOMMU section iommu/iova: Consolidate code for adding new node to iovad domain rbtree --- 644b4930bf7e2adeffbe842e1097f7933c6a9158 diff --cc drivers/gpu/drm/tegra/drm.c index dba4e090d3df,bbce47dc79e6..9a1e34e48f64 --- a/drivers/gpu/drm/tegra/drm.c +++ b/drivers/gpu/drm/tegra/drm.c @@@ -804,6 -883,49 +883,15 @@@ static const struct file_operations teg .llseek = noop_llseek, }; -static u32 tegra_drm_get_vblank_counter(struct drm_device *drm, - unsigned int pipe) -{ - struct drm_crtc *crtc = drm_crtc_from_index(drm, pipe); - struct tegra_dc *dc = to_tegra_dc(crtc); - - if (!crtc) - return 0; - - return tegra_dc_get_vblank_counter(dc); -} - -static int tegra_drm_enable_vblank(struct drm_device *drm, unsigned int pipe) -{ - struct drm_crtc *crtc = drm_crtc_from_index(drm, pipe); - struct tegra_dc *dc = to_tegra_dc(crtc); - - if (!crtc) - return -ENODEV; - - tegra_dc_enable_vblank(dc); - - return 0; -} - -static void tegra_drm_disable_vblank(struct drm_device *drm, unsigned int pipe) -{ - struct drm_crtc *crtc = drm_crtc_from_index(drm, pipe); - struct tegra_dc *dc = to_tegra_dc(crtc); - - if (crtc) - tegra_dc_disable_vblank(dc); -} - + static int tegra_drm_context_cleanup(int id, void *p, void *data) + { + struct tegra_drm_context *context = p; + + tegra_drm_context_free(context); + + return 0; + } + static void tegra_drm_preclose(struct drm_device *drm, struct drm_file *file) { struct tegra_drm_file *fpriv = file->driver_priv;