mirror of
https://gitlab.com/qemu-project/qemu
synced 2024-11-02 21:32:52 +00:00
ia64 fixes
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@1846 c046a42c-6fe2-441c-8c8c-71466251a162
This commit is contained in:
parent
ad1a5b7853
commit
fd4a43e4e2
6 changed files with 9 additions and 40 deletions
|
@ -252,9 +252,6 @@ ifeq ($(findstring m68k, $(TARGET_ARCH) $(ARCH)),m68k)
|
|||
LIBOBJS+=m68k-dis.o
|
||||
endif
|
||||
|
||||
ifeq ($(ARCH),ia64)
|
||||
OBJS += ia64-syscall.o
|
||||
endif
|
||||
ifdef CONFIG_GDBSTUB
|
||||
OBJS+=gdbstub.o
|
||||
endif
|
||||
|
|
|
@ -1363,7 +1363,6 @@ int cpu_signal_handler(int host_signum, struct siginfo *info,
|
|||
#ifndef __ISR_VALID
|
||||
/* This ought to be in <bits/siginfo.h>... */
|
||||
# define __ISR_VALID 1
|
||||
# define si_flags _sifields._sigfault._si_pad0
|
||||
#endif
|
||||
|
||||
int cpu_signal_handler(int host_signum, struct siginfo *info, void *puc)
|
||||
|
@ -1379,7 +1378,7 @@ int cpu_signal_handler(int host_signum, struct siginfo *info, void *puc)
|
|||
case SIGSEGV:
|
||||
case SIGBUS:
|
||||
case SIGTRAP:
|
||||
if (info->si_code && (info->si_flags & __ISR_VALID))
|
||||
if (info->si_code && (info->si_segvflags & __ISR_VALID))
|
||||
/* ISR.W (write-access) is bit 33: */
|
||||
is_write = (info->si_isr >> 33) & 1;
|
||||
break;
|
||||
|
|
6
dyngen.c
6
dyngen.c
|
@ -2475,10 +2475,12 @@ fprintf(outfile,
|
|||
);
|
||||
#ifdef HOST_IA64
|
||||
fprintf(outfile,
|
||||
" ia64_apply_fixes(&gen_code_ptr, ltoff_fixes, "
|
||||
" {\n"
|
||||
" extern char code_gen_buffer[];\n"
|
||||
" ia64_apply_fixes(&gen_code_ptr, ltoff_fixes, "
|
||||
"(uint64_t) code_gen_buffer + 2*(1<<20), plt_fixes,\n\t\t\t"
|
||||
"sizeof(plt_target)/sizeof(plt_target[0]),\n\t\t\t"
|
||||
"plt_target, plt_offset);\n");
|
||||
"plt_target, plt_offset);\n }\n");
|
||||
#endif
|
||||
|
||||
/* generate some code patching */
|
||||
|
|
3
dyngen.h
3
dyngen.h
|
@ -420,6 +420,9 @@ static inline void ia64_apply_fixes (uint8_t **gen_code_pp,
|
|||
}
|
||||
ia64_imm22(fixup->addr, (long) vp - gp);
|
||||
}
|
||||
/* Keep code ptr aligned. */
|
||||
if ((long) gen_code_ptr & 15)
|
||||
gen_code_ptr += 8;
|
||||
*gen_code_pp = gen_code_ptr;
|
||||
}
|
||||
|
||||
|
|
|
@ -1,32 +0,0 @@
|
|||
/* derived from glibc sysdeps/unix/sysv/linux/ia64/sysdep.S */
|
||||
|
||||
#define __ASSEMBLY__
|
||||
|
||||
#include <asm/asmmacro.h>
|
||||
#include <asm/unistd.h>
|
||||
|
||||
ENTRY(__syscall_error)
|
||||
.prologue ASM_UNW_PRLG_RP|ASM_UNW_PRLG_PFS, ASM_UNW_PRLG_GRSAVE(0)
|
||||
alloc r33=ar.pfs, 0, 4, 0, 0
|
||||
mov r32=rp
|
||||
.body
|
||||
mov r35=r8
|
||||
mov r34=r1
|
||||
;;
|
||||
br.call.sptk.many b0 = __errno_location
|
||||
.Lret0: /* force new bundle */
|
||||
st4 [r8]=r35
|
||||
mov r1=r34
|
||||
mov rp=r32
|
||||
mov r8=-1
|
||||
mov ar.pfs=r33
|
||||
br.ret.sptk.few b0
|
||||
END(__syscall_error)
|
||||
|
||||
GLOBAL_ENTRY(__ia64_syscall)
|
||||
mov r15=r37 /* syscall number */
|
||||
break __BREAK_SYSCALL
|
||||
cmp.eq p6,p0=-1,r10 /* r10 = -1 on error */
|
||||
(p6) br.cond.spnt.few __syscall_error
|
||||
br.ret.sptk.few b0
|
||||
.endp __ia64_syscall
|
|
@ -1623,7 +1623,7 @@ int do_fork(CPUState *env, unsigned int flags, unsigned long newsp)
|
|||
#endif
|
||||
new_env->opaque = ts;
|
||||
#ifdef __ia64__
|
||||
ret = clone2(clone_func, new_stack + NEW_STACK_SIZE, flags, new_env);
|
||||
ret = __clone2(clone_func, new_stack + NEW_STACK_SIZE, flags, new_env);
|
||||
#else
|
||||
ret = clone(clone_func, new_stack + NEW_STACK_SIZE, flags, new_env);
|
||||
#endif
|
||||
|
|
Loading…
Reference in a new issue