Page MenuHomeFreeBSD

tidy up swap_pager_putpages
ClosedPublic

Authored by dougm on Jul 28 2019, 4:38 AM.
Tags
None
Referenced Files
Unknown Object (File)
Fri, May 22, 3:24 PM
Unknown Object (File)
May 17 2026, 4:54 PM
Unknown Object (File)
May 15 2026, 3:38 AM
Unknown Object (File)
May 6 2026, 10:48 PM
Unknown Object (File)
May 5 2026, 10:30 AM
Unknown Object (File)
May 1 2026, 10:32 AM
Unknown Object (File)
Apr 28 2026, 10:11 AM
Unknown Object (File)
Apr 28 2026, 4:25 AM
Subscribers

Details

Summary

(1) convert the panic() at the function's start into a KASSERT(), (2) convert sync into a bool-type variable async, (3) make the variable definitions style(9) compliant, and (4) move the calls to swp_pager_init_freerange() and swp_pager_freeswapspace() out from under the object lock.

Diff Detail

Lint
Lint Skipped
Unit
Tests Skipped

Event Timeline

swap_pager.c
1366–1367

Isn't this assignment unnecessary?

1382

I think it's within the scope of this patch to fix the style issue here: Add spaces around the '+'.

1411–1412

Add spaces around the '+'.

swap_pager.c
1355–1356

I think that this one line no longer applies.

1366

I would delete this blank line because the above block comment describes the below initialization to 'async'.

Apply reviewer suggestions. Make another style(9) fix.

swap_pager.c
1335

Please fix the "whos".

1355–1356

Please capitalize and punctuate these sentences.

1387

Shouldn't this be a period instead of a comma?

alc added reviewers: kib, markj.

I think that this is a good change and ready to commit. Give Kostik and Mark a chance to comment.

This revision is now accepted and ready to land.Jul 28 2019, 5:07 PM