Page MenuHomeFreeBSD

MFC r300220,r300223
ClosedPublic

Authored by ngie on Jun 10 2016, 8:49 PM.
Tags
None
Referenced Files
Unknown Object (File)
Oct 15 2024, 2:12 AM
Unknown Object (File)
Oct 1 2024, 7:08 PM
Unknown Object (File)
Oct 1 2024, 12:04 AM
Unknown Object (File)
Sep 30 2024, 3:24 AM
Unknown Object (File)
Sep 29 2024, 11:27 PM
Unknown Object (File)
Sep 20 2024, 9:38 AM
Unknown Object (File)
Sep 17 2024, 6:43 PM
Unknown Object (File)
Sep 15 2024, 10:34 AM
Subscribers

Details

Summary

MFC r300220,r300223

MFC r300220,r300223:

r300220 (by cem):

sys/vmmeter.h: Fix trivial '-Wsign-compare' warning in common header

Frankly, it doesn't make sense for vm_pageout_wakeup_thresh to have a negative
value (it is only ever set to a fraction of v_free_min, which is unsigned and
also obviously non-negative). But I'm not going to try and convert every
non-negative scalar in the VM to unsigned today, so just cast it for the
comparison.

r300223 (by cem):

vm/vm_page.h: Fix trivial '-Wpointer-sign' warning

pq_vcnt, as a count of real things, has no business being negative. It is only
ever initialized by a u_int counter.

The warning came from the atomic_add_int() in vm_pagequeue_cnt_add().

Rectify the warning by changing the variable to u_int. No functional change.

Suggested by: Clang 3.3

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

ngie retitled this revision from to MFC r300220,r300223.
ngie updated this object.
ngie edited the test plan for this revision. (Show Details)
ngie added a reviewer: cem.
ngie added subscribers: alc, kib.

I'm sending the CR out to double-check whether or not this change should be committed to ^/stable/10 . The structure type is changing for "struct vm_pagequeue", but the change seems ok.

I've run make buildworld/buildkernel for amd64/i386. I'm going to run make tinderbox on arm/mips/powerpc/sparc64 as a sanity check.

kib added a reviewer: kib.
This revision is now accepted and ready to land.Jun 11 2016, 4:27 AM
alc added a reviewer: alc.
This revision was automatically updated to reflect the committed changes.