alc wrote: Suppose that the object is OBJ_ONEMAPPING and that we, in fact, have a single mapping to it. Then, we punch a hole in that mapping. vm_map_entry_delete() only subtracts from the object's charge when we shrink the size of the object. Now, suppose that we perform mmap(MAP_ANON) to reallocate some of the hole. Aren't we going to add to the charge here, even though vm_map_entry_delete() never subtracted from the charge for the hole that was created? Only account the change in the charged object size that was added to it. Also remove ifdef-ed block that tried to correct charge and that is not needed. vm_object_coalesce(): simplify common expression Add next_end variable to replace commonly occuring next_pindex + next_size expression.
Details
Details
Diff Detail
Diff Detail
- Repository
- rG FreeBSD src repository
- Lint
Lint Skipped - Unit
Tests Skipped
Event Timeline
Comment Actions
P.S. The semester is winding down, so I have more spare time for reviews now.
| sys/vm/vm_object.c | ||
|---|---|---|
| 2204 | I observe that this change introduces even more repetitions of next_pindex + next_size. Should we introduce a next_end? | |