diff options
author | Paul Beesley <paul.beesley@arm.com> | 2019-08-13 11:20:25 +0000 |
---|---|---|
committer | TrustedFirmware Code Review <review@review.trustedfirmware.org> | 2019-08-13 11:20:25 +0000 |
commit | a8ab58e9b291297f3484624a11b24039cb4e1ee8 (patch) | |
tree | b430be4870c855be4c72a65415fcbae560d81d89 /lib/xlat_tables/aarch32/nonlpae_tables.c | |
parent | 3e516bef12fde665bc90682953514c6de3462376 (diff) | |
parent | 9624c0a9e03ea01d3015beafb0a90cd9afd97eb0 (diff) |
Merge changes from topic "jc/coverity-fixes" into integration
* changes:
Fix Coverity #261967, Infinite loop
Fix Coverity #343017, Missing unlock
Fix Coverity #343008, Side affect in assertion
Fix Coverity #342970, Uninitialized scalar variable
Diffstat (limited to 'lib/xlat_tables/aarch32/nonlpae_tables.c')
-rw-r--r-- | lib/xlat_tables/aarch32/nonlpae_tables.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/xlat_tables/aarch32/nonlpae_tables.c b/lib/xlat_tables/aarch32/nonlpae_tables.c index e31f9d84..bd6b152e 100644 --- a/lib/xlat_tables/aarch32/nonlpae_tables.c +++ b/lib/xlat_tables/aarch32/nonlpae_tables.c @@ -1,6 +1,6 @@ /* * Copyright (c) 2016-2017, Linaro Limited. All rights reserved. - * Copyright (c) 2014-2017, Arm Limited. All rights reserved. + * Copyright (c) 2014-2019, Arm Limited. All rights reserved. * Copyright (c) 2014, STMicroelectronics International N.V. * All rights reserved. * @@ -445,7 +445,8 @@ static mmap_region_t *init_xlation_table_inner(mmap_region_t *mm, } else { xlat_table = (unsigned long)mmu_l2_base + next_xlat * MMU32B_L2_TABLE_SIZE; - assert(++next_xlat <= MAX_XLAT_TABLES); + next_xlat++; + assert(next_xlat <= MAX_XLAT_TABLES); memset((char *)xlat_table, 0, MMU32B_L2_TABLE_SIZE); |