WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-ia64-devel

[Xen-ia64-devel] pv_ops: ministate.h typo fix

To: <xen-ia64-devel@xxxxxxxxxxxxxxxxxxx>
Subject: [Xen-ia64-devel] pv_ops: ministate.h typo fix
From: "Dong, Eddie" <eddie.dong@xxxxxxxxx>
Date: Fri, 21 Mar 2008 15:17:04 +0800
Delivery-date: Fri, 21 Mar 2008 00:19:48 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-ia64-devel-request@lists.xensource.com?subject=help>
List-id: Discussion of the ia64 port of Xen <xen-ia64-devel.lists.xensource.com>
List-post: <mailto:xen-ia64-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-ia64-devel>, <mailto:xen-ia64-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-ia64-devel>, <mailto:xen-ia64-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-ia64-devel-bounces@xxxxxxxxxxxxxxxxxxx
Thread-index: AciLI5BKfF3ZGP5gTlW3Ffd0bttK4A==
Thread-topic: pv_ops: ministate.h typo fix
The MACRO parameter COVER in DO_SAVE_MIN won't
be replaced by COVER macro in inst.h since it is already
replaced when compiler extend SAVE_MIN_WITH_COVER
macro etc.
Thanks, eddie




    Fix DO_SAVE_MIN macro typo, and move some
    instructions to make bundle compact.
    
    Signed-off-by: Yaozu (Eddie) Dong <eddie.dong@xxxxxxxxx>

diff --git a/arch/ia64/kernel/ivt.S b/arch/ia64/kernel/ivt.S
index d1cebe5..f2306ae 100644
--- a/arch/ia64/kernel/ivt.S
+++ b/arch/ia64/kernel/ivt.S
@@ -75,7 +75,6 @@
 # define DBG_FAULT(i)
 #endif
 
-#include "inst_paravirt.h"
 #include "minstate.h"
 
 #define FAULT(n)
\
diff --git a/arch/ia64/kernel/minstate.h b/arch/ia64/kernel/minstate.h
index 10a412c..9e18fb0 100644
--- a/arch/ia64/kernel/minstate.h
+++ b/arch/ia64/kernel/minstate.h
@@ -2,6 +2,7 @@
 #include <asm/cache.h>
 
 #include "entry.h"
+#include "inst_paravirt.h"
 
 #ifdef __IA64_ASM_PARAVIRTUALIZED_NATIVE
 /*
@@ -29,7 +30,7 @@
  * Note that psr.ic is NOT turned on by this macro.  This is so that
  * we can pass interruption state as arguments to a handler.
  */
-#define DO_SAVE_MIN(__COVER,SAVE_IFS,EXTRA)
\
+#define DO_SAVE_MIN(COVER,SAVE_IFS,EXTRA)
\
        mov r16=IA64_KR(CURRENT);       /* M */
\
        mov r27=ar.rsc;                 /* M */
\
        mov r20=r1;                     /* A */
\
@@ -38,7 +39,7 @@
        mov r26=ar.pfs;                 /* I */
\
        MOV_FROM_IIP(r28);              /* M */
\
        mov r21=ar.fpsr;                /* M */
\
-       __COVER;                        /* B;; (or nothing) */
\
+       COVER;                          /* B;; (or nothing) */
\
        ;;
\
        adds r16=IA64_TASK_THREAD_ON_USTACK_OFFSET,r16;
\
        ;;
\
@@ -194,6 +195,6 @@
        st8 [r25]=r10;          /* ar.ssd */    \
        ;;
 
-#define SAVE_MIN_WITH_COVER    DO_SAVE_MIN(cover, mov r30=cr.ifs,)
-#define SAVE_MIN_WITH_COVER_R19        DO_SAVE_MIN(cover, mov
r30=cr.ifs, mov r15=r19)
+#define SAVE_MIN_WITH_COVER    DO_SAVE_MIN(COVER, mov r30=cr.ifs,)
+#define SAVE_MIN_WITH_COVER_R19        DO_SAVE_MIN(COVER, mov
r30=cr.ifs, mov r15=r19)
 #define SAVE_MIN               DO_SAVE_MIN(     , mov r30=r0, )
diff --git a/arch/ia64/xen/xenivt.S b/arch/ia64/xen/xenivt.S
index 2d509f2..17987af 100644
--- a/arch/ia64/xen/xenivt.S
+++ b/arch/ia64/xen/xenivt.S
@@ -13,9 +13,8 @@
 #include <asm/kregs.h>
 #include <asm/pgtable.h>
 
-#include <asm/xen/inst.h>
-#include <asm/xen/minstate.h>
 #include "../kernel/minstate.h"
+#include <asm/xen/minstate.h>
 
        .section .text,"ax"
 GLOBAL_ENTRY(xen_event_callback)
diff --git a/include/asm-ia64/xen/inst.h b/include/asm-ia64/xen/inst.h
index a8fb2ac..1e92d02 100644
--- a/include/asm-ia64/xen/inst.h
+++ b/include/asm-ia64/xen/inst.h
@@ -414,10 +414,10 @@
        movl r30 = XSI_B1NAT;           \
        ;;                              \
        ld8 r30 = [r30];                \
+       mov r31 = 1;                    \
        ;;                              \
        mov ar.unat = r30;              \
        movl r30 = XSI_BANKNUM;         \
-       mov r31 = 1;                    \
        ;;                              \
        st4 [r30] = r31;                \
        movl r30 = XSI_BANK1_R16;       \
diff --git a/include/asm-ia64/xen/minstate.h
b/include/asm-ia64/xen/minstate.h
index 67bbf79..7cdebc2 100644
--- a/include/asm-ia64/xen/minstate.h
+++ b/include/asm-ia64/xen/minstate.h
@@ -25,17 +25,16 @@
  * Note that psr.ic is NOT turned on by this macro.  This is so that
  * we can pass interruption state as arguments to a handler.
  */
-#define DO_SAVE_MIN(__COVER,SAVE_IFS,EXTRA)
\
+#define DO_SAVE_MIN(COVER,SAVE_IFS,EXTRA)
\
        mov r16=IA64_KR(CURRENT);       /* M */
\
        mov r27=ar.rsc;                 /* M */
\
        mov r20=r1;                     /* A */
\
        mov r25=ar.unat;                /* M */
\
        MOV_FROM_IPSR(r29);             /* M */
\
-       mov r26=ar.pfs;                 /* I */
\
        MOV_FROM_IIP(r28);              /* M */
\
        mov r21=ar.fpsr;                /* M */
\
-       __COVER;                        /* B;; (or nothing) */
\
-       ;;
\
+       mov r26=ar.pfs;                 /* I */
\
+       COVER;                          /* B;; (or nothing) */
\
        adds r16=IA64_TASK_THREAD_ON_USTACK_OFFSET,r16;
\
        ;;
\
        ld1 r17=[r16];                          /* load
current->thread.on_ustack flag */       \
@@ -80,17 +79,17 @@
 .mem.offset 8,0; st8.spill [r17]=r9,16;
\
         ;;
\
 .mem.offset 0,0; st8.spill [r16]=r10,24;
\
+       movl r8=XSI_PRECOVER_IFS;
\
 .mem.offset 8,0; st8.spill [r17]=r11,24;
\
         ;;
\
        /* xen special handling for possibly lazy cover */
\
        /* XXX: SAVE_MIN case in dispatch_ia32_handler: mov r30=r0 */
\
-       movl r8=XSI_PRECOVER_IFS;
\
        ;;
\
        ld8 r30=[r8];
\
-       ;;
\
+(pUStk)        sub r18=r18,r22;        /* r18=RSE.ndirty*8 */
\
        st8 [r16]=r28,16;       /* save cr.iip */
\
+       ;;      \
        st8 [r17]=r30,16;       /* save cr.ifs */
\
-(pUStk)        sub r18=r18,r22;        /* r18=RSE.ndirty*8 */
\
        mov r8=ar.ccv;
\
        mov r9=ar.csd;
\
        mov r10=ar.ssd;
\
@@ -131,7 +130,5 @@
        adds r2=IA64_PT_REGS_R16_OFFSET,r1;
\
        ;;
\
        movl r1=__gp;           /* establish kernel global pointer */
\
-       ;;
\
-       /*bsw.1;*/              /* switch back to bank 1 (must be last
in insn group) */       \
        ;;
 #endif /* __IA64_ASM_PARAVIRTUALIZED_XEN */

Attachment: minstate_fix2.patch
Description: minstate_fix2.patch

_______________________________________________
Xen-ia64-devel mailing list
Xen-ia64-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-ia64-devel
<Prev in Thread] Current Thread [Next in Thread>