mirror of
https://chromium.googlesource.com/crosvm/crosvm
synced 2024-11-25 05:03:05 +00:00
569a58490e
When creating shared memory, 'name' can have one of two meanings. It could either be a debugging tag with no semantic meaning, or it could uniquely identify a shared memory object within some namespace. Linux memfd uses name in the first meaning, whereas Windows (and Linux shm) uses it in the second meaning. Currently, crosvm has no use cases for the named shared memory of the second type, so it is not supported. Make it clear that the SharedMemory APIs treats name as a debugging-only name. Remove the "anon" and "named" constructors, since they had no semantic meaning. Also require a name when constructing a SharedMemory, since there's no reason not to provide one to make debugging easier. The only semantic change is setting the name of GuestMemory's underlying shmem to "crosvm_guest", which it was until recently. This fixes some ManaTEE tests which use the name to determine CrOS guest memory usage. BUG=None TEST=compiles Change-Id: I78d5046df04d6f19640abbbc67af6bd433a177b0 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/crosvm/+/3676695 Commit-Queue: David Stevens <stevensd@chromium.org> Reviewed-by: Daniel Verkamp <dverkamp@chromium.org> Tested-by: kokoro <noreply+kokoro@google.com> |
||
---|---|---|
.. | ||
src | ||
tests | ||
Cargo.toml |