[idd] clipboard: batch helper stream delivery

Extend the clipboard target boundary with ordered prefix delivery.
Pass up to four queued LGMP stream records to the Helper ring in one
operation, apply state only to the accepted prefix, and retain the
remaining suffix for exact retries.

The channel holds its write lock across the prefix and emits one pipe
doorbell per stream window instead of one per record.
This commit is contained in:
Geoffrey McRae
2026-08-15 16:32:43 +10:00
parent 5bdfc0fe80
commit 94d5f3729e
5 changed files with 206 additions and 111 deletions

View File

@@ -42,6 +42,12 @@ public:
virtual ClipboardChannelResult SendClipboard(
const KVMFRClipboardMessage& record, const uint8_t * data) = 0;
// Sends an ordered prefix of client-to-Helper records. accepted reports
// how many records were consumed for every result; the source retains and
// retries an unaccepted suffix when the target returns BUSY.
virtual ClipboardChannelResult SendClipboardBatch(
const ClipboardChannelWrite * records, size_t count, size_t& accepted) = 0;
// The source calls ClipboardReceiveReady after a Helper-to-client record
// returned BUSY and it can accept an exact retry of that record.
virtual void ClipboardReceiveReady() = 0;