]> git.proxmox.com Git - mirror_ubuntu-eoan-kernel.git/commit
drm/crc: Cleanup crtc_crc_open function
authorMahesh Kumar <mahesh1.kumar@intel.com>
Tue, 21 Aug 2018 08:38:56 +0000 (14:08 +0530)
committerRodrigo Vivi <rodrigo.vivi@intel.com>
Wed, 22 Aug 2018 16:47:58 +0000 (09:47 -0700)
commitc0811a7d5befe34a17772760100e26b09a561c0e
treef964f8165d4c67a01d534979a2afda41ba67a10d
parentaf6979331da12d2db92a1fe7e1aba85ee5f4b06d
drm/crc: Cleanup crtc_crc_open function

This patch make changes to allocate crc-entries buffer before
enabling CRC generation.
It moves all the failure check early in the function before setting
the source or memory allocation.
Now set_crc_source takes only two variable inputs, values_cnt we
already gets as part of verify_crc_source.

Changes since V1:
 - refactor code to use single spin lock
Changes since V2:
 - rebase
Changes since V3:
 - rebase on top of VKMS driver

Signed-off-by: Mahesh Kumar <mahesh1.kumar@intel.com>
Cc: dri-devel@lists.freedesktop.org
Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Cc: Haneen Mohammed <hamohammed.sa@gmail.com>
Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Acked-by: Leo Li <sunpeng.li@amd.com> (V2)
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> (V3)
Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20180821083858.26275-3-mahesh1.kumar@intel.com
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.h
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_crc.c
drivers/gpu/drm/drm_debugfs_crc.c
drivers/gpu/drm/i915/intel_drv.h
drivers/gpu/drm/i915/intel_pipe_crc.c
drivers/gpu/drm/rcar-du/rcar_du_crtc.c
drivers/gpu/drm/rockchip/rockchip_drm_vop.c
drivers/gpu/drm/vkms/vkms_crc.c
drivers/gpu/drm/vkms/vkms_drv.h
include/drm/drm_crtc.h