12.07.2015 Views

Geode GXLV Processor Series Low Power Integrated x86 Solutions

Geode GXLV Processor Series Low Power Integrated x86 Solutions

Geode GXLV Processor Series Low Power Integrated x86 Solutions

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

<strong>Geode</strong> <strong>GXLV</strong> <strong>Processor</strong> <strong>Series</strong><strong>Processor</strong> Programming (Continued)Gate DescriptorsFour kinds of gate descriptors are used to provide protectionduring control transfers:• Call gates• Trap gates• Interrupt gates• Task gates(For more information on protection refer to Section 3.9“Protection” on page 91.)Call Gate Descriptor (CGD). Call gates are used todefine legal entry points to a procedure with a higher privilegelevel. The call gates are used by CALL and JUMPinstructions in much the same manner as code segmentdescriptors. When a decoded instruction refers to a callgate descriptor in the GDT or LDT, the call gate is used topoint to another descriptor in the table that defines thedestination code segment.The following privilege levels are tested during the transferthrough the call gate:• CPL = Current Privilege Level• RPL = Segment Selector Field• DPL = Descriptor Privilege Level in the call gatedescriptor• DPL = Descriptor Privilege Level in the destinationcode segmentThe maximum value of the CPL and RPL must be equalor less than the gate DPL. For a JMP instruction the destinationDPL equals the CPL. For a CALL instruction thedestination DPL is less than or equal to the CPL.Conforming Code Segments. Transfer to a procedurewith a higher privilege level can also be accomplished bybypassing the use of call gates, if the requested procedureis to be executed in a conforming code segment.Conforming code segments have the C bit set in theTYPE field in their descriptor.The bit structure and definitions for gate descriptors areshown in Tables 3-24 and 3-25.Table 3-24. Gate Descriptors31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0Memory Offset +4OFFSET[31:16] P DPL 0 TYPE 0 0 0 PARAMETERSMemory Offset +0SELECTOR[15:0]OFFSET[15:0]Table 3-25. Gate Descriptors Bit DefinitionsBitMemoryOffset Name Description31:16 +4 OFFSET Offset: Offset used during a call gate to calculate the branch target.15:0 +031:16 +0 SELECTOR Segment Selector15 +4 P Segment Present14:13 +4 DPL Descriptor Privilege Level11:8 +4 TYPE Segment Type:0100 = 16-bit call gate 1100 = 32-bit call gate0101 = Task gate 1110 = 32-bit interrupt gate0110 = 16-bit interrupt gate 1111 = 32-bit trap gate0111 = 16-bit trap gate4:0 +4 PARAMETERS Parameters: Number of parameters to copy from the caller’s stack to the called procedure’sstack.www.national.com 74 Revision 1.3

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!