Page MenuHomeFreeBSD

sfxge(4): handle negative ticks difference correctly
ClosedPublic

Authored by arybchik on Jun 8 2016, 6:06 PM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, Apr 29, 9:59 PM
Unknown Object (File)
Mon, Apr 29, 9:59 PM
Unknown Object (File)
Mon, Apr 29, 9:59 PM
Unknown Object (File)
Sun, Apr 28, 9:23 PM
Unknown Object (File)
Thu, Apr 25, 11:38 PM
Unknown Object (File)
Thu, Apr 25, 11:35 PM
Unknown Object (File)
Sat, Apr 20, 10:59 AM
Unknown Object (File)
Mar 23 2024, 1:27 AM
Subscribers

Details

Summary

ticks are signed int and if statistics is not updated for a long time
(more than INT_MAX ticks, but less than UINT_MAX) difference becomes
negative and less than hz for a long time.

Other option to repeat is simply load driver (which initializes
timestamps to 0) when ticks are negative.

Sponsored by: Solarflare Communications, Inc.
MFC after: 1 week

Test Plan

Module built, loaded, sysctl stats checked.
Stats tested on a lucky host with negative ticks.

Diff Detail

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

Event Timeline

arybchik retitled this revision from to sfxge(4): handle negative ticks difference correctly.
arybchik updated this object.
arybchik edited the test plan for this revision. (Show Details)
arybchik added reviewers: gnn, philip, bz, np.
This revision was automatically updated to reflect the committed changes.