[roll] Roll fuchsia [usb-peripheral] Wait for pending requests during ClearFunctions and PrepareStop

Introduce a mechanism to ensure all pending USB requests are completed
before finishing the driver shutdown or clearing functions. This
prevents potential use-after-free or race conditions during teardown.

- Implement WaitForPendingRequests() to defer callbacks until
  pending_requests_ is empty.
- Update ClearFunctions() and PrepareStop() to use this mechanism.
- Add a unit test to verify that pending requests are completed when
  ClearFunctions is called.

Original-Bug: 496790710
Test: fx test usb-peripheral-unittest
Original-Reviewed-on: https://fuchsia-review.googlesource.com/c/fuchsia/+/1552634
Original-Revision: 9eb4c62a4550fcdebfc50a5702d5c306df43a266
GitOrigin-RevId: 74046ec728a8e3e9a1891afa1f9b0fd81a8f65e3
Change-Id: I898074a0bcfbfe62db98038ff0cc937e4876d74f
1 file changed
tree: e3ca6138532e71d29d1b91b572df527313b043e4
  1. ctf/
  2. git-hooks/
  3. infra/
  4. third_party/
  5. cobalt
  6. flower
  7. jiri.lock
  8. MILESTONE
  9. minimal
  10. prebuilts
  11. README.md
  12. stem
  13. test_durations
README.md

Integration

This repository contains Fuchsia's Global Integration manifest files.

Making changes

All changes should be made to the internal version of this repository. Our infrastructure automatically updates this version when the internal one changes.

Currently all changes must be made by a Google employee. Non-Google employees wishing to make a change can ask for assistance in one of the communication channels documented at get involved.

Obtaining the source

First install Jiri.

Next run:

$ jiri init
$ jiri import minimal https://fuchsia.googlesource.com/integration
$ jiri update

Third party

Third party projects should have their own subdirectory in ./third_party.