]> git.proxmox.com Git - mirror_edk2.git/blame - Vlv2DeviceRefCodePkg/ValleyView2Soc/CPU/PowerManagement/AcpiTables/Ssdt/Cpu0Ist.asl
Upload BSD-licensed Vlv2TbltDevicePkg and Vlv2DeviceRefCodePkg to
[mirror_edk2.git] / Vlv2DeviceRefCodePkg / ValleyView2Soc / CPU / PowerManagement / AcpiTables / Ssdt / Cpu0Ist.asl
CommitLineData
3cbfba02
DW
1/*-----------------------------------------------------------------------------\r
2-------------------------------------------------------------------------------\r
3\r
4\r
5 Intel Silvermont Processor Power Management BIOS Reference Code\r
6\r
7 Copyright (c) 2006 - 2014, Intel Corporation\r
8\r
9 This program and the accompanying materials are licensed and made available under\r
10 the terms and conditions of the BSD License that accompanies this distribution.\r
11 The full text of the license may be found at\r
12 http://opensource.org/licenses/bsd-license.php.\r
13\r
14 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
15 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
16\r
17\r
18 Filename: CPU0IST.ASL\r
19\r
20 Revision: Refer to Readme\r
21\r
22 Date: Refer to Readme\r
23\r
24--------------------------------------------------------------------------------\r
25-------------------------------------------------------------------------------\r
26\r
27 This Processor Power Management BIOS Source Code is furnished under license\r
28 and may only be used or copied in accordance with the terms of the license.\r
29 The information in this document is furnished for informational use only, is\r
30 subject to change without notice, and should not be construed as a commitment\r
31 by Intel Corporation. Intel Corporation assumes no responsibility or liability\r
32 for any errors or inaccuracies that may appear in this document or any\r
33 software that may be provided in association with this document.\r
34\r
35 Except as permitted by such license, no part of this document may be\r
36 reproduced, stored in a retrieval system, or transmitted in any form or by\r
37 any means without the express written consent of Intel Corporation.\r
38\r
39 WARNING: You are authorized and licensed to install and use this BIOS code\r
40 ONLY on an IST PC. This utility may damage any system that does not\r
41 meet these requirements.\r
42\r
43 An IST PC is a computer which\r
44 (1) Is capable of seamlessly and automatically transitioning among\r
45 multiple performance states (potentially operating at different\r
46 efficiency ratings) based upon power source changes, END user\r
47 preference, processor performance demand, and thermal conditions; and\r
48 (2) Includes an Intel Pentium II processors, Intel Pentium III\r
49 processor, Mobile Intel Pentium III Processor-M, Mobile Intel Pentium 4\r
50 Processor-M, Intel Pentium M Processor, or any other future Intel\r
51 processors that incorporates the capability to transition between\r
52 different performance states by altering some, or any combination of,\r
53 the following processor attributes: core voltage, core frequency, bus\r
54 frequency, number of processor cores available, or any other attribute\r
55 that changes the efficiency (instructions/unit time-power) at which the\r
56 processor operates.\r
57\r
58-------------------------------------------------------------------------------\r
59-------------------------------------------------------------------------------\r
60\r
61NOTES:\r
62 (1) <TODO> - IF the trap range and port definitions do not match those\r
63 specified by this reference code, this file must be modified IAW the\r
64 individual implmentation.\r
65\r
66--------------------------------------------------------------------------------\r
67------------------------------------------------------------------------------*/\r
68\r
69\r
70DefinitionBlock (\r
71 "CPU0IST.aml",\r
72 "SSDT",\r
73 0x01,\r
74 "PmRef",\r
75 "Cpu0Ist",\r
76 0x3000\r
77 )\r
78{\r
79 External (\_PR.CPU0, DeviceObj)\r
80 External (PDC0)\r
81 External (CFGD)\r
82\r
83 Scope(\_PR.CPU0)\r
84 {\r
85 //OperationRegion (DEB0, SystemIO, 0x80, 1) //DBG\r
86 //Field (DEB0, ByteAcc,NoLock,Preserve) //DBG\r
87 //{ DBG8, 8,} //DBG\r
88\r
89 Name(_PPC, 0) // Initialize as All States Available.\r
90\r
91 // NOTE: For CMP systems; this table is not loaded unless\r
92 // the required driver support is present.\r
93 // So, we do not check for those cases here.\r
94 //\r
95 // CFGD[0] = GV3 Capable/Enabled\r
96 // PDCx[0] = OS Capable of Hardware P-State control\r
97 //\r
98 Method(_PCT,0)\r
99 {\r
100 If(LAnd(And(CFGD,0x0001), And(PDC0,0x0001)))\r
101 {\r
102 //Store(0xA0,DBG8) //DBG\r
103 Return(Package() // Native Mode\r
104 {\r
105 ResourceTemplate(){Register(FfixedHW, 0, 0, 0)},\r
106 ResourceTemplate(){Register(FfixedHW, 0, 0, 0)}\r
107 })\r
108 }\r
109 // @NOTE: IO Trap is not supported. Therefore should not expose any IO interface for _PCT\r
110 // For all other cases, report control through the\r
111 // SMI interface. (The port used for SMM control is fixed up\r
112 // by the initialization code.)\r
113 //\r
114 Return(Package() // SMM Mode\r
115 {\r
116 ResourceTemplate(){Register(FfixedHW, 0, 0, 0)},\r
117 ResourceTemplate(){Register(FfixedHW, 0, 0, 0)}\r
118 })\r
119 }\r
120\r
121\r
122 // NOTE: For CMP systems; this table is not loaded if MP\r
123 // driver support is not present or P-State are disabled.\r
124 //\r
125 Method(_PSS,0)\r
126 {\r
127 //\r
128 // Report NSPP if:\r
129 // (1) GV3 capable (Not checked, see above.)\r
130 // (2) Driver support direct hardware control\r
131 // (3) MP driver support present (Not checked, see above.)\r
132 // else;\r
133 // Report SPSS\r
134 //\r
135 // PDCx[0] = OS Capable of Hardware P-State control\r
136 //\r
137 If(And(PDC0,0x0001)){\r
138 //Store(0xB0,DBG8) //DBG\r
139 Return(NPSS)\r
140 }\r
141 //Store(0xBF,DBG8) //DBG\r
142 // Otherwise, report SMM mode\r
143 //\r
144 Return(SPSS)\r
145\r
146 }\r
147\r
148 Name(SPSS,Package()\r
149 {\r
150 Package(){0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000},\r
151 Package(){0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000},\r
152 Package(){0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000},\r
153 Package(){0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000},\r
154 Package(){0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000},\r
155 Package(){0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000},\r
156 Package(){0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000},\r
157 Package(){0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000},\r
158 Package(){0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000},\r
159 Package(){0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000},\r
160 Package(){0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000},\r
161 Package(){0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000},\r
162 Package(){0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000},\r
163 Package(){0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000},\r
164 Package(){0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000},\r
165 Package(){0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000}\r
166 })\r
167\r
168 Name(NPSS,Package()\r
169 {\r
170 Package(){0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000},\r
171 Package(){0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000},\r
172 Package(){0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000},\r
173 Package(){0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000},\r
174 Package(){0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000},\r
175 Package(){0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000},\r
176 Package(){0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000},\r
177 Package(){0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000},\r
178 Package(){0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000},\r
179 Package(){0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000},\r
180 Package(){0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000},\r
181 Package(){0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000},\r
182 Package(){0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000},\r
183 Package(){0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000},\r
184 Package(){0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000},\r
185 Package(){0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000, 0x80000000}\r
186 })\r
187\r
188 // The _PSD object provides information to the OSPM related\r
189 // to P-State coordination between processors in a multi-processor\r
190 // configurations.\r
191 //\r
192 Method(_PSD,0)\r
193 {\r
194 //\r
195 // IF CMP is supported/enabled\r
196 // IF quad core processor\r
197 // IF PDC[11]\r
198 // Report 4 processors and HW_ALL as the coordination type\r
199 // ELSE\r
200 // Report 4 processors and SW_ALL as the coordination type\r
201 // ELSE\r
202 // IF PDC[11]\r
203 // Report 2 processors and HW_ALL as the coordination type\r
204 // ELSE\r
205 // Report 2 processors and SW_ALL as the coordination type\r
206 // ELSE\r
207 // Report 1 processor and SW_ALL as the coordination type\r
208 // (Domain 0)\r
209 //\r
210 // CFGD[24] = Two or more cores enabled\r
211 // CFGD[23] = Four cores enabled\r
212 // PDCx[11] = Hardware coordination with hardware feedback\r
213 //\r
214\r
215 If(And(CFGD,0x1000000)) // CMP Enabled.\r
216 {\r
217 If(And(CFGD,0x800000)) // 2 or 4 process.\r
218 {\r
219 If(And(PDC0,0x0800))\r
220 {\r
221 Return(Package(){ // HW_ALL\r
222 Package(){\r
223 5, // # entries.\r
224 0, // Revision.\r
225 0, // Domain #.\r
226 0xFE, // Coord Type- HW_ALL.\r
227 4 // # processors.\r
228 }\r
229 })\r
230 } // If(And(PDC0,0x0800))\r
231 Return(Package(){ // SW_ALL\r
232 Package(){\r
233 5, // # entries.\r
234 0, // Revision.\r
235 0, // Domain #.\r
236 0xFC, // Coord Type- SW_ALL.\r
237 4 // # processors.\r
238 }\r
239 })\r
240 } else {\r
241 Return(Package(){ // HW_ALL\r
242 Package(){\r
243 5, // # entries.\r
244 0, // Revision.\r
245 0, // Domain #.\r
246 0xFE, // Coord Type- HW_ALL.\r
247 2 // # processors.\r
248 }\r
249 })\r
250 }\r
251 } // If(And(CFGD,0x1000000)) // CMP Enabled.\r
252\r
253 Return(Package(){ // SW_ALL\r
254 Package(){\r
255 5, // # entries.\r
256 0, // Revision.\r
257 0, // Domain #.\r
258 0xFC, // Coord Type- SW_ALL.\r
259 1 // # processors.\r
260 }\r
261 })\r
262 } // Method(_PSD,0)\r
263 } // Scope(\_PR.CPU0)\r
264} // End of Definition Block\r
265\r
266\r