mirror of
https://chromium.googlesource.com/crosvm/crosvm
synced 2025-02-05 18:20:34 +00:00
std::task::Waker unconditionally implements Send + Sync so the raw waker that we provide also must implement those traits. Switch to using an Arc<AtomicBool>. This also fixes an inconsistency where the waker was defined to be an Rc<Cell<bool>> but all the vtable functions were treating as an Rc<AtomicBool>. To reduce the vtable boilerplate use the ArcWake trait from the futures crate. BUG=none TEST=unit tests Change-Id: I3870e4d7f6ce0de9f6ac3313a2f4474ae29018b2 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/crosvm/+/2287079 Reviewed-by: Daniel Verkamp <dverkamp@chromium.org> Reviewed-by: Dylan Reid <dgreid@chromium.org> Tested-by: Chirantan Ekbote <chirantan@chromium.org> Commit-Queue: Chirantan Ekbote <chirantan@chromium.org>
18 lines
376 B
TOML
18 lines
376 B
TOML
[package]
|
|
name = "cros_async"
|
|
version = "0.1.0"
|
|
authors = ["The Chromium OS Authors"]
|
|
edition = "2018"
|
|
|
|
[dependencies]
|
|
io_uring = { path = "../io_uring" }
|
|
libc = "*"
|
|
paste = "*"
|
|
pin-utils = "0.1.0-alpha.4"
|
|
sys_util = { path = "../sys_util" }
|
|
syscall_defines = { path = "../syscall_defines" }
|
|
|
|
[dependencies.futures]
|
|
version = "*"
|
|
default-features = false
|
|
features = ["alloc"]
|