The specifications stated in section 2.3.1 "Process to locate the Device-context":
If DC.tc.v == 0, stop and report "DDT entry not valid" (cause = 258).
If the DC is misconfigured as determined by the rules outlined in Section 2.1.4, then stop and report "DDT entry misconfigured" (cause = 259).
However, in our case when DC.tc.v == 0, satisfying point 9, and simultaneously DC.tc.gade == 1, satisfying point 10, preference should be given to point 9 and should give cause = 258 but RTL is giving preference to point number 10, and giving cause = 259 which is wrong.
Here is the counter Example of a violation of specs where in the third cycle there is ddt_walk_o and in the fourth cycle dc.tc.v == 0 and dc.tc.gade == 1 which should result in cause_n == 257 but it is giving cause_n == 258 which is a violation of specs.
The specifications stated in section 2.3.1 "Process to locate the Device-context":
However, in our case when DC.tc.v == 0, satisfying point 9, and simultaneously DC.tc.gade == 1, satisfying point 10, preference should be given to point 9 and should give cause = 258 but RTL is giving preference to point number 10, and giving cause = 259 which is wrong.
Here is the counter Example of a violation of specs where in the third cycle there is ddt_walk_o and in the fourth cycle dc.tc.v == 0 and dc.tc.gade == 1 which should result in cause_n == 257 but it is giving cause_n == 258 which is a violation of specs.![image](https://github.com/zero-day-labs/riscv-iommu/assets/140173282/f2e7275b-ae6f-49ef-85cf-d0faec9ae754)