crosvm/common
Grzegorz Jaszczyk d7db39550e sys_util: netlink: add functionality for family name query and mcast group id parsing
In order to listen on a specific netlink generic multicast group for a given
family (e.g. "acpi_mc_group" multicast group registered for "acpi_event" family),
we first need to get its group id registered by the kernel.

To achieve above, this commit implements two functionalities:
1) family name query (family_name_query), which prepares proper netlink
   message, which is next send to netlink generic controller to query
   kernel about a given family name. (e.g. it can be used to query about
   "acpi_event" family)
2) parse the netlink generic answer and get group id registered for a
   given generic netlink multicast group name (get_multicast_group_id)
   (e.g. it can be used to get multicast group id for "acpi_mc_group").

BUG=b:197247746, b:205072342
TEST=Use introduced functionality to query about "acpi_event" generic
netlink family and get group id for "acpi_mc_group" group. Additionally
test the same after hacking the kernel and registering two other multicast
groups for acpi_event, so "acpi_mc_group" got a different group id. In
both cases successfully listen on "acpi_mc_group".

Change-Id: Ia7681fae2200ff5baebbad3742c9dd97ac59cae5
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/crosvm/+/3515924
Reviewed-by: Daniel Verkamp <dverkamp@chromium.org>
Tested-by: kokoro <noreply+kokoro@google.com>
Commit-Queue: Tomasz Nowicki <tnowicki@google.com>
2022-03-19 07:27:42 +00:00
..
assertions crosvm: migrate to Rust 2021 edition 2022-03-09 01:16:03 +00:00
audio_streams audio_streams: Add async interface to remove dependency on cros_async 2022-03-15 17:29:21 +00:00
balloon_control crosvm: migrate to Rust 2021 edition 2022-03-09 01:16:03 +00:00
cros-fuzz crosvm: migrate to Rust 2021 edition 2022-03-09 01:16:03 +00:00
cros_async Refactoring: use super:: instead of crate:: 2022-03-16 23:59:29 +00:00
cros_asyncv2 crosvm: migrate to Rust 2021 edition 2022-03-09 01:16:03 +00:00
data_model Upstream data_model 2022-03-10 18:48:52 +00:00
io_uring rm build_test files 2022-03-16 21:38:04 +00:00
p9 crosvm: migrate to Rust 2021 edition 2022-03-09 01:16:03 +00:00
sync crosvm: migrate to Rust 2021 edition 2022-03-09 01:16:03 +00:00
sys_util sys_util: netlink: add functionality for family name query and mcast group id parsing 2022-03-19 07:27:42 +00:00
sys_util_core Refactoring: use super:: instead of crate:: 2022-03-16 23:59:29 +00:00
win_sys_util Refactoring: Use super:: instead of crate:: in win_sys_util 2022-03-17 23:57:24 +00:00
win_util Upstream win_util 2022-03-14 20:39:10 +00:00
README.md docs: Use mdformat to format markdown files 2022-01-27 21:29:11 +00:00

Crosvm General Purpose Libraries

The crates in this folder are general purpose libraries used by other projects in ChromeOS as well.

To make them accessible independendly of crosvm, each of these crates is excluded from the crosvm workspace.

List of libraries

  • cros-fuzz: Support crate for fuzzing rust code in ChromeOS
  • p9: Server implementation of the 9p file system protocol