Page MenuHomeFreeBSD

vm_object: use iterators in DB_SHOW*()
ClosedPublic

Authored by dougm on Apr 21 2025, 7:30 PM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, Sep 22, 2:50 AM
Unknown Object (File)
Sun, Sep 21, 1:55 AM
Unknown Object (File)
Fri, Sep 19, 12:43 PM
Unknown Object (File)
Thu, Sep 18, 7:27 PM
Unknown Object (File)
Thu, Sep 18, 3:42 PM
Unknown Object (File)
Sat, Sep 13, 11:32 PM
Unknown Object (File)
Sep 3 2025, 1:53 PM
Unknown Object (File)
Aug 24 2025, 12:00 PM
Subscribers

Details

Summary

Replace tailq pointers with iterators in the DB_SHOW* functions.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

dougm requested review of this revision.Apr 21 2025, 7:30 PM
dougm created this revision.
sys/vm/vm_object.c
2839–2840

After this 'continue', wouldn't the fidx value become invalid? IMO it should be updated for each loop iteration when the state is 'in the run'.

2841
dougm marked an inline comment as done.

Rewrite DB_SHOW_COMMAND_FLAGS to make it clearer.

sys/vm/vm_object.c
2839–2840

I'm using fidx improperly. In the original code, it is set at the beginning of a run and printed at the end of the run. My use of it at the top of the loop is wrong.

kib added inline comments.
sys/vm/vm_object.c
2847
This revision is now accepted and ready to land.Apr 22 2025, 3:15 PM
This revision was automatically updated to reflect the committed changes.