ia64/xen-unstable

changeset 16469:4ac315e33f88

[IA64] Extract debug_op.h from arch-ia64.h

Signed-off-by: Tristan Gingold <tgingold@free.fr>
author Alex Williamson <alex.williamson@hp.com>
date Mon Nov 26 10:03:53 2007 -0700 (2007-11-26)
parents 9f61a0add5b6
children 98defc4f3bf9
files xen/arch/ia64/vmx/vmx_vcpu.c xen/arch/ia64/xen/hypercall.c xen/include/asm-ia64/debugger.h xen/include/public/arch-ia64.h xen/include/public/arch-ia64/debug_op.h
line diff
     1.1 --- a/xen/arch/ia64/vmx/vmx_vcpu.c	Mon Nov 26 15:32:54 2007 +0000
     1.2 +++ b/xen/arch/ia64/vmx/vmx_vcpu.c	Mon Nov 26 10:03:53 2007 -0700
     1.3 @@ -35,6 +35,7 @@
     1.4  #include <asm/vmx_mm_def.h>
     1.5  #include <asm/vmx.h>
     1.6  #include <asm/vmx_phy_mode.h>
     1.7 +#include <asm/debugger.h>
     1.8  
     1.9  /**************************************************************************
    1.10   VCPU general register access routines
     2.1 --- a/xen/arch/ia64/xen/hypercall.c	Mon Nov 26 15:32:54 2007 +0000
     2.2 +++ b/xen/arch/ia64/xen/hypercall.c	Mon Nov 26 10:03:53 2007 -0700
     2.3 @@ -32,6 +32,7 @@
     2.4  #include <public/callback.h>
     2.5  #include <xen/event.h>
     2.6  #include <xen/perfc.h>
     2.7 +#include <public/arch-ia64/debug_op.h>
     2.8  
     2.9  extern long do_physdev_op(int cmd, XEN_GUEST_HANDLE(void) arg);
    2.10  extern long do_callback_op(int cmd, XEN_GUEST_HANDLE(void) arg);
     3.1 --- a/xen/include/asm-ia64/debugger.h	Mon Nov 26 15:32:54 2007 +0000
     3.2 +++ b/xen/include/asm-ia64/debugger.h	Mon Nov 26 10:03:53 2007 -0700
     3.3 @@ -40,6 +40,7 @@
     3.4  #include <xen/sched.h>
     3.5  #include <xen/softirq.h>
     3.6  #include <xen/gdbstub.h>
     3.7 +#include <public/arch-ia64/debug_op.h>
     3.8  
     3.9  void show_registers(struct cpu_user_regs *regs);
    3.10  void dump_stack(void);
     4.1 --- a/xen/include/public/arch-ia64.h	Mon Nov 26 15:32:54 2007 +0000
     4.2 +++ b/xen/include/public/arch-ia64.h	Mon Nov 26 10:03:53 2007 -0700
     4.3 @@ -579,79 +579,6 @@ struct xen_ia64_boot_param {
     4.4  /* Extra debug features.  */
     4.5  #define __HYPERVISOR_ia64_debug_op  __HYPERVISOR_arch_2
     4.6  
     4.7 -/* Set/Get extra conditions to break.  */
     4.8 -#define XEN_IA64_DEBUG_OP_SET_FLAGS 1
     4.9 -#define XEN_IA64_DEBUG_OP_GET_FLAGS 2
    4.10 -
    4.11 -/* Break on kernel single step.  */
    4.12 -#define XEN_IA64_DEBUG_ON_KERN_SSTEP   (1 << 0)
    4.13 -
    4.14 -/* Break on kernel debug (breakpoint or watch point).  */
    4.15 -#define XEN_IA64_DEBUG_ON_KERN_DEBUG   (1 << 1)
    4.16 -
    4.17 -/* Break on kernel taken branch.  */
    4.18 -#define XEN_IA64_DEBUG_ON_KERN_TBRANCH (1 << 2)
    4.19 -
    4.20 -/* Break on interrupt injection.  */
    4.21 -#define XEN_IA64_DEBUG_ON_EXTINT       (1 << 3)
    4.22 -
    4.23 -/* Break on interrupt injection.  */
    4.24 -#define XEN_IA64_DEBUG_ON_EXCEPT       (1 << 4)
    4.25 -
    4.26 -/* Break on event injection.  */
    4.27 -#define XEN_IA64_DEBUG_ON_EVENT        (1 << 5)
    4.28 -
    4.29 -/* Break on privop/virtualized instruction (slow path only).  */
    4.30 -#define XEN_IA64_DEBUG_ON_PRIVOP       (1 << 6)
    4.31 -
    4.32 -/* Break on emulated PAL call (at entry).  */
    4.33 -#define XEN_IA64_DEBUG_ON_PAL          (1 << 7)
    4.34 -
    4.35 -/* Break on emulated SAL call (at entry).  */
    4.36 -#define XEN_IA64_DEBUG_ON_SAL          (1 << 8)
    4.37 -
    4.38 -/* Break on emulated EFI call (at entry).  */
    4.39 -#define XEN_IA64_DEBUG_ON_EFI          (1 << 9)
    4.40 -
    4.41 -/* Break on rfi emulation (slow path only, before exec).  */
    4.42 -#define XEN_IA64_DEBUG_ON_RFI          (1 << 10)
    4.43 -
    4.44 -/* Break on address translation switch.  */
    4.45 -#define XEN_IA64_DEBUG_ON_MMU          (1 << 11)
    4.46 -
    4.47 -/* Break on bad guest physical address.  */
    4.48 -#define XEN_IA64_DEBUG_ON_BAD_MPA      (1 << 12)
    4.49 -
    4.50 -/* Force psr.ss bit.  */
    4.51 -#define XEN_IA64_DEBUG_FORCE_SS        (1 << 13)
    4.52 -
    4.53 -/* Force psr.db bit.  */
    4.54 -#define XEN_IA64_DEBUG_FORCE_DB        (1 << 14)
    4.55 -
    4.56 -/* Break on ITR/PTR.  */
    4.57 -#define XEN_IA64_DEBUG_ON_TR           (1 << 15)
    4.58 -
    4.59 -/* Break on ITC/PTC.L/PTC.G/PTC.GA.  */
    4.60 -#define XEN_IA64_DEBUG_ON_TC           (1 << 16)
    4.61 -
    4.62 -/* Get translation cache.  */
    4.63 -#define XEN_IA64_DEBUG_OP_GET_TC   3
    4.64 -
    4.65 -/* Translate virtual address to guest physical address.  */
    4.66 -#define XEN_IA64_DEBUG_OP_TRANSLATE 4
    4.67 -
    4.68 -#ifndef __ASSEMBLY__
    4.69 -union xen_ia64_debug_op {
    4.70 -    uint64_t flags;
    4.71 -    struct xen_ia64_debug_vtlb {
    4.72 -        uint64_t nbr;                             /* IN/OUT */
    4.73 -        XEN_GUEST_HANDLE_64(ia64_tr_entry_t) tr;  /* IN/OUT */
    4.74 -    } vtlb;
    4.75 -};
    4.76 -typedef union xen_ia64_debug_op xen_ia64_debug_op_t;
    4.77 -DEFINE_XEN_GUEST_HANDLE(xen_ia64_debug_op_t);
    4.78 -#endif /* __ASSEMBLY__ */
    4.79 -
    4.80  /* Xencomm macros.  */
    4.81  #define XENCOMM_INLINE_MASK 0xf800000000000000UL
    4.82  #define XENCOMM_INLINE_FLAG 0x8000000000000000UL
     5.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     5.2 +++ b/xen/include/public/arch-ia64/debug_op.h	Mon Nov 26 10:03:53 2007 -0700
     5.3 @@ -0,0 +1,96 @@
     5.4 +/******************************************************************************
     5.5 + * debug_op.h
     5.6 + *
     5.7 + * Copyright (c) 2007 Tristan Gingold <tgingold@free.fr>
     5.8 + *
     5.9 + * This program is free software; you can redistribute it and/or modify
    5.10 + * it under the terms of the GNU General Public License as published by
    5.11 + * the Free Software Foundation; either version 2 of the License, or
    5.12 + * (at your option) any later version.
    5.13 + *
    5.14 + * This program is distributed in the hope that it will be useful,
    5.15 + * but WITHOUT ANY WARRANTY; without even the implied warranty of
    5.16 + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    5.17 + * GNU General Public License for more details.
    5.18 + *
    5.19 + * You should have received a copy of the GNU General Public License
    5.20 + * along with this program; if not, write to the Free Software
    5.21 + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
    5.22 + *
    5.23 + */
    5.24 +
    5.25 +#ifndef __XEN_PUBLIC_IA64_DEBUG_OP_H__
    5.26 +#define __XEN_PUBLIC_IA64_DEBUG_OP_H__
    5.27 +
    5.28 +/* Set/Get extra conditions to break.  */
    5.29 +#define XEN_IA64_DEBUG_OP_SET_FLAGS 1
    5.30 +#define XEN_IA64_DEBUG_OP_GET_FLAGS 2
    5.31 +
    5.32 +/* Break on kernel single step.  */
    5.33 +#define XEN_IA64_DEBUG_ON_KERN_SSTEP   (1 << 0)
    5.34 +
    5.35 +/* Break on kernel debug (breakpoint or watch point).  */
    5.36 +#define XEN_IA64_DEBUG_ON_KERN_DEBUG   (1 << 1)
    5.37 +
    5.38 +/* Break on kernel taken branch.  */
    5.39 +#define XEN_IA64_DEBUG_ON_KERN_TBRANCH (1 << 2)
    5.40 +
    5.41 +/* Break on interrupt injection.  */
    5.42 +#define XEN_IA64_DEBUG_ON_EXTINT       (1 << 3)
    5.43 +
    5.44 +/* Break on interrupt injection.  */
    5.45 +#define XEN_IA64_DEBUG_ON_EXCEPT       (1 << 4)
    5.46 +
    5.47 +/* Break on event injection.  */
    5.48 +#define XEN_IA64_DEBUG_ON_EVENT        (1 << 5)
    5.49 +
    5.50 +/* Break on privop/virtualized instruction (slow path only).  */
    5.51 +#define XEN_IA64_DEBUG_ON_PRIVOP       (1 << 6)
    5.52 +
    5.53 +/* Break on emulated PAL call (at entry).  */
    5.54 +#define XEN_IA64_DEBUG_ON_PAL          (1 << 7)
    5.55 +
    5.56 +/* Break on emulated SAL call (at entry).  */
    5.57 +#define XEN_IA64_DEBUG_ON_SAL          (1 << 8)
    5.58 +
    5.59 +/* Break on emulated EFI call (at entry).  */
    5.60 +#define XEN_IA64_DEBUG_ON_EFI          (1 << 9)
    5.61 +
    5.62 +/* Break on rfi emulation (slow path only, before exec).  */
    5.63 +#define XEN_IA64_DEBUG_ON_RFI          (1 << 10)
    5.64 +
    5.65 +/* Break on address translation switch.  */
    5.66 +#define XEN_IA64_DEBUG_ON_MMU          (1 << 11)
    5.67 +
    5.68 +/* Break on bad guest physical address.  */
    5.69 +#define XEN_IA64_DEBUG_ON_BAD_MPA      (1 << 12)
    5.70 +
    5.71 +/* Force psr.ss bit.  */
    5.72 +#define XEN_IA64_DEBUG_FORCE_SS        (1 << 13)
    5.73 +
    5.74 +/* Force psr.db bit.  */
    5.75 +#define XEN_IA64_DEBUG_FORCE_DB        (1 << 14)
    5.76 +
    5.77 +/* Break on ITR/PTR.  */
    5.78 +#define XEN_IA64_DEBUG_ON_TR           (1 << 15)
    5.79 +
    5.80 +/* Break on ITC/PTC.L/PTC.G/PTC.GA.  */
    5.81 +#define XEN_IA64_DEBUG_ON_TC           (1 << 16)
    5.82 +
    5.83 +/* Get translation cache.  */
    5.84 +#define XEN_IA64_DEBUG_OP_GET_TC   3
    5.85 +
    5.86 +/* Translate virtual address to guest physical address.  */
    5.87 +#define XEN_IA64_DEBUG_OP_TRANSLATE 4
    5.88 +
    5.89 +union xen_ia64_debug_op {
    5.90 +    uint64_t flags;
    5.91 +    struct xen_ia64_debug_vtlb {
    5.92 +        uint64_t nbr;                             /* IN/OUT */
    5.93 +        XEN_GUEST_HANDLE_64(ia64_tr_entry_t) tr;  /* IN/OUT */
    5.94 +    } vtlb;
    5.95 +};
    5.96 +typedef union xen_ia64_debug_op xen_ia64_debug_op_t;
    5.97 +DEFINE_XEN_GUEST_HANDLE(xen_ia64_debug_op_t);
    5.98 +
    5.99 +#endif /* __XEN_PUBLIC_IA64_DEBUG_OP_H__ */