2020-09-17 13:06:35 +03:00
|
|
|
gdt:
|
2020-12-06 18:43:38 +03:00
|
|
|
dw .size - 1 + 8 ; GDT size
|
|
|
|
dd .start - 8 ; GDT start address
|
2019-05-30 17:25:23 +03:00
|
|
|
|
2020-09-17 13:06:35 +03:00
|
|
|
.start:
|
|
|
|
; 32-bit code
|
|
|
|
dw 0xffff ; Limit
|
|
|
|
dw 0x0000 ; Base (low 16 bits)
|
|
|
|
db 0x00 ; Base (mid 8 bits)
|
|
|
|
db 10011010b ; Access
|
|
|
|
db 11001111b ; Granularity
|
|
|
|
db 0x00 ; Base (high 8 bits)
|
2019-05-30 17:25:23 +03:00
|
|
|
|
2020-09-17 13:06:35 +03:00
|
|
|
; 32-bit data
|
|
|
|
dw 0xffff ; Limit
|
|
|
|
dw 0x0000 ; Base (low 16 bits)
|
|
|
|
db 0x00 ; Base (mid 8 bits)
|
|
|
|
db 10010010b ; Access
|
|
|
|
db 11001111b ; Granularity
|
|
|
|
db 0x00 ; Base (high 8 bits)
|
2019-05-30 17:25:23 +03:00
|
|
|
|
2020-09-17 13:06:35 +03:00
|
|
|
.end:
|
2020-03-25 06:38:23 +03:00
|
|
|
|
2020-09-17 13:06:35 +03:00
|
|
|
.size: equ .end - .start
|