remove a useless call to uvm_map_protect(). the kernel text is already
mapped read-only in pmap_bootstrap() and the comment which tried to explain why this might be needed anyway didn't make any sense.
This commit is contained in:
parent
1cedb649d4
commit
e49a700498
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: machdep.c,v 1.145 2001/04/24 04:31:13 thorpej Exp $ */
|
||||
/* $NetBSD: machdep.c,v 1.146 2001/05/28 21:54:26 chs Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1994, 1995 Gordon W. Ross
|
||||
@ -291,15 +291,6 @@ cpu_startup()
|
||||
format_bytes(pbuf, sizeof(pbuf), bufpages * NBPG);
|
||||
printf("using %d buffers containing %s of memory\n", nbuf, pbuf);
|
||||
|
||||
/*
|
||||
* Tell the VM system that writing to kernel text isn't allowed.
|
||||
* If we don't, we might end up COW'ing the text segment!
|
||||
*/
|
||||
if (uvm_map_protect(kernel_map, (vm_offset_t) kernel_text,
|
||||
m68k_trunc_page((vm_offset_t) etext),
|
||||
UVM_PROT_READ|UVM_PROT_EXEC, TRUE) != 0)
|
||||
panic("can't protect kernel text");
|
||||
|
||||
/*
|
||||
* Allocate a virtual page (for use by /dev/mem)
|
||||
* This page is handed to pmap_enter() therefore
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: machdep.c,v 1.66 2001/05/28 20:56:54 chs Exp $ */
|
||||
/* $NetBSD: machdep.c,v 1.67 2001/05/28 21:54:27 chs Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1988 University of Utah.
|
||||
@ -293,15 +293,6 @@ cpu_startup()
|
||||
format_bytes(pbuf, sizeof(pbuf), bufpages * NBPG);
|
||||
printf("using %d buffers containing %s of memory\n", nbuf, pbuf);
|
||||
|
||||
/*
|
||||
* Tell the VM system that writing to kernel text isn't allowed.
|
||||
* If we don't, we might end up COW'ing the text segment!
|
||||
*/
|
||||
if (uvm_map_protect(kernel_map, (vm_offset_t) kernel_text,
|
||||
m68k_trunc_page((vm_offset_t) etext),
|
||||
UVM_PROT_READ|UVM_PROT_EXEC, TRUE) != 0)
|
||||
panic("can't protect kernel text");
|
||||
|
||||
/*
|
||||
* Allocate a virtual page (for use by /dev/mem)
|
||||
* This page is handed to pmap_enter() therefore
|
||||
|
Loading…
Reference in New Issue
Block a user