diff options
author | Thomas Bushnell <thomas@gnu.org> | 1999-07-11 23:36:31 +0000 |
---|---|---|
committer | Thomas Bushnell <thomas@gnu.org> | 1999-07-11 23:36:31 +0000 |
commit | 74ccbe61fd6af5e2eb4fcdebefde6d86f005c05d (patch) | |
tree | fea52296fc5e05ee6fe89e58b4db752fd907352d /i386 | |
parent | 853b3e303c66c85d26b256f7cdb0e17113dda847 (diff) |
1999-07-11 Thomas Bushnell, BSG <tb@mit.edu>
* i386/i386at/model_dep.c (init_alloc_aligned): Make the checks
correctly for addresses falling into skip regions. Reported by
Momchil Velikov (velco@fadata.bg).
Diffstat (limited to 'i386')
-rw-r--r-- | i386/i386at/model_dep.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/i386/i386at/model_dep.c b/i386/i386at/model_dep.c index 9caca30..57260fa 100644 --- a/i386/i386at/model_dep.c +++ b/i386/i386at/model_dep.c @@ -479,7 +479,7 @@ init_alloc_aligned(vm_size_t size, vm_offset_t *addrp) avail_next += size; /* Skip past the I/O and ROM area. */ - if ((avail_next > (boot_info->mem_lower * 0x400)) && (addr < 0x100000)) + if ((avail_next >= (boot_info->mem_lower * 0x400)) && (addr < 0x100000)) { avail_next = 0x100000; goto retry; @@ -498,22 +498,22 @@ init_alloc_aligned(vm_size_t size, vm_offset_t *addrp) } /* Skip any areas occupied by valuable boot_info data. */ - if ((avail_next > boot_info_start_pa) && (addr < boot_info_end_pa)) + if ((avail_next >= boot_info_start_pa) && (addr < boot_info_end_pa)) { avail_next = boot_info_end_pa; goto retry; } - if ((avail_next > cmdline_start_pa) && (addr < cmdline_end_pa)) + if ((avail_next >= cmdline_start_pa) && (addr < cmdline_end_pa)) { avail_next = cmdline_end_pa; goto retry; } - if ((avail_next > mods_start_pa) && (addr < mods_end_pa)) + if ((avail_next >= mods_start_pa) && (addr < mods_end_pa)) { avail_next = mods_end_pa; goto retry; } - if ((avail_next > kern_sym_start) && (addr < kern_sym_end)) + if ((avail_next >= kern_sym_start) && (addr < kern_sym_end)) { avail_next = kern_sym_end; goto retry; @@ -524,7 +524,7 @@ init_alloc_aligned(vm_size_t size, vm_offset_t *addrp) phystokv(boot_info->mods_addr); for (i = 0; i < boot_info->mods_count; i++) { - if ((avail_next > m[i].mod_start) + if ((avail_next >= m[i].mod_start) && (addr < m[i].mod_end)) { avail_next = m[i].mod_end; |