Use AtomicU64 for handle_ref_count

This allows us to use a read lock instead of a write on `lookup`.

Intriguingly, the corresponding call to decrease the count in `forget`
does not need a lock, thanks to Rust. So this should be a net
performance gain.

Also, panic is a handle's reference count is about to overflow.

Bug: 220386264
Test: atest AuthFsHostTest
Change-Id: Icc3ba1a3fe92431837d6cffb470688ae0883a355
1 file changed
tree: 90ccce84da45164bc155746039ab36436cd32131
  1. .prebuilt_info/
  2. apex/
  3. apkdmverity/
  4. authfs/
  5. compos/
  6. demo/
  7. docs/
  8. javalib/
  9. launcher/
  10. libs/
  11. microdroid/
  12. microdroid_manager/
  13. pvmfw/
  14. tests/
  15. virtualizationservice/
  16. vm/
  17. zipfuse/
  18. .clang-format
  19. .gitignore
  20. Android.bp
  21. OWNERS
  22. PREUPLOAD.cfg
  23. README.md
  24. TEST_MAPPING
README.md

Virtualization

This repository contains userspace services related to running virtual machines on Android, especially protected virtual machines. See the getting started documentation and Microdroid README for more information.