diff options
| author | David Vrabel <david.vrabel@citrix.com> | 2012-07-09 06:39:07 -0400 |
|---|---|---|
| committer | Konrad Rzeszutek Wilk <konrad.wilk@oracle.com> | 2012-07-19 15:51:45 -0400 |
| commit | 59290362da587ce2e6d2f4a7f85e362fa2d7fd39 (patch) | |
| tree | f111491ff440fa50cc7d0c7d33496e7c4a1c48ed | |
| parent | 66a27dde9ae96e35278983f2e59bea04eb714cd0 (diff) | |
xen/x86: add desc_equal() to compare GDT descriptors
Signed-off-by: David Vrabel <david.vrabel@citrix.com>
[v1: Moving it to the Xen file]
Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
| -rw-r--r-- | arch/x86/xen/enlighten.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/arch/x86/xen/enlighten.c b/arch/x86/xen/enlighten.c index 0c1ab43f6672..225ffdc3c4ca 100644 --- a/arch/x86/xen/enlighten.c +++ b/arch/x86/xen/enlighten.c | |||
| @@ -539,6 +539,12 @@ static void __init xen_load_gdt_boot(const struct desc_ptr *dtr) | |||
| 539 | BUG(); | 539 | BUG(); |
| 540 | } | 540 | } |
| 541 | 541 | ||
| 542 | static inline bool desc_equal(const struct desc_struct *d1, | ||
| 543 | const struct desc_struct *d2) | ||
| 544 | { | ||
| 545 | return d1->a == d2->a && d1->b == d2->b; | ||
| 546 | } | ||
| 547 | |||
| 542 | static void load_TLS_descriptor(struct thread_struct *t, | 548 | static void load_TLS_descriptor(struct thread_struct *t, |
| 543 | unsigned int cpu, unsigned int i) | 549 | unsigned int cpu, unsigned int i) |
| 544 | { | 550 | { |
