e805ed83ba
drm/amd/powerplay: delete useless files.
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:17 -04:00
ab4f06d3ad
drm/amd/powerplay: use smu7 hwmgr to manager iceland
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:17 -04:00
18aafc59b1
drm/amd/powerplay: implement fw related smu interface for iceland.
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:16 -04:00
9c6d495696
drm/amd/powerplay: use smu7 common functions and data on icelannd.
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:16 -04:00
5746f90c56
drm/amd/powerplay: use smu7 common functions and data on Fiji.
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:15 -04:00
d01ec3fb8c
drm/amd/powerplay: use smu7 common functions and data on Polars10.
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:15 -04:00
ac43f0800f
drm/amd/powerplay: use smu7 common functions and data on Tonga.
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:14 -04:00
1ff55f4651
drm/amd/powerplay: implement smu7_smumgr for asics with smu ip version 7.
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:14 -04:00
fb044ed90c
drm/amd/powerplay: use smu7_hwmgr to manager tonga.
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:13 -04:00
1486022088
drm/amd/powerplay: implement fw image related smum interface for tonga.
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:12 -04:00
b859c20703
drm/amd/powerplay: use smu7 hwmgr to manager fiji
...
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:12 -04:00
18edef19ea
drm/amd/powerplay: implement fw image related smu interface for Fiji.
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:11 -04:00
4be051aeb3
drm/amd/powerplay: use smu7 hwmgr to manager polaris10/11
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:11 -04:00
34a564eaf5
drm/amd/powerplay: implement fw image related smum interface for Polaris.
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:10 -04:00
599a7e9fe1
drm/amd/powerplay: implement smu7 hwmgr to manager asics with smu ip version 7.
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Reviewed-by: Ken Wang <Qingqing.Wang@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:10 -04:00
ee1a51f882
drm/amd/powerplay: add common interface in smumgr to help to visit fw image.
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:09 -04:00
6a99a964f6
drm/amd/powerplay: add parameter of the mclk switch latency time
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Ken Wang <Qingqing.Wang@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:09 -04:00
c07aefc268
drm/amd/powerplay: fix potential issue of array access violation
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:22:08 -04:00
9716ebc38d
drm/amd/powerplay: fix mclk not switching back after multi-head was disabled
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
Cc: stable@vger.kernel.org
2016-09-19 13:22:08 -04:00
e313de7e89
Revert "drm/amdgpu: skip suspend/resume on DRM_SWITCH_POWER_DYNAMIC_OFF"
...
This is not necessary as pointed out by Lukas Wunner.
This reverts commit f46cf3735f
.
2016-09-19 13:22:06 -04:00
02124a03e6
drm/amdgpu/dce6: fix off by one in interrupt setup
...
Reviewed-by: Tom St Denis <tom.stdenis@amd.com >
Reported-by: Christian Inci <chris.pcguy.inci@gmail.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-19 13:21:54 -04:00
d9a1f0b4eb
drm: use drm_file to tag vm-bos
...
Rather than using "struct file*", use "struct drm_file*" as tag VM tag for
BOs. This will pave the way for "struct drm_file*" without any "struct
file*" back-pointer.
Signed-off-by: David Herrmann <dh.herrmann@gmail.com >
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch >
Link: http://patchwork.freedesktop.org/patch/msgid/20160901124837.680-3-dh.herrmann@gmail.com
2016-09-19 11:22:08 +02:00
9f31a0b032
drm/amdgpu: clean function declarations in amdgpu_ttm.c up
...
We get 2 warnings when building kernel with W=1:
drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c:985:5: warning: no previous prototype for 'amdgpu_ttm_init' [-Wmissing-prototypes]
drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c:1092:6: warning: no previous prototype for 'amdgpu_ttm_fini' [-Wmissing-prototypes]
In fact, both functions are declared in
drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c, but should be declared in
a header file, thus can be recognized in other file.
So this patch moves the declarations into
drivers/gpu/drm/amd/amdgpu/amdgpu.h.
Reviewed-by: Christian König <christian.koenig@amd.com >
Signed-off-by: Baoyou Xie <baoyou.xie@linaro.org >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-16 15:53:04 -04:00
9a9db6ef7c
drm/amdgpu: use the new ring ib and dma frame size callbacks (v2)
...
Use them to more accurately determine the ring size required
for ib submission.
v2: drop extra alignment
Reviewed-by: Christian König <christian.koenig@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-16 15:53:03 -04:00
58fafbaf16
drm/amdgpu/vce3: add ring callbacks for ib and dma frame size
...
Reviewed-by: Christian König <christian.koenig@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-16 15:53:02 -04:00
9d6b7a6447
drm/amdgpu/vce2: add ring callbacks for ib and dma frame size
...
Reviewed-by: Christian König <christian.koenig@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-16 15:53:02 -04:00
a6f8d72867
drm/amdgpu/vce: add common ring callbacks for ib and dma frame size
...
Reviewed-by: Christian König <christian.koenig@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-16 15:53:01 -04:00
c3f5875888
drm/amdgpu/uvd6: add ring callbacks for ib and dma frame size
...
Reviewed-by: Christian König <christian.koenig@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-16 15:53:01 -04:00
cdbbb7846c
drm/amdgpu/uvd5: add ring callbacks for ib and dma frame size
...
Reviewed-by: Christian König <christian.koenig@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-16 15:53:00 -04:00
23f8f8006a
drm/amdgpu/uvd4.2: add ring callbacks for ib and dma frame size
...
Reviewed-by: Christian König <christian.koenig@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-16 15:53:00 -04:00
928d467448
drm/amdgpu/sdma3: add ring callbacks for ib and dma frame size
...
Reviewed-by: Christian König <christian.koenig@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-16 15:52:59 -04:00
fe7c0f26da
drm/amdgpu/sdma2.4: add ring callbacks for ib and dma frame size
...
Reviewed-by: Christian König <christian.koenig@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-16 15:52:58 -04:00
77b52a5bc6
drm/amdgpu/cik_sdma: add ring callbacks for ib and dma frame size
...
Reviewed-by: Christian König <christian.koenig@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-16 15:52:58 -04:00
229e2d46da
drm/amdgpu/si_dma: add ring callbacks for ib and dma frame size
...
Reviewed-by: Christian König <christian.koenig@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-16 15:52:57 -04:00
7512ad16b5
drm/amdgpu/gfx8: add ring callbacks for ib and dma frame size
...
Reviewed-by: Christian König <christian.koenig@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-16 15:52:57 -04:00
b04e26b3c7
drm/amdgpu/gfx7: add ring callbacks for ib and dma frame size
...
Reviewed-by: Christian König <christian.koenig@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-16 15:52:56 -04:00
a851d0f4ca
drm/amdgpu/gfx6: add ring callbacks for ib and dma frame size
...
Reviewed-by: Christian König <christian.koenig@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-16 15:52:55 -04:00
b6384ff537
drm/amdgpu/ring: add an interface to get dma frame and ib size
...
Used to properly calculate space on the ring for ib submissions.
Reviewed-by: Christian König <christian.koenig@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-16 15:52:55 -04:00
e75a887162
drm/amdgpu/sdma3: drop unused functions
...
These are not used yet.
Reviewed-by: Edward O'Callaghan <funfunctor@folklore1984.net >
Reviewed-by: Christian König <christian.koenig@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-16 15:52:54 -04:00
95e588a014
drm/amdgpu/gfx6: drop gds_switch callback
...
GDS works differently on GFX6, plus the callback was
empty.
Reviewed-by: Edward O'Callaghan <funfunctor@folklore1984.net >
Reviewed-by: Christian König <christian.koenig@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-16 15:52:54 -04:00
0f444c24dd
drm/amdgpu/gfx6: add ring_emit_cntxcntl
...
Missing for gfx6.
Reviewed-by: Edward O'Callaghan <funfunctor@folklore1984.net >
Reviewed-by: Christian König <christian.koenig@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-16 15:52:53 -04:00
668f52c303
drm/amdgpu/gfx6: drop duplicate code
...
The compute functions just called the gfx functions, drop
the wrapper.
Reviewed-by: Edward O'Callaghan <funfunctor@folklore1984.net >
Reviewed-by: Christian König <christian.koenig@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-16 15:52:52 -04:00
2255e8c109
drm/amdgpu/si: fix ring size for compute
...
We switched the other asics, but missed this.
Reviewed-by: Christian König <christian.koenig@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-16 15:52:52 -04:00
72f417a2e0
drm/amd/powerplay: Partially revert change initialize platform caps
...
partially revert commit I36f3c9e3a28cbf290652edfb6e19109da660c4f1
this will lead APU can't work.
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Huang Rui <ray.huang@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-16 15:52:51 -04:00
d932f37c4a
drm/amdgpu: not set cg for vce/uvd in late init.
...
no need to set cg for uvd/vce in late init.
As when ring test, uvd/vce's dpm will be enabled/disabled.
the cg will be set.
fix issue suspend when play video or encode, then resume back,
the clock will be bypassed on Polaris/Fiji.
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-16 15:52:51 -04:00
aa0ef3ccd6
drm/amd/powerplay: add pptable point check before use it
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Acked-by: Christian König <christian.koenig@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Reviewed-by: Edward O'Callaghan <funfunctor@folklore1984.net >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-16 15:52:50 -04:00
b1c8e1e21f
drm/amd/powerplay: add pp_table_version in hwmgr.
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Acked-by: Christian König <christian.koenig@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Reviewed-by: Edward O'Callaghan <funfunctor@folklore1984.net >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-16 15:52:49 -04:00
e1aa5715f6
drm/amd/powerplay: rename tonga_processpptable* to processpptable_v1_0*.
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Acked-by: Christian König <christian.koenig@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Reviewed-by: Edward O'Callaghan <funfunctor@folklore1984.net >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-16 15:52:49 -04:00
a47c78d964
drm/amdgpu/vi: Use correct external_rev_id for stoney
...
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Jordan Lazare <Jordan.Lazare@amd.com >
Cc: stable@vger.kernel.org
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2016-09-16 15:52:48 -04:00
d912adef4d
drm/amdgpu: squash lines for simple wrapper functions
...
Remove unneeded variables and assignments.
Reviewed-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk >
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com >
Signed-off-by: Sean Paul <seanpaul@chromium.org >
Link: http://patchwork.freedesktop.org/patch/msgid/1473863952-7658-2-git-send-email-yamada.masahiro@socionext.com
2016-09-15 10:39:21 -04:00