[roll pigweed] pw_transfer: Version 2 completion handshake in C++

In legacy transfer, completions were one-sided. As such, there was no
guarantee that the peer of a transfer recognized that it was finished.
If the completion chunk was lost, the peer would continue trying to send
regular chunks until it timed out, while the terminator could already
have cleaned up all of its resources and been reused in a new context.
This has led to several bugs in projects using pw_transfer.

This change updates the completion protocol in transfer v2 to require
that completion chunks are acknowledged. After one side of the transfer
terminates with a completion chunk, it waits for the peer to acknowledge
the completion. The completion chunk is re-sent in response to non-ack
chunks or following a timeout.

Original-Reviewed-on: https://pigweed-review.googlesource.com/c/pigweed/pigweed/+/102600

https://pigweed.googlesource.com/pigweed/pigweed
pigweed Rolled-Commits: 1493ec54764574d..643379783d0f1ed
Roller-URL: https://ci.chromium.org/b/8805724617486841569
CQ-Do-Not-Cancel-Tryjobs: true
Change-Id: I1f0fd52ad66fa435d98006bc8ef99d06813102c4
Reviewed-on: https://pigweed-review.googlesource.com/c/pigweed/zephyr-integration/+/106733
Bot-Commit: Pigweed Integration Roller <pigweed-integration-roller@pigweed.google.com.iam.gserviceaccount.com>
Commit-Queue: Pigweed Integration Roller <pigweed-integration-roller@pigweed.google.com.iam.gserviceaccount.com>
1 file changed
tree: 662dd131a270954c68c6a2d71c86b4fb8bbc1322
  1. .gitmodules
  2. test.sh