Eliminate a goto and a label in vm_map_wire_locked by inserting an 'else'.
Reviewed by: alc Approved by: kib, markj (mentors, implicit) Differential Revision: https://reviews.freebsd.org/D20845
This commit is contained in:
parent
dda0c86204
commit
38e220e8df
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=349713
@ -3170,9 +3170,7 @@ vm_map_wire_locked(vm_map_t map, vm_offset_t start, vm_offset_t end, int flags)
|
||||
rv = KERN_INVALID_ADDRESS;
|
||||
goto done;
|
||||
}
|
||||
goto next_entry;
|
||||
}
|
||||
if (entry->wired_count == 0) {
|
||||
} else if (entry->wired_count == 0) {
|
||||
entry->wired_count++;
|
||||
|
||||
npages = atop(entry->end - entry->start);
|
||||
@ -3250,7 +3248,6 @@ vm_map_wire_locked(vm_map_t map, vm_offset_t start, vm_offset_t end, int flags)
|
||||
* Check the map for holes in the specified region.
|
||||
* If VM_MAP_WIRE_HOLESOK was specified, skip this check.
|
||||
*/
|
||||
next_entry:
|
||||
if ((flags & VM_MAP_WIRE_HOLESOK) == 0 &&
|
||||
entry->end < end && entry->next->start > entry->end) {
|
||||
end = entry->end;
|
||||
|
Loading…
Reference in New Issue
Block a user