Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
lib: sbi: fix number of PMP entries detection
CSR_PMPADDRn lower bits may read all-0 or all-1, depending on the configuration. For TOR it is all-0, for NAPOT - all-1. Thus if PMP entry was pre-configured as NAPOT, original code would stop scanning because value read back not equal to the written one. Mask lower bits before comparison to fix this Signed-off-by: Vladimir Kondratiev <[email protected]>
- Loading branch information