187{
193
194 if (CommandTokens.size() != 1)
195 {
196 ShowMessages("incorrect use of the '%s'\n\n",
198
200 return;
201 }
202
203
204
205
207 {
208 return;
209 }
210
211
212
213
214 ShowMessages("*** (%s Mode) PHYSICAL LAPIC ID = %u, Ver = 0x%x, MaxLvtEntry = %d, DirectedEOI = P%d/E%d, (SW: '%s')\n"
215 " -> TPR = 0x%08x, PPR = 0x%08x\n"
216 " -> LDR = 0x%08x, SVR = 0x%08x, Err = 0x%08x\n"
217 " -> LVT_INT0 = 0x%08x, LVT_INT1 = 0x%08x\n"
218 " -> LVT_CMCI = 0x%08x, LVT_PMCR = 0x%08x\n"
219 " -> LVT_TMR = 0x%08x, LVT_TSR = 0x%08x\n"
220 " -> LVT_ERR = 0x%08x\n"
221 " -> InitialCount = 0x%08x, CurrentCount = 0x%08x, DivideConfig = 0x%08x\n",
222 IsUsingX2APIC ? "X2APIC" : "XAPIC",
225 (LocalApic.
Version & 0xFF0000) >> 16,
244
245
246
247
248 ShowMessages("ISR : ");
249
250 for (i = 0; i < 8; i++)
251 {
252 k = 1;
254 for (j = 0; j < 32; j++)
255 {
256 if (0 != (Reg & k))
257 {
258 ShowMessages(
"0x%02hhx ", (
UINT8)(i * 32 + j));
259 }
260 k = k << 1;
261 }
262 }
263 ShowMessages("\n");
264
265 ShowMessages("TMR : ");
266
267 for (i = 0; i < 8; i++)
268 {
269 k = 1;
271 for (j = 0; j < 32; j++)
272 {
273 if (Reg & k)
274 {
275 ShowMessages(
"0x%02hhx ", (
UINT8)(i * 32 + j));
276 }
277 k = k << 1;
278 }
279 }
280
281 ShowMessages("\n");
282
283 ShowMessages("IRR : ");
284
285 for (i = 0; i < 8; i++)
286 {
287 k = 1;
289 for (j = 0; j < 32; j++)
290 {
291 if (Reg & k)
292 {
293 ShowMessages(
"0x%02hhx ", (
UINT8)(i * 32 + j));
294 }
295 k = k << 1;
296 }
297 }
298
299 ShowMessages("\n");
300}
BOOLEAN HyperDbgGetLocalApic(PLAPIC_PAGE LocalApic, PBOOLEAN IsUsingX2APIC)
Request to get Local APIC.
Definition apic.cpp:169
VOID CommandApicHelp()
help of the !apic command
Definition apic.cpp:26
std::string GetCaseSensitiveStringFromCommandToken(CommandToken TargetToken)
Get case sensitive string from command token.
Definition common.cpp:467
UINT32 LvtLINT1
Definition RequestStructures.h:1192
UINT32 LvtError
Definition RequestStructures.h:1195
UINT32 TMR[32]
Definition RequestStructures.h:1162
UINT32 Version
Definition RequestStructures.h:1131
UINT32 LvtCmci
Definition RequestStructures.h:1171
UINT32 LvtThermalSensor
Definition RequestStructures.h:1183
UINT32 InitialCount
Definition RequestStructures.h:1198
UINT32 CurrentCount
Definition RequestStructures.h:1201
UINT32 ISR[32]
Definition RequestStructures.h:1160
UINT32 DivideConfiguration
Definition RequestStructures.h:1206
UINT32 TPR
Definition RequestStructures.h:1136
UINT32 ErrorStatus
Definition RequestStructures.h:1166
UINT32 LvtTimer
Definition RequestStructures.h:1180
UINT32 LogicalDestination
Definition RequestStructures.h:1151
UINT32 IRR[32]
Definition RequestStructures.h:1164
UINT32 LvtLINT0
Definition RequestStructures.h:1189
UINT32 Id
Definition RequestStructures.h:1128
UINT32 ProcessorPriority
Definition RequestStructures.h:1142
UINT32 LvtPerfMonCounters
Definition RequestStructures.h:1186
UINT32 SpuriousInterruptVector
Definition RequestStructures.h:1157