Current-Users archive

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

Build fix for sh3 - only built tested



Hi, the following seems to fix the build of
sh3 and doesn't seem to invasive.

feel free to use it, or any other solution.

I have no sh3 hardware to test it.
Index: sh3/pmap.c
===================================================================
RCS file: /cvsroot/src/sys/arch/sh3/sh3/pmap.c,v
retrieving revision 1.79
diff -u -p -u -r1.79 pmap.c
--- sh3/pmap.c	23 Dec 2016 07:15:28 -0000	1.79
+++ sh3/pmap.c	23 Dec 2016 18:20:43 -0000
@@ -128,7 +128,7 @@ vaddr_t
 pmap_steal_memory(vsize_t size, vaddr_t *vstart, vaddr_t *vend)
 {
 	int npage;
-	paddr_t pa;
+	paddr_t start;
 	vaddr_t va;
 	uvm_physseg_t bank;
 
@@ -147,9 +147,9 @@ pmap_steal_memory(vsize_t size, vaddr_t 
 	KDASSERT(uvm_physseg_valid_p(bank));
 
 	/* Steal pages */
-	pa = ptoa(uvm_physseg_get_start(bank));
+	start = uvm_physseg_get_start(bank);
 	uvm_physseg_unplug(start, npage);
-	va = SH3_PHYS_TO_P1SEG(pa);
+	va = SH3_PHYS_TO_P1SEG(ptoa(start));
 	memset((void *)va, 0, size);
 
 	return (va);


Home | Main Index | Thread Index | Old Index