From: Dave Airlie Date: Mon, 9 May 2016 03:49:56 +0000 (+1000) Subject: Merge tag 'v4.6-rc7' into drm-next X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=bafb86f5bc3173479002555dea7f31d943b12332;p=linux-beck.git Merge tag 'v4.6-rc7' into drm-next Merge this back as we've built up a fair few conflicts, and I have some newer trees to pull in. --- bafb86f5bc3173479002555dea7f31d943b12332 diff --cc MAINTAINERS index 33181d862e5a,a727d9959ecd..b81c71902079 --- a/MAINTAINERS +++ b/MAINTAINERS @@@ -3975,18 -3879,9 +3975,18 @@@ S: Maintaine F: drivers/gpu/drm/sti F: Documentation/devicetree/bindings/display/st,stih4xx.txt +DRM DRIVER FOR TDFX VIDEO CARDS +S: Orphan / Obsolete +F: drivers/gpu/drm/tdfx/ + +DRM DRIVER FOR USB DISPLAYLINK VIDEO ADAPTERS +M: Dave Airlie +S: Odd Fixes +F: drivers/gpu/drm/udl/ + DRM DRIVERS FOR VIVANTE GPU IP M: Lucas Stach - R: Russell King + R: Russell King R: Christian Gmeiner L: dri-devel@lists.freedesktop.org S: Maintained @@@ -7030,11 -6905,9 +7030,11 @@@ L: linux-man@vger.kernel.or S: Maintained MARVELL ARMADA DRM SUPPORT - M: Russell King + M: Russell King S: Maintained F: drivers/gpu/drm/armada/ +F: include/uapi/drm/armada_drm.h +F: Documentation/devicetree/bindings/display/armada/ MARVELL 88E6352 DSA support M: Guenter Roeck diff --cc drivers/gpu/drm/amd/amdgpu/amdgpu.h index 1012bd3f3482,1bcbade479dc..113fd4bf9b64 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu.h +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu.h @@@ -1639,8 -1591,8 +1639,9 @@@ struct amdgpu_uvd struct amdgpu_bo *vcpu_bo; void *cpu_addr; uint64_t gpu_addr; + unsigned fw_version; void *saved_bo; + unsigned max_handles; atomic_t handles[AMDGPU_MAX_UVD_HANDLES]; struct drm_file *filp[AMDGPU_MAX_UVD_HANDLES]; struct delayed_work idle_work; diff --cc drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c index db86012deb67,871018c634e0..abda242980ba --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c @@@ -171,19 -158,11 +171,22 @@@ int amdgpu_uvd_sw_init(struct amdgpu_de DRM_INFO("Found UVD firmware Version: %hu.%hu Family ID: %hu\n", version_major, version_minor, family_id); + /* + * Limit the number of UVD handles depending on microcode major + * and minor versions. The firmware version which has 40 UVD + * instances support is 1.80. So all subsequent versions should + * also have the same support. + */ + if ((version_major > 0x01) || + ((version_major == 0x01) && (version_minor >= 0x50))) + adev->uvd.max_handles = AMDGPU_MAX_UVD_HANDLES; + + adev->uvd.fw_version = ((version_major << 24) | (version_minor << 16) | + (family_id << 8)); + bo_size = AMDGPU_GPU_PAGE_ALIGN(le32_to_cpu(hdr->ucode_size_bytes) + 8) - + AMDGPU_UVD_STACK_SIZE + AMDGPU_UVD_HEAP_SIZE; + + AMDGPU_UVD_STACK_SIZE + AMDGPU_UVD_HEAP_SIZE + + AMDGPU_UVD_SESSION_SIZE * adev->uvd.max_handles; r = amdgpu_bo_create(adev, bo_size, PAGE_SIZE, true, AMDGPU_GEM_DOMAIN_VRAM, AMDGPU_GEM_CREATE_CPU_ACCESS_REQUIRED, diff --cc drivers/gpu/drm/exynos/exynos_drm_fimd.c index 547d759a0a6f,018449f8d557..cec508f9a335 --- a/drivers/gpu/drm/exynos/exynos_drm_fimd.c +++ b/drivers/gpu/drm/exynos/exynos_drm_fimd.c @@@ -919,12 -878,21 +919,11 @@@ out drm_crtc_handle_vblank(&ctx->crtc->base); } -static void fimd_dp_clock_enable(struct exynos_drm_crtc *crtc, bool enable) +static void fimd_dp_clock_enable(struct exynos_drm_clk *clk, bool enable) { - struct fimd_context *ctx = crtc->ctx; - u32 val; - - /* - * Only Exynos 5250, 5260, 5410 and 542x requires enabling DP/MIE - * clock. On these SoCs the bootloader may enable it but any - * power domain off/on will reset it to disable state. - */ - if (ctx->driver_data != &exynos5_fimd_driver_data && - ctx->driver_data != &exynos5420_fimd_driver_data) - return; - - val = enable ? DP_MIE_CLK_DP_ENABLE : DP_MIE_CLK_DISABLE; + struct fimd_context *ctx = container_of(clk, struct fimd_context, + dp_clk); + u32 val = enable ? DP_MIE_CLK_DP_ENABLE : DP_MIE_CLK_DISABLE; - writel(val, ctx->regs + DP_MIE_CLKCON); } diff --cc drivers/gpu/drm/ttm/ttm_bo.c index 301e2371c34f,e3daafa1be13..39386f50af87 --- a/drivers/gpu/drm/ttm/ttm_bo.c +++ b/drivers/gpu/drm/ttm/ttm_bo.c @@@ -227,26 -230,13 +227,17 @@@ EXPORT_SYMBOL(ttm_bo_del_sub_from_lru) void ttm_bo_move_to_lru_tail(struct ttm_buffer_object *bo) { + struct ttm_bo_device *bdev = bo->bdev; + int put_count = 0; lockdep_assert_held(&bo->resv->lock.base); + if (bdev->driver->lru_removal) + bdev->driver->lru_removal(bo); + - if (bo->mem.placement & TTM_PL_FLAG_NO_EVICT) { - list_del_init(&bo->swap); - list_del_init(&bo->lru); - - } else { - if (bo->ttm && !(bo->ttm->page_flags & TTM_PAGE_FLAG_SG)) { - list_del(&bo->swap); - list_add(&bo->swap, bdev->driver->swap_lru_tail(bo)); - } - - list_del(&bo->lru); - list_add(&bo->lru, bdev->driver->lru_tail(bo)); - } + put_count = ttm_bo_del_from_lru(bo); + ttm_bo_list_ref_sub(bo, put_count, true); + ttm_bo_add_to_lru(bo); } EXPORT_SYMBOL(ttm_bo_move_to_lru_tail);