UnnamedOS
gdt_entry_t Struct Reference

An entry in the GDT. More...

#include <gdt.h>

Data Fields

uint16_t limit0_15: 16
 maximum offset allowed (byte 1-2)
 
uint32_t base0_23: 24
 where the segment begins (byte 1-3)
 
uint8_t ac: 1
 accessed
 
uint8_t rw: 1
 read / write allowed
 
uint8_t dc: 1
 direction / conforming
 
uint8_t ex: 1
 executable
 
uint8_t dt: 1
 descriptor type
 
uint8_t dpl: 2
 Descriptor privilege level. More...
 
uint8_t pr: 1
 present
 
uint8_t limit16_19: 4
 maximum offset allowed (last nibble)
 
uint8_t reserved: 2
 always 0 (long mode & available)
 
uint8_t sz: 1
 size
 
uint8_t gr: 1
 granularity
 
uint8_t base24_31: 8
 where the segment begins (byte 4)
 

Detailed Description

An entry in the GDT.

This corresponds directly to a memory segment or TSS.

Definition at line 20 of file gdt.h.

Field Documentation

uint8_t gdt_entry_t::dpl

Descriptor privilege level.

Whereas CPL is the current privilege level and RPL the requested privilege level.

Definition at line 28 of file gdt.h.


The documentation for this struct was generated from the following file: