1 #ifndef __ASM_HOST_LDT_H
2 #define __ASM_HOST_LDT_H
6 #define LDT_entry_a(info) \
7 ((((info)->base_addr & 0x0000ffff) << 16) | ((info)->limit & 0x0ffff))
9 #define LDT_entry_b(info) \
10 (((info)->base_addr & 0xff000000) | \
11 (((info)->base_addr & 0x00ff0000) >> 16) | \
12 ((info)->limit & 0xf0000) | \
13 (((info)->read_exec_only ^ 1) << 9) | \
14 ((info)->contents << 10) | \
15 (((info)->seg_not_present ^ 1) << 15) | \
16 ((info)->seg_32bit << 22) | \
17 ((info)->limit_in_pages << 23) | \
18 ((info)->useable << 20) | \
21 #define _LDT_empty(info) (\
22 (info)->base_addr == 0 && \
23 (info)->limit == 0 && \
24 (info)->contents == 0 && \
25 (info)->read_exec_only == 1 && \
26 (info)->seg_32bit == 0 && \
27 (info)->limit_in_pages == 0 && \
28 (info)->seg_not_present == 1 && \
29 (info)->useable == 0 )
32 #define LDT_empty(info) (_LDT_empty(info) && ((info)->lm == 0))
34 #define LDT_empty(info) (_LDT_empty(info))