Skip to content

Comments

vhost-user: Add support for GET_SHMEM_CONFIG message#339

Open
aesteve-rh wants to merge 1 commit intorust-vmm:mainfrom
aesteve-rh:mmap-backend-cmd
Open

vhost-user: Add support for GET_SHMEM_CONFIG message#339
aesteve-rh wants to merge 1 commit intorust-vmm:mainfrom
aesteve-rh:mmap-backend-cmd

Conversation

@aesteve-rh
Copy link
Contributor

@aesteve-rh aesteve-rh commented Dec 11, 2025

Add support for GET_SHMEM_CONFIG message to retrieve VirtIO Shared Memory Regions configuration.

This is useful when the frontend is unaware of specific backend type and configuration of the memory layout.

Based on the patch [1] which is just waiting for being merged.

[1] -
https://lore.kernel.org/all/20251111091058.879669-1-aesteve@redhat.com/

Summary of the PR

Please summarize here why the changes in this PR are needed.

Requirements

Before submitting your PR, please make sure you addressed the following
requirements:

  • All commits in this PR have Signed-Off-By trailers (with
    git commit -s), and the commit message has max 60 characters for the
    summary and max 75 characters for each description line.
  • All added/changed functionality has a corresponding unit/integration
    test.
  • All added/changed public-facing functionality has entries in the "Upcoming
    Release" section of CHANGELOG.md (if no such section exists, please create one).
  • Any newly added unsafe code is properly documented.

@aesteve-rh
Copy link
Contributor Author

cc @mtjhrc @dorindabassey

@alyssais
Copy link
Contributor

alyssais commented Dec 28, 2025

Shouldn't there be a VhostUserFrontend::get_shmem_config method?

@aesteve-rh
Copy link
Contributor Author

Shouldn't there be a VhostUserFrontend::get_shmem_config method?

True, good catch! Added.

@stefano-garzarella
Copy link
Member

stefano-garzarella commented Jan 8, 2026

CI issues should be unrelated and fixed by #340
Please rebase when it will be merged (just waiting CI results).

@aesteve-rh aesteve-rh force-pushed the mmap-backend-cmd branch 2 times, most recently from 6ab007f to 6b49347 Compare January 9, 2026 09:43
@aesteve-rh aesteve-rh force-pushed the mmap-backend-cmd branch 2 times, most recently from 38a0579 to bfef1da Compare January 19, 2026 10:23
Copy link
Contributor

@alyssais alyssais left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks and sorry for the confusion!

crosvm-bot pushed a commit to google/crosvm that referenced this pull request Jan 23, 2026
This is not intended to be variable size in the spec.  Making it
fixed-size makes the implementation much simpler, and avoids sending
variable-size responses to frontends that may not understand them.

TEST=Run crosvm and another frontend with a crosvm vhost-user GPU device.

Link: rust-vmm/vhost#339 (comment)
Change-Id: I33adad1b3d314f9fc276d1b63b9f79102d919880
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/7486921
Reviewed-by: Frederick Mayle <fmayle@google.com>
Reviewed-by: Gurchetan Singh <gurchetansingh@chromium.org>
Reviewed-by: Sergio Rodriguez <sorama@google.com>
Add support for GET_SHMEM_CONFIG message to retrieve
VirtIO Shared Memory Regions configuration.

This is useful when the frontend is unaware of specific
backend type and configuration of the memory layout.

Based on the patch [1] which is just waiting for being
merged.

[1] -
https://lore.kernel.org/all/20251111091058.879669-1-aesteve@redhat.com/

Signed-off-by: Albert Esteve <aesteve@redhat.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants