Felix Kuehling
02208441cc
drm/amdgpu: Add PASID management
...
Allows assigning a PASID to a VM for identifying VMs involved in page
faults. The global PASID manager is also exported in the KFD
interface so that AMDGPU and KFD can share the PASID space.
PASIDs of different sizes can be requested. On APUs, the PASID size
is deterined by the capabilities of the IOMMU. So KFD must be able
to allocate PASIDs in a smaller range.
Signed-off-by: Felix Kuehling <Felix.Kuehling@amd.com >
Acked-by: Alex Deucher <alexander.deucher@amd.com >
Reviewed-by: Oded Gabbay <oded.gabbay@gmail.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2017-09-26 13:07:02 -04:00
Felix Kuehling
ca290da8f6
drm/amdgpu: Fix error handling in amdgpu_vm_init
...
Make sure vm->root.bo is not left reserved if amdgpu_bo_kmap fails.
Signed-off-by: Felix Kuehling <Felix.Kuehling@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2017-09-26 13:07:01 -04:00
Rex Zhu
0596df6b09
drm/amd/powerplay: Simplify smu7_voting_clients()
...
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 >
2017-09-26 13:07:01 -04:00
Rex Zhu
780cffc599
drm/amdgpu: add powerplay support for CI asics
...
currently, for CI asics,
use dpm by default, amdgpu.dpm=-1.
when set amdgpu.dpm=1, enable powplay.
when set amdgpu.dpm=0, disable both dpm and powerplay.
when powerplay is stable on CI asics, ci_dpm will
be removed.
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 >
2017-09-26 13:07:00 -04:00
Rex Zhu
86457c3b21
drm/amd/powerplay: Add support for CI asics to hwmgr
...
Add support for CI asics (Bonaire, Hawaii) to
the powerplay hwmgr
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 >
2017-09-26 13:06:59 -04:00
Rex Zhu
970d9804b0
drm/amd/powerplay: Add support functions for CI to ppatomctrl.c
...
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 >
2017-09-26 13:06:59 -04:00
Rex Zhu
89c67699ad
drm/amd/powerplay: refine dmesg info under powerplay
...
Use pr_debug to prevent spamming unimportant dmesg.
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 >
2017-09-26 13:06:58 -04:00
Rex Zhu
2a527680a1
drm/amd/powerplay: fix set target TDP error on tonga/iceland
...
ConfigurableTDP do not exist from Fiji.
so only use in previous ASIC.
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 >
2017-09-26 13:06:58 -04:00
Rex Zhu
9f4b35411c
drm/amd/powerplay: add CI asics support to smumgr (v3)
...
This ports support for CI asics (Bonaire, Hawaii)
to the powerplay smumgr
v2: warning fix (Alex)
v3: squash in fix for thermal (Tom)
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 >
2017-09-26 13:06:57 -04:00
Rex Zhu
510c2558b9
drm/amd/powerplay: fix pcie max lane define error
...
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2017-09-18 23:30:37 -04:00
Rex Zhu
e71b7ae673
drm/amd/powerplay: fix spelling typo in function name
...
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 >
2017-09-18 23:30:36 -04:00
Rex Zhu
6df9855fe2
drm/amdgpu: add support for request SI/CI firmware in CGS
...
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 >
2017-09-18 23:30:36 -04:00
Rex Zhu
cd4d74648b
drm/amdgpu: unify the interface of amd_pm_funcs
...
put amd_pm_funcs table in struct powerplay for all
asics.
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2017-09-18 23:30:35 -04:00
Rex Zhu
f93f0c3a7e
drm/amd/powerplay: use struct amd_pm_funcs in powerplay
...
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 >
2017-09-18 23:30:34 -04:00
Rex Zhu
cfa289fd49
drm/amdgpu: rename amdgpu_dpm_funcs to amd_pm_funcs
...
renamed amdgpu_dpm_funcs and moved to amd_shared.h
so can shared with powerplay.
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 >
2017-09-18 23:30:34 -04:00
Rex Zhu
698f88e697
drm/amd/powerplay: delete dead code in powerplay
...
delete functiontable related codes
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 >
2017-09-18 23:30:33 -04:00
Rex Zhu
cf2623d951
drm/amd/powerplay: refine powerplay code for RV
...
use function points instand of function table.
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 >
2017-09-18 23:30:32 -04:00
Rex Zhu
06d31a69ca
drm/amd/powerplay: refine powerplay code for CZ/ST
...
1. add function points instand of creat function tables
2. implement stop dpm tasks for CZ/ST
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 >
2017-09-18 23:30:32 -04:00
Rex Zhu
1ab4720441
drm/amd/powerplay: refine code for thermal control in powerplay
...
add function point start_thermal_controller in hwmgr,
delete thermal function table and related functions
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 >
2017-09-18 23:30:31 -04:00
Tom St Denis
97bae49c44
drm/amd/amdgpu: Support VM environments in amdgpu_ttm_access_memory()
...
Signed-off-by: Tom St Denis <tom.stdenis@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2017-09-18 23:30:31 -04:00
Arnd Bergmann
e882064655
drm/radeon: properly initialize r600_audio_status() data
...
The structure returned from r600_audio_status() is only partially
initialized, and older gcc versions (4.3 and 4.4) warn about this:
drivers/gpu/drm/radeon/r600_hdmi.c: In function 'r600_audio_status':
drivers/gpu/drm/radeon/r600_hdmi.c:108: error: 'status.id' is used uninitialized in this function
drivers/gpu/drm/radeon/r600_hdmi.c:108: error: 'status.connected' is used uninitialized in this function
drivers/gpu/drm/radeon/r600_hdmi.c:108: error: 'status.offset' is used uninitialized in this function
This is harmless and surprisingly correct in C99, as the caller
only accesses the fields that got initialized, so newer compilers
don't warn about it, but initializing the entire structure feels
like the right thing to do here and avoids the warning.
Reviewed-by: Christian König <christian.koenig@amd.com >
Signed-off-by: Arnd Bergmann <arnd@arndb.de >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2017-09-18 23:30:30 -04:00
Alex Deucher
cf661ec1ff
drm/amdgpu/psp: declare raven psp firmware
...
So it gets picked up properly by the kernel.
Reviewed-by: Junwei Zhang <Jerry.Zhang@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2017-09-18 23:30:29 -04:00
Allen Pais
376b6a1f4f
drivers:gpu:Use ARRAY_SIZE() for the size calculation of the array.
...
Signed-off-by: Allen Pais <allen.lkml@gmail.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2017-09-13 14:56:29 -04:00
Tom St Denis
c30572814d
drm/amd/amdgpu: Change vram debugfs to NO_KIQ for VM environments
...
Reviewed-by: Christian König <christian.koenig@amd.com >
Signed-off-by: Tom St Denis <tom.stdenis@amd.com >
Reviewed-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2017-09-13 14:56:12 -04:00
Christian König
0d2bd2ae04
drm/ttm: fix memory leak while individualizing BOs
...
We need to free the reservation object before we take the BO
from the delayed delete list.
Signed-off-by: Christian König <christian.koenig@amd.com >
Reviewed-by: Monk Liu <monk.liu@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2017-09-13 12:10:14 -04:00