This is an automated email from Gerrit. Florian Fainelli ([email protected]) just uploaded a new patch set to Gerrit, which you can find at http://openocd.zylin.com/5215
-- gerrit commit de89cc7f0df4967bd3a395c56be090642e6c3362 Author: Florian Fainelli <[email protected]> Date: Wed Jun 5 15:23:33 2019 -0700 armv7a_mmu: Check earlier for PAR read Check earlier that the read of the PAR register was successful instead of starting the decoding and then checking for an error reading that register. Change-Id: Id96c2b2f76d2d1c745fcfa55ad4c1e6db92106f9 Signed-off-by: Florian Fainelli <[email protected]> diff --git a/src/target/armv7a_mmu.c b/src/target/armv7a_mmu.c index 153bfcc..859332a 100644 --- a/src/target/armv7a_mmu.c +++ b/src/target/armv7a_mmu.c @@ -143,14 +143,14 @@ int armv7a_mmu_translate_va_pa(struct target *target, uint32_t va, retval = dpm->instr_read_data_r0(dpm, ARMV4_5_MRC(15, 0, 0, 7, 4, 0), val); + if (retval != ERROR_OK) + goto done; /* decode memory attribute */ NOS = (*val >> 10) & 1; /* Not Outer shareable */ NS = (*val >> 9) & 1; /* Non secure */ INNER = (*val >> 4) & 0x7; OUTER = (*val >> 2) & 0x3; - if (retval != ERROR_OK) - goto done; *val = (*val & ~0xfff) + (va & 0xfff); if (meminfo) { LOG_INFO("%" PRIx32 " : %" PRIx32 " %s outer shareable %s secured", -- _______________________________________________ OpenOCD-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/openocd-devel
