aboutsummaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/amd
AgeCommit message (Collapse)AuthorFilesLines
2015-12-21drm/amdgpu/cgs: add sys info query for pcie gen and link widthAlex Deucher2-0/+8
Needed by powerplay to properly handle pcie dpm switching. Reviewed-by: Jammy Zhou <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2015-12-21drm/amdgpu: store pcie gen mask and link widthAlex Deucher4-20/+99
We'll need this later for pcie dpm. Reviewed-by: Jammy Zhou <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2015-12-21drm/amdgpu: extract pcie helpers to common headerAlex Deucher6-137/+193
These will be used by multiple powerplay drivers and other IP modules. Reviewed-by: Jammy Zhou <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2015-12-21drm/amd/powerplay/fiji: enable pcie and mclk forcing for lowAlex Deucher1-5/+25
When forcing the lowest state also force mclk and pcie. Signed-off-by: Alex Deucher <[email protected]>
2015-12-21drm/amd/powerplay/tonga: enable pcie and mclk forcing for lowAlex Deucher1-11/+37
When forcing the lowest state also force mclk and pcie. Signed-off-by: Alex Deucher <[email protected]>
2015-12-21drm/amd/powerplay: refine the logic of whether need to update power state.Rex Zhu2-3/+11
Better handle power state changes. Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Reviewed-by: Jammy Zhou <[email protected]>
2015-12-21drm/amd/powerplay: implement new funcs to check current states for tonga.Rex Zhu1-0/+62
Implement the new callbacks for tonga. Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Reviewed-by: Jammy Zhou <[email protected]>
2015-12-21drm/amd/powerplay: add and export hwmgr interface to eventmgr to check hw ↵Rex Zhu3-0/+34
states. Interface between hwmgr and eventmgr. Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Reviewed-by: Jammy Zhou <[email protected]>
2015-12-21drm/amdgpu: support per device powerplay enablement (v2)Jammy Zhou6-61/+65
The amdgu_powerplay variable is global for multiple GPU instances. v2: fold in Flora's module option change, protect adev reference in macros Signed-off-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Reviewed-by: Christian König <[email protected]>
2015-12-21drm/amdgpu: enable sysfs interface for powerplayRex Zhu1-9/+11
Same interface exposed in pre-powerplay dpm code. Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-12-21drm/amdgpu: export fan control functions to amdgpuRex Zhu1-5/+25
Hook up the amdgpu thermal control callbacks for powerplay. Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-12-21drm/amdgpu/powerplay: implement fan control interface in amd_powerplay_funcsRex Zhu2-1/+88
This adds the interface needed to expose powerplay fan control to sysfs via hwmon. Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-12-21drm/amdgpu/powerplay: implement thermal control for tonga.Rex Zhu5-2/+798
Implement thermal and fan control for tonga. Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-12-21drm/amdgpu/powerplay: enable thermal interrupt task in eventmgr.Rex Zhu6-4/+48
Add thermal handling to the event manager. Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-12-21drm/amdgpu/powerplay: add thermal control interface in hwmgr.Rex Zhu3-2/+47
Thermal controller interface. Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-12-21drm/amdgpu/powerplay: mv ppinterrupt.h to inc folder to share with other ↵Rex Zhu2-22/+26
submodule. Redefine interrupt callback function in accordance with cgs. Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-12-21drm/amdgpu/powerplay: add new function point in hwmgr_funcs for thermal controlRex Zhu1-0/+22
Add the interface for fan and thermal control. Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-12-21drm/amd/powerplay: Add CG and PG support for tongaRex Zhu5-15/+440
Implement clock and power gating support for tonga. On Tonga this is handles by the SMU rather than direct register settings in the driver. Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-12-21drm/amd/powerplay: add new function point in hwmgr_func for CG/PG.Rex Zhu1-0/+3
Add callbacks interface for clock and powergating. Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-12-21drm/amdgpu/powerplay: add some definition for other ip block to update cg pg.Rex Zhu1-0/+41
Interface for clock and power gating handling. Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-12-21drm/amdgpu: enable powerplay module by default for fiji.Rex Zhu1-0/+3
Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-12-21drm/amdgpu: enable powerplay module by default for tonga.Rex Zhu1-0/+8
Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-12-21drm/amdgpu/powerplay: program display gap for tonga.Rex Zhu1-0/+91
Implement displaygap programming for tonga. This is required for properly mclk switching. Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-12-21drm/amdgpu/powerplay: implement pem_task for display_configuration_changeRex Zhu4-6/+15
Add support for display configuration changes to the event manager. Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-12-21drm/amdgpu/poweprlay: export program display gap function to eventmgrRex Zhu2-0/+29
This allows the eventmgr to properly update the displaygap on certain power events. Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-12-21drm/amdgpu/powerplay: add function point in hwmgr_funcs for program display gapRex Zhu1-1/+3
Displaygap support is required for proper mclk switching. Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-12-21drm/amd/amdgpu: enable powerplay and smc firmware loading for Fiji.Eric Huang3-1/+7
Switch over to handling in the powerplay module. Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Eric Huang <[email protected]>
2015-12-21drm/amdgpu: add amdgpu.powerplay module optionJammy Zhou1-0/+5
This option can be used to enable the new powerplay implementation, and it is disabled by default. Signed-off-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-12-21drm/amd/powerplay: add Fiji DPM support.Eric Huang7-1/+5815
This enabled DPM support for Fiji. DPM is dynamic clock and voltage scaling. v2: rename fiji_hwmgr_early_init to fiji_hwmgr_init v3: (agd) fold in endian fix, additional function addition Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Eric Huang <[email protected]>
2015-12-21drm/amd/powerplay: add Fiji SMU support.Eric Huang4-1/+1117
Add support for the SMU manager for Fiji. This handles the firmware loading for other IP blocks (GFX, SDMA, etc.). Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Eric Huang <[email protected]>
2015-12-21drm/amd/powerplay: update atomctrl for fijiEric Huang3-9/+496
Add some new functions to support Fiji. Split out from the previous patch. Reviewed-by: Jammy Zhou <[email protected]> Signed-off-by: Eric Huang <[email protected]>
2015-12-21drm/amd/powerplay: add/update headers for Fiji SMU and DPMEric Huang7-182/+12926
New headers for Fiji. Reviewed-by: Jammy Zhou <[email protected]> Signed-off-by: Eric Huang <[email protected]>
2015-12-21drm/amd/powerplay: add Tonga dpm support (v3)yanyang120-12/+9284
This implements DPM for tonga. DPM handles dynamic clock and voltage scaling. v2: merge all the patches related with tonga dpm v3: merge dpm force level fix, cgs display fix, spelling fix Reviewed-by: Alex Deucher <[email protected]> Reviewed-by: Jammy Zhou <[email protected]> Signed-off-by: yanyang1 <[email protected]> Signed-off-by: Rex Zhu <[email protected]> Signed-off-by: Eric Huang <[email protected]>
2015-12-21drm/amd/powerplay: Add Tonga SMU supportJammy Zhou5-2/+921
The SMU manager handles firmware loading for other IP blocks (GFX, SDMA, etc.). This implements it for Tonga. v3: delete peci sub-module v2: use cgs interface directly Signed-off-by: Young Yang <[email protected]> Signed-off-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-12-21drm/amd/powerplay: add header file for tonga smu and dpmyanyang14-198/+1844
These headers provide the SMU interface used by the driver. Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: yanyang1 <[email protected]>
2015-12-21drm/amd/powerplay: Move smu7*.h from amdgpu to powerplay.yanyang13-0/+0
Move smu7.h, smu7_discrete.h and smu7_fusion.h from amdgpu to powerplay. Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: yanyang1 <[email protected]>
2015-12-21drm/amd/powerplay: Add ixSWRST_COMMAND_1 in bif_5_0_d.hyanyang11-0/+1
Add ixSWRST_COMMAND_1 in bif_5_0_d.h. Required by new powerplay code for tonga and fiji. Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: yanyang1 <[email protected]>
2015-12-21drm/amd/powerplay: implement functions of amd_powerplay_funcRex Zhu1-8/+183
This is the common interface for interacting with the powerplay module. v2: squash in fixes Signed-off-by: Rex Zhu <[email protected]> Acked-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-12-21drm/amd/powerplay: add event manager sub-componentRex Zhu20-1/+2423
The event manager handles power related driver events. Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-12-21drm/amd/powerplay: add CG and PG support for carrizoRex Zhu10-12/+1058
This adds clock and powergating support for CZ. v2: squash in fixes Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-12-21drm/amd/powerplay: add Carrizo dpm supportJammy Zhou4-3/+1212
This patch enables basic DPM support for Carrizo. DPM handles dynamic clock and voltage scaling. v3: delete peci sub-module v2: use cgs interface directly correct define SMU_EnabledFeatureScoreboard_SclkDpmOn Signed-off-by: Rex Zhu <[email protected]> Signed-off-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-12-21drm/amd/powerplay: add Carrizo smu supportJammy Zhou8-2/+963
This implements the SMU firmware manager interface for CZ. Some header files are moved from amdgpu folder to powerplay as well. v3: delete peci sub-module. v2: use cgs interface directly add load_mec_firmware function Signed-off-by: Rex Zhu <[email protected]> Signed-off-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-12-21drm/amd/powerplay: add hardware manager sub-componentJammy Zhou16-6/+3439
The hwmgr handles all hardware related calls, including clock/power gating control, DPM, read and parse PPTable, etc. v5: squash in fixes v4: implement acpi's atcs function use cgs interface v3: fix code style error and add big-endian mode support. v2: use cgs interface directly in hwmgr sub-module Signed-off-by: Rex Zhu <[email protected]> Signed-off-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-12-21drm/amd/powerplay: add SMU manager sub-componentJammy Zhou6-0/+560
The SMUMGR is one sub-component of powerplay for SMU firmware support. The SMU handles firmware loading for other IP blocks (GFX, SDMA, etc.) on VI parts. The adds the core powerplay infrastructure to handle that. v3: direct use printk in powerplay module. v2: direct use cgs_read/write_register functions in smu-modules Signed-off-by: Rex Zhu <[email protected]> Signed-off-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-12-21drm/amdgpu: export amd_powerplay_func to amdgpu and other ip blockRex Zhu2-81/+180
Update amdgpu to deal with the new powerplay module properly. v2: squash in fixes v3: squash in Rex's power state reporting fix Signed-off-by: Rex Zhu <[email protected]> Acked-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-12-21drm/amdgpu: disable legacy path of firmware check if powerplay is enabledRex Zhu2-49/+55
Powerplay will use a different interface once it's integrated. These legacy pathes will be removed once powerplay is enabled by default. Signed-off-by: Rex Zhu <[email protected]> Signed-off-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-12-21drm/amd/powerplay: add basic powerplay frameworkAlex Deucher11-9/+717
amdgpu_pp_ip_funcs is introduced to handle the two code paths, the legacy one and the new powerplay implementation. CONFIG_DRM_AMD_POWERPLAY kernel configuration option is introduced for the powerplay component. v4: squash in fixes v3: register debugfs file when powerplay module enable v2: add amdgpu_ucode_init_bo in hw init when amdgpu_powerplay enable. Signed-off-by: Rex Zhu <[email protected]> Signed-off-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-12-21drm/amdgpu: add new cgs interface to get display info (v2)Rex Zhu2-0/+60
Add new CGS interfaces to query display info across modules. This is nedded by the powerplay module for synchronizing with the display module. v2: (agd): fold in refresh rate fix, rebase Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-12-21drm/amdgpu: implement cgs interface to query system infoRex Zhu2-0/+46
Add a query to get the bus number and function of the device. Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Jammy Zhou <[email protected]>
2015-12-21drm/amdgpu: implement new cgs interface for acpi functionRex Zhu2-3/+262
Add a new driver internal interface for accessing ACPI methods. These will be used by various new components including powerplay. Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>