riscv-non-isa/riscv-iommu

Question about page request fault report related to iommu_mode in model

Closed this issue · 1 comments

From the handle_page_request in libiommu/src/iommu_ats.c, when ddtp.iommu_mode is OFF or Bare, the response code is missing here. According to the spec, Response Failure response should be added when ddtp.iommu_mode is OFF and Invalid Request response should be added when ddtp.iommu_mode is Bare.

Additionally, in such case, is fault report still needed? From the spec, such case is not listed in the conditions described in Chapter 2.7.

If fault report is needed, similar with Chapter 2.3, would the cause be like
(1) ddtp.iommu_mode is OFF -> cause 256,
(2) ddtp.iommu_mode is Bare -> cause 260 ?

Please help to check.

The missing check in handle_page_request is added by PR #301 . The section 2.7 notes the 3 cases where faults are not logged - for all other cases the faults are logged. Added the cause code to the list in 2f57efc