drm/radeon/dpm: update cac leakage table parsing for CI

Uses a different table format if the board supports EVV.

Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drm/radeon/dpm: add support for parsing the atom powertune table

Needed for DPM on CI.

Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drm/radeon/dpm: grab mvdd_dependency_on_mclk info from vbios

Required for dpm on CI.

Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drm/radeon: add structs to store vce clock voltage deps

Used for vce power management.

Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drm/radeon: add clock voltage dep tables for acp, samu

Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drm/radeon: parse the vce clock voltage deps table

Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drm/radeon: parse the uvd clock voltage deps table

Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drm/radeon/dpm: clean up the extended table error pathes

Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drm/radeon: parse the samu clock voltage deps table

Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drm/radeon: parse the acp clock voltage deps table

Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drm/radeon: add r600_get_pcie_lane_support helper

Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drm/radeon/dpm: add vce clocks to radeon_ps

Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drm/radeon/dpm: add a helper to encode pcie lane setting

convert from number of lanes to register setting.

Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drm/radeon/dpm: add helper to fetch the vrefresh of the current mode

Needed for DPM on CI.

Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drm/radeon/kms: add dpm support for KB/KV

This adds dpm support for KB/KV asics.  This includes:
- dynamic engine clock scaling
- dynamic voltage scaling
- power containment
- shader power scaling

Set radeon.dpm=1 to enable.

Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drm/radeon: add dpm support for CI dGPUs (v2)

This adds dpm support for btc asics. This includes:
- dynamic engine clock scaling
- dynamic memory clock scaling
- dynamic voltage scaling
- dynamic pcie gen switching

Set radeon.dpm=1 to enable.

v2: remove unused radeon_atombios.c changes,
    make missing smc ucode non-fatal

Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drm/radeon/dpm: add debugfs support for CI

This allows you to look at the current DPM state via debugfs.

Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drm/radeon/dpm: implement force performance level for CI

Allows you to force the selected performance level via sysfs.

Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drm/radeon/dpm: implement vblank_too_short callback for CI

Check if we can switch the mclk during the vblank time otherwise
we may get artifacts on the screen when the mclk changes.

Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drm/radeon/dpm: add debugfs support for KB/KV

This allows you to look at the current DPM state via
debugfs.

Signed-off-by: Alex Deucher <alexander.deucher@amd.com>