4 Copyright (c) 2006 -2007, Intel Corporation All rights
5 reserved. This program and the accompanying materials are
6 licensed and made available under the terms and conditions of
7 the BSD License which accompanies this distribution. The full
8 text of the license may be found at
9 http://opensource.org/licenses/bsd-license.php
11 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
12 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
14 Module Name: PalCallLib.h
18 #ifndef __PAL_CALL_LIB_H__
19 #define __PAL_CALL_LIB_H__
21 #define PAL_SUCCESS 0x0
24 // CacheType of PAL_CACHE_FLUSH.
26 #define PAL_CACHE_FLUSH_INSTRUCTION_ALL 1
27 #define PAL_CACHE_FLUSH_DATA_ALL 2
28 #define PAL_CACHE_FLUSH_ALL 3
29 #define PAL_CACHE_FLUSH_SYNC_TO_DATA 4
33 // Bitmask of Opearation of PAL_CACHE_FLUSH.
35 #define PAL_CACHE_FLUSH_INVALIDATE_LINES BIT0
36 #define PAL_CACHE_FLUSH_NO_INVALIDATE_LINES 0
37 #define PAL_CACHE_FLUSH_POLL_INTERRUPT BIT1
38 #define PAL_CACHE_FLUSH_NO_INTERRUPT 0
42 PAL Procedure - PAL_CACHE_FLUSH.
44 Flush the instruction or data caches. It is required by IPF.
45 The PAL procedure supports the Static Registers calling
46 convention. It could be called at virtual mode and physical
49 @param Index Index of PAL_CACHE_FLUSH within the
50 list of PAL procedures.
52 @param CacheType Unsigned 64-bit integer indicating
55 @param Operation Formatted bit vector indicating the
56 operation of this call.
58 @param ProgressIndicator Unsigned 64-bit integer specifying
59 the starting position of the flush
62 @return R9 Unsigned 64-bit integer specifying the vector
63 number of the pending interrupt.
65 @return R10 Unsigned 64-bit integer specifying the
66 starting position of the flush operation.
68 @return R11 Unsigned 64-bit integer specifying the vector
69 number of the pending interrupt.
71 @return Status 2 - Call completed without error, but a PMI
72 was taken during the execution of this
75 @return Status 1 - Call has not completed flushing due to
78 @return Status 0 - Call completed without error
80 @return Status -2 - Invalid argument
82 @return Status -3 - Call completed with error
85 #define PAL_CACHE_FLUSH 1
89 // Attributes of PAL_CACHE_CONFIG_INFO1
91 #define PAL_CACHE_ATTR_WT 0
92 #define PAL_CACHE_ATTR_WB 1
95 // PAL_CACHE_CONFIG_INFO1.StoreHint
97 #define PAL_CACHE_STORE_TEMPORAL 0
98 #define PAL_CACHE_STORE_NONE_TEMPORAL 3
101 // PAL_CACHE_CONFIG_INFO1.StoreHint
103 #define PAL_CACHE_STORE_TEMPORAL_LVL_1 0
104 #define PAL_CACHE_STORE_NONE_TEMPORAL_LVL_ALL 3
107 // PAL_CACHE_CONFIG_INFO1.StoreHint
109 #define PAL_CACHE_LOAD_TEMPORAL_LVL_1 0
110 #define PAL_CACHE_LOAD_NONE_TEMPORAL_LVL_1 1
111 #define PAL_CACHE_LOAD_NONE_TEMPORAL_LVL_ALL 3
114 // Detail the characteristics of a given processor controlled
115 // cache in the cache hierarchy.
118 UINT64 IsUnified
: 1;
119 UINT64 Attributes
: 2;
120 UINT64 Associativity
:8;
123 UINT64 StoreLatency
:8;
126 } PAL_CACHE_INFO_RETURN1
;
129 // Detail the characteristics of a given processor controlled
130 // cache in the cache hierarchy.
134 UINT64 AliasBoundary
:8;
137 } PAL_CACHE_INFO_RETURN2
;
141 PAL Procedure - PAL_CACHE_INFO.
143 Return detailed instruction or data cache information. It is
144 required by IPF. The PAL procedure supports the Static
145 Registers calling convention. It could be called at virtual
146 mode and physical mode.
148 @param Index Index of PAL_CACHE_INFO within the list of
151 @param CacheLevel Unsigned 64-bit integer specifying the
152 level in the cache hierarchy for which
153 information is requested. This value must
154 be between 0 and one less than the value
155 returned in the cache_levels return value
156 from PAL_CACHE_SUMMARY.
158 @param CacheType Unsigned 64-bit integer with a value of 1
159 for instruction cache and 2 for data or
160 unified cache. All other values are
163 @param Reserved Should be 0.
166 @return R9 Detail the characteristics of a given
167 processor controlled cache in the cache
168 hierarchy. See PAL_CACHE_INFO_RETURN1.
170 @return R10 Detail the characteristics of a given
171 processor controlled cache in the cache
172 hierarchy. See PAL_CACHE_INFO_RETURN2.
174 @return R11 Reserved with 0.
177 @return Status 0 - Call completed without error
179 @return Status -2 - Invalid argument
181 @return Status -3 - Call completed with error
184 #define PAL_CACHE_INFO 2
189 // Level of PAL_CACHE_INIT.
191 #define PAL_CACHE_INIT_ALL 0xffffffffffffffffULL
196 #define PAL_CACHE_INIT_TYPE_INSTRUCTION 0x1
197 #define PAL_CACHE_INIT_TYPE_DATA 0x2
198 #define PAL_CACHE_INIT_TYPE_INSTRUCTION_AND_DATA 0x3
201 // Restrict of PAL_CACHE_INIT.
203 #define PAL_CACHE_INIT_NO_RESTRICT 0
204 #define PAL_CACHE_INIT_RESTRICTED 1
208 PAL Procedure - PAL_CACHE_INIT.
210 Initialize the instruction or data caches. It is required by
211 IPF. The PAL procedure supports the Static Registers calling
212 convention. It could be called at physical mode.
214 @param Index Index of PAL_CACHE_INIT within the list of PAL
217 @param Level Unsigned 64-bit integer containing the level of
218 cache to initialize. If the cache level can be
219 initialized independently, only that level will
220 be initialized. Otherwise
221 implementation-dependent side-effects will
224 @param CacheType Unsigned 64-bit integer with a value of 1 to
225 initialize the instruction cache, 2 to
226 initialize the data cache, or 3 to
227 initialize both. All other values are
230 @param Restrict Unsigned 64-bit integer with a value of 0 or
231 1. All other values are reserved. If
232 restrict is 1 and initializing the specified
233 level and cache_type of the cache would
234 cause side-effects, PAL_CACHE_INIT will
235 return -4 instead of initializing the cache.
238 @return Status 0 - Call completed without error
240 @return Status -2 - Invalid argument
242 @return Status -3 - Call completed with error.
244 @return Status -4 - Call could not initialize the specified
245 level and cache_type of the cache without
246 side-effects and restrict was 1.
249 #define PAL_CACHE_INIT 3
253 // PAL_CACHE_PROTECTION.Method.
255 #define PAL_CACHE_PROTECTION_NONE_PROTECT 0
256 #define PAL_CACHE_PROTECTION_ODD_PROTECT 1
257 #define PAL_CACHE_PROTECTION_EVEN_PROTECT 2
258 #define PAL_CACHE_PROTECTION_ECC_PROTECT 3
263 // PAL_CACHE_PROTECTION.TagOrData.
265 #define PAL_CACHE_PROTECTION_PROTECT_DATA 0
266 #define PAL_CACHE_PROTECTION_PROTECT_TAG 1
267 #define PAL_CACHE_PROTECTION_PROTECT_TAG_ANDTHEN_DATA 2
268 #define PAL_CACHE_PROTECTION_PROTECT_DATA_ANDTHEN_TAG 3
271 // 32-bit protection information structures.
280 } PAL_CACHE_PROTECTION
;
284 PAL Procedure - PAL_CACHE_PROT_INFO.
286 Return instruction or data cache protection information. It is
287 required by IPF. The PAL procedure supports the Static
288 Registers calling convention. It could be called at physical
289 mode and Virtual mode.
291 @param Index Index of PAL_CACHE_PROT_INFO within the list of
294 @param CacheLevel Unsigned 64-bit integer specifying the level
295 in the cache hierarchy for which information
296 is requested. This value must be between 0
297 and one less than the value returned in the
298 cache_levels return value from
301 @param CacheType Unsigned 64-bit integer with a value of 1
302 for instruction cache and 2 for data or
303 unified cache. All other values are
306 @return R9 Detail the characteristics of a given
307 processor controlled cache in the cache
308 hierarchy. See PAL_CACHE_PROTECTION[0..1].
310 @return R10 Detail the characteristics of a given
311 processor controlled cache in the cache
312 hierarchy. See PAL_CACHE_PROTECTION[2..3].
314 @return R11 Detail the characteristics of a given
315 processor controlled cache in the cache
316 hierarchy. See PAL_CACHE_PROTECTION[4..5].
319 @return Status 0 - Call completed without error
321 @return Status -2 - Invalid argument
323 @return Status -3 - Call completed with error.
326 #define PAL_CACHE_PROT_INFO 38
330 @param ThreadId The thread identifier of the logical
331 processor for which information is being
332 returned. This value will be unique on a per
335 @param CoreId The core identifier of the logical processor
336 for which information is being returned.
337 This value will be unique on a per physical
338 processor package basis.
342 UINT64 ThreadId
: 16;
343 UINT64 Reserved1
: 16;
345 UINT64 Reserved2
: 16;
346 } PAL_PCOC_N_CACHE_INFO1
;
350 @param LogicalAddress Logical address: geographical address
351 of the logical processor for which
352 information is being returned. This is
353 the same value that is returned by the
354 PAL_FIXED_ADDR procedure when it is
355 called on the logical processor.
359 UINT64 LogicalAddress
: 16;
360 UINT64 Reserved1
: 16;
361 UINT64 Reserved2
: 32;
362 } PAL_PCOC_N_CACHE_INFO2
;
366 PAL Procedure - PAL_CACHE_SHARED_INFO.
368 Returns information on which logical processors share caches.
369 It is optional. The PAL procedure supports the Static
370 Registers calling convention. It could be called at physical
371 mode and Virtual mode.
373 @param Index Index of PAL_CACHE_SHARED_INFO within the list
376 @param CacheLevel Unsigned 64-bit integer specifying the
377 level in the cache hierarchy for which
378 information is requested. This value must
379 be between 0 and one less than the value
380 returned in the cache_levels return value
381 from PAL_CACHE_SUMMARY.
383 @param CacheType Unsigned 64-bit integer with a value of 1
384 for instruction cache and 2 for data or
385 unified cache. All other values are
388 @param ProcNumber Unsigned 64-bit integer that specifies for
389 which logical processor information is
390 being requested. This input argument must
391 be zero for the first call to this
392 procedure and can be a maximum value of
393 one less than the number of logical
394 processors sharing this cache, which is
395 returned by the num_shared return value.
397 @return R9 Unsigned integer that returns the number of
398 logical processors that share the processor
399 cache level and type, for which information was
402 @return R10 The format of PAL_PCOC_N_CACHE_INFO1.
404 @return R11 The format of PAL_PCOC_N_CACHE_INFO2.
406 @return Status 0 - Call completed without error
408 @return Status -1 - Unimplemented procedure
410 @return Status -2 - Invalid argument
412 @return Status -3 - Call completed with error.
415 #define PAL_CACHE_SHARED_INFO 43
420 PAL Procedure - PAL_CACHE_SUMMARY.
422 Return a summary of the cache hierarchy. It is required by
423 IPF. The PAL procedure supports the Static Registers calling
424 convention. It could be called at physical mode and Virtual
427 @param Index Index of PAL_CACHE_SUMMARY within the list of
431 @return R9 CacheLevels Unsigned 64-bit integer denoting the
432 number of levels of cache
433 implemented by the processor.
434 Strictly, this is the number of
435 levels for which the cache
436 controller is integrated into the
437 processor (the cache SRAMs may be
438 external to the processor).
440 @return R10 UniqueCaches Unsigned 64-bit integer denoting the
441 number of unique caches implemented
442 by the processor. This has a maximum
443 of 2*cache_levels, but may be less
444 if any of the levels in the cache
445 hierarchy are unified caches or do
446 not have both instruction and data
449 @return Status 0 - Call completed without error
451 @return Status -2 - Invalid argument
453 @return Status -3 - Call completed with error.
456 #define PAL_CACHE_SUMMARY 4
460 // Virtual Memory Attributes implemented by processor.
462 #define PAL_MEMORY_ATTR_WB 0
463 #define PAL_MEMORY_ATTR_WC 6
464 #define PAL_MEMORY_ATTR_UC 4
465 #define PAL_MEMORY_ATTR_UCE 5
466 #define PAL_MEMORY_ATTR_NATPAGE 7
470 PAL Procedure - PAL_MEM_ATTRIB.
472 Return a list of supported memory attributes.. It is required
473 by IPF. The PAL procedure supports the Static Registers calling
474 convention. It could be called at physical mode and Virtual
477 @param Index Index of PAL_MEM_ATTRIB within the list of PAL
481 @return R9 Attributes 8-bit vector of memory attributes
482 implemented by processor. See Virtual
483 Memory Attributes above.
485 @return Status 0 - Call completed without error
487 @return Status -2 - Invalid argument
489 @return Status -3 - Call completed with error.
493 #define PAL_MEM_ATTRIB 5
497 PAL Procedure - PAL_PREFETCH_VISIBILITY.
499 Used in architected sequence to transition pages from a
500 cacheable, speculative attribute to an uncacheable attribute.
501 It is required by IPF. The PAL procedure supports the Static
502 Registers calling convention. It could be called at physical
503 mode and Virtual mode.
505 @param Index Index of PAL_PREFETCH_VISIBILITY within the list
508 @param TransitionType Unsigned integer specifying the type
509 of memory attribute transition that is
512 @return Status 1 Call completed without error; this
513 call is not necessary on remote
516 @return Status 0 - Call completed without error
518 @return Status -2 - Invalid argument
520 @return Status -3 - Call completed with error.
523 #define PAL_PREFETCH_VISIBILITY 41
527 PAL Procedure - PAL_PTCE_INFO.
529 Return information needed for ptc.e instruction to purge
530 entire TC. It is required by IPF. The PAL procedure supports
531 the Static Registers calling convention. It could be called at
532 physical mode and Virtual mode.
534 @param Index Index of PAL_PTCE_INFO within the list
537 @return R9 Unsigned 64-bit integer denoting the beginning
538 address to be used by the first PTCE instruction
541 @return R10 Two unsigned 32-bit integers denoting the loop
542 counts of the outer (loop 1) and inner (loop 2)
543 purge loops. count1 (loop 1) is contained in bits
544 63:32 of the parameter, and count2 (loop 2) is
545 contained in bits 31:0 of the parameter.
547 @return R11 Two unsigned 32-bit integers denoting the loop
548 strides of the outer (loop 1) and inner (loop 2)
549 purge loops. stride1 (loop 1) is contained in bits
550 63:32 of the parameter, and stride2 (loop 2) is
551 contained in bits 31:0 of the parameter.
553 @return Status 0 - Call completed without error
555 @return Status -2 - Invalid argument
557 @return Status -3 - Call completed with error.
560 #define PAL_PTCE_INFO 6
566 @param NumberSets Unsigned 8-bit integer denoting the number
567 of hash sets for the specified level
568 (1=fully associative)
570 @param NumberWays Unsigned 8-bit integer denoting the
571 associativity of the specified level
574 @param NumberEntries Unsigned 16-bit integer denoting the
575 number of entries in the specified TC.
578 @param PageSizeIsOptimized Flag denoting whether the
579 specified level is optimized for
580 the region's preferred page size
581 (1=optimized) tc_pages indicates
582 which page sizes are usable by
583 this translation cache.
585 @param TcIsUnified Flag denoting whether the specified TC is
588 @param EntriesReduction Flag denoting whether installed
589 translation registers will reduce
590 the number of entries within the
597 UINT64 NumberEntries
:16;
598 UINT64 PageSizeIsOptimized
:1;
599 UINT64 TcIsUnified
:1;
600 UINT64 EntriesReduction
:1;
605 PAL Procedure - PAL_VM_INFO.
607 Return detailed information about virtual memory features
608 supported in the processor. It is required by IPF. The PAL
609 procedure supports the Static Registers calling convention. It
610 could be called at physical mode and Virtual mode.
612 @param Index Index of PAL_VM_INFO within the list
615 @param TcLevel Unsigned 64-bit integer specifying the level
616 in the TLB hierarchy for which information is
617 required. This value must be between 0 and one
618 less than the value returned in the
619 vm_info_1.num_tc_levels return value from
622 @param TcType Unsigned 64-bit integer with a value of 1 for
623 instruction translation cache and 2 for data
624 or unified translation cache. All other values
627 @return R9 8-byte formatted value returning information
628 about the specified TC. See PAL_TC_INFO above.
630 @return R10 64-bit vector containing a bit for each page
631 size supported in the specified TC, where bit
632 position n indicates a page size of 2**n.
634 @return Status 0 - Call completed without error
636 @return Status -2 - Invalid argument
638 @return Status -3 - Call completed with error.
641 #define PAL_VM_INFO 7
646 PAL Procedure - PAL_VM_PAGE_SIZE.
648 Return virtual memory TC and hardware walker page sizes
649 supported in the processor. It is required by IPF. The PAL
650 procedure supports the Static Registers calling convention. It
651 could be called at physical mode and Virtual mode.
653 @param Index Index of PAL_VM_PAGE_SIZE within the list
657 @return R9 64-bit vector containing a bit for each
658 architected page size that is supported for
659 TLB insertions and region registers.
661 @return R10 64-bit vector containing a bit for each
662 architected page size supported for TLB purge
665 @return Status 0 - Call completed without error
667 @return Status -2 - Invalid argument
669 @return Status -3 - Call completed with error.
672 #define PAL_VM_PAGE_SIZE 34
676 @param WalkerPresent 1-bit flag indicating whether a hardware
677 TLB walker is implemented (1 = walker
680 @param WidthOfPhysicalAddress Unsigned 7-bit integer
681 denoting the number of bits of
682 physical address implemented.
684 @param WidthOfKey Unsigned 8-bit integer denoting the number
685 of bits mplemented in the PKR.key field.
687 @param MaxPkrIndex Unsigned 8-bit integer denoting the
688 maximum PKR index (number of PKRs-1).
690 @param HashTagId Unsigned 8-bit integer which uniquely
691 identifies the processor hash and tag
694 @param MaxDtrIndex Unsigned 8 bit integer denoting the
695 maximum data translation register index
696 (number of dtr entries - 1).
698 @param MaxItrIndex Unsigned 8 bit integer denoting the
699 maximum instruction translation register
700 index (number of itr entries - 1).
702 @param NumberOfUniqueTc Unsigned 8-bit integer denoting the
703 number of unique TCs implemented.
707 @param NumberOfTcLevels Unsigned 8-bit integer denoting the
712 UINT64 WalkerPresent
:1;
713 UINT64 WidthOfPhysicalAddress
: 7;
715 UINT64 MaxPkrIndex
:8;
717 UINT64 MaxDtrIndex
:8;
718 UINT64 MaxItrIndex
:8;
719 UINT64 NumberOfUniqueTc
:8;
720 UINT64 NumberOfTcLevels
:8;
725 @param WidthOfVirtualAddress Unsigned 8-bit integer denoting
726 is the total number of virtual
729 @param WidthOfRid Unsigned 8-bit integer denoting the number
730 of bits implemented in the RR.rid field.
732 @param MaxPurgedTlbs Unsigned 16 bit integer denoting the
733 maximum number of concurrent outstanding
734 TLB purges allowed by the processor. A
735 value of 0 indicates one outstanding
736 purge allowed. A value of 216-1
737 indicates no limit on outstanding
738 purges. All other values indicate the
739 actual number of concurrent outstanding
744 UINT64 WidthOfVirtualAddress
:8;
746 UINT64 MaxPurgedTlbs
:16;
752 PAL Procedure - PAL_VM_SUMMARY.
754 Return summary information about virtual memory features
755 supported in the processor. It is required by IPF. The PAL
756 procedure supports the Static Registers calling convention. It
757 could be called at physical mode and Virtual mode.
759 @param Index Index of PAL_VM_SUMMARY within the list
763 @return R9 8-byte formatted value returning global virtual
764 memory information. See PAL_VM_INFO1 above.
766 @return R10 8-byte formatted value returning global virtual
767 memory information. See PAL_VM_INFO2 above.
769 @return Status 0 - Call completed without error
771 @return Status -2 - Invalid argument
773 @return Status -3 - Call completed with error.
776 #define PAL_VM_SUMMARY 8
780 // Bit mask of TR_valid flag.
782 #define PAL_TR_ACCESS_RIGHT_IS_VALID BIT0
783 #define PAL_TR_PRIVILEGE_LEVEL_IS_VALID BIT1
784 #define PAL_TR_DIRTY_IS_VALID BIT2
785 #define PAL_TR_MEMORY_ATTR_IS_VALID BIT3
790 PAL Procedure - PAL_VM_TR_READ.
792 Read contents of a translation register. It is required by
793 IPF. The PAL procedure supports the Stacked Register calling
794 convention. It could be called at physical mode.
796 @param Index Index of PAL_VM_TR_READ within the list
799 @param RegNumber Unsigned 64-bit number denoting which TR to
802 @param TrType Unsigned 64-bit number denoting whether to
803 read an ITR (0) or DTR (1). All other values
806 @param TrBuffer 64-bit pointer to the 32-byte memory buffer in
807 which translation data is returned.
809 @return R9 Formatted bit vector denoting which fields are
810 valid. See TR_valid above.
812 @return Status 0 - Call completed without error
814 @return Status -2 - Invalid argument
816 @return Status -3 - Call completed with error.
819 #define PAL_VM_TR_READ 261
825 // Bit Mask of Processor Bus Fesatures .
830 When 0, bus data errors are detected and single bit errors are
831 corrected. When 1, no error detection or correction is done.
834 #define PAL_BUS_DISABLE_DATA_ERROR_SIGNALLING BIT63
839 When 0, bus address errors are signalled on the bus. When 1,
840 no bus errors are signalled on the bus. If Disable Bus Address
841 Error Checking is 1, this bit is ignored.
844 #define PAL_BUS_DISABLE_ADDRESS_ERROR_SIGNALLING BIT62
851 When 0, bus errors are detected, single bit errors are
852 corrected., and a CMCI or MCA is generated internally to the
853 processor. When 1, no bus address errors are detected or
857 #define PAL_BUS_DISABLE_ADDRESS_ERROR_CHECK BIT61
862 When 0, bus protocol errors (BINIT#) are signaled by the
863 processor on the bus. When 1, bus protocol errors (BINIT#) are
864 not signaled on the bus. If Disable Bus Initialization Event
865 Checking is 1, this bit is ignored.
868 #define PAL_BUS_DISABLE_INITIALIZATION_EVENT_SIGNALLING BIT60
873 When 0, bus protocol errors (BINIT#) are detected and sampled
874 and an MCA is generated internally to the processor. When 1,
875 the processor will ignore bus protocol error conditions
879 #define PAL_BUS_DISABLE_INITIALIZATION_EVENT_CHECK BIT59
885 When 0, BERR# is signalled if a bus error is detected. When 1,
886 bus errors are not signalled on the bus.
889 #define PAL_BUS_DISABLE_ERROR_SIGNALLING BIT58
896 When 0, BERR# is signalled when internal processor requestor
897 initiated bus errors are detected. When 1, internal requester
898 bus errors are not signalled on the bus.
901 #define PAL_BUS_DISABLE__INTERNAL_ERROR_SIGNALLING BIT57
906 When 0, the processor takes an MCA if BERR# is asserted. When
907 1, the processor ignores the BERR# signal.
910 #define PAL_BUS_DISABLE_ERROR_CHECK BIT56
915 When 0, the processor asserts BINIT# if it detects a parity
916 error on the signals which identify the transactions to which
917 this is a response. When 1, the processor ignores parity on
921 #define PAL_BUS_DISABLE_RSP_ERROR_CHECK BIT55
926 When 0, the in-order transaction queue is limited only by the
927 number of hardware entries. When 1, the processor's in-order
928 transactions queue is limited to one entry.
931 #define PAL_BUS_DISABLE_TRANSACTION_QUEUE BIT54
935 Enable a bus cache line replacement transaction when a cache
936 line in the exclusive state is replaced from the highest level
937 processor cache and is not present in the lower level processor
938 caches. When 0, no bus cache line replacement transaction will
939 be seen on the bus. When 1, bus cache line replacement
940 transactions will be seen on the bus when the above condition is
944 #define PAL_BUS_ENABLE_EXCLUSIVE_CACHE_LINE_REPLACEMENT BIT53
949 Enable a bus cache line replacement transaction when a cache
950 line in the shared or exclusive state is replaced from the
951 highest level processor cache and is not present in the lower
952 level processor caches.
953 When 0, no bus cache line replacement transaction will be seen
954 on the bus. When 1, bus cache line replacement transactions
955 will be seen on the bus when the above condition is detected.
958 #define PAL_BUS_ENABLE_SHARED_CACHE_LINE_REPLACEMENT BIT52
964 When 0, the data bus is configured at the 2x data transfer
965 rate.When 1, the data bus is configured at the 1x data
966 transfer rate, 30 Opt. Req. Disable Bus Lock Mask. When 0, the
967 processor executes locked transactions atomically. When 1, the
968 processor masks the bus lock signal and executes locked
969 transactions as a non-atomic series of transactions.
972 #define PAL_BUS_ENABLE_HALF_TRANSFER BIT30
976 When 0, the processor will deassert bus request when finished
977 with each transaction. When 1, the processor will continue to
978 assert bus request after it has finished, if it was the last
979 agent to own the bus and if there are no other pending
983 #define PAL_BUS_REQUEST_BUS_PARKING BIT29
988 PAL Procedure - PAL_BUS_GET_FEATURES.
990 Return configurable processor bus interface features and their
991 current settings. It is required by IPF. The PAL procedure
992 supports the Stacked Register calling convention. It could be
993 called at physical mode.
995 @param Index Index of PAL_BUS_GET_FEATURES within the list
998 @return R9 64-bit vector of features implemented.
999 (1=implemented, 0=not implemented)
1001 @return R10 64-bit vector of current feature settings.
1003 @return R11 64-bit vector of features controllable by
1004 software. (1=controllable, 0= not controllable)
1006 @return Status 0 - Call completed without error
1008 @return Status -2 - Invalid argument
1010 @return Status -3 - Call completed with error.
1013 #define PAL_BUS_GET_FEATURES 9
1017 PAL Procedure - PAL_BUS_SET_FEATURES.
1019 Enable or disable configurable features in processor bus
1020 interface. It is required by IPF. It is required by IPF. The PAL procedure
1021 supports the Static Registers calling convention. It could be
1022 called at physical mode.
1024 @param Index Index of PAL_BUS_SET_FEATURES within the list
1027 @param FeatureSelect 64-bit vector denoting desired state of
1028 each feature (1=select, 0=non-select).
1030 @return Status 0 - Call completed without error
1032 @return Status -2 - Invalid argument
1034 @return Status -3 - Call completed with error.
1037 #define PAL_BUS_SET_FEATURES 10
1042 PAL Procedure - PAL_DEBUG_INFO.
1044 Return the number of instruction and data breakpoint
1045 registers. It is required by IPF. It is required by IPF. The
1046 PAL procedure supports the Static Registers calling
1047 convention. It could be called at physical mode and virtual
1050 @param Index Index of PAL_DEBUG_INFO within the list of PAL
1053 @return R9 Unsigned 64-bit integer denoting the number of
1054 pairs of instruction debug registers implemented
1057 @return R10 Unsigned 64-bit integer denoting the number of
1058 pairs of data debug registers implemented by the
1061 @return Status 0 - Call completed without error
1063 @return Status -2 - Invalid argument
1065 @return Status -3 - Call completed with error.
1068 #define PAL_DEBUG_INFO 11
1072 PAL Procedure - PAL_FIXED_ADDR.
1074 Return the fixed component of a processor¡¯s directed address.
1075 It is required by IPF. It is required by IPF. The PAL
1076 procedure supports the Static Registers calling convention. It
1077 could be called at physical mode and virtual mode.
1079 @param Index Index of PAL_FIXED_ADDR within the list of PAL
1082 @return R9 Fixed geographical address of this processor.
1085 @return Status 0 - Call completed without error
1087 @return Status -2 - Invalid argument
1089 @return Status -3 - Call completed with error.
1092 #define PAL_FIXED_ADDR 12
1096 PAL Procedure - PAL_FREQ_BASE.
1098 Return the frequency of the output clock for use by the
1099 platform, if generated by the processor. It is optinal. The
1100 PAL procedure supports the Static Registers calling
1101 convention. It could be called at physical mode and virtual
1104 @param Index Index of PAL_FREQ_BASE within the list of PAL
1107 @return R9 Base frequency of the platform if generated by the
1111 @return Status 0 - Call completed without error
1113 @return Status -1 - Unimplemented procedure
1115 @return Status -2 - Invalid argument
1117 @return Status -3 - Call completed with error.
1120 #define PAL_FREQ_BASE 13
1125 PAL Procedure - PAL_FREQ_RATIOS.
1127 Return ratio of processor, bus, and interval time counter to
1128 processor input clock or output clock for platform use, if
1129 generated by the processor. It is required by IPF. The PAL
1130 procedure supports the Static Registers calling convention. It
1131 could be called at physical mode and virtual mode.
1133 @param Index Index of PAL_FREQ_RATIOS within the list of PAL
1136 @return R9 Ratio of the processor frequency to the input
1137 clock of the processor, if the platform clock is
1138 generated externally or to the output clock to the
1139 platform, if the platform clock is generated by
1142 @return R10 Ratio of the bus frequency to the input clock of
1143 the processor, if the platform clock is generated
1144 externally or to the output clock to the platform,
1145 if the platform clock is generated by the
1148 @return R11 Ratio of the interval timer counter rate to input
1149 clock of the processor, if the platform clock is
1150 generated externally or to the output clock to the
1151 platform, if the platform clock is generated by
1154 @return Status 0 - Call completed without error
1156 @return Status -2 - Invalid argument
1158 @return Status -3 - Call completed with error.
1161 #define PAL_FREQ_RATIOS 14
1165 @param NumberOfLogicalProcessors Total number of logical
1166 processors on this physical
1167 processor package that are
1170 @param ThreadsPerCore Number of threads per core.
1172 @param CoresPerProcessor Total number of cores on this
1173 physical processor package.
1175 @param PhysicalProcessorPackageId Physical processor package
1176 identifier which was
1177 assigned at reset by the
1179 controller. This value may
1180 or may not be unique
1181 across the entire platform
1182 since it depends on the
1183 platform vendor's policy.
1186 UINT64 NumberOfLogicalProcessors
:16;
1187 UINT64 ThreadsPerCore
:8;
1189 UINT64 CoresPerProcessor
;
1191 UINT64 PhysicalProcessorPackageId
:8;
1193 } PAL_LOGICAL_PROCESSPR_OVERVIEW
;
1197 @param ThreadId The thread identifier of the logical
1198 processor for which information is being
1199 returned. This value will be unique on a per
1202 @param CoreId The core identifier of the logical processor
1203 for which information is being returned.
1204 This value will be unique on a per physical
1205 processor package basis.
1210 UINT64 Reserved1
:16;
1212 UINT64 Reserved2
:16;
1213 } PAL_LOGICAL_PROCESSORN_INFO1
;
1218 @param LogicalAddress Geographical address of the logical
1219 processor for which information is being
1220 returned. This is the same value that is
1221 returned by the PAL_FIXED_ADDR procedure
1222 when it is called on the logical
1228 UINT64 LogicalAddress
:16;
1230 } PAL_LOGICAL_PROCESSORN_INFO2
;
1234 PAL Procedure - PAL_LOGICAL_TO_PHYSICAL.
1236 Return information on which logical processors map to a
1237 physical processor die. It is optinal. The PAL procedure
1238 supports the Static Registers calling convention. It could be
1239 called at physical mode and virtual mode.
1241 @param Index Index of PAL_LOGICAL_TO_PHYSICAL within the list of PAL
1244 @param ProcessorNumber Signed 64-bit integer that specifies
1245 for which logical processor
1246 information is being requested. When
1247 this input argument is -1, information
1248 is returned about the logical
1249 processor on which the procedure call
1250 is made. This input argument must be
1251 in the range of 1 up to one less than
1252 the number of logical processors
1253 returned by num_log in the
1254 log_overview return value.
1257 @return R9 The format of PAL_LOGICAL_PROCESSPR_OVERVIEW.
1259 @return R10 The format of PAL_LOGICAL_PROCESSORN_INFO1.
1261 @return R11 The format of PAL_LOGICAL_PROCESSORN_INFO2.
1264 @return Status 0 - Call completed without error
1266 @return Status -1 - Unimplemented procedure
1268 @return Status -2 - Invalid argument
1270 @return Status -3 - Call completed with error.
1273 #define PAL_LOGICAL_TO_PHYSICAL 42
1278 @param NumberOfPmcPairs Unsigned 8-bit number defining the
1279 number of generic PMC/PMD pairs.
1281 @param WidthOfCounter Unsigned 8-bit number in the range
1282 0:60 defining the number of
1283 implemented counter bits.
1285 @param TypeOfCycleCounting Unsigned 8-bit number defining the
1286 event type for counting processor
1290 @param TypeOfRetiredInstructionBundle Retired Unsigned 8-bit
1292 event type for retired
1293 instruction bundles.
1297 UINT64 NumberOfPmcPairs
:8;
1298 UINT64 WidthOfCounter
:8;
1299 UINT64 TypeOfCycleCounting
:8;
1300 UINT64 TypeOfRetiredInstructionBundle
:8;
1302 } PAL_PERFORMANCE_INFO
;
1306 PAL Procedure - PAL_PERF_MON_INFO.
1308 Return the number and type of performance monitors. It is
1309 required by IPF. The PAL procedure supports the Static
1310 Registers calling convention. It could be called at physical
1311 mode and virtual mode.
1313 @param Index Index of PAL_PERF_MON_INFO within the list of
1316 @param PerformanceBuffer An address to an 8-byte aligned
1317 128-byte memory buffer.
1320 @return R9 Information about the performance monitors
1321 implemented. See PAL_PERFORMANCE_INFO;
1323 @return Status 0 - Call completed without error
1325 @return Status -2 - Invalid argument
1327 @return Status -3 - Call completed with error.
1330 #define PAL_PERF_MON_INFO 15
1334 PAL Procedure - PAL_PLATFORM_ADDR.
1336 Specify processor interrupt block address and I/O port space
1337 address. It is required by IPF. The PAL procedure supports the
1338 Static Registers calling convention. It could be called at
1339 physical mode and virtual mode.
1341 @param Index Index of PAL_PLATFORM_ADDR within the list of
1344 @param Type Unsigned 64-bit integer specifying the type of
1345 block. 0 indicates that the processor interrupt
1346 block pointer should be initialized. 1 indicates
1347 that the processor I/O block pointer should be
1350 @param Address Unsigned 64-bit integer specifying the address
1351 to which the processor I/O block or interrupt
1352 block shall be set. The address must specify
1353 an implemented physical address on the
1354 processor model, bit 63 is ignored.
1357 @return Status 0 - Call completed without error
1359 @return Status -1 - Unimplemented procedure.
1361 @return Status -2 - Invalid argument
1363 @return Status -3 - Call completed with error.
1366 #define PAL_PLATFORM_ADDR 16
1371 @param EnableBerrPromotion Bit63. Enable BERR promotion. When
1372 1, the Bus Error (BERR) signal is
1373 promoted to the Bus Initialization
1374 (BINIT) signal, and the BINIT pin
1375 is asserted on the occurrence of
1376 each Bus Error. Setting this bit
1377 has no effect if BINIT signalling
1379 PAL_BUS_GET/SET_FEATURES)
1381 @param EnableMcaPromotion Bit62, Enable MCA promotion. When
1382 1, machine check aborts (MCAs) are
1383 promoted to the Bus Error signal,
1384 and the BERR pin is assert on each
1385 occurrence of an MCA. Setting this
1386 bit has no effect if BERR
1387 signalling is disabled. (See
1388 PAL_BUS_GET/SET_FEATURES)
1390 @param EnableMcaToBinitPromotion Bit61, Enable MCA to BINIT
1391 promotion. When 1, machine
1392 check aborts (MCAs) are
1394 Initialization signal, and
1395 the BINIT pin is assert on
1396 each occurrence of an MCA.
1397 Setting this bit has no
1398 effect if BINIT signalling
1400 PAL_BUS_GET/SET_FEATURES)
1402 @param EnableCmciPromotion Bit60, Enable CMCI promotion When
1403 1, Corrected Machine Check
1404 Interrupts (CMCI) are promoted to
1405 MCAs. They are also further
1406 promoted to BERR if bit 39, Enable
1407 MCA promotion, is also set and
1408 they are promoted to BINIT if bit
1409 38, Enable MCA to BINIT promotion,
1410 is also set. This bit has no
1411 effect if MCA signalling is
1413 PAL_BUS_GET/SET_FEATURES)
1415 @param DisableCache Bit59, Disable Cache. When 0, the
1416 processor performs cast outs on
1417 cacheable pages and issues and responds
1418 to coherency requests normally. When 1,
1419 the processor performs a memory access
1420 for each reference regardless of cache
1421 contents and issues no coherence
1422 requests and responds as if the line
1423 were not present. Cache contents cannot
1424 be relied upon when the cache is
1425 disabled. WARNING: Semaphore
1426 instructions may not be atomic or may
1427 cause Unsupported Data Reference faults
1428 if caches are disabled.
1430 @param DisableCoherency Bit58, Disable Coherency. When 0,
1431 the processor uses normal coherency
1432 requests and responses. When 1, the
1433 processor answers all requests as if
1434 the line were not present.
1436 @param DisableDPM Bit57, Disable Dynamic Power Management
1437 (DPM). When 0, the hardware may reduce
1438 power consumption by removing the clock
1439 input from idle functional units. When 1,
1440 all functional units will receive clock
1441 input, even when idle.
1443 @param DisableBinitWithTimeout Bit56, Disable a BINIT on
1444 internal processor time-out.
1445 When 0, the processor may
1446 generate a BINIT on an
1447 internal processor time-out.
1448 When 1, the processor will not
1449 generate a BINIT on an
1450 internal processor time-out.
1451 The event is silently ignored.
1454 @param EnableEnvNotification Bit55, Enable external
1455 notification when the processor
1456 detects hardware errors caused
1457 by environmental factors that
1459 deterministic behavior of the
1460 processor. When 1, this bit will
1461 enable external notification,
1462 when 0 external notification is
1463 not provided. The type of
1464 external notification of these
1465 errors is processor-dependent. A
1466 loss of processor deterministic
1467 behavior is considered to have
1469 environmentally induced errors
1470 cause the processor to deviate
1471 from its normal execution and
1472 eventually causes different
1473 behavior which can be observed
1474 at the processor bus pins.
1475 Processor errors that do not
1476 have this effects (i.e.,
1477 software induced machine checks)
1478 may or may not be promoted
1479 depending on the processor
1482 @param EnableVmsw Bit54, Enable the use of the vmsw
1483 instruction. When 0, the vmsw instruction
1484 causes a Virtualization fault when
1485 executed at the most privileged level.
1486 When 1, this bit will enable normal
1487 operation of the vmsw instruction.
1489 @param EnableMcaOnDataPoisoning Bit53, Enable MCA signaling
1490 on data-poisoning event
1491 detection. When 0, a CMCI
1492 will be signaled on error
1493 detection. When 1, an MCA
1494 will be signaled on error
1495 detection. If this feature
1496 is not supported, then the
1497 corresponding argument is
1498 ignored when calling
1499 PAL_PROC_SET_FEATURES. Note
1500 that the functionality of
1501 this bit is independent of
1502 the setting in bit 60
1503 (Enable CMCI promotion), and
1504 that the bit 60 setting does
1505 not affect CMCI signaling
1506 for data-poisoning related
1507 events. Volume 2: Processor
1508 Abstraction Layer 2:431
1509 PAL_PROC_GET_FEATURES
1511 @param DisablePState Bit52, Disable P-states. When 1, the PAL
1512 P-state procedures (PAL_PSTATE_INFO,
1513 PAL_SET_PSTATE, PAL_GET_PSTATE) will
1514 return with a status of -1
1515 (Unimplemented procedure).
1517 @param DisableBranchPrediction Bit47, Disable Dynamic branch
1518 prediction. When 0, the
1519 processor may predict branch
1520 targets and speculatively
1521 execute, but may not commit
1522 results. When 1, the processor
1523 must wait until branch targets
1524 are known to execute.
1526 @param DisableDynamicInsCachePrefetch Bit46, Disable
1527 DynamicInstruction Cache
1528 Prefetch. When 0, the
1529 processor may prefetch
1531 instruction which has
1532 not been executed, but
1535 instructions may not be
1536 fetched until needed or
1537 hinted for execution.
1538 (Prefetch for a hinted
1539 branch is allowed even
1540 when dynamic instruction
1544 @param DisableDynamicDataCachePrefetch Bit45, Disable Dynamic
1545 Data Cache Prefetch.
1546 When 0, the processor
1547 may prefetch into the
1548 caches any data which
1549 has not been accessed
1551 execution, but which
1553 accessed. When 1, no
1555 until it is needed for
1556 instruction execution
1560 @param DisableSpontaneousDeferral Bit44, Disable Spontaneous
1561 Deferral. When 1, the
1562 processor may optionally
1563 defer speculative loads
1564 that do not encounter any
1565 exception conditions, but
1567 implementation-dependent
1568 conditions (e.g., cache
1569 miss). When 0, spontaneous
1570 deferral is disabled.
1572 @param DisableDynamicPrediction Bit43, Disable Dynamic
1573 Predicate Prediction. When
1574 0, the processor may predict
1575 predicate results and
1576 execute speculatively, but
1577 may not commit results until
1578 the actual predicates are
1579 known. When 1, the processor
1580 shall not execute predicated
1581 instructions until the
1582 actual predicates are known.
1584 @param NoXr1ThroughXr3 Bit42, No XR1 through XR3 implemented.
1585 Denotes whether XR1 XR3 are
1586 implemented for machine check
1587 recovery. This feature may only be
1588 interrogated by PAL_PROC_GET_FEATURES.
1589 It may not be enabled or disabled by
1590 PAL_PROC_SET_FEATURES. The
1591 corresponding argument is ignored.
1593 @param NoXipXpsrXfs Bit41, No XIP, XPSR, and XFS
1594 implemented. Denotes whether XIP, XPSR,
1595 and XFS are implemented for machine
1596 check recovery. This feature may only be
1597 interrogated by PAL_PROC_GET_FEATURES.
1598 It may not be enabled or disabled by
1599 PAL_PROC_SET_FEATURES. The corresponding
1600 argument is ignored.
1602 @param NoVM Bit40, No Virtual Machine features implemented.
1603 Denotes whether PSR.vm is implemented. This
1604 feature may only be interrogated by
1605 PAL_PROC_GET_FEATURES. It may not be enabled or
1606 disabled by PAL_PROC_SET_FEATURES. The
1607 corresponding argument is ignored.
1609 @param NoVariablePState Bit39, No Variable P-state
1610 performance: A value of 1, indicates
1611 that a processor implements
1612 techniques to optimize performance
1613 for the given P-state power budget
1614 by dynamically varying the
1615 frequency, such that maximum
1616 performance is achieved for the
1617 power budget. A value of 0,
1618 indicates that P-states have no
1619 frequency variation or very small
1620 frequency variations for their given
1621 power budget. This feature may only
1623 PAL_PROC_GET_FEATURES. it may not be
1624 enabled or disabled by
1625 PAL_PROC_SET_FEATURES. The
1626 corresponding argument is ignored.
1629 @param NoSimpleImpInUndefinedIns Bit38, No Simple
1631 unimplemented instruction
1632 addresses. Denotes how an
1633 unimplemented instruction
1634 address is recorded in IIP
1636 Instruction Address trap or
1637 fault. When 1, the full
1638 unimplemented address is
1639 recorded in IIP; when 0, the
1640 address is sign extended
1641 (virtual addresses) or zero
1643 addresses). This feature may
1644 only be interrogated by
1645 PAL_PROC_GET_FEATURES. It
1646 may not be enabled or
1648 PAL_PROC_SET_FEATURES. The
1649 corresponding argument is
1652 @param NoPresentPmi Bit37, No INIT, PMI, and LINT pins
1653 present. Denotes the absence of INIT,
1654 PMI, LINT0 and LINT1 pins on the
1655 processor. When 1, the pins are absent.
1656 When 0, the pins are present. This
1657 feature may only be interrogated by
1658 PAL_PROC_GET_FEATURES. It may not be
1659 enabled or disabled by
1660 PAL_PROC_SET_FEATURES. The corresponding
1661 argument is ignored.
1663 @param FaultInUndefinedIns Bit36, No Unimplemented
1664 instruction address reported as
1665 fault. Denotes how the processor
1666 reports the detection of
1667 unimplemented instruction
1668 addresses. When 1, the processor
1669 reports an Unimplemented
1670 Instruction Address fault on the
1671 unimplemented address; when 0, it
1672 reports an Unimplemented
1673 Instruction Address trap on the
1674 previous instruction in program
1675 order. This feature may only be
1677 PAL_PROC_GET_FEATURES. It may not
1678 be enabled or disabled by
1679 PAL_PROC_SET_FEATURES. The
1680 corresponding argument is
1685 UINT64 Reserved1
:36;
1686 UINT64 FaultInUndefinedIns
:1;
1687 UINT64 NoPresentPmi
:1;
1688 UINT64 NoSimpleImpInUndefinedIns
:1;
1689 UINT64 NoVariablePState
:1;
1691 UINT64 NoXipXpsrXfs
:1;
1692 UINT64 NoXr1ThroughXr3
:1;
1693 UINT64 DisableDynamicPrediction
:1;
1694 UINT64 DisableSpontaneousDeferral
:1;
1695 UINT64 DisableDynamicDataCachePrefetch
:1;
1696 UINT64 DisableDynamicInsCachePrefetch
:1;
1697 UINT64 DisableBranchPrediction
:1;
1699 UINT64 DisablePState
:1;
1700 UINT64 EnableMcaOnDataPoisoning
:1;
1701 UINT64 EnableVmsw
:1;
1702 UINT64 EnableEnvNotification
:1;
1703 UINT64 DisableBinitWithTimeout
:1;
1704 UINT64 DisableDPM
:1;
1705 UINT64 DisableCoherency
:1;
1706 UINT64 DisableCache
:1;
1707 UINT64 EnableCmciPromotion
:1;
1708 UINT64 EnableMcaToBinitPromotion
:1;
1709 UINT64 EnableMcaPromotion
:1;
1710 UINT64 EnableBerrPromotion
:1;
1711 } PAL_PROCESSOR_FEATURES
;
1715 PAL Procedure - PAL_PROC_GET_FEATURES.
1717 Return configurable processor features and their current
1718 setting. It is required by IPF. The PAL procedure supports the
1719 Static Registers calling convention. It could be called at
1720 physical mode and virtual mode.
1722 @param Index Index of PAL_PROC_GET_FEATURES within the list of
1725 @param Reserved Reserved parameter.
1727 @param FeatureSet Feature set information is being requested
1731 @return R9 64-bit vector of features implemented. See
1732 PAL_PROCESSOR_FEATURES.
1734 @return R10 64-bit vector of current feature settings. See
1735 PAL_PROCESSOR_FEATURES.
1737 @return R11 64-bit vector of features controllable by
1740 @return Status 1 - Call completed without error; The
1741 feature_set passed is not supported but a
1742 feature_set of a larger value is supported.
1744 @return Status 0 - Call completed without error
1746 @return Status -2 - Invalid argument
1748 @return Status -3 - Call completed with error.
1750 @return Status -8 - feature_set passed is beyond the maximum
1751 feature_set supported
1754 #define PAL_PROC_GET_FEATURES 17
1759 PAL Procedure - PAL_PROC_SET_FEATURES.
1761 Enable or disable configurable processor features. It is
1762 required by IPF. The PAL procedure supports the Static
1763 Registers calling convention. It could be called at physical
1766 @param Index Index of PAL_PROC_SET_FEATURES within the list of
1769 @param FeatureSelect 64-bit vector denoting desired state of
1770 each feature (1=select, 0=non-select).
1772 @param FeatureSet Feature set to apply changes to. See
1773 PAL_PROC_GET_FEATURES for more information
1778 @return Status 1 - Call completed without error; The
1779 feature_set passed is not supported but a
1780 feature_set of a larger value is supported
1782 @return Status 0 - Call completed without error
1784 @return Status -2 - Invalid argument
1786 @return Status -3 - Call completed with error.
1788 @return Status -8 - feature_set passed is beyond the maximum
1789 feature_set supported
1792 #define PAL_PROC_SET_FEATURES 18
1796 // Value of PAL_REGISTER_INFO.InfoRequest.
1798 #define PAL_APPLICATION_REGISTER_IMPLEMENTED 0
1799 #define PAL_APPLICATION_REGISTER_READABLE 1
1800 #define PAL_CONTROL_REGISTER_IMPLEMENTED 2
1801 #define PAL_CONTROL_REGISTER_READABLE 3
1806 PAL Procedure - PAL_REGISTER_INFO.
1808 Return AR and CR register information. It is required by IPF.
1809 The PAL procedure supports the Static Registers calling
1810 convention. It could be called at physical mode and virtual
1813 @param Index Index of PAL_REGISTER_INFO within the list of
1816 @param InfoRequest Unsigned 64-bit integer denoting what
1817 register information is requested. See
1818 PAL_REGISTER_INFO.InfoRequest above.
1820 @return R9 64-bit vector denoting information for registers
1821 0-63. Bit 0 is register 0, bit 63 is register 63.
1823 @return R10 64-bit vector denoting information for registers
1824 64-127. Bit 0 is register 64, bit 63 is register
1828 @return Status 0 - Call completed without error
1830 @return Status -2 - Invalid argument
1832 @return Status -3 - Call completed with error.
1836 #define PAL_REGISTER_INFO 39
1840 PAL Procedure - PAL_RSE_INFO.
1842 Return RSE information. It is required by IPF. The PAL
1843 procedure supports the Static Registers calling convention. It
1844 could be called at physical mode and virtual mode.
1846 @param Index Index of PAL_RSE_INFO within the list of
1849 @param InfoRequest Unsigned 64-bit integer denoting what
1850 register information is requested. See
1851 PAL_REGISTER_INFO.InfoRequest above.
1853 @return R9 Number of physical stacked general registers.
1855 @return R10 RSE hints supported by processor.
1857 @return Status 0 - Call completed without error
1859 @return Status -2 - Invalid argument
1861 @return Status -3 - Call completed with error.
1865 #define PAL_RSE_INFO 19
1869 @param VersionOfPalB Is a 16-bit binary coded decimal (BCD)
1870 number that provides identification
1871 information about the PAL_B firmware.
1873 @param PalVendor Is an unsigned 8-bit integer indicating the
1874 vendor of the PAL code.
1876 @param VersionOfPalB Is a 16-bit binary coded decimal (BCD)
1877 number that provides identification
1878 information about the PAL_A firmware. In
1879 the split PAL_A model, this return value
1880 is the version number of the
1881 processor-specific PAL_A. The generic
1882 PAL_A version is not returned by this
1883 procedure in the split PAL_A model.
1887 UINT64 VersionOfPalB
:16;
1890 UINT64 VersionOfPalA
:16;
1891 UINT64 Reserved2
:16;
1896 PAL Procedure - PAL_VERSION.
1898 Return version of PAL code. It is required by IPF. The PAL
1899 procedure supports the Static Registers calling convention. It
1900 could be called at physical mode and virtual mode.
1902 @param Index Index of PAL_VERSION within the list of
1905 @param InfoRequest Unsigned 64-bit integer denoting what
1906 register information is requested. See
1907 PAL_REGISTER_INFO.InfoRequest above.
1909 @return R9 8-byte formatted value returning the minimum PAL
1910 version needed for proper operation of the
1911 processor. See PAL_VERSION_INFO above.
1913 @return R10 8-byte formatted value returning the current PAL
1914 version running on the processor. See
1915 PAL_VERSION_INFO above.
1917 @return Status 0 - Call completed without error
1919 @return Status -2 - Invalid argument
1921 @return Status -3 - Call completed with error.
1925 #define PAL_VERSION 20
1930 // Vectors of PAL_MC_CLEAR_LOG.pending
1932 #define PAL_MC_PENDING BIT0
1933 #define PAL_INIT_PENDING BIT1
1937 PAL Procedure - PAL_MC_CLEAR_LOG.
1939 Clear all error information from processor error logging
1940 registers. It is required by IPF. The PAL procedure supports
1941 the Static Registers calling convention. It could be called at
1942 physical mode and virtual mode.
1944 @param Index Index of PAL_MC_CLEAR_LOG within the list of
1948 @return R9 64-bit vector denoting whether an event is
1949 pending. See PAL_MC_CLEAR_LOG.pending above.
1952 @return Status 0 - Call completed without error
1954 @return Status -2 - Invalid argument
1956 @return Status -3 - Call completed with error.
1960 #define PAL_MC_CLEAR_LOG 21
1964 PAL Procedure - PAL_MC_DRAIN.
1966 Ensure that all operations that could cause an MCA have
1967 completed. It is required by IPF. The PAL procedure supports
1968 the Static Registers calling convention. It could be called at
1969 physical mode and virtual mode.
1971 @param Index Index of PAL_MC_DRAIN within the list of PAL
1975 @return Status 0 - Call completed without error
1977 @return Status -2 - Invalid argument
1979 @return Status -3 - Call completed with error.
1983 #define PAL_MC_DRAIN 22
1988 PAL Procedure - PAL_MC_DYNAMIC_STATE.
1990 Return Processor Dynamic State for logging by SAL. It is
1991 optional. The PAL procedure supports the Static Registers
1992 calling convention. It could be called at physical mode.
1994 @param Index Index of PAL_MC_DYNAMIC_STATE within the list of PAL
1997 @param Offset Offset of the next 8 bytes of Dynamic Processor
1998 State to return. (multiple of 8).
2000 @return R9 Unsigned 64-bit integer denoting bytes of Dynamic
2001 Processor State returned.
2003 @return R10 Next 8 bytes of Dynamic Processor State.
2005 @return Status 0 - Call completed without error
2007 @return Status -1 - Unimplemented procedure.
2009 @return Status -2 - Invalid argument
2011 @return Status -3 - Call completed with error.
2015 #define PAL_MC_DYNAMIC_STATE 24
2020 // Values of PAL_MC_ERROR_INFO.InfoIndex.
2022 #define PAL_PROCESSOR_ERROR_MAP 0
2023 #define PAL_PROCESSOR_STATE_PARAM 1
2024 #define PAL_STRUCTURE_SPECIFIC_ERROR 2
2028 @param CoreId Bit3:0, Processor core ID (default is 0 for
2029 processors with a single core)
2031 @param ThreadId Bit7:4, Logical thread ID (default is 0 for
2032 processors that execute a single thread)
2034 @param InfoOfInsCache Bit11:8, Error information is
2035 available for 1st, 2nd, 3rd, and 4th
2036 level instruction caches.
2038 @param InfoOfDataCache Bit15:12, Error information is
2039 available for 1st, 2nd, 3rd, and 4th
2040 level data/unified caches.
2042 @param InfoOfInsTlb Bit19:16 Error information is available
2043 for 1st, 2nd, 3rd, and 4th level
2046 @param InfoOfDataTlb Bit23:20, Error information is available
2047 for 1st, 2nd, 3rd, and 4th level
2050 @param InfoOfProcessorBus Bit27:24 Error information is
2051 available for the 1st, 2nd, 3rd,
2052 and 4th level processor bus
2055 @param InfoOfRegisterFile Bit31:28 Error information is
2056 available on register file
2059 @param InfoOfMicroArch Bit47:32, Error information is
2060 available on micro-architectural
2067 UINT64 InfoOfInsCache
:4;
2068 UINT64 InfoOfDataCache
:4;
2069 UINT64 InfoOfInsTlb
:4;
2070 UINT64 InfoOfDataTlb
:4;
2071 UINT64 InfoOfProcessorBus
:4;
2072 UINT64 InfoOfRegisterFile
:4;
2073 UINT64 InfoOfMicroArch
:4;
2075 } PAL_MC_ERROR_INFO_LEVEL_INDEX
;
2078 // Value of PAL_MC_ERROR_INFO.ErrorTypeIndex
2080 #define PAL_ERR_INFO_BY_LEVEL_INDEX 0
2081 #define PAL_ERR_INFO_TARGET_ADDRESS 1
2082 #define PAL_ERR_INFO_REQUESTER_IDENTIFIER 2
2083 #define PAL_ERR_INFO_REPONSER_INDENTIFIER 3
2084 #define PAL_ERR_INFO_PRECISE_INSTRUCTION_POINTER 4
2088 @param Operation Bit3:0, Type of cache operation that caused
2089 the machine check: 0 - unknown or internal
2090 error 1 - load 2 - store 3 - instruction
2091 fetch or instruction prefetch 4 - data
2092 prefetch (both hardware and software) 5 -
2093 snoop (coherency check) 6 - cast out
2094 (explicit or implicit write-back of a cache
2095 line) 7 - move in (cache line fill)
2097 @param FailedCacheLevel Bit5:4 Level of cache where the
2098 error occurred. A value of 0
2099 indicates the first level of cache.
2101 @param FailedInDataPart Bit8, Failure located in the data
2102 part of the cache line.
2104 @param FailedInTagPart Bit9, Failure located in the tag part
2107 @param FailedInDataCache Bit10, Failure located in the data
2110 @param FailedInInsCache Bit11, Failure located in the
2114 @param Mesi Bit14:12, 0 - cache line is invalid. 1 - cache
2115 line is held shared. 2 - cache line is held
2116 exclusive. 3 - cache line is modified. All other
2117 values are reserved.
2119 @param MesiIsValid Bit15, The mesi field in the cache_check
2122 @param FailedWay Bit20:16, Failure located in the way of
2123 the cache indicated by this value.
2125 @param WayIndexIsValid Bit21, The way and index field in the
2126 cache_check parameter is valid.
2128 @param MultipleBitsError Bit23, A multiple-bit error was
2129 detected, and data was poisoned for
2130 the corresponding cache line during
2133 @param IndexOfCacheLineError Bit51:32, Index of the cache
2134 line where the error occurred.
2136 @param InstructionSet Bit54, Instruction set. If this value
2137 is set to zero, the instruction that
2138 generated the machine check was an
2139 Intel Itanium instruction. If this bit
2140 is set to one, the instruction that
2141 generated the machine check was IA-32
2144 @param InstructionSetIsValid Bit55, The is field in the
2145 cache_check parameter is valid.
2147 @param PrivilegeLevel Bit57:56, Privilege level. The
2148 privilege level of the instruction
2149 bundle responsible for generating the
2152 @param PrivilegeLevelIsValide Bit58, The pl field of the
2153 cache_check parameter is
2156 @param McCorrected Bit59, Machine check corrected: This bit
2157 is set to one to indicate that the machine
2158 check has been corrected.
2160 @param TargetAddressIsValid Bit60, Target address is valid:
2161 This bit is set to one to
2162 indicate that a valid target
2163 address has been logged.
2165 @param RequesterIdentifier Bit61, Requester identifier: This
2166 bit is set to one to indicate that
2167 a valid requester identifier has
2170 @param ResponserIdentifier Bit62, Responder identifier: This
2171 bit is set to one to indicate that
2172 a valid responder identifier has
2175 @param PreciseInsPointer Bit63, Precise instruction pointer.
2176 This bit is set to one to indicate
2177 that a valid precise instruction
2178 pointer has been logged.
2183 UINT64 FailedCacheLevel
:2;
2185 UINT64 FailedInDataPart
:1;
2186 UINT64 FailedInTagPart
:1;
2187 UINT64 FailedInDataCache
:1;
2188 UINT64 FailedInInsCache
:1;
2190 UINT64 MesiIsValid
:1;
2192 UINT64 WayIndexIsValid
:1;
2195 UINT64 MultipleBitsError
:1;
2197 UINT64 IndexOfCacheLineError
:20;
2199 UINT64 InstructionSet
:1;
2200 UINT64 InstructionSetIsValid
:1;
2202 UINT64 PrivilegeLevel
:2;
2203 UINT64 PrivilegeLevelIsValide
:1;
2205 UINT64 McCorrected
:1;
2207 UINT64 TargetAddressIsValid
:1;
2208 UINT64 RequesterIdentifier
:1;
2209 UINT64 ResponserIdentifier
:1;
2210 UINT64 PreciseInsPointer
:1;
2212 } PAL_CACHE_CHECK_INFO
;
2216 @param FailedSlot Bit7:0, Slot number of the translation
2217 register where the failure occurred.
2219 @param FailedSlotIsValid Bit8, The tr_slot field in the
2220 TLB_check parameter is valid.
2222 @param TlbLevel Bit11:10, The level of the TLB where the
2223 error occurred. A value of 0 indicates the
2226 @param FailedInDataTr Bit16, Error occurred in the data
2227 translation registers.
2229 @param FailedInInsTr Bit17, Error occurred in the instruction
2230 translation registers
2232 @param FailedInDataTc Bit18, Error occurred in data
2235 @param FailedInInsTc Bit19, Error occurred in the instruction
2238 @param FailedOperation Bit23:20, Type of cache operation that
2239 caused the machine check: 0 - unknown
2240 1 - TLB access due to load instruction
2241 2 - TLB access due to store
2242 instruction 3 - TLB access due to
2243 instruction fetch or instruction
2244 prefetch 4 - TLB access due to data
2245 prefetch (both hardware and software)
2246 5 - TLB shoot down access 6 - TLB
2247 probe instruction (probe, tpa) 7 -
2248 move in (VHPT fill) 8 - purge (insert
2249 operation that purges entries or a TLB
2250 purge instruction) All other values
2253 @param InstructionSet Bit54, Instruction set. If this value
2254 is set to zero, the instruction that
2255 generated the machine check was an
2256 Intel Itanium instruction. If this bit
2257 is set to one, the instruction that
2258 generated the machine check was IA-32
2261 @param InstructionSetIsValid Bit55, The is field in the
2262 TLB_check parameter is valid.
2264 @param PrivelegeLevel Bit57:56, Privilege level. The
2265 privilege level of the instruction
2266 bundle responsible for generating the
2269 @param PrivelegeLevelIsValid Bit58, The pl field of the
2270 TLB_check parameter is valid.
2272 @param McCorrected Bit59, Machine check corrected: This bit
2273 is set to one to indicate that the machine
2274 check has been corrected.
2276 @param TargetAddressIsValid Bit60, Target address is valid:
2277 This bit is set to one to
2278 indicate that a valid target
2279 address has been logged.
2281 @param RequesterIdentifier Bit61 Requester identifier: This
2282 bit is set to one to indicate that
2283 a valid requester identifier has
2286 @param ResponserIdentifier Bit62, Responder identifier: This
2287 bit is set to one to indicate that
2288 a valid responder identifier has
2291 @param PreciseInsPointer Bit63 Precise instruction pointer.
2292 This bit is set to one to indicate
2293 that a valid precise instruction
2294 pointer has been logged.
2297 UINT64 FailedSlot
:8;
2298 UINT64 FailedSlotIsValid
:1;
2299 UINT64 Reserved1
:1;
2301 UINT64 Reserved2
:4;
2302 UINT64 FailedInDataTr
:1;
2303 UINT64 FailedInInsTr
:1;
2304 UINT64 FailedInDataTc
:1;
2305 UINT64 FailedInInsTc
:1;
2306 UINT64 FailedOperation
:4;
2307 UINT64 Reserved3
:30;
2308 UINT64 InstructionSet
:1;
2309 UINT64 InstructionSetIsValid
:1;
2310 UINT64 PrivelegeLevel
:2;
2311 UINT64 PrivelegeLevelIsValid
:1;
2312 UINT64 McCorrected
:1;
2313 UINT64 TargetAddressIsValid
:1;
2314 UINT64 RequesterIdentifier
:1;
2315 UINT64 ResponserIdentifier
:1;
2316 UINT64 PreciseInsPointer
:1;
2317 } PAL_TLB_CHECK_INFO
;
2321 PAL Procedure - PAL_MC_ERROR_INFO.
2323 Return Processor Machine Check Information and Processor
2324 Static State for logging by SAL. It is required by IPF. The
2325 PAL procedure supports the Static Registers calling
2326 convention. It could be called at physical and virtual mode.
2328 @param Index Index of PAL_MC_ERROR_INFO within the list of PAL
2331 @param InfoIndex Unsigned 64-bit integer identifying the
2332 error information that is being requested.
2333 See PAL_MC_ERROR_INFO.InfoIndex.
2335 @param LevelIndex 8-byte formatted value identifying the
2336 structure to return error information
2337 on. See PAL_MC_ERROR_INFO_LEVEL_INDEX.
2339 @param ErrorTypeIndex Unsigned 64-bit integer denoting the
2340 type of error information that is
2341 being requested for the structure
2342 identified in LevelIndex.
2345 @return R9 Error information returned. The format of this
2346 value is dependant on the input values passed.
2348 @return R10 If this value is zero, all the error information
2349 specified by err_type_index has been returned. If
2350 this value is one, more structure-specific error
2351 information is available and the caller needs to
2352 make this procedure call again with level_index
2353 unchanged and err_type_index, incremented.
2356 @return Status 0 - Call completed without error
2358 @return Status -2 - Invalid argument
2360 @return Status -3 - Call completed with error.
2362 @return Status -6 - Argument was valid, but no error
2363 information was available
2367 #define PAL_MC_ERROR_INFO 25
2371 PAL Procedure - PAL_MC_EXPECTED.
2373 Set/Reset Expected Machine Check Indicator. It is required by
2374 IPF. The PAL procedure supports the Static Registers calling
2375 convention. It could be called at physical mode.
2377 @param Index Index of PAL_MC_EXPECTED within the list of PAL
2380 @param Expected Unsigned integer with a value of 0 or 1 to
2381 set or reset the hardware resource
2382 PALE_CHECK examines for expected machine
2386 @return R9 Unsigned integer denoting whether a machine check
2387 was previously expected.
2390 @return Status 0 - Call completed without error
2392 @return Status -2 - Invalid argument
2394 @return Status -3 - Call completed with error.
2397 #define PAL_MC_EXPECTED 23
2401 PAL Procedure - PAL_MC_REGISTER_MEM.
2403 Register min-state save area with PAL for machine checks and
2404 inits. It is required by IPF. The PAL procedure supports the
2405 Static Registers calling convention. It could be called at
2408 @param Index Index of PAL_MC_REGISTER_MEM within the list of PAL
2411 @param Address Physical address of the buffer to be
2412 registered with PAL.
2416 @return Status 0 - Call completed without error
2418 @return Status -2 - Invalid argument
2420 @return Status -3 - Call completed with error.
2423 #define PAL_MC_REGISTER_MEM 27
2427 PAL Procedure - PAL_MC_RESUME.
2429 Restore minimal architected state and return to interrupted
2430 process. It is required by IPF. The PAL procedure supports the
2431 Static Registers calling convention. It could be called at
2434 @param Index Index of PAL_MC_RESUME within the list of PAL
2437 @param SetCmci Unsigned 64 bit integer denoting whether to
2438 set the CMC interrupt. A value of 0 indicates
2439 not to set the interrupt, a value of 1
2440 indicated to set the interrupt, and all other
2441 values are reserved.
2443 @param SavePtr Physical address of min-state save area used
2444 to used to restore processor state.
2446 @param NewContext Unsigned 64-bit integer denoting whether
2447 the caller is returning to a new context.
2448 A value of 0 indicates the caller is
2449 returning to the interrupted context, a
2450 value of 1 indicates that the caller is
2451 returning to a new context.
2455 @return Status -2 - Invalid argument
2457 @return Status -3 - Call completed with error.
2460 #define PAL_MC_RESUME 26
2464 PAL Procedure - PAL_HALT.
2466 Enter the low-power HALT state or an implementation-dependent
2467 low-power state. It is optinal. The PAL procedure supports the
2468 Static Registers calling convention. It could be called at
2471 @param Index Index of PAL_HALT within the list of PAL
2474 @param HaltState Unsigned 64-bit integer denoting low power
2477 @param IoDetailPtr 8-byte aligned physical address pointer to
2478 information on the type of I/O
2479 (load/store) requested.
2482 @return R9 Value returned if a load instruction is requested
2483 in the io_detail_ptr
2486 @return Status 0 - Call completed without error
2488 @return Status -1 - Unimplemented procedure
2490 @return Status -2 - Invalid argument
2492 @return Status -3 - Call completed with error.
2500 PAL Procedure - PAL_HALT_INFO.
2502 Return the low power capabilities of the processor. It is
2503 required by IPF. The PAL procedure supports the
2504 Stacked Registers calling convention. It could be called at
2505 physical and virtual mode.
2507 @param Index Index of PAL_HALT_INFO within the list of PAL
2510 @param PowerBuffer 64-bit pointer to a 64-byte buffer aligned
2511 on an 8-byte boundary.
2515 @return Status 0 - Call completed without error
2517 @return Status -2 - Invalid argument
2519 @return Status -3 - Call completed with error.
2522 #define PAL_HALT_INFO 257
2527 PAL Procedure - PAL_HALT_LIGHT.
2529 Enter the low power LIGHT HALT state. It is required by
2530 IPF. The PAL procedure supports the Static Registers calling
2531 convention. It could be called at physical and virtual mode.
2533 @param Index Index of PAL_HALT_LIGHT within the list of PAL
2537 @return Status 0 - Call completed without error
2539 @return Status -2 - Invalid argument
2541 @return Status -3 - Call completed with error.
2544 #define PAL_HALT_LIGHT 29
2548 PAL Procedure - PAL_CACHE_LINE_INIT.
2550 Initialize tags and data of a cache line for processor
2551 testing. It is required by IPF. The PAL procedure supports the
2552 Static Registers calling convention. It could be called at
2553 physical and virtual mode.
2555 @param Index Index of PAL_CACHE_LINE_INIT within the list of PAL
2558 @param Address Unsigned 64-bit integer value denoting the
2559 physical address from which the physical page
2560 number is to be generated. The address must be
2561 an implemented physical address, bit 63 must
2564 @param DataValue 64-bit data value which is used to
2565 initialize the cache line.
2568 @return Status 0 - Call completed without error
2570 @return Status -2 - Invalid argument
2572 @return Status -3 - Call completed with error.
2575 #define PAL_CACHE_LINE_INIT 31
2579 PAL Procedure - PAL_CACHE_READ.
2581 Read tag and data of a cache line for diagnostic testing. It
2582 is optional. The PAL procedure supports the
2583 Satcked Registers calling convention. It could be called at
2586 @param Index Index of PAL_CACHE_READ within the list of PAL
2589 @param LineId 8-byte formatted value describing where in the
2590 cache to read the data.
2592 @param Address 64-bit 8-byte aligned physical address from
2593 which to read the data. The address must be an
2594 implemented physical address on the processor
2595 model with bit 63 set to zero.
2597 @return R9 Right-justified value returned from the cache
2600 @return R10 The number of bits returned in data.
2602 @return R11 The status of the cache line.
2606 @return Status 1 - The word at address was found in the
2607 cache, but the line was invalid.
2609 @return Status 0 - Call completed without error
2611 @return Status -2 - Invalid argument
2613 @return Status -3 - Call completed with error.
2615 @return Status -5 - The word at address was not found in the
2618 @return Status -7 - The operation requested is not supported
2619 for this cache_type and level.
2622 #define PAL_CACHE_READ 259
2627 Write tag and data of a cache for diagnostic testing. It is
2628 optional. The PAL procedure supports the Satcked Registers
2629 calling convention. It could be called at physical mode.
2631 @param Index Index of PAL_CACHE_WRITE within the list of PAL
2634 @param LineId 8-byte formatted value describing where in the
2635 cache to write the data.
2637 @param Address 64-bit 8-byte aligned physical address at
2638 which the data should be written. The address
2639 must be an implemented physical address on the
2640 processor model with bit 63 set to 0.
2642 @param Data Unsigned 64-bit integer value to write into
2643 the specified part of the cache.
2646 @return Status 0 - Call completed without error
2648 @return Status -2 - Invalid argument
2650 @return Status -3 - Call completed with error.
2653 @return Status -7 - The operation requested is not supported
2654 for this cache_type and level.
2657 #define PAL_CACHE_WRITE 260
2661 PAL Procedure - PAL_TEST_INFO.
2663 Returns alignment and size requirements needed for the memory
2664 buffer passed to the PAL_TEST_PROC procedure as well as
2665 information on self-test control words for the processor self
2666 tests. It is required by IPF. The PAL procedure supports the
2667 Static Registers calling convention. It could be called at
2670 @param Index Index of PAL_TEST_INFO within the list of PAL
2673 @param TestPhase Unsigned integer that specifies which phase
2674 of the processor self-test information is
2675 being requested on. A value of 0 indicates
2676 the phase two of the processor self-test and
2677 a value of 1 indicates phase one of the
2678 processor self-test. All other values are
2681 @return R9 Unsigned 64-bit integer denoting the number of
2682 bytes of main memory needed to perform the second
2683 phase of processor self-test.
2685 @return R10 Unsigned 64-bit integer denoting the alignment
2686 required for the memory buffer.
2688 @return R11 48-bit wide bit-field indicating if control of
2689 the processor self-tests is supported and which
2690 bits of the test_control field are defined for
2694 @return Status 0 - Call completed without error
2696 @return Status -2 - Invalid argument
2698 @return Status -3 - Call completed with error.
2702 #define PAL_TEST_INFO 37
2706 @param BufferSize Indicates the size in bytes of the memory
2707 buffer that is passed to this procedure.
2708 BufferSize must be greater than or equal in
2709 size to the bytes_needed return value from
2710 PAL_TEST_INFO, otherwise this procedure will
2711 return with an invalid argument return
2714 @param TestPhase Defines which phase of the processor
2715 self-tests are requested to be run. A value
2716 of zero indicates to run phase two of the
2717 processor self-tests. Phase two of the
2718 processor self-tests are ones that require
2719 external memory to execute correctly. A
2720 value of one indicates to run phase one of
2721 the processor self-tests. Phase one of the
2722 processor self-tests are tests run during
2723 PALE_RESET and do not depend on external
2724 memory to run correctly. When the caller
2725 requests to have phase one of the processor
2726 self-test run via this procedure call, a
2727 memory buffer may be needed to save and
2728 restore state as required by the PAL calling
2729 conventions. The procedure PAL_TEST_INFO
2730 informs the caller about the requirements of
2735 UINT64 BufferSize
:56;
2737 } PAL_TEST_INFO_INFO
;
2741 @param TestControl This is an ordered implementation-specific
2742 control word that allows the user control
2743 over the length and runtime of the
2744 processor self-tests. This control word is
2745 ordered from the longest running tests up
2746 to the shortest running tests with bit 0
2747 controlling the longest running test. PAL
2748 may not implement all 47-bits of the
2749 test_control word. PAL communicates if a
2750 bit provides control by placing a zero in
2751 that bit. If a bit provides no control,
2752 PAL will place a one in it. PAL will have
2753 two sets of test_control bits for the two
2754 phases of the processor self-test. PAL
2755 provides information about implemented
2756 test_control bits at the hand-off from PAL
2757 to SAL for the firmware recovery check.
2758 These test_control bits provide control
2759 for phase one of processor self-test. It
2760 also provides this information via the PAL
2761 procedure call PAL_TEST_INFO for both the
2762 phase one and phase two processor tests
2763 depending on which information the caller
2764 is requesting. PAL interprets these bits
2765 as input parameters on two occasions. The
2766 first time is when SAL passes control back
2767 to PAL after the firmware recovery check.
2768 The second time is when a call to
2769 PAL_TEST_PROC is made. When PAL interprets
2770 these bits it will only interpret
2771 implemented test_control bits and will
2772 ignore the values located in the
2773 unimplemented test_control bits. PAL
2774 interprets the implemented bits such that
2775 if a bit contains a zero, this indicates
2776 to run the test. If a bit contains a one,
2777 this indicates to PAL to skip the test. If
2778 the cs bit indicates that control is not
2779 available, the test_control bits will be
2780 ignored or generate an illegal argument in
2781 procedure calls if the caller sets these
2784 @param ControlSupport This bit defines if an implementation
2785 supports control of the PAL self-tests
2786 via the self-test control word. If
2787 this bit is 0, the implementation does
2788 not support control of the processor
2789 self-tests via the self-test control
2790 word. If this bit is 1, the
2791 implementation does support control of
2792 the processor self-tests via the
2793 self-test control word. If control is
2794 not supported, GR37 will be ignored at
2795 the hand-off between SAL and PAL after
2796 the firmware recovery check and the
2797 PAL procedures related to the
2798 processor self-tests may return
2799 illegal arguments if a user tries to
2800 use the self-test control features.
2804 UINT64 TestControl
:47;
2805 UINT64 ControlSupport
:1;
2807 } PAL_SELF_TEST_CONTROL
;
2811 @param Attributes Specifies the memory attributes that are
2812 allowed to be used with the memory buffer
2813 passed to this procedure. The attributes
2814 parameter is a vector where each bit
2815 represents one of the virtual memory
2816 attributes defined by the architecture.See
2817 MEMORY_AATRIBUTES. The caller is required
2818 to support the cacheable attribute for the
2819 memory buffer, otherwise an invalid
2820 argument will be returned.
2823 @param TestControl Is the self-test control word
2824 corresponding to the test_phase passed.
2825 This test_control directs the coverage and
2826 runtime of the processor self-tests
2827 specified by the test_phase input
2828 argument. Information on if this
2829 feature is implemented and the number of
2830 bits supported can be obtained by the
2831 PAL_TEST_INFO procedure call. If this
2832 feature is implemented by the processor,
2833 the caller can selectively skip parts of
2834 the processor self-test by setting
2835 test_control bits to a one. If a bit has a
2836 zero, this test will be run. The values in
2837 the unimplemented bits are ignored. If
2838 PAL_TEST_INFO indicated that the self-test
2839 control word is not implemented, this
2840 procedure will return with an invalid
2841 argument status if the caller sets any of
2842 the test_control bits. See
2843 PAL_SELF_TEST_CONTROL.
2846 UINT64 Attributes
:8;
2848 UINT64 TestControl
:48;
2853 PAL Procedure - PAL_TEST_PROC.
2855 Perform late processor self test. It is required by IPF. The
2856 PAL procedure supports the Static Registers calling
2857 convention. It could be called at physical mode.
2859 @param Index Index of PAL_TEST_PROC within the list of PAL
2862 @param TestAddress 64-bit physical address of main memory
2863 area to be used by processor self-test.
2864 The memory region passed must be
2865 cacheable, bit 63 must be zero.
2867 @param TestInfo Input argument specifying the size of the
2868 memory buffer passed and the phase of the
2869 processor self-test that should be run. See
2872 @param TestParam Input argument specifying the self-test
2873 control word and the allowable memory
2874 attributes that can be used with the memory
2875 buffer. See PAL_TEST_CONTROL.
2877 @return R9 Formatted 8-byte value denoting the state of the
2878 processor after self-test
2882 @return Status 1 - Call completed without error, but hardware
2883 failures occurred during self-test.
2885 @return Status 0 - Call completed without error
2887 @return Status -2 - Invalid argument
2889 @return Status -3 - Call completed with error.
2893 #define PAL_TEST_PROC 258
2897 @param NumberOfInterruptControllers Number of interrupt
2898 controllers currently
2899 enabled on the system.
2901 @param NumberOfProcessors Number of processors currently
2902 enabled on the system.
2906 UINT32 NumberOfInterruptControllers
;
2907 UINT32 NumberOfProcessors
;
2908 } PAL_PLATFORM_INFO
;
2912 PAL Procedure - PAL_COPY_INFO.
2914 Return information needed to relocate PAL procedures and PAL
2915 PMI code to memory. It is required by IPF. The PAL procedure
2916 supports the Static Registers calling convention. It could be
2917 called at physical mode.
2919 @param Index Index of PAL_COPY_INFO within the list of PAL
2922 @param CopyType Unsigned integer denoting type of procedures
2923 for which copy information is requested.
2925 @param PlatformInfo 8-byte formatted value describing the
2926 number of processors and the number of
2927 interrupt controllers currently enabled
2928 on the system. See PAL_PLATFORM_INFO.
2931 @param McaProcStateInfo Unsigned integer denoting the number
2932 of bytes that SAL needs for the
2933 min-state save area for each
2938 @return R9 Unsigned integer denoting the number of bytes of
2939 PAL information that must be copied to main
2942 @return R10 Unsigned integer denoting the starting alignment
2943 of the data to be copied.
2945 @return Status 0 - Call completed without error
2947 @return Status -2 - Invalid argument
2949 @return Status -3 - Call completed with error.
2953 #define PAL_COPY_INFO 30
2957 PAL Procedure - PAL_COPY_PAL.
2959 Relocate PAL procedures and PAL PMI code to memory. It is
2960 required by IPF. The PAL procedure supports the Stacked
2961 Registers calling convention. It could be called at physical
2964 @param Index Index of PAL_COPY_PAL within the list of PAL
2967 @param TargetAddress Physical address of a memory buffer to
2968 copy relocatable PAL procedures and PAL
2971 @param AllocSize Unsigned integer denoting the size of the
2972 buffer passed by SAL for the copy operation.
2975 @param CopyOption Unsigned integer indicating whether
2976 relocatable PAL code and PAL PMI code
2977 should be copied from firmware address
2978 space to main memory.
2981 @return R9 Unsigned integer denoting the offset of PAL_PROC
2982 in the relocatable segment copied.
2984 @return Status 0 - Call completed without error
2986 @return Status -2 - Invalid argument
2988 @return Status -3 - Call completed with error.
2992 #define PAL_COPY_PAL 256
2996 PAL Procedure - PAL_ENTER_IA_32_ENV.
2998 Enter IA-32 System environment. It is optional. The PAL
2999 procedure supports the Static Registers calling convention.
3000 It could be called at physical mode.
3002 Note: Since this is a special call, it does not follow the PAL
3003 static register calling convention. GR28 contains the index of
3004 PAL_ENTER_IA_32_ENV within the list of PAL procedures. All other
3005 input arguments including GR29-GR31 are setup by SAL to values
3006 as required by the IA-32 operating system defined in Table
3007 11-67. The registers that are designated as preserved, scratch,
3008 input arguments and procedure return values by the static
3009 procedure calling convention are not followed by this call. For
3010 instance, GR5 and GR6 need not be preserved since these are
3011 regarded as scratch by the IA-32 operating system. Note: In an
3012 MP system, this call must be COMPLETED on the first CPU to enter
3013 the IA-32 System Environment (may or may not be the BSP) prior
3014 to being called on the remaining processors in the MP system.
3016 @param Index GR28 contains the index of the
3017 PAL_ENTER_IA_32_ENV call within the list of PAL
3021 @return Status The status is returned in GR4.
3022 -1 - Un-implemented procedure 0 JMPE detected
3025 0 - 1 SAL allocated buffer for IA-32 System
3026 Environment operation is too small
3028 2 - IA-32 Firmware Checksum Error
3030 3 - SAL allocated buffer for IA-32 System
3031 Environment operation is not properly aligned
3033 4 - Error in SAL MP Info Table
3035 5 - Error in SAL Memory Descriptor Table
3037 6 - Error in SAL System Table
3039 7 - Inconsistent IA-32 state
3041 8 - IA-32 Firmware Internal Error
3043 9 - IA-32 Soft Reset (Note: remaining register
3044 state is undefined for this termination
3047 10 - Machine Check Error
3049 11 - Error in SAL I/O Intercept Table
3051 12 - Processor exit due to other processor in
3052 MP system terminating the IA32 system
3053 environment. (Note: remaining register state
3054 is undefined for this termination reason.)
3056 13 - Itanium architecture-based state
3057 corruption by either SAL PMI handler or I/O
3058 Intercept callback function.
3062 #define PAL_ENTER_IA_32_ENV 33
3066 PAL Procedure - PAL_PMI_ENTRYPOINT.
3068 Register PMI memory entrypoints with processor. It is required
3069 by IPF. The PAL procedure supports the Stacked Registers
3070 calling convention. It could be called at physical mode.
3072 @param Index Index of PAL_PMI_ENTRYPOINT within the list of
3075 @param SalPmiEntry 256-byte aligned physical address of SAL
3076 PMI entrypoint in memory.
3079 @return Status 0 - Call completed without error
3081 @return Status -2 - Invalid argument
3083 @return Status -3 - Call completed with error.
3087 #define PAL_PMI_ENTRYPOINT 32
3092 The ASCII brand identification string will be copied to the
3093 address specified in the address input argument. The processor
3094 brand identification string is defined to be a maximum of 128
3095 characters long; 127 bytes will contain characters and the 128th
3096 byte is defined to be NULL (0). A processor may return less than
3097 the 127 ASCII characters as long as the string is null
3098 terminated. The string length will be placed in the brand_info
3102 #define PAL_BRAND_INFO_ID_REQUEST 0
3106 PAL Procedure - PAL_BRAND_INFO.
3108 Provides processor branding information. It is optional by
3109 IPF. The PAL procedure supports the Stacked Registers calling
3110 convention. It could be called at physical and Virtual mode.
3113 @param Index Index of PAL_BRAND_INFO within the list of PAL
3116 @param InfoRequest Unsigned 64-bit integer specifying the
3117 information that is being requested. (See
3118 PAL_BRAND_INFO_ID_REQUEST)
3120 @param Address Unsigned 64-bit integer specifying the
3121 address of the 128-byte block to which the
3122 processor brand string shall be written.
3125 @reture R9 Brand information returned. The format of this
3126 value is dependent on the input values passed.
3129 @return Status 0 - Call completed without error
3131 @return Status -1 - Unimplemented procedure
3133 @return Status -2 - Invalid argument
3135 @return Status -3 - Call completed with error.
3137 @return Status -6 - Input argument is not implemented.
3140 #define PAL_BRAND_INFO 274
3144 PAL Procedure - PAL_GET_HW_POLICY.
3146 Returns the current hardware resource sharing policy of the
3147 processor. It is optional by IPF. The PAL procedure supports
3148 the Static Registers calling convention. It could be called at
3149 physical and Virtual mode.
3152 @param Index Index of PAL_GET_HW_POLICY within the list of PAL
3155 @param ProcessorNumber Unsigned 64-bit integer that specifies
3156 for which logical processor
3157 information is being requested. This
3158 input argument must be zero for the
3159 first call to this procedure and can
3160 be a maximum value of one less than
3161 the number of logical processors
3162 impacted by the hardware resource
3163 sharing policy, which is returned by
3164 the R10 return value.
3167 @reture R9 Unsigned 64-bit integer representing the current
3168 hardware resource sharing policy.
3170 @return R10 Unsigned 64-bit integer that returns the number
3171 of logical processors impacted by the policy
3174 @return R11 Unsigned 64-bit integer containing the logical
3175 address of one of the logical processors
3176 impacted by policy modification.
3179 @return Status 0 - Call completed without error
3181 @return Status -1 - Unimplemented procedure
3183 @return Status -2 - Invalid argument
3185 @return Status -3 - Call completed with error.
3187 @return Status -9 - Call requires PAL memory buffer.
3190 #define PAL_GET_HW_POLICY 48
3194 // Value of PAL_SET_HW_POLICY.Policy
3196 #define PAL_SET_HW_POLICY_PERFORMANCE 0
3197 #define PAL_SET_HW_POLICY_FAIRNESS 1
3198 #define PAL_SET_HW_POLICY_HIGH_PRIORITY 2
3199 #define PAL_SET_HW_POLICY_EXCLUSIVE_HIGH_PRIORITY 3
3203 PAL Procedure - PAL_SET_HW_POLICY.
3205 Sets the current hardware resource sharing policy of the
3206 processor. It is optional by IPF. The PAL procedure supports
3207 the Static Registers calling convention. It could be called at
3208 physical and Virtual mode.
3211 @param Index Index of PAL_SET_HW_POLICY within the list of PAL
3214 @param Policy Unsigned 64-bit integer specifying the hardware
3215 resource sharing policy the caller is setting.
3216 See Value of PAL_SET_HW_POLICY.Policy above.
3219 @return Status 1 - Call completed successfully but could not
3220 change the hardware policy since a
3221 competing logical processor is set in
3222 exclusive high priority.
3224 @return Status 0 - Call completed without error
3226 @return Status -1 - Unimplemented procedure
3228 @return Status -2 - Invalid argument
3230 @return Status -3 - Call completed with error.
3232 @return Status -9 - Call requires PAL memory buffer.
3235 #define PAL_SET_HW_POLICY 49
3240 @param Mode Bit2:0, Indicates the mode of operation for this
3241 procedure: 0 - Query mode 1 ¨C Error inject mode
3242 (err_inj should also be specified) 2 - Cancel
3243 outstanding trigger. All other fields in
3244 PAL_MC_ERROR_TYPE_INFO,
3245 PAL_MC_ERROR_STRUCTURE_INFO and
3246 PAL_MC_ERROR_DATA_BUFFER are ignored. All other
3247 values are reserved.
3249 @param ErrorInjection Bit5:3, indicates the mode of error
3250 injection: 0 - Error inject only (no
3251 error consumption) 1 - Error inject
3252 and consume All other values are
3256 @param ErrorSeverity Bit7:6, indicates the severity desired
3257 for error injection/query. Definitions
3258 of the different error severity types
3259 0 - Corrected error 1 - Recoverable
3260 error 2 - Fatal error 3 - Reserved
3263 @param ErrorStructure Bit12:8, Indicates the structure
3264 identification for error
3265 injection/query: 0 - Any structure
3266 (cannot be used during query mode).
3267 When selected, the structure type used
3268 for error injection is determined by
3269 PAL. 1 - Cache 2 - TLB 3 - Register
3270 file 4 - Bus/System interconnect 5-15
3271 - Reserved 16-31 - Processor
3272 specific error injection
3273 capabilities.ErrorDataBuffer is used
3274 to specify error types. Please refer
3275 to the processor specific
3276 documentation for additional details.
3278 @param StructureHierarchy Bit15:13, Indicates the structure
3280 injection/query: 0 - Any level of
3281 hierarchy (cannot be used during
3282 query mode). When selected, the
3283 structure hierarchy used for error
3284 injection is determined by PAL. 1
3285 - Error structure hierarchy
3286 level-1 2 - Error structure
3287 hierarchy level-2 3 - Error
3288 structure hierarchy level-3 4 -
3289 Error structure hierarchy level-4
3290 All other values are reserved.
3291 Reserved 63:16 Reserved
3296 UINT64 ErrorInjection
:3;
3297 UINT64 ErrorSeverity
:2;
3298 UINT64 ErrorStructure
:5;
3299 UINT64 StructureHierarchy
:3;
3301 } PAL_MC_ERROR_TYPE_INFO
;
3305 @param StructInfoIsValid Bit0 When 1, indicates that the
3306 structure information fields
3307 (c_t,cl_p,cl_id) are valid and
3308 should be used for error injection.
3309 When 0, the structure information
3310 fields are ignored, and the values
3311 of these fields used for error
3313 implementation-specific.
3315 @param CacheType Bit2:1 Indicates which cache should be used
3316 for error injection: 0 - Reserved 1 -
3317 Instruction cache 2 - Data or unified cache
3321 @param PortionOfCacheLine Bit5:3 Indicates the portion of the
3322 cache line where the error should
3323 be injected: 0 - Reserved 1 - Tag
3324 2 - Data 3 - mesi All other
3325 values are reserved.
3327 @param Mechanism Bit8:6 Indicates which mechanism is used to
3328 identify the cache line to be used for error
3329 injection: 0 - Reserved 1 - Virtual address
3330 provided in the inj_addr field of the buffer
3331 pointed to by err_data_buffer should be used
3332 to identify the cache line for error
3333 injection. 2 - Physical address provided in
3334 the inj_addr field of the buffer pointed to
3335 by err_data_buffershould be used to identify
3336 the cache line for error injection. 3 - way
3337 and index fields provided in err_data_buffer
3338 should be used to identify the cache line
3339 for error injection. All other values are
3342 @param DataPoisonOfCacheLine Bit9 When 1, indicates that a
3343 multiple bit, non-correctable
3344 error should be injected in the
3345 cache line specified by cl_id.
3346 If this injected error is not
3347 consumed, it may eventually
3348 cause a data-poisoning event
3349 resulting in a corrected error
3350 signal, when the associated
3351 cache line is cast out (implicit
3352 or explicit write-back of the
3353 cache line). The error severity
3354 specified by err_sev in
3355 err_type_info must be set to 0
3356 (corrected error) when this bit
3360 @param TrigerInfoIsValid Bit32 When 1, indicates that the
3361 trigger information fields (trigger,
3362 trigger_pl) are valid and should be
3363 used for error injection. When 0,
3364 the trigger information fields are
3365 ignored and error injection is
3366 performed immediately.
3368 @param Triger Bit36:33 Indicates the operation type to be
3369 used as the error trigger condition. The
3370 address corresponding to the trigger is
3371 specified in the trigger_addr field of the
3372 buffer pointed to by err_data_buffer: 0 -
3373 Instruction memory access. The trigger match
3374 conditions for this operation type are similar
3375 to the IBR address breakpoint match conditions
3376 1 - Data memory access. The trigger match
3377 conditions for this operation type are similar
3378 to the DBR address breakpoint match conditions
3379 All other values are reserved.
3381 @param PrivilegeOfTriger Bit39:37 Indicates the privilege
3382 level of the context during which
3383 the error should be injected: 0 -
3384 privilege level 0 1 - privilege
3385 level 1 2 - privilege level 2 3 -
3386 privilege level 3 All other values
3387 are reserved. If the implementation
3388 does not support privilege level
3389 qualifier for triggers (i.e. if
3390 trigger_pl is 0 in the capabilities
3391 vector), this field is ignored and
3392 triggers can be taken at any
3397 UINT64 StructInfoIsValid
:1;
3399 UINT64 PortionOfCacheLine
:3;
3401 UINT64 DataPoisonOfCacheLine
:1;
3402 UINT64 Reserved1
:22;
3403 UINT64 TrigerInfoIsValid
:1;
3405 UINT64 PrivilegeOfTriger
:3;
3406 UINT64 Reserved2
:24;
3407 } PAL_MC_ERROR_STRUCT_INFO
;
3411 Buffer Pointed to by err_data_buffer ¨C TLB
3415 UINT64 TrigerAddress
;
3416 UINT64 VirtualPageNumber
:52;
3419 UINT64 Reserved2
:40;
3420 } PAL_MC_ERROR_DATA_BUFFER_TLB
;
3424 PAL Procedure - PAL_MC_ERROR_INJECT.
3426 Injects the requested processor error or returns information
3427 on the supported injection capabilities for this particular
3428 processor implementation. It is optional by IPF. The PAL
3429 procedure supports the Stacked Registers calling convention.
3430 It could be called at physical and Virtual mode.
3433 @param Index Index of PAL_MC_ERROR_INJECT within the list of PAL
3436 @param ErrorTypeInfo Unsigned 64-bit integer specifying the
3437 first level error information which
3438 identifies the error structure and
3439 corresponding structure hierarchy, and
3442 @param ErrorStructInfo Unsigned 64-bit integer identifying
3443 the optional structure specific
3444 information that provides the second
3445 level details for the requested error.
3447 @param ErrorDataBuffer 64-bit physical address of a buffer
3448 providing additional parameters for
3449 the requested error. The address of
3450 this buffer must be 8-byte aligned.
3452 @return R9 64-bit vector specifying the supported error
3453 injection capabilities for the input argument
3454 combination of struct_hier, err_struct and
3455 err_sev fields in ErrorTypeInfo.
3457 @return R10 64-bit vector specifying the architectural
3458 resources that are used by the procedure.
3461 @return Status 0 - Call completed without error
3463 @return Status -1 - Unimplemented procedure
3465 @return Status -2 - Invalid argument
3467 @return Status -3 - Call completed with error.
3469 @return Status -4 - Call completed with error; the requested
3470 error could not be injected due to failure in
3471 locating the target location in the specified
3474 @return Status -5 - Argument was valid, but requested error
3475 injection capability is not supported.
3477 @return Status -9 - Call requires PAL memory buffer.
3480 #define PAL_MC_ERROR_INJECT 276
3484 // Types of PAL_GET_PSTATE.Type
3486 #define PAL_GET_PSTATE_RECENT 0
3487 #define PAL_GET_PSTATE_AVERAGE_NEW_START 1
3488 #define PAL_GET_PSTATE_AVERAGE 2
3489 #define PAL_GET_PSTATE_NOW 3
3493 PAL Procedure - PAL_GET_PSTATE.
3495 Returns the performance index of the processor. It is optional
3496 by IPF. The PAL procedure supports the Stacked Registers
3497 calling convention. It could be called at physical and Virtual
3501 @param Index Index of PAL_GET_PSTATE within the list of PAL
3504 @param Type Type of performance_index value to be returned
3505 by this procedure.See PAL_GET_PSTATE.Type above.
3508 @return R9 Unsigned integer denoting the processor
3509 performance for the time duration since the last
3510 PAL_GET_PSTATE procedure call was made. The
3511 value returned is between 0 and 100, and is
3512 relative to the performance index of the highest
3515 @return Status 1 - Call completed without error, but accuracy
3516 of performance index has been impacted by a
3517 thermal throttling event, or a
3518 hardware-initiated event.
3520 @return Status 0 - Call completed without error
3522 @return Status -1 - Unimplemented procedure
3524 @return Status -2 - Invalid argument
3526 @return Status -3 - Call completed with error.
3528 @return Status -9 - Call requires PAL memory buffer.
3531 #define PAL_GET_PSTATE 262
3535 Layout of PAL_PSTATE_INFO.PStateBuffer
3539 UINT32 PerformanceIndex
:7;
3541 UINT32 TypicalPowerDissipation
:20;
3542 UINT32 TransitionLatency1
;
3543 UINT32 TransitionLatency2
;
3545 } PAL_PSTATE_INFO_BUFFER
;
3550 PAL Procedure - PAL_PSTATE_INFO.
3552 Returns information about the P-states suppor