Deleted Added
full compact
vm_map.c (29316) vm_map.c (29653)
1/*
2 * Copyright (c) 1991, 1993
3 * The Regents of the University of California. All rights reserved.
4 *
5 * This code is derived from software contributed to Berkeley by
6 * The Mach Operating System project at Carnegie-Mellon University.
7 *
8 * Redistribution and use in source and binary forms, with or without

--- 47 unchanged lines hidden (view full) ---

56 * Software Distribution Coordinator or Software.Distribution@CS.CMU.EDU
57 * School of Computer Science
58 * Carnegie Mellon University
59 * Pittsburgh PA 15213-3890
60 *
61 * any improvements or extensions that they make and grant Carnegie the
62 * rights to redistribute these changes.
63 *
1/*
2 * Copyright (c) 1991, 1993
3 * The Regents of the University of California. All rights reserved.
4 *
5 * This code is derived from software contributed to Berkeley by
6 * The Mach Operating System project at Carnegie-Mellon University.
7 *
8 * Redistribution and use in source and binary forms, with or without

--- 47 unchanged lines hidden (view full) ---

56 * Software Distribution Coordinator or Software.Distribution@CS.CMU.EDU
57 * School of Computer Science
58 * Carnegie Mellon University
59 * Pittsburgh PA 15213-3890
60 *
61 * any improvements or extensions that they make and grant Carnegie the
62 * rights to redistribute these changes.
63 *
64 * $Id: vm_map.c,v 1.89 1997/09/01 03:17:18 bde Exp $
64 * $Id: vm_map.c,v 1.90 1997/09/12 15:58:47 jlemon Exp $
65 */
66
67/*
68 * Virtual memory mapping module.
69 */
70
71#include <sys/param.h>
72#include <sys/systm.h>

--- 136 unchanged lines hidden (view full) ---

209
210void
211vm_init2(void) {
212 zinitna(kmapentzone, &kmapentobj,
213 NULL, 0, cnt.v_page_count / 4, ZONE_INTERRUPT, 4);
214 zinitna(mapentzone, &mapentobj,
215 NULL, 0, 0, 0, 4);
216 zinitna(mapzone, &mapobj,
65 */
66
67/*
68 * Virtual memory mapping module.
69 */
70
71#include <sys/param.h>
72#include <sys/systm.h>

--- 136 unchanged lines hidden (view full) ---

209
210void
211vm_init2(void) {
212 zinitna(kmapentzone, &kmapentobj,
213 NULL, 0, cnt.v_page_count / 4, ZONE_INTERRUPT, 4);
214 zinitna(mapentzone, &mapentobj,
215 NULL, 0, 0, 0, 4);
216 zinitna(mapzone, &mapobj,
217 NULL, 0, 0, 0, 1);
217 NULL, 0, 0, 0, 2);
218 pmap_init2();
218 pmap_init2();
219 vm_object_init2();
219}
220
221void
222vmspace_free(vm)
223 register struct vmspace *vm;
224{
225
226 if (vm->vm_refcnt == 0)

--- 452 unchanged lines hidden (view full) ---

679 if (end > map->max_offset || end < start)
680 return (1);
681 next = entry->next;
682 if (next == &map->header || next->start >= end)
683 break;
684 }
685 SAVE_HINT(map, entry);
686 *addr = start;
220}
221
222void
223vmspace_free(vm)
224 register struct vmspace *vm;
225{
226
227 if (vm->vm_refcnt == 0)

--- 452 unchanged lines hidden (view full) ---

680 if (end > map->max_offset || end < start)
681 return (1);
682 next = entry->next;
683 if (next == &map->header || next->start >= end)
684 break;
685 }
686 SAVE_HINT(map, entry);
687 *addr = start;
687 if (map == kernel_map && round_page(start + length) > kernel_vm_end)
688 pmap_growkernel(round_page(start + length));
688 if (map == kernel_map) {
689 vm_offset_t ksize;
690 if ((ksize = round_page(start + length)) > kernel_vm_end) {
691 pmap_growkernel(ksize);
692 }
693 }
689 return (0);
690}
691
692/*
693 * vm_map_find finds an unallocated region in the target address
694 * map with the given length. The search is defined to be
695 * first-fit from the specified address; the region found is
696 * returned in the same parameter.

--- 1826 unchanged lines hidden ---
694 return (0);
695}
696
697/*
698 * vm_map_find finds an unallocated region in the target address
699 * map with the given length. The search is defined to be
700 * first-fit from the specified address; the region found is
701 * returned in the same parameter.

--- 1826 unchanged lines hidden ---