Page MenuHomeFreeBSD

Eliminate key press requirement "show vmopag" command output.
ClosedPublic

Authored by stevek on Dec 17 2021, 10:04 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sun, Apr 7, 6:57 AM
Unknown Object (File)
Sat, Apr 6, 10:09 PM
Unknown Object (File)
Mar 16 2024, 5:02 PM
Unknown Object (File)
Feb 27 2024, 11:15 PM
Unknown Object (File)
Feb 19 2024, 8:20 PM
Unknown Object (File)
Feb 11 2024, 12:11 PM
Unknown Object (File)
Jan 28 2024, 9:42 PM
Unknown Object (File)
Jan 20 2024, 5:49 AM

Details

Summary

One was required to press a key to continue after every 18 lines of
output. This requirement had been in the "show vmopag" command since it
was introduced, which was many years before paging was added to DDB.
With paging, this explict key check is no longer necessary.

Obtained from: Juniper Networks, Inc.
MFC after: 1 week

Test Plan

Run "show vmopag" from db> prompt and see that it does not need additional
keypresses other than the ones needed for the pager.

Diff Detail

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

Event Timeline

jhb added a subscriber: jhb.

Magic 18's and not documented at all,

sys/vm/vm_object.c
2838

Somewhere (perhaps at the end of the loop) you might want to throw in a

if (db_pager_quit)
    return;

To allow exiting the output if it is long. I'm not sure if you really want to put it in all the places that checked before, maybe just at the start of each TAILQ_FOREACH() loop (both outer and inner)?

This revision is now accepted and ready to land.Dec 18 2021, 12:23 AM

Thanks, this saves me a submission.

sys/vm/vm_object.c
2838

This is exactly where I placed these returns in my diff. The output is quite long so I would say they are necessary.

Add db_pager_quit checks per review comments

This revision now requires review to proceed.Dec 20 2021, 12:38 AM
This revision was not accepted when it landed; it landed in state Needs Review.Dec 20 2021, 12:41 AM
This revision was automatically updated to reflect the committed changes.