[ulib/fs] wait for remote to close on error

During remote mounting, the host filesystem essentially takes ownership
of the remote filesystem, and similar to channel ownership, it is
responsible for tearing down the remote filesystem when an error occurs.
This tear down on error was asynchronous - it wouldn't wait for a
response before finishing the request. This would cause tests to
occationally flake if they tore down the test environment before the
async filesystem shutdown finished.

This change makes Mount and MountAndCreate block on the shut down of the
remote filesystem.

Before this change, `fx test fs-management-test -- -f
MountFailsWithoutAdminCase.MountFailsWithoutAdmin` would fail every few
hundred times on qemu, with this change it's gone for about 10k without
a failure.

Bug: 61269
Test: fx test fs-management-test
Change-Id: I1b5471061d9affafe8f055e172e17a46bb21d3e6
Reviewed-on: https://fuchsia-review.googlesource.com/c/fuchsia/+/450294
Reviewed-by: Chris Suter <csuter@google.com>
Testability-Review: Chris Suter <csuter@google.com>
Commit-Queue: Stephen Demos <sdemos@google.com>
2 files changed
tree: 47fd62879e321e9970009c852354d45df433e886
  1. boards/
  2. build/
  3. bundles/
  4. docs/
  5. examples/
  6. garnet/
  7. products/
  8. scripts/
  9. sdk/
  10. src/
  11. third_party/
  12. tools/
  13. zircon/
  14. .clang-format
  15. .clang-tidy
  16. .gitattributes
  17. .gitignore
  18. .gn
  19. .style.yapf
  20. AUTHORS
  21. BUILD.gn
  22. CODE_OF_CONDUCT.md
  23. CONTRIBUTING.md
  24. LICENSE
  25. OWNERS
  26. PATENTS
  27. README.md
  28. rustfmt.toml
README.md

Fuchsia

Pink + Purple == Fuchsia (a new operating system)

What is Fuchsia?

Fuchsia is a modular, capability-based operating system. Fuchsia runs on modern 64-bit Intel and ARM processors.

Fuchsia is an open source project with a code of conduct that we expect everyone who interacts with the project to respect.

Read more about Fuchsia's principles.

How can I build and run Fuchsia?

See Getting Started.

Where can I learn more about Fuchsia?

See fuchsia.dev.