Skip to content

feat: virtual riscv-iommu support#307

Open
liulog wants to merge 2 commits into
syswonder:devfrom
liulog:wip/riscv-viommu
Open

feat: virtual riscv-iommu support#307
liulog wants to merge 2 commits into
syswonder:devfrom
liulog:wip/riscv-viommu

Conversation

@liulog
Copy link
Copy Markdown
Contributor

@liulog liulog commented May 12, 2026

Overview

This PR adds preliminary RISC-V vIOMMU support for guest zones. The current implementation focuses on basic register emulation, 1-level DDT handling, and command queue forwarding, allowing guests to interact with a virtualized RISC-V IOMMU interface while the hypervisor maintains control over the physical IOMMU state.

Supported Features

  • Basic vIOMMU MMIO register emulation
  • 1-level Device Directory Table virtualization
  • Command Queue support

Not Supported Yet

  • IOMMU interrupt handling
  • Advanced DDT modes
    • Only 1-level DDT mode is currently supported.
    • 2-level and 3-level DDT modes are not implemented for guest.
  • Full command set support
    • Some command types and function variants are ignored or reported as unsupported.
  • MSI remapping through the virtual IOMMU
    • MSI page table ownership is retained by the hypervisor.

Test

image

Notes

This implementation is an initial vIOMMU foundation for RISC-V. It provides the minimum register, DDT, and command queue paths needed for early guest interaction, while leaving fault reporting, interrupt delivery, and full feature coverage for future work.

@github-actions github-actions Bot added the feature New feature or request label May 12, 2026
@liulog liulog marked this pull request as draft May 12, 2026 13:37
@liulog liulog marked this pull request as ready for review May 19, 2026 13:03
@liulog liulog requested review from Solicey and ZhongkaiXu May 19, 2026 13:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feature New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant