ia64/xen-unstable
changeset 9009:b417cb20f1db
[IA64] Misc clean-up and warnings removal.
Signed-off-by: Tristan Gingold <tristan.gingold@bull.net>
Signed-off-by: Tristan Gingold <tristan.gingold@bull.net>
author | awilliam@xenbuild.aw |
---|---|
date | Tue Feb 28 13:10:16 2006 -0700 (2006-02-28) |
parents | 4db98649cc36 |
children | e58ff5fd3550 |
files | xen/arch/ia64/xen/irq.c xen/arch/ia64/xen/privop.c xen/arch/ia64/xen/process.c xen/include/asm-ia64/debugger.h xen/include/asm-ia64/linux-xen/asm/tlbflush.h xen/include/asm-ia64/privop.h xen/include/asm-ia64/xensystem.h |
line diff
1.1 --- a/xen/arch/ia64/xen/irq.c Tue Feb 28 12:43:08 2006 -0700 1.2 +++ b/xen/arch/ia64/xen/irq.c Tue Feb 28 13:10:16 2006 -0700 1.3 @@ -129,7 +129,9 @@ unsigned int __ia64_local_vector_to_irq 1.4 } 1.5 #endif 1.6 1.7 +#ifndef XEN 1.8 static void register_irq_proc (unsigned int irq); 1.9 +#endif 1.10 1.11 /* 1.12 * Special irq handlers. 1.13 @@ -1492,6 +1494,7 @@ extern void domain_pend_keyboard_interru 1.14 irqreturn_t guest_forward_keyboard_input(int irq, void *nada, struct pt_regs *regs) 1.15 { 1.16 domain_pend_keyboard_interrupt(irq); 1.17 + return 0; 1.18 } 1.19 1.20 void serial_input_init(void)
2.1 --- a/xen/arch/ia64/xen/privop.c Tue Feb 28 12:43:08 2006 -0700 2.2 +++ b/xen/arch/ia64/xen/privop.c Tue Feb 28 13:10:16 2006 -0700 2.3 @@ -529,7 +529,7 @@ IA64FAULT priv_mov_from_psr(VCPU *vcpu, 2.4 Privileged operation decode and dispatch routines 2.5 **************************************************************************/ 2.6 2.7 -IA64_SLOT_TYPE slot_types[0x20][3] = { 2.8 +static const IA64_SLOT_TYPE slot_types[0x20][3] = { 2.9 {M, I, I}, {M, I, I}, {M, I, I}, {M, I, I}, 2.10 {M, I, ILLEGAL}, {M, I, ILLEGAL}, 2.11 {ILLEGAL, ILLEGAL, ILLEGAL}, {ILLEGAL, ILLEGAL, ILLEGAL}, 2.12 @@ -549,7 +549,7 @@ IA64_SLOT_TYPE slot_types[0x20][3] = { 2.13 // pointer to privileged emulation function 2.14 typedef IA64FAULT (*PPEFCN)(VCPU *vcpu, INST64 inst); 2.15 2.16 -PPEFCN Mpriv_funcs[64] = { 2.17 +static const PPEFCN Mpriv_funcs[64] = { 2.18 priv_mov_to_rr, priv_mov_to_dbr, priv_mov_to_ibr, priv_mov_to_pkr, 2.19 priv_mov_to_pmc, priv_mov_to_pmd, 0, 0, 2.20 0, priv_ptc_l, priv_ptc_g, priv_ptc_ga, 2.21 @@ -799,7 +799,7 @@ priv_emulate(VCPU *vcpu, REGS *regs, UIN 2.22 #define HYPERPRIVOP_SET_KR 0x12 2.23 #define HYPERPRIVOP_MAX 0x12 2.24 2.25 -char *hyperpriv_str[HYPERPRIVOP_MAX+1] = { 2.26 +static const char * const hyperpriv_str[HYPERPRIVOP_MAX+1] = { 2.27 0, "rfi", "rsm.dt", "ssm.dt", "cover", "itc.d", "itc.i", "ssm.i", 2.28 "=ivr", "=tpr", "tpr=", "eoi", "itm=", "thash", "ptc.ga", "itr.d", 2.29 "=rr", "rr=", "kr=" 2.30 @@ -898,7 +898,7 @@ ia64_hyperprivop(unsigned long iim, REGS 2.31 Privileged operation instrumentation routines 2.32 **************************************************************************/ 2.33 2.34 -char *Mpriv_str[64] = { 2.35 +static const char * const Mpriv_str[64] = { 2.36 "mov_to_rr", "mov_to_dbr", "mov_to_ibr", "mov_to_pkr", 2.37 "mov_to_pmc", "mov_to_pmd", "<0x06>", "<0x07>", 2.38 "<0x08>", "ptc_l", "ptc_g", "ptc_ga", 2.39 @@ -918,7 +918,7 @@ char *Mpriv_str[64] = { 2.40 }; 2.41 2.42 #define RS "Rsvd" 2.43 -char *cr_str[128] = { 2.44 +static const char * const cr_str[128] = { 2.45 "dcr","itm","iva",RS,RS,RS,RS,RS, 2.46 "pta",RS,RS,RS,RS,RS,RS,RS, 2.47 "ipsr","isr",RS,"iip","ifa","itir","iipa","ifs",
3.1 --- a/xen/arch/ia64/xen/process.c Tue Feb 28 12:43:08 2006 -0700 3.2 +++ b/xen/arch/ia64/xen/process.c Tue Feb 28 13:10:16 2006 -0700 3.3 @@ -228,14 +228,12 @@ unsigned long pending_false_positive = 0 3.4 3.5 void reflect_extint(struct pt_regs *regs) 3.6 { 3.7 -// extern unsigned long vcpu_verbose, privop_trace; 3.8 unsigned long isr = regs->cr_ipsr & IA64_PSR_RI; 3.9 struct vcpu *v = current; 3.10 static int first_extint = 1; 3.11 3.12 if (first_extint) { 3.13 printf("Delivering first extint to domain: isr=0x%lx, iip=0x%lx\n", isr, regs->cr_iip); 3.14 - //privop_trace = 1; vcpu_verbose = 1; 3.15 first_extint = 0; 3.16 } 3.17 if (vcpu_timer_pending_early(v)) 3.18 @@ -339,12 +337,8 @@ ia64_fault (unsigned long vector, unsign 3.19 { 3.20 struct pt_regs *regs = (struct pt_regs *) &stack; 3.21 unsigned long code; 3.22 -#if 0 3.23 - unsigned long error = isr; 3.24 - int result, sig; 3.25 -#endif 3.26 char buf[128]; 3.27 - static const char *reason[] = { 3.28 + static const char * const reason[] = { 3.29 "IA-64 Illegal Operation fault", 3.30 "IA-64 Privileged Operation fault", 3.31 "IA-64 Privileged Register fault", 3.32 @@ -708,9 +702,8 @@ void 3.33 ia64_handle_privop (unsigned long ifa, struct pt_regs *regs, unsigned long isr, unsigned long itir) 3.34 { 3.35 IA64FAULT vector; 3.36 - struct vcpu *v = current; 3.37 3.38 - vector = priv_emulate(v,regs,isr); 3.39 + vector = priv_emulate(current,regs,isr); 3.40 if (vector != IA64_NO_FAULT && vector != IA64_RFI_IN_PROGRESS) { 3.41 // Note: if a path results in a vector to reflect that requires 3.42 // iha/itir (e.g. vcpu_force_data_miss), they must be set there 3.43 @@ -764,7 +757,8 @@ ia64_handle_reflection (unsigned long if 3.44 } 3.45 #endif 3.46 printf("*** NaT fault... attempting to handle as privop\n"); 3.47 -printf("isr=0x%lx, ifa=0x%lx, iip=0x%lx, ipsr=0x%lx\n", isr, ifa, regs->cr_iip, psr); 3.48 +printf("isr=%016lx, ifa=%016lx, iip=%016lx, ipsr=%016lx\n", 3.49 + isr, ifa, regs->cr_iip, psr); 3.50 //regs->eml_unat = 0; FIXME: DO WE NEED THIS??? 3.51 // certain NaT faults are higher priority than privop faults 3.52 vector = priv_emulate(v,regs,isr);
4.1 --- a/xen/include/asm-ia64/debugger.h Tue Feb 28 12:43:08 2006 -0700 4.2 +++ b/xen/include/asm-ia64/debugger.h Tue Feb 28 13:10:16 2006 -0700 4.3 @@ -40,6 +40,8 @@ 4.4 4.5 #include <xen/gdbstub.h> 4.6 4.7 +void show_registers(struct cpu_user_regs *regs); 4.8 + 4.9 // NOTE: on xen struct pt_regs = struct cpu_user_regs 4.10 // see include/asm-ia64/linux-xen/asm/ptrace.h 4.11 #ifdef CRASH_DEBUG
5.1 --- a/xen/include/asm-ia64/linux-xen/asm/tlbflush.h Tue Feb 28 12:43:08 2006 -0700 5.2 +++ b/xen/include/asm-ia64/linux-xen/asm/tlbflush.h Tue Feb 28 13:10:16 2006 -0700 5.3 @@ -103,6 +103,10 @@ flush_tlb_pgtables (struct mm_struct *mm 5.4 */ 5.5 } 5.6 5.7 + 5.8 #define flush_tlb_kernel_range(start, end) flush_tlb_all() /* XXX fix me */ 5.9 +#ifdef XEN 5.10 +extern void flush_tlb_mask(cpumask_t mask); 5.11 +#endif 5.12 5.13 #endif /* _ASM_IA64_TLBFLUSH_H */
6.1 --- a/xen/include/asm-ia64/privop.h Tue Feb 28 12:43:08 2006 -0700 6.2 +++ b/xen/include/asm-ia64/privop.h Tue Feb 28 13:10:16 2006 -0700 6.3 @@ -209,4 +209,6 @@ typedef union U_INST64 { 6.4 6.5 extern void privify_memory(void *start, UINT64 len); 6.6 6.7 +extern int ia64_hyperprivop(unsigned long iim, REGS *regs); 6.8 + 6.9 #endif
7.1 --- a/xen/include/asm-ia64/xensystem.h Tue Feb 28 12:43:08 2006 -0700 7.2 +++ b/xen/include/asm-ia64/xensystem.h Tue Feb 28 13:10:16 2006 -0700 7.3 @@ -78,7 +78,6 @@ extern struct task_struct *vmx_ia64_swit 7.4 #define __cmpxchg_user(ptr, new, old, _size) \ 7.5 ({ \ 7.6 register long __gu_r8 asm ("r8"); \ 7.7 - register long __gu_r9 asm ("r9"); \ 7.8 asm volatile ("mov ar.ccv=%0;;" :: "rO"(old)); \ 7.9 asm volatile ("mov %1=r0;;\n" \ 7.10 "[1:]\tcmpxchg"_size".acq %0=[%2],%3,ar.ccv\n" \