PERFORCE change 38829 for review

Peter Wemm peter at FreeBSD.org
Mon Sep 29 18:44:54 PDT 2003


http://perforce.freebsd.org/chv.cgi?CH=38829

Change 38829 by peter at peter_hammer on 2003/09/29 18:44:20

	oh the horror that this file is!  I don't know where to start.

Affected files ...

.. //depot/projects/hammer/sys/amd64/amd64/mp_machdep.c#7 edit

Differences ...

==== //depot/projects/hammer/sys/amd64/amd64/mp_machdep.c#7 (text+ko) ====

@@ -251,10 +251,10 @@
 	setidt(IPI_INVLRNG, IDTVEC(invlrng), SDT_SYSIGT, SEL_KPL, 0);
 
 	/* Install an inter-CPU IPI for forwarding hardclock() */
-	setidt(IPI_HARDCLOCK, IDTVEC(hardclock), SDT_SYSIGT, 0);
+	setidt(IPI_HARDCLOCK, IDTVEC(hardclock), SDT_SYSIGT, SEL_KPL, 0);
 	
 	/* Install an inter-CPU IPI for forwarding statclock() */
-	setidt(IPI_STATCLOCK, IDTVEC(statclock), SDT_SYSIGT, 0);
+	setidt(IPI_STATCLOCK, IDTVEC(statclock), SDT_SYSIGT, SEL_KPL, 0);
 	
 	/* Install an inter-CPU IPI for lazy pmap release */
 	setidt(IPI_LAZYPMAP, IDTVEC(lazypmap), SDT_SYSIGT, SEL_KPL, 0);
@@ -322,9 +322,9 @@
 	int	x, myid = bootAP;
 	u_int	cr0;
 
-	gdt_segs[GPRIV_SEL].ssd_base = (int) &SMP_prvspace[myid];
+	gdt_segs[GPRIV_SEL].ssd_base = (long) &SMP_prvspace[myid];
 	gdt_segs[GPROC0_SEL].ssd_base =
-		(int) &SMP_prvspace[myid].pcpu.pc_common_tss;
+		(long) &SMP_prvspace[myid].pcpu.pc_common_tss;
 	SMP_prvspace[myid].pcpu.pc_prvspace =
 		&SMP_prvspace[myid].pcpu;
 
@@ -333,7 +333,7 @@
 	}
 
 	r_gdt.rd_limit = NGDT * sizeof(gdt[0]) - 1;
-	r_gdt.rd_base = (int) &gdt[myid * NGDT];
+	r_gdt.rd_base = (long) &gdt[myid * NGDT];
 	lgdt(&r_gdt);			/* does magic intra-segment return */
 
 	lidt(&r_idt);
@@ -434,7 +434,7 @@
 		cpu++;
 
 		/* first page of AP's private space */
-		pg = cpu * i386_btop(sizeof(struct privatespace));
+		pg = cpu * amd64_btop(sizeof(struct privatespace));
 
 		/* allocate a new private data page */
 		pc = (struct pcpu *)kmem_alloc(kernel_map, PAGE_SIZE);


More information about the p4-projects mailing list