zero-day-labs / riscv-iommu

IOMMU IP compliant with the RISC-V IOMMU Specification v1.0
Apache License 2.0
66 stars 12 forks source link

[RTL] Fix for issue number 17 and 18 #23

Closed mhayat-10xe closed 2 months ago

mhayat-10xe commented 2 months ago

Description

This PR has the fix for issue #17 and #18.

Changes

  1. Moved the pdte/ddte reserved check directly underneath the pdte/ddte validity check to ensure the second check activates only if the first validity check fails.
  2. Introduced a condition within this block: if ddt_walk is high, cause_code will be set to "DDT Entry Misconfigured"; otherwise, it will be set to "PDT Entry Misconfigured".