From fa872b345fafde3b9ae1c3a35ea011e4d8a0684b Mon Sep 17 00:00:00 2001 From: David Mosberger Date: Mon, 20 Oct 2003 23:54:20 -0700 Subject: [PATCH] ia64: Fix IA-32 NPTL fixes so things compile again. --- arch/ia64/ia32/binfmt_elf32.c | 2 +- arch/ia64/ia32/ia32priv.h | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/arch/ia64/ia32/binfmt_elf32.c b/arch/ia64/ia32/binfmt_elf32.c index 8f29963bcd90e..07938b26c1780 100644 --- a/arch/ia64/ia32/binfmt_elf32.c +++ b/arch/ia64/ia32/binfmt_elf32.c @@ -63,7 +63,7 @@ struct page * ia32_install_shared_page (struct vm_area_struct *vma, unsigned long address, int no_share) { # define NUM_SHARED_PAGES (PAGE_SIZE > IA32_PAGE_SIZE ? 1 : 2) - struct page *pg = ia32_shared_page[NUM_SHARED__PAGES * smp_processor_id() + struct page *pg = ia32_shared_page[NUM_SHARED_PAGES * smp_processor_id() + (address - vma->vm_start)/PAGE_SIZE]; get_page(pg); diff --git a/arch/ia64/ia32/ia32priv.h b/arch/ia64/ia32/ia32priv.h index e7b4fa608109b..7a95993680412 100644 --- a/arch/ia64/ia32/ia32priv.h +++ b/arch/ia64/ia32/ia32priv.h @@ -457,11 +457,11 @@ void ia64_elf32_init(struct pt_regs *regs); static inline void load_TLS (struct thread_struct *t, unsigned int cpu) { - extern struct desc_struct *cpu_gdt_table[NR_CPUS]; + extern unsigned long *cpu_gdt_table[NR_CPUS]; - cpu_gdt_table[cpu][GDT_ENTRY_TLS_MIN + 0] = t->tls_array[0]; - cpu_gdt_table[cpu][GDT_ENTRY_TLS_MIN + 1] = t->tls_array[1]; - cpu_gdt_table[cpu][GDT_ENTRY_TLS_MIN + 2] = t->tls_array[2]; + memcpy(cpu_gdt_table[cpu] + GDT_ENTRY_TLS_MIN + 0, &t->tls_array[0], sizeof(long)); + memcpy(cpu_gdt_table[cpu] + GDT_ENTRY_TLS_MIN + 1, &t->tls_array[1], sizeof(long)); + memcpy(cpu_gdt_table[cpu] + GDT_ENTRY_TLS_MIN + 2, &t->tls_array[2], sizeof(long)); } struct ia32_user_desc { -- 2.53.0