Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 22 additions & 0 deletions arch/arm64/core/xen/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -33,3 +33,25 @@ config XEN_INTERFACE_VERSION
help
Xen interface version to use. This is the version of the
interface that Zephyr will use to communicate with the hypervisor.

config XEN_DOMCTL_INTERFACE_VERSION
hex "Xen Domctl interface version"
default 0x17
range 0x15 0x17
depends on XEN
help
Xen Domctl interface version to use. This is the version of the
domctl interface that Zephyr will use to communicate with
the hypervisor. The default value is the latest version supported
by the kernel.

config XEN_SYSCTL_INTERFACE_VERSION
hex "Xen Sysctl interface version"
default 0x15
range 0x15 0x15
depends on XEN
help
Xen Sysctl interface version to use. This is the version of the
domctl interface that Zephyr will use to communicate with
the hypervisor. The default value is the latest version supported
by the kernel.
5 changes: 4 additions & 1 deletion arch/arm64/core/xen/hypercall.S
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/* SPDX-License-Identifier: Apache-2.0 */
/*
* Copyright (c) 2021-2023 EPAM Systems
* Copyright (c) 2021-2025 EPAM Systems
*/

#include <zephyr/toolchain.h>
Expand All @@ -23,7 +23,10 @@ HYPERCALL(sched_op);
HYPERCALL(event_channel_op);
HYPERCALL(hvm_op);
HYPERCALL(memory_op);
HYPERCALL(dm_op);
Copy link
Contributor

Choose a reason for hiding this comment

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

Generic comment regarding commit message for arch: arm64: core: xen: hypercall: Add dm_op hypercall:

You need to not only describe what was added, but also explain why it is needed in Zephyr and how it will be used.

Copy link
Member Author

Choose a reason for hiding this comment

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

I have separated the PR to #96727. This has also been looked at. I think it will be merged soon, so I plan to rebase it. Thank you.

HYPERCALL(xen_version);

#ifdef CONFIG_XEN_DOM0
HYPERCALL(domctl);
HYPERCALL(sysctl);
#endif
1 change: 1 addition & 0 deletions drivers/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ add_subdirectory_ifdef(CONFIG_STEPPER stepper)
add_subdirectory_ifdef(CONFIG_SYSCON syscon)
add_subdirectory_ifdef(CONFIG_SYS_CLOCK_EXISTS timer)
add_subdirectory_ifdef(CONFIG_TEE tee)
add_subdirectory_ifdef(CONFIG_VHOST vhost)
add_subdirectory_ifdef(CONFIG_VIDEO video)
add_subdirectory_ifdef(CONFIG_VIRTIO virtio)
add_subdirectory_ifdef(CONFIG_VIRTUALIZATION virtualization)
Expand Down
1 change: 1 addition & 0 deletions drivers/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,7 @@ source "drivers/syscon/Kconfig"
source "drivers/timer/Kconfig"
source "drivers/usb/Kconfig"
source "drivers/usb_c/Kconfig"
source "drivers/vhost/Kconfig"
source "drivers/video/Kconfig"
source "drivers/virtio/Kconfig"
source "drivers/virtualization/Kconfig"
Expand Down
7 changes: 7 additions & 0 deletions drivers/vhost/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# Copyright (c) 2025 TOKITA Hiroshi
# SPDX-License-Identifier: Apache-2.0

zephyr_library()

zephyr_library_sources_ifdef(CONFIG_VHOST vringh.c)
zephyr_library_sources_ifdef(CONFIG_VHOST_XEN_MMIO vhost_xen_mmio.c)
24 changes: 24 additions & 0 deletions drivers/vhost/Kconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# Copyright (c) 2025 TOKITA Hiroshi
# SPDX-License-Identifier: Apache-2.0

config VHOST
bool "support for VIRTIO"
help
Enable options for VIRTIO

if VHOST

config VHOST_XEN_MMIO
bool "support for MMIO-based VIRTIO backend on Xen hypervisor"
default y
depends on DT_HAS_XEN_VHOST_MMIO_ENABLED
select XEN_STORE_CLI
select XEN_DMOP
help
Enable VIRTIO-MMIO backend on Xen hypervisor

endif # VIRTIO

module = VHOST
module-str = VHOST
source "subsys/logging/Kconfig.template.log_config"
Loading
Loading