Use BBSIZE / PAGE_SIZE, instead of 2, in swap_pager.c. Don't trim the first BBSIZE bytes, swapon_trim, in swapon.c.
- Group Reviewers
- rS351064: swap_pager.c reserves 2 blocks for a bsd label. Change that 2 to the
|94–97 ↗||(On Diff #60601)|
The crash dump will still be deleted by the -E option. The late option will simply delay the execution of swapon(8) until after savecore(8) has copied the crash dump to another location.
|2305–2306 ↗||(On Diff #60601)|
Consider the possibility that PAGE_SIZE is greater than BBSIZE. (We still barely support one architecture, sparc64, where they are equal.) I think that howmany(BBSIZE, PAGE_SIZE) will "do the right thing."
|93 ↗||(On Diff #60608)|
This sentence has become long enough that I would recommend splitting it into two: "... command. This command marks all blocks ...
|94–99 ↗||(On Diff #60608)|
My recollection is that the style guidelines for man pages say that new sentences should start on their own line in the first column.
"This marking can erase a crash dump.
|249 ↗||(On Diff #60608)|
Ditto: "... command to the device. This command marks ...
Which one is a better value to pass here, 0 or howmany(BBSIZE, PAGE_SIZE) ?
I think behavior is the same regardless of the value given blist_free(sp->sw_blist, howmany(BBSIZE, PAGE_SIZE), nblks - howmany(BBSIZE, PAGE_SIZE)) was done.