Repository navigation
Conversation
Assisted-by: Codex:GPT-6
Assisted-by: Codex:GPT-6
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
libusb: retain 1024 input reports and expose native queue loss counters
Bursty input can overflow the small libusb receive queue and silently discard old
reports. Port the locally validated 1024-report limit, received/dropped/peak
counters, mutex-protected
hid_get_queue_stats()snapshot and close-time logging.The existing queue and oldest-report discard policy are preserved. Peak depth is
measured before eviction and can reach 1025. Other backends return unsupported;
existing APIs retain their behavior.
The original hardware validation transferred 22658 reports with zero drops and
matching Python/C counters. New Linux checks compile both native backends and
exercise the actual callback using mocked USB operations: overflow boundary,
FIFO retention, invalid pointers and a 22658-report zero-drop synthetic run.
Address/undefined sanitizers passed with leak detection disabled due to sandbox
tracing restrictions. No hardware was accessed. Native builds used cc because
CMake/Autotools are unavailable. Other platforms need CI.
Companion Python contribution: stman/cython-hidapi branch feat/libusb-queue-stats.
Assisted-by: Codex:GPT-6