]> git.baikalelectronics.ru Git - kernel.git/commit
drm/amd/display: Add control mechanism for FPU
authorRodrigo Siqueira <Rodrigo.Siqueira@amd.com>
Tue, 27 Jul 2021 00:52:46 +0000 (20:52 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Fri, 6 Aug 2021 01:17:59 +0000 (21:17 -0400)
commit96ee63730fa30614e943ac352ef772be49a712d9
treed35f008e9afa9521a7845b1aa8e56a687ed00bb0
parentc8b3538d05f7393e09a29bb0c3f9dda19c1e5da6
drm/amd/display: Add control mechanism for FPU

DC invokes DC_FPU_START/END in multiple parts of the code; this can
create a situation where we invoke this FPU operation in a nested way or
exit too early. For avoiding this situation, this commit adds a
mechanism where dc_fpu_begin/end manages the access to
kernel_fpu_begin/end.

Change since V3:
- Christian: Move PPC64 code to dc_fpu_begin/end.

Change since V2:
- Christian: Do not use this_cpu_* between get/put_cpu_ptr().

Change since V1:
- Use a better variable names
- Use get_cpu_ptr and put_cpu_ptr to better balance preemption enable
and disable

Cc: Harry Wentland <harry.wentland@amd.com>
Cc: Anson Jacob <Anson.Jacob@amd.com>
Cc: Christian König <christian.koenig@amd.com>
Cc: Hersen Wu <hersenxs.wu@amd.com>
Cc: Aric Cyr <aric.cyr@amd.com>
Cc: Jun Lei <jun.lei@amd.com>
Cc: Dmytro Laktyushkin <dmytro.laktyushkin@amd.com>
Cc: Qingqing Zhuo <qingqing.zhuo@amd.com>
Signed-off-by: Rodrigo Siqueira <Rodrigo.Siqueira@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/amdgpu_dm/Makefile
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_trace.h
drivers/gpu/drm/amd/display/amdgpu_dm/dc_fpu.c [new file with mode: 0644]
drivers/gpu/drm/amd/display/amdgpu_dm/dc_fpu.h [new file with mode: 0644]
drivers/gpu/drm/amd/display/dc/dc_trace.h
drivers/gpu/drm/amd/display/dc/os_types.h