Specifications
234 AMD Geode™ GeodeROM Functional Specification
System Management Mode Software
32087C
15.13.4.2 GET_REGISTER
The GET_REGISTER macro is used to retrieve a general-purpose register from the interrupted (non-SMM) task.
• Parameter0
— Register name
Note: This system call is only valid when servicing a synchronous event (EVENT_SOFTWARE_SMI, EVENT_IO_TRAP,
EVENT_MEMORY_TRAP). Attempting to use it when servicing an asynchronous event is a programming error.
Example of usage:
Register_EDX = GET_REGISTER (R_EDX); // Get caller's EDX
15.13.4.3 SET_HEADER_DATA
The SET_HEADER_DATA macro is used to write data to the SMI header from the interrupted (non-SMM) task. The size of
the field written is determined by the field.
• Parameter0
— Name of SMM header field
• Parameter1
—Data
Note: This system call is only valid when servicing a synchronous event (EVENT_SOFTWARE_SMI, EVENT_IO_TRAP,
EVENT_MEMORY_TRAP). Attempting to use it when servicing an asynchronous event signals an error.
Example of usage:
SET_HEADER_DATA(CURRENT_EIP, GET_HEADER_DATA (NEXT_EIP));
15.13.4.4 GET_HEADER_DATA
The GET_HEADER_DATA macro is used to read data from the SMI header from the interrupted (non-SMM) task. The size
of the field retrieved is determined by the field.
• Parameter0
— Name of SMM header field
Note: This system call is only valid when servicing a synchronous event (EVENT_SOFTWARE_SMI, EVENT_IO_TRAP,
EVENT_MEMORY_TRAP). Attempting to use it when servicing an asynchronous event signals an error.
Valid SMM header field names are:
NEXT_EIP
CURRENT_EIP
CS_LIMIT
CS_BASE
CS_SELECTOR
CS_ATTRIBUTE
R_CR0
R_DR7
EFLAGS
DATA_SIZE
IO_ADDRESS
WRITE_DATA
Example of usage:
Address = GET_HEADER_DATA (NEXT_EIP); // Get address of trapped instruction