Commit ac43f080 authored by Rex Zhu's avatar Rex Zhu Committed by Alex Deucher

drm/amd/powerplay: use smu7 common functions and data on Tonga.

Signed-off-by: default avatarRex Zhu <Rex.Zhu@amd.com>
Reviewed-by: default avatarAlex Deucher <alexander.deucher@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent 1ff55f46
...@@ -26,16 +26,7 @@ ...@@ -26,16 +26,7 @@
#include "smu72_discrete.h" #include "smu72_discrete.h"
#define SMC_RAM_END 0x40000 #include "smu7_smumgr.h"
struct tonga_buffer_entry {
uint32_t data_size;
uint32_t mc_addr_low;
uint32_t mc_addr_high;
void *kaddr;
unsigned long handle;
};
struct tonga_mc_reg_entry { struct tonga_mc_reg_entry {
uint32_t mclk_max; uint32_t mclk_max;
...@@ -52,19 +43,8 @@ struct tonga_mc_reg_table { ...@@ -52,19 +43,8 @@ struct tonga_mc_reg_table {
struct tonga_smumgr { struct tonga_smumgr {
uint8_t *pHeader;
uint8_t *pMecImage;
uint32_t soft_regs_start;
uint32_t dpm_table_start;
uint32_t mc_reg_table_start;
uint32_t fan_table_start;
uint32_t arb_table_start;
struct tonga_buffer_entry header_buffer;
struct tonga_buffer_entry smu_buffer;
struct smu7_smumgr smu7_data;
struct SMU72_Discrete_DpmTable smc_state_table; struct SMU72_Discrete_DpmTable smc_state_table;
struct SMU72_Discrete_Ulv ulv_setting; struct SMU72_Discrete_Ulv ulv_setting;
struct SMU72_Discrete_PmFuses power_tune_table; struct SMU72_Discrete_PmFuses power_tune_table;
...@@ -76,13 +56,4 @@ struct tonga_smumgr { ...@@ -76,13 +56,4 @@ struct tonga_smumgr {
}; };
extern int tonga_smum_init(struct pp_smumgr *smumgr);
extern int tonga_copy_bytes_to_smc(struct pp_smumgr *smumgr,
uint32_t smcStartAddress, const uint8_t *src,
uint32_t byteCount, uint32_t limit);
extern int tonga_read_smc_sram_dword(struct pp_smumgr *smumgr, uint32_t smcAddress,
uint32_t *value, uint32_t limit);
extern int tonga_write_smc_sram_dword(struct pp_smumgr *smumgr, uint32_t smcAddress,
uint32_t value, uint32_t limit);
#endif #endif
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment