Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/sparc64/sparc64 More cast / format cleanup to make ...



details:   https://anonhg.NetBSD.org/src/rev/d1b18234c8ae
branches:  trunk
changeset: 500079:d1b18234c8ae
user:      fvdl <fvdl%NetBSD.org@localhost>
date:      Mon Dec 04 20:40:07 2000 +0000

description:
More cast / format cleanup to make this compile cleanly in 32bit mode.

diffstat:

 sys/arch/sparc64/sparc64/cache.c        |   4 +-
 sys/arch/sparc64/sparc64/db_interface.c |  42 ++++++++++++++++----------------
 sys/arch/sparc64/sparc64/intr.c         |   7 +++--
 3 files changed, 27 insertions(+), 26 deletions(-)

diffs (95 lines):

diff -r 752d18293f22 -r d1b18234c8ae sys/arch/sparc64/sparc64/cache.c
--- a/sys/arch/sparc64/sparc64/cache.c  Mon Dec 04 20:33:12 2000 +0000
+++ b/sys/arch/sparc64/sparc64/cache.c  Mon Dec 04 20:40:07 2000 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: cache.c,v 1.3 2000/08/01 00:28:03 eeh Exp $ */
+/*     $NetBSD: cache.c,v 1.4 2000/12/04 20:40:07 fvdl Exp $ */
 
 /*
  * Copyright (c) 1996
@@ -115,7 +115,7 @@
        ls = cacheinfo.c_linesize;
        i = NBPG >> cacheinfo.dc_l2linesize;
        /* Assume E$ takes care of itself*/
-       kp = (int *)((pa & (cacheinfo.ec_totalsize - 1)) + KERNBASE);
+       kp = (int *)(u_long)((pa & (cacheinfo.ec_totalsize - 1)) + KERNBASE);
        j = 0; /* defeat optimizer? */
        for (; --i >= 0; p += ls) {
                flush(p);       /* Take care of I$. */
diff -r 752d18293f22 -r d1b18234c8ae sys/arch/sparc64/sparc64/db_interface.c
--- a/sys/arch/sparc64/sparc64/db_interface.c   Mon Dec 04 20:33:12 2000 +0000
+++ b/sys/arch/sparc64/sparc64/db_interface.c   Mon Dec 04 20:40:07 2000 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: db_interface.c,v 1.47 2000/12/04 16:01:19 fvdl Exp $ */
+/*     $NetBSD: db_interface.c,v 1.48 2000/12/04 20:40:07 fvdl Exp $ */
 
 /*
  * Mach Operating System
@@ -657,26 +657,26 @@
        for (i=0; i<pcb->pcb_nsaved; i++) {
                db_printf("win %d: at %llx local, in\n", i, 
                          (unsigned long long)pcb->pcb_rw[i+1].rw_in[6]);
-               db_printf("%16lx %16lx %16lx %16lx\n",
-                         pcb->pcb_rw[i].rw_local[0],
-                         pcb->pcb_rw[i].rw_local[1],
-                         pcb->pcb_rw[i].rw_local[2],
-                         pcb->pcb_rw[i].rw_local[3]);
-               db_printf("%16lx %16lx %16lx %16lx\n",
-                         pcb->pcb_rw[i].rw_local[4],
-                         pcb->pcb_rw[i].rw_local[5],
-                         pcb->pcb_rw[i].rw_local[6],
-                         pcb->pcb_rw[i].rw_local[7]);
-               db_printf("%16lx %16lx %16lx %16lx\n",
-                         pcb->pcb_rw[i].rw_in[0],
-                         pcb->pcb_rw[i].rw_in[1],
-                         pcb->pcb_rw[i].rw_in[2],
-                         pcb->pcb_rw[i].rw_in[3]);
-               db_printf("%16lx %16lx %16lx %16lx\n",
-                         pcb->pcb_rw[i].rw_in[4],
-                         pcb->pcb_rw[i].rw_in[5],
-                         pcb->pcb_rw[i].rw_in[6],
-                         pcb->pcb_rw[i].rw_in[7]);
+               db_printf("%16llx %16llx %16llx %16llx\n",
+                         (unsigned long long)pcb->pcb_rw[i].rw_local[0],
+                         (unsigned long long)pcb->pcb_rw[i].rw_local[1],
+                         (unsigned long long)pcb->pcb_rw[i].rw_local[2],
+                         (unsigned long long)pcb->pcb_rw[i].rw_local[3]);
+               db_printf("%16llx %16llx %16llx %16llx\n",
+                         (unsigned long long)pcb->pcb_rw[i].rw_local[4],
+                         (unsigned long long)pcb->pcb_rw[i].rw_local[5],
+                         (unsigned long long)pcb->pcb_rw[i].rw_local[6],
+                         (unsigned long long)pcb->pcb_rw[i].rw_local[7]);
+               db_printf("%16llx %16llx %16llx %16llx\n",
+                         (unsigned long long)pcb->pcb_rw[i].rw_in[0],
+                         (unsigned long long)pcb->pcb_rw[i].rw_in[1],
+                         (unsigned long long)pcb->pcb_rw[i].rw_in[2],
+                         (unsigned long long)pcb->pcb_rw[i].rw_in[3]);
+               db_printf("%16llx %16llx %16llx %16llx\n",
+                         (unsigned long long)pcb->pcb_rw[i].rw_in[4],
+                         (unsigned long long)pcb->pcb_rw[i].rw_in[5],
+                         (unsigned long long)pcb->pcb_rw[i].rw_in[6],
+                         (unsigned long long)pcb->pcb_rw[i].rw_in[7]);
        }
 }
 
diff -r 752d18293f22 -r d1b18234c8ae sys/arch/sparc64/sparc64/intr.c
--- a/sys/arch/sparc64/sparc64/intr.c   Mon Dec 04 20:33:12 2000 +0000
+++ b/sys/arch/sparc64/sparc64/intr.c   Mon Dec 04 20:40:07 2000 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: intr.c,v 1.36 2000/12/04 16:01:19 fvdl Exp $ */
+/*     $NetBSD: intr.c,v 1.37 2000/12/04 20:40:07 fvdl Exp $ */
 
 /*
  * Copyright (c) 1992, 1993
@@ -103,8 +103,9 @@
        /* If we're in polled mode ignore spurious interrupts */
        if ((fp->tf_pil == PIL_SER) /* && swallow_zsintrs */) return;
 
-       printf("stray interrupt ipl %u pc=%lx npc=%lx pstate=%s vecttored=%d\n",
-           fp->tf_pil, fp->tf_pc, fp->tf_npc, 
+       printf("stray interrupt ipl %u pc=%llx npc=%llx pstate=%s vecttored=%d\n",
+           fp->tf_pil, (unsigned long long)fp->tf_pc,
+           (unsigned long long)fp->tf_npc, 
            bitmask_snprintf((fp->tf_tstate>>TSTATE_PSTATE_SHIFT),
              PSTATE_BITS, buf, sizeof(buf)), vectored);
 



Home | Main Index | Thread Index | Old Index