1 /** @file 2 STM Status Codes 3 4 Copyright (c) 2015 - 2016, Intel Corporation. All rights reserved.<BR> 5 This program and the accompanying materials 6 are licensed and made available under the terms and conditions of the BSD License 7 which accompanies this distribution. The full text of the license may be found at 8 http://opensource.org/licenses/bsd-license.php. 9 10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, 11 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. 12 13 @par Specification Reference: 14 SMI Transfer Monitor (STM) User Guide Revision 1.00 15 16 **/ 17 18 #ifndef _STM_STATUS_CODE_H_ 19 #define _STM_STATUS_CODE_H_ 20 21 /** 22 STM Status Codes 23 **/ 24 typedef UINT32 STM_STATUS; 25 26 /** 27 Success code have BIT31 clear. 28 All error codes have BIT31 set. 29 STM errors have BIT16 set. 30 SMM errors have BIT17 set 31 Errors that apply to both STM and SMM have bits BIT15, BT16, and BIT17 set. 32 STM TXT.ERRORCODE codes have BIT30 set. 33 @{ 34 **/ 35 #define STM_SUCCESS 0x00000000 36 #define SMM_SUCCESS 0x00000000 37 #define ERROR_STM_SECURITY_VIOLATION (BIT31 | BIT16 | 0x0001) 38 #define ERROR_STM_CACHE_TYPE_NOT_SUPPORTED (BIT31 | BIT16 | 0x0002) 39 #define ERROR_STM_PAGE_NOT_FOUND (BIT31 | BIT16 | 0x0003) 40 #define ERROR_STM_BAD_CR3 (BIT31 | BIT16 | 0x0004) 41 #define ERROR_STM_PHYSICAL_OVER_4G (BIT31 | BIT16 | 0x0005) 42 #define ERROR_STM_VIRTUAL_SPACE_TOO_SMALL (BIT31 | BIT16 | 0x0006) 43 #define ERROR_STM_UNPROTECTABLE_RESOURCE (BIT31 | BIT16 | 0x0007) 44 #define ERROR_STM_ALREADY_STARTED (BIT31 | BIT16 | 0x0008) 45 #define ERROR_STM_WITHOUT_SMX_UNSUPPORTED (BIT31 | BIT16 | 0x0009) 46 #define ERROR_STM_STOPPED (BIT31 | BIT16 | 0x000A) 47 #define ERROR_STM_BUFFER_TOO_SMALL (BIT31 | BIT16 | 0x000B) 48 #define ERROR_STM_INVALID_VMCS_DATABASE (BIT31 | BIT16 | 0x000C) 49 #define ERROR_STM_MALFORMED_RESOURCE_LIST (BIT31 | BIT16 | 0x000D) 50 #define ERROR_STM_INVALID_PAGECOUNT (BIT31 | BIT16 | 0x000E) 51 #define ERROR_STM_LOG_ALLOCATED (BIT31 | BIT16 | 0x000F) 52 #define ERROR_STM_LOG_NOT_ALLOCATED (BIT31 | BIT16 | 0x0010) 53 #define ERROR_STM_LOG_NOT_STOPPED (BIT31 | BIT16 | 0x0011) 54 #define ERROR_STM_LOG_NOT_STARTED (BIT31 | BIT16 | 0x0012) 55 #define ERROR_STM_RESERVED_BIT_SET (BIT31 | BIT16 | 0x0013) 56 #define ERROR_STM_NO_EVENTS_ENABLED (BIT31 | BIT16 | 0x0014) 57 #define ERROR_STM_OUT_OF_RESOURCES (BIT31 | BIT16 | 0x0015) 58 #define ERROR_STM_FUNCTION_NOT_SUPPORTED (BIT31 | BIT16 | 0x0016) 59 #define ERROR_STM_UNPROTECTABLE (BIT31 | BIT16 | 0x0017) 60 #define ERROR_STM_UNSUPPORTED_MSR_BIT (BIT31 | BIT16 | 0x0018) 61 #define ERROR_STM_UNSPECIFIED (BIT31 | BIT16 | 0xFFFF) 62 #define ERROR_SMM_BAD_BUFFER (BIT31 | BIT17 | 0x0001) 63 #define ERROR_SMM_INVALID_RSC (BIT31 | BIT17 | 0x0004) 64 #define ERROR_SMM_INVALID_BUFFER_SIZE (BIT31 | BIT17 | 0x0005) 65 #define ERROR_SMM_BUFFER_TOO_SHORT (BIT31 | BIT17 | 0x0006) 66 #define ERROR_SMM_INVALID_LIST (BIT31 | BIT17 | 0x0007) 67 #define ERROR_SMM_OUT_OF_MEMORY (BIT31 | BIT17 | 0x0008) 68 #define ERROR_SMM_AFTER_INIT (BIT31 | BIT17 | 0x0009) 69 #define ERROR_SMM_UNSPECIFIED (BIT31 | BIT17 | 0xFFFF) 70 #define ERROR_INVALID_API (BIT31 | BIT17 | BIT16 | BIT15 | 0x0001) 71 #define ERROR_INVALID_PARAMETER (BIT31 | BIT17 | BIT16 | BIT15 | 0x0002) 72 #define STM_CRASH_PROTECTION_EXCEPTION (BIT31 | BIT30 | 0xF001) 73 #define STM_CRASH_PROTECTION_EXCEPTION_FAILURE (BIT31 | BIT30 | 0xF002) 74 #define STM_CRASH_DOMAIN_DEGRADATION_FAILURE (BIT31 | BIT30 | 0xF003) 75 #define STM_CRASH_BIOS_PANIC (BIT31 | BIT30 | 0xE000) 76 /// @} 77 78 #endif 79