Author: dougm
Date: Sat Jul 25 18:29:10 2020
New Revision: 363532
URL: https://svnweb.freebsd.org/changeset/base/363532
Log:
Fix an overflow bug in the blist allocator that needlessly capped max
swap size by dividing a value, which was always a multiple of 64, by
64. Remove the code that re
Author: dougm
Date: Thu Jul 23 17:16:20 2020
New Revision: 363450
URL: https://svnweb.freebsd.org/changeset/base/363450
Log:
Rank balanced (RB) trees are a class of balanced trees that includes
AVL trees, red-black trees, and others. Weak AVL (wavl) trees are a
recently discovered member of
Author: dougm
Date: Thu Jun 25 17:44:14 2020
New Revision: 362617
URL: https://svnweb.freebsd.org/changeset/base/362617
Log:
Eliminate the color field from the RB element struct. Identify the
color of a node (or, really, the color of the link from the parent to
the node) by using one of the
Author: dougm
Date: Tue Jun 23 22:47:54 2020
New Revision: 362562
URL: https://svnweb.freebsd.org/changeset/base/362562
Log:
In r362552, RB_SET_PARENT is defined, and use in parens in
RB_CLEAR_NODE. But it is not an expression, and ought not to be
enclosed in parens. Remove them.
Appr
Author: dougm
Date: Tue Jun 23 20:02:55 2020
New Revision: 362552
URL: https://svnweb.freebsd.org/changeset/base/362552
Log:
Define RB_SET_PARENT to do all assignments to rb parent
pointers. Define RB_SWAP_CHILD to replace the child of a parent with
its twin, and use it in 4 places. Use RB_S
Author: dougm
Date: Sat Jun 20 20:25:39 2020
New Revision: 362450
URL: https://svnweb.freebsd.org/changeset/base/362450
Log:
In concluding RB_REMOVE_COLOR, in the case when the sibling of the
root of the too-short tree is black and at least one of the children
of that sibling is red, either
Author: dougm
Date: Sat Jun 13 01:54:09 2020
New Revision: 362139
URL: https://svnweb.freebsd.org/changeset/base/362139
Log:
Linuxkpi uses the rb-tree structures without using their interfaces,
making them break when the representation changes. Revert changes that
eliminated the color field
can. Thanks for your inquiry.
Doug Moore
On 2020-06-12 12:53, Hans Petter Selasky wrote:
> On 2020-06-12 19:51, Hans Petter Selasky wrote:
>> On 2020-06-12 19:48, Doug Moore wrote:
>>> Author: dougm
>>> Date: Fri Jun 12 17:48:12 2020
>>> New Revision: 362110
Author: dougm
Date: Fri Jun 12 17:48:12 2020
New Revision: 362110
URL: https://svnweb.freebsd.org/changeset/base/362110
Log:
Revert r362108, as it breaks compilation.
Modified:
head/sys/compat/linuxkpi/common/include/linux/rbtree.h
Modified: head/sys/compat/linuxkpi/common/include/linux/rbtr
Author: dougm
Date: Fri Jun 12 16:51:55 2020
New Revision: 362108
URL: https://svnweb.freebsd.org/changeset/base/362108
Log:
The linuxkpi code accesses left/right rb tree pointers without using
RB_LEFT or RB_RIGHT, so they aren't stripping off the color bit
encoded there. Strip off that bit
Author: dougm
Date: Wed Jun 10 03:36:17 2020
New Revision: 362000
URL: https://svnweb.freebsd.org/changeset/base/362000
Log:
Fixup r361997 by balancing parens. Duh.
Modified:
head/sys/sys/tree.h
Modified: head/sys/sys/tree.h
==
Author: dougm
Date: Wed Jun 10 02:50:25 2020
New Revision: 361997
URL: https://svnweb.freebsd.org/changeset/base/361997
Log:
Restore an RB_COLOR macro, for the benefit of a bit of DIAGNOSTIC code
that depends on it.
Reported by: rpokala, mjguzik
Reviewed by: markj
Differential Revis
Author: dougm
Date: Tue Jun 9 20:19:11 2020
New Revision: 361984
URL: https://svnweb.freebsd.org/changeset/base/361984
Log:
To reduce the size of an rb_node, drop the color field. Set the least
significant bit in the pointer to the node from its parent to indicate
that the node is red. Have
Author: dougm
Date: Tue Jun 2 17:18:16 2020
New Revision: 361727
URL: https://svnweb.freebsd.org/changeset/base/361727
Log:
Remove from RB_REMOVE_COLOR some null checks where the pointer checked
is provably never null. Restructure the surrounding code just enough
to make the non-nullness o
Author: dougm
Date: Sat May 30 01:48:12 2020
New Revision: 361640
URL: https://svnweb.freebsd.org/changeset/base/361640
Log:
RB_REMOVE invokes RB_REMOVE_COLOR either when child is red or child is
null. In the first case, RB_REMOVE_COLOR just changes the child to
black and returns. With this
Author: dougm
Date: Thu May 21 05:34:02 2020
New Revision: 361324
URL: https://svnweb.freebsd.org/changeset/base/361324
Log:
For the case when RB_REMOVE requires a nontrivial search to find the
node to replace the one being removed, restructure to first remove the
replacement node and correc
Author: dougm
Date: Mon Feb 24 04:01:09 2020
New Revision: 358268
URL: https://svnweb.freebsd.org/changeset/base/358268
Log:
The last argument to swp_pager_getswapspace is always 1. Remove that argument.
Reviewed by: markj
Differential Revision:https://reviews.freebsd.org/D23810
Author: dougm
Date: Sat Feb 1 21:47:34 2020
New Revision: 357389
URL: https://svnweb.freebsd.org/changeset/base/357389
Log:
In dmar_gas_lowermatch, skip searching a subtree if all its addresses are
greater than lowaddr.
In dmar_gas_uppermatch, skip searching a subtree if all its
gaps-betwee
Author: dougm
Date: Mon Jan 27 15:09:13 2020
New Revision: 357173
URL: https://svnweb.freebsd.org/changeset/base/357173
Log:
Correct the use of RB_AUGMENT in the RB_TREE macros so that is invoked
at the root of every subtree that changes in an insert or delete, and
only once, and ordered fro
Author: dougm
Date: Fri Jan 24 07:48:11 2020
New Revision: 357073
URL: https://svnweb.freebsd.org/changeset/base/357073
Log:
Most uses of vm_map_clip_start follow a call to vm_map_lookup. Define
an inline function vm_map_lookup_clip_start that invokes them both and
use it in places that invo
Author: dougm
Date: Tue Dec 31 22:20:54 2019
New Revision: 356243
URL: https://svnweb.freebsd.org/changeset/base/356243
Log:
The map-entry clipping functions modify start and end entries of an
entry in the vm_map, making invariants related to the max_free entry
field invalid. Move the clippi
Author: dougm
Date: Sun Dec 22 21:53:05 2019
New Revision: 356028
URL: https://svnweb.freebsd.org/changeset/base/356028
Log:
Fix typo using RB_INITIALIZER.
The macro RB_INITIALIZER ignores its argument, but is documented to
require "&head" as argument to initialize "head". So using
"_v
Author: dougm
Date: Thu Dec 19 16:39:52 2019
New Revision: 355913
URL: https://svnweb.freebsd.org/changeset/base/355913
Log:
Including into non-kernel software leads to a
compilation error because, without _KERNEL defined, the macro
TMPFS_VALIDATE_DIR is invoked, but never defined. User-lev
Author: dougm
Date: Sat Dec 14 19:44:42 2019
New Revision: 355757
URL: https://svnweb.freebsd.org/changeset/base/355757
Log:
Simplify the processing a leaf mask to find big-enough ranges of set
bits, by storing and modifying the complement of the original leaf
mask, and by avoiding some unne
Author: dougm
Date: Wed Dec 11 16:09:57 2019
New Revision: 355612
URL: https://svnweb.freebsd.org/changeset/base/355612
Log:
Extract code common to _vm_map_clip_start and _vm_map_clip_end into a
function, vm_map_entry_clone, that can be invoked by each.
Reviewed by: kib, markj
Different
Author: dougm
Date: Mon Dec 9 05:09:46 2019
New Revision: 32
URL: https://svnweb.freebsd.org/changeset/base/32
Log:
Revert r355505. The code that it allowed to compile has been removed.
Modified:
head/sys/vm/vm_map.h
Modified: head/sys/vm/vm_map.h
==
Author: dougm
Date: Sun Dec 8 22:33:51 2019
New Revision: 355538
URL: https://svnweb.freebsd.org/changeset/base/355538
Log:
Define a vm_map method for user-space for advancing from a map entry
to its successor in cases where examining a map entry requires a
helper like kvm_read_all. Use th
Author: dougm
Date: Sat Dec 7 18:40:46 2019
New Revision: 355502
URL: https://svnweb.freebsd.org/changeset/base/355502
Log:
Fix a type error in fixing libprocstat to be compatible with vm_map changes.
Approved by: markj
Differential Revision: https://reviews.freebsd.org/D22726
Modified:
Author: dougm
Date: Sat Dec 7 18:16:35 2019
New Revision: 355501
URL: https://svnweb.freebsd.org/changeset/base/355501
Log:
r355491 broke compilation of libprocstat.c. Change that code to use
new methods for accessing first, next map entries.
Approved by: kib
Differential Revision: ht
Author: dougm
Date: Sat Dec 7 17:14:33 2019
New Revision: 355491
URL: https://svnweb.freebsd.org/changeset/base/355491
Log:
Remove the next and prev fields from vm_map_entry, to save a bit of
space. Where the vm_map tree now has null pointers, store pointers to
next and previous entries in
Author: dougm
Date: Wed Dec 4 03:36:54 2019
New Revision: 355377
URL: https://svnweb.freebsd.org/changeset/base/355377
Log:
Change the implementation of bit_ffc_area_at so that, in the worst
case, the number of operations spent on each b-bit word is
proportional to lg b rather than b.
Author: dougm
Date: Fri Nov 29 02:06:45 2019
New Revision: 355201
URL: https://svnweb.freebsd.org/changeset/base/355201
Log:
Functions that call vm_map_splay_merge sometimes set data fields
(e.g. root->left = NULL) to affect the behavior of that function. This
change stops that data manipula
Author: dougm
Date: Wed Nov 27 21:00:44 2019
New Revision: 355147
URL: https://svnweb.freebsd.org/changeset/base/355147
Log:
Inline some splay helper functions to improve performance on a
micro-benchmark.
Reviewed by: markj
Tested by: pho
Differential Revision: https://reviews.freebsd
Author: dougm
Date: Mon Nov 25 02:19:47 2019
New Revision: 355076
URL: https://svnweb.freebsd.org/changeset/base/355076
Log:
Where 'current' is used to index over vm_map entries, use
'entry'. Where 'entry' is used to identify the starting point for
iteration, use 'first_entry'. These are the
Author: dougm
Date: Sat Nov 23 17:22:36 2019
New Revision: 355032
URL: https://svnweb.freebsd.org/changeset/base/355032
Log:
The error messages that indicate bugs in 'area' bitstring functions
should identify accurately which function exhibited the bug.
Reviewed by: asomers
MFC after: 1
Author: dougm
Date: Wed Nov 20 16:06:48 2019
New Revision: 354895
URL: https://svnweb.freebsd.org/changeset/base/354895
Log:
Instead of looking up a predecessor or successor to the current map
entry, when that entry has been seen already, keep the
already-looked-up value in a variable and us
Author: dougm
Date: Tue Nov 19 08:06:31 2019
New Revision: 354850
URL: https://svnweb.freebsd.org/changeset/base/354850
Log:
Drop the extra argument from swp_pager_meta_ctl and have it do lookup
only. Rename it swp_pager_meta_lookup. Stop checking for obj->type
== swap there and assert it
Author: dougm
Date: Sun Nov 17 18:38:37 2019
New Revision: 354795
URL: https://svnweb.freebsd.org/changeset/base/354795
Log:
Add a helper function for testing a swap block and freeing it if empty.
Submitted by: ota_j.email.ne.jp
Approved by: alc, kib, dougm
Differential Revision: https:
Author: dougm
Date: Sun Nov 17 06:50:36 2019
New Revision: 354785
URL: https://svnweb.freebsd.org/changeset/base/354785
Log:
The loop in vm_map_protect that verifies that all transition map
entries are stabilized, repeatedly verifies the same entry. Check each
entry in turn.
Reviewed by
Author: dougm
Date: Wed Nov 13 15:56:07 2019
New Revision: 354684
URL: https://svnweb.freebsd.org/changeset/base/354684
Log:
Define wrapper functions vm_map_entry_{succ,pred} to act as wrappers
around entry->{next,prev} when those are used for ordered list
traversal, and use those wrapper fu
Author: dougm
Date: Mon Nov 11 16:59:49 2019
New Revision: 354618
URL: https://svnweb.freebsd.org/changeset/base/354618
Log:
swap_pager_meta_free() frees allocated blocks in a way that
exploits the sparsity of allocated blocks in a range, without
issuing an "are you there?" query for every b
Author: dougm
Date: Sat Nov 9 17:08:27 2019
New Revision: 354570
URL: https://svnweb.freebsd.org/changeset/base/354570
Log:
For vm_map, #defining DIAGNOSTIC to turn on full assertion-based
consistency checking slows performance dramatically. This change
reduces the number of assertions chec
Author: dougm
Date: Mon Oct 14 17:51:57 2019
New Revision: 353497
URL: https://svnweb.freebsd.org/changeset/base/353497
Log:
Correct a transcription error that broke GENERIC introduced in r353496.
Modified:
head/sys/vm/vm_map.c
Modified: head/sys/vm/vm_map.c
=
Author: dougm
Date: Mon Oct 14 17:15:42 2019
New Revision: 353496
URL: https://svnweb.freebsd.org/changeset/base/353496
Log:
Move the definition of _vm_map_assert_consistent so that it can use
vm_map_free_{left,right} rather than re-implementing them. Use the
VM_MAP_FOREACH macro where appl
Author: dougm
Date: Tue Oct 8 07:14:21 2019
New Revision: 353298
URL: https://svnweb.freebsd.org/changeset/base/353298
Log:
Define macro VM_MAP_ENTRY_FOREACH for enumerating the entries in a vm_map.
In case the implementation ever changes from using a chain of next pointers,
then changing t
Author: dougm
Date: Tue Sep 17 02:53:59 2019
New Revision: 352433
URL: https://svnweb.freebsd.org/changeset/base/352433
Log:
Remove dead code from vm_map_unlink_entry made dead by r351476, and also
a no-longer-used enumerant.
Reviewed by: alc
Approved by: markj (mentor, implicit)
Test
Author: dougm
Date: Sun Aug 25 07:06:51 2019
New Revision: 351476
URL: https://svnweb.freebsd.org/changeset/base/351476
Log:
vm_map_simplify_entry considers merging an entry with its two
neighbors, and is used in a way so that if entries a and b cannot be
merged, we consider them twice, firs
Author: dougm
Date: Thu Aug 15 02:30:44 2019
New Revision: 351064
URL: https://svnweb.freebsd.org/changeset/base/351064
Log:
swap_pager.c reserves 2 blocks for a bsd label. Change that 2 to the
expression howmany(BBSIZE, PAGE_SIZE), where BBSIZE is the size of the
boot block area. That can
Author: dougm
Date: Sun Jul 28 19:32:23 2019
New Revision: 350392
URL: https://svnweb.freebsd.org/changeset/base/350392
Log:
In swap_pager_putpages, move the initialization of a free-blocks
counter, and the final freeing of freed swap blocks, outside the
region where an object lock is held.
Author: dougm
Date: Fri Jul 26 15:18:11 2019
New Revision: 350359
URL: https://svnweb.freebsd.org/changeset/base/350359
Log:
Rewrite the comments that explain swapon_trim() to make them more
comprehensible.
Suggested by: rpokala
Approved by: markj (mentor)
Differential Revision: https
Author: dougm
Date: Sat Jul 20 20:47:07 2019
New Revision: 350183
URL: https://svnweb.freebsd.org/changeset/base/350183
Log:
In trimming on startup, invoke swapon before closing the fd used for
trimming so that a geli device isn't detached before swapon is
invoked.
Submitted by: sigsys_
Author: dougm
Date: Fri Jul 19 20:47:35 2019
New Revision: 350155
URL: https://svnweb.freebsd.org/changeset/base/350155
Log:
Define vm_map_entry_in_transition to handle an in-transition map
entry, combining code currently in vm_map_unwire and
vm_map_wire_locked into a single function, called
Author: dougm
Date: Thu Jul 11 20:52:39 2019
New Revision: 349923
URL: https://svnweb.freebsd.org/changeset/base/349923
Log:
Address problems in blist_alloc introduced in r349777. The swap block
allocator could become corrupted
if a retry to allocate swap space, after a larger allocation att
Author: dougm
Date: Sun Jul 7 06:57:04 2019
New Revision: 349799
URL: https://svnweb.freebsd.org/changeset/base/349799
Log:
A style-related change, r349791, made unclear the meaning of a
comment. Rewrite that comment to improve its clarity.
Reported by: cem
Reviewed by: alc, cem
Appr
Author: dougm
Date: Sat Jul 6 15:55:16 2019
New Revision: 349791
URL: https://svnweb.freebsd.org/changeset/base/349791
Log:
Fix style(9) violations involving division by PAGE_SIZE.
Reviewed by: alc
Approved by: markj (mentor)
Differential Revision: https://reviews.freebsd.org/D20847
M
Author: dougm
Date: Sat Jul 6 06:15:03 2019
New Revision: 349777
URL: https://svnweb.freebsd.org/changeset/base/349777
Log:
Change blist_next_leaf_alloc so that it can examine more than one leaf
after the one where the possible block allocation begins, and allocate
a larger number of blocks
Author: dougm
Date: Fri Jul 5 16:49:34 2019
New Revision: 349767
URL: https://svnweb.freebsd.org/changeset/base/349767
Log:
Based on work posted at https://reviews.freebsd.org/D13484, change
swap_pager_swapoff_object and swp_pager_force_pagein so that they can
page in multiple pages at a ti
Author: dougm
Date: Thu Jul 4 19:25:30 2019
New Revision: 349745
URL: https://svnweb.freebsd.org/changeset/base/349745
Log:
Move an assignment, drop a label, and change gotos to break statements
in vm_map_unwire. The code generated on amd86 is unchanged.
Approved by: markj (mentor)
Dif
Author: dougm
Date: Thu Jul 4 19:17:55 2019
New Revision: 349744
URL: https://svnweb.freebsd.org/changeset/base/349744
Log:
Replace a 'goto' with an 'else' in vm_map_wire_locked.
Reviewed by: alc
Approved by: markj (mentor)
Differential Revision:https://reviews.freebsd.org/D208
Author: dougm
Date: Thu Jul 4 19:12:13 2019
New Revision: 349743
URL: https://svnweb.freebsd.org/changeset/base/349743
Log:
Change boolean_t variables in vm_map_unwire and vm_map_wire_locked to
bool. Drop result variable. Add holes_ok bool to replace repeated
masking of flags parameter.
Author: dougm
Date: Thu Jul 4 18:28:49 2019
New Revision: 349741
URL: https://svnweb.freebsd.org/changeset/base/349741
Log:
Drop a temp variable from vm_map_insert, with no effect on the
resulting amd64 machine code.
Reviewed by: alc
Approved by: kib, markj (mentors, implicit)
Differ
Author: dougm
Date: Wed Jul 3 22:41:54 2019
New Revision: 349713
URL: https://svnweb.freebsd.org/changeset/base/349713
Log:
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: htt
Author: dougm
Date: Sun Jun 30 02:08:13 2019
New Revision: 349550
URL: https://svnweb.freebsd.org/changeset/base/349550
Log:
Remove a call to vm_map_simplify_entry from _vm_map_clip_start.
Recent changes to vm_map_protect have made it unnecessary.
Reviewed by: alc
Approved by: kib (ment
Author: dougm
Date: Fri Jun 28 02:14:54 2019
New Revision: 349498
URL: https://svnweb.freebsd.org/changeset/base/349498
Log:
If vm_map_protect fails with KERN_RESOURCE_SHORTAGE, be sure to
simplify modified entries before returning.
Reviewed by: alc, markj (earlier version), kib (earlier
Author: dougm
Date: Wed Jun 26 03:12:57 2019
New Revision: 349405
URL: https://svnweb.freebsd.org/changeset/base/349405
Log:
Revert r349393, which leads to an assertion failure on bootup, in
vm_map_stack_locked.
Reported by: l...@lerctr.org
Approved by: kib, markj (mentors, implicit)
Mo
Author: dougm
Date: Tue Jun 25 20:25:16 2019
New Revision: 349393
URL: https://svnweb.freebsd.org/changeset/base/349393
Log:
Eliminate some uses of the prev and next fields of vm_map_entry_t.
Since the only caller to vm_map_splay is vm_map_lookup_entry, move the
implementation of vm_map_s
Author: dougm
Date: Tue Jun 25 17:27:37 2019
New Revision: 349379
URL: https://svnweb.freebsd.org/changeset/base/349379
Log:
Document the KERN_PROTECTION_FAILURE return value from vm_map_protect().
Reviewed by: alc (earlier version)
Approved by: kib, markj (mentors)
Differential Revisio
I regret that I omitted the following from the commit message below:
Tested by: pho
Doug Moore
On 6/25/19 2:44 AM, Doug Moore wrote:
> Author: dougm
> Date: Tue Jun 25 07:44:37 2019
> New Revision: 349363
> URL: https://svnweb.freebsd.org/changeset/base/349363
>
> Log:
>
Author: dougm
Date: Tue Jun 25 07:44:37 2019
New Revision: 349363
URL: https://svnweb.freebsd.org/changeset/base/349363
Log:
vm_map_protect may return an INVALID_ARGUMENT or PROTECTION_FAILURE
error response after clipping the first map entry in the region to be
reserved. This creates a pair
Author: dougm
Date: Sat Jun 22 19:27:09 2019
New Revision: 349293
URL: https://svnweb.freebsd.org/changeset/base/349293
Log:
You can't use block special nodes for swap, so don't let that happen.
Fix a style violation with regard to header file arrangement.
Improved by: alc
Approved b
Author: dougm
Date: Sat Jun 22 03:16:01 2019
New Revision: 349286
URL: https://svnweb.freebsd.org/changeset/base/349286
Log:
Modify swapon(8) to invoke BIO_DELETE to trim swap devices, either if
'-E' appears on the swapon command line, or if "trimonce" appears as
an fstab option.
Discus
The patch makes it appear that a call to vm_map_simplify_entry has been
removed, and that another has been added. They are the same call, just
moved from after a comment to before it.
Doug Moore
On 6/15/19 12:30 AM, Oliver Pinter wrote:
>
>
> On Saturday, June 15, 2019, Doug Moore &
Author: dougm
Date: Sat Jun 15 04:30:13 2019
New Revision: 349046
URL: https://svnweb.freebsd.org/changeset/base/349046
Log:
Critical comments were lost in r349203. This patch seeks to restore
the lost information in new comments.
Reported by: alc
Reviewed by: alc
Approved by: kib (me
Author: dougm
Date: Fri Jun 14 03:15:54 2019
New Revision: 349030
URL: https://svnweb.freebsd.org/changeset/base/349030
Log:
Avoid using the prev field of vm_map_entry_t in two functions that
iterate over consecutive vm_map entries, and that can easily just
'remember' the prev value instead
Author: dougm
Date: Thu Jun 13 20:09:07 2019
New Revision: 349023
URL: https://svnweb.freebsd.org/changeset/base/349023
Log:
Create a function for creating objects to back map entries, and one
for giving cred to a map entry backed by an object, and use them
instead of the code duplicated inl
Author: dougm
Date: Tue Jun 11 22:41:39 2019
New Revision: 348968
URL: https://svnweb.freebsd.org/changeset/base/348968
Log:
To test to see if a free space is big enough compare the required
length to the difference of the two offsets that define the gap, to
avoid overflow, rather that addin
Author: dougm
Date: Mon Jun 10 22:06:40 2019
New Revision: 348883
URL: https://svnweb.freebsd.org/changeset/base/348883
Log:
r348879 introduced a wrong-way comparison that broke mmap.
This change rights that comparison.
Reported by: pho
Approved by: markj (mentor)
MFC after: 3 days
Author: dougm
Date: Mon Jun 10 21:34:07 2019
New Revision: 348881
URL: https://svnweb.freebsd.org/changeset/base/348881
Log:
The computations of vm_map_splay_split and vm_map_splay_merge touch both
children of every entry on the search path as part of updating values of
the max_free field. B
Author: dougm
Date: Mon Jun 10 21:26:14 2019
New Revision: 348879
URL: https://svnweb.freebsd.org/changeset/base/348879
Log:
Change the check for 'size' wrapping around to zero in kern_mmap to account
for both the lower and upper bound modifications. Change the error returned
to ENOMEM. Rena
The comment and the code that rejects size==0, or doesn't, are copied
below. Konstantin Belousov is the last person to have touched most of
it, and can better explain its meaning than I.
Doug Moore
/*
* Enforce the constraints.
* Mapping of length 0 is only allowed fo
transformed to zero,
and which was the problem that Peter Holm reported.
Doug Moore
On 6/10/19 8:00 AM, Shawn Webb wrote:
> On Mon, Jun 10, 2019 at 03:07:11AM +0000, Doug Moore wrote:
>> Author: dougm
>> Date: Mon Jun 10 03:07:10 2019
>> New Revision: 348843
>> URL: https://s
-fwrapv concerns signed arithmetic. This calculation is with unsigned
arithmetic, and the possibility of wrapping around to 0 is part of the
language.
Doug Moore
On 6/10/19 1:35 AM, Andriy Gapon wrote:
> On 10/06/2019 06:07, Doug Moore wrote:
>> Author: dougm
>> Date: Mon Jun 1
I understand that I ought to have included this in the previous checkin.
MFC after: 3 days
and that my description of the appropriateness of len==0 passed to mmap
was imprecise. I regret the error.
Doug Moore
On 6/9/19 10:07 PM, Doug Moore wrote:
> Author: dougm
> Date: Mon Jun 10 03
Author: dougm
Date: Mon Jun 10 03:07:10 2019
New Revision: 348843
URL: https://svnweb.freebsd.org/changeset/base/348843
Log:
There are times when a len==0 parameter to mmap is okay. But on a
32-bit machine, a len parameter just a few bytes short of 4G, rounded
up to a page boundary and hitti
Author: dougm
Date: Sat Jun 8 17:49:17 2019
New Revision: 348809
URL: https://svnweb.freebsd.org/changeset/base/348809
Log:
Simple code refactoring originally in D13484.
Extract swp_pager_force_dirty() and swp_pager_force_launder() out of
swp_pager_force_pagein().
Extract swap_pager
Author: dougm
Date: Thu Jun 6 16:28:34 2019
New Revision: 348749
URL: https://svnweb.freebsd.org/changeset/base/348749
Log:
The means of finding ranges of free pages was changed for
vm_reserv_break in r348484, and there was found to improve performance
minutely and reduce code size. This ch
Yalta, Crimea, USSR, 1988
11/28 Nik Clayton born in Peterborough, United Kingdom,
1973
11/28 Stanislav Sedov born in Chelyabinsk, USSR, 1985
+11/29 Doug Moore born in Arlington, Texas, United States,
1960
12/01 Hajimu Umemoto born in Nara, Japan, 1961
12/01 Alexey Dokuchaev born in
On 5/31/19 10:05 PM, Kubilay Kocak wrote:
> On 1/06/2019 7:02 am, Doug Moore wrote:
>> Author: dougm
>> Date: Fri May 31 21:02:42 2019
>> New Revision: 348484
>> URL: https://svnweb.freebsd.org/changeset/base/348484
>>
> Can this be an MFC candidate?
If one of
Author: dougm
Date: Fri May 31 21:02:42 2019
New Revision: 348484
URL: https://svnweb.freebsd.org/changeset/base/348484
Log:
The function vm_phys_free_contig invokes vm_phys_free_pages for every
power-of-two page block it frees, launching an unsuccessful search for
a buddy to pair up with ea
Author: dougm
Date: Tue May 28 15:47:00 2019
New Revision: 348327
URL: https://svnweb.freebsd.org/changeset/base/348327
Log:
Implement the ffs and fls functions, and their longer counterparts, in
cpufunc, in terms of __builtin_ffs and the like, for arm32 v6 and v7
architectures, and use thos
Author: dougm
Date: Tue May 28 00:51:23 2019
New Revision: 348318
URL: https://svnweb.freebsd.org/changeset/base/348318
Log:
Reduce the code size and number of ffsl calls in vm_reserv_break. Use
xor to find where free ranges begin and end.
Tested by: pho
Reviewed by:alc
Approved by:ma
Author: dougm
Date: Thu May 23 02:10:41 2019
New Revision: 348144
URL: https://svnweb.freebsd.org/changeset/base/348144
Log:
Fix typo from r348128: _func__ -> __func__
Reported by: LINT
Modified:
head/sys/vm/vm_map.c
Modified: head/sys/vm/vm_map.c
===
Author: dougm
Date: Wed May 22 23:11:16 2019
New Revision: 348128
URL: https://svnweb.freebsd.org/changeset/base/348128
Log:
Cleanups made necessary by r348115, or reactions to it:
1. Change size_t to vm_size_t in some places.
2. Rename vm_map_entry_resize_free to drop the _free part.
3. F
Author: dougm
Date: Wed May 22 17:40:54 2019
New Revision: 348115
URL: https://svnweb.freebsd.org/changeset/base/348115
Log:
Passing a parameter to vm_map_entry_resize_free that describes the
amount of resizing reduces the number of functions changing the vm_map
invariants regarding the max_
Author: dougm
Date: Fri May 17 15:52:17 2019
New Revision: 347927
URL: https://svnweb.freebsd.org/changeset/base/347927
Log:
Implement the ffs and fls functions, and their longer counterparts, in
cpufunc, in terms of __builtin_ffs and the like, for arm64
architectures, and use those, rather
I refer you to the discussion that began with that question from Cy
Schubert on Friday night.
I apologize again for the brevity of my commit message.
Doug Moore
On 5/13/19 12:06 AM, Enji Cooper wrote:
> Hi Doug,
>
>> On May 10, 2019, at 7:13 PM, Doug Moore wrote:
>>
>&g
On 5/11/19 5:52 AM, Bruce Evans wrote:
> On Sat, 11 May 2019, Doug Moore wrote:
>> +#ifdef HAVE_INLINE_FFS
>> + case sizeof(int):
>> + return (ffs(mask) - 1);
>> +#endif
>
> This is unreachable, since sizeof(int) is 4 on all supported arches, and
Author: dougm
Date: Sat May 11 16:15:13 2019
New Revision: 347493
URL: https://svnweb.freebsd.org/changeset/base/347493
Log:
A new parameter to blist_alloc specifies an upper bound on the size of
the allocation request, so that the blocks allocated are from the next
set of free blocks big en
Author: dougm
Date: Sat May 11 10:16:43 2019
New Revision: 347487
URL: https://svnweb.freebsd.org/changeset/base/347487
Log:
Callers of swp_pager_getswapspace get either as many blocks as they
requested, or none, and in the latter case it is up to them to pick a
smaller request to make - whi
Author: dougm
Date: Sat May 11 09:09:10 2019
New Revision: 347484
URL: https://svnweb.freebsd.org/changeset/base/347484
Log:
When bitpos can't be implemented with an inline ffs* instruction,
change the binary search so that it does not depend on a single bit
only being set in the bitmask. Us
1 - 100 of 109 matches
Mail list logo