1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24 #ifndef SMU8_FUSION_H
25 #define SMU8_FUSION_H
26
27 #include "smu8.h"
28
29 #pragma pack(push, 1)
30
31 #define SMU8_MAX_CUS 2
32 #define SMU8_PSMS_PER_CU 4
33 #define SMU8_CACS_PER_CU 4
34
35 struct SMU8_GfxCuPgScoreboard {
36 uint8_t Enabled;
37 uint8_t spare[3];
38 };
39
40 struct SMU8_Port80MonitorTable {
41 uint32_t MmioAddress;
42 uint32_t MemoryBaseHi;
43 uint32_t MemoryBaseLo;
44 uint16_t MemoryBufferSize;
45 uint16_t MemoryPosition;
46 uint16_t PollingInterval;
47 uint8_t EnableCsrShadow;
48 uint8_t EnableDramShadow;
49 };
50
51
52 #define PWRMGT_SEPARATION_TIME_SHIFT 0
53 #define PWRMGT_SEPARATION_TIME_MASK 0xFFFF
54 #define PWRMGT_DISABLE_CPU_CSTATES_SHIFT 16
55 #define PWRMGT_DISABLE_CPU_CSTATES_MASK 0x1
56 #define PWRMGT_DISABLE_CPU_PSTATES_SHIFT 24
57 #define PWRMGT_DISABLE_CPU_PSTATES_MASK 0x1
58
59
60 #define NUM_SCLK_LEVELS 8
61 #define NUM_LCLK_LEVELS 8
62 #define NUM_UVD_LEVELS 8
63 #define NUM_ECLK_LEVELS 8
64 #define NUM_ACLK_LEVELS 8
65
66 struct SMU8_Fusion_ClkLevel {
67 uint8_t GnbVid;
68 uint8_t GfxVid;
69 uint8_t DfsDid;
70 uint8_t DeepSleepDid;
71 uint32_t DfsBypass;
72 uint32_t Frequency;
73 };
74
75 struct SMU8_Fusion_SclkBreakdownTable {
76 struct SMU8_Fusion_ClkLevel ClkLevel[NUM_SCLK_LEVELS];
77 struct SMU8_Fusion_ClkLevel DpmOffLevel;
78
79 uint32_t SclkValidMask;
80 uint32_t MaxSclkIndex;
81 };
82
83 struct SMU8_Fusion_LclkBreakdownTable {
84 struct SMU8_Fusion_ClkLevel ClkLevel[NUM_LCLK_LEVELS];
85 struct SMU8_Fusion_ClkLevel DpmOffLevel;
86
87 uint32_t LclkValidMask;
88 uint32_t MaxLclkIndex;
89 };
90
91 struct SMU8_Fusion_EclkBreakdownTable {
92 struct SMU8_Fusion_ClkLevel ClkLevel[NUM_ECLK_LEVELS];
93 struct SMU8_Fusion_ClkLevel DpmOffLevel;
94 struct SMU8_Fusion_ClkLevel PwrOffLevel;
95 uint32_t EclkValidMask;
96 uint32_t MaxEclkIndex;
97 };
98
99 struct SMU8_Fusion_VclkBreakdownTable {
100 struct SMU8_Fusion_ClkLevel ClkLevel[NUM_UVD_LEVELS];
101 struct SMU8_Fusion_ClkLevel DpmOffLevel;
102 struct SMU8_Fusion_ClkLevel PwrOffLevel;
103 uint32_t VclkValidMask;
104 uint32_t MaxVclkIndex;
105 };
106
107 struct SMU8_Fusion_DclkBreakdownTable {
108 struct SMU8_Fusion_ClkLevel ClkLevel[NUM_UVD_LEVELS];
109 struct SMU8_Fusion_ClkLevel DpmOffLevel;
110 struct SMU8_Fusion_ClkLevel PwrOffLevel;
111 uint32_t DclkValidMask;
112 uint32_t MaxDclkIndex;
113 };
114
115 struct SMU8_Fusion_AclkBreakdownTable {
116 struct SMU8_Fusion_ClkLevel ClkLevel[NUM_ACLK_LEVELS];
117 struct SMU8_Fusion_ClkLevel DpmOffLevel;
118 struct SMU8_Fusion_ClkLevel PwrOffLevel;
119 uint32_t AclkValidMask;
120 uint32_t MaxAclkIndex;
121 };
122
123
124 struct SMU8_Fusion_ClkTable {
125 struct SMU8_Fusion_SclkBreakdownTable SclkBreakdownTable;
126 struct SMU8_Fusion_LclkBreakdownTable LclkBreakdownTable;
127 struct SMU8_Fusion_EclkBreakdownTable EclkBreakdownTable;
128 struct SMU8_Fusion_VclkBreakdownTable VclkBreakdownTable;
129 struct SMU8_Fusion_DclkBreakdownTable DclkBreakdownTable;
130 struct SMU8_Fusion_AclkBreakdownTable AclkBreakdownTable;
131 };
132
133 #pragma pack(pop)
134
135 #endif