File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -296,7 +296,8 @@ void arc_core_mpu_enable(void)
296
296
* simulate MPU enable
297
297
*/
298
298
#elif CONFIG_ARC_MPU_VER == 3
299
- arc_core_mpu_default (0 );
299
+ #define MPU_ENABLE_ATTR 0
300
+ arc_core_mpu_default (MPU_ENABLE_ATTR );
300
301
#endif
301
302
}
302
303
@@ -506,7 +507,8 @@ void arc_core_mpu_configure_mem_domain(struct k_mem_domain *mem_domain)
506
507
* it doesn't work for memory domain, because the dynamic region numbers.
507
508
* So be careful to avoid the overlap situation.
508
509
*/
509
- for (; region_index < _get_num_regions () - 1 ; region_index ++ ) {
510
+ u32_t num_regions = _get_num_regions () - 1 ;
511
+ for (; region_index < num_regions ; region_index ++ ) {
510
512
#endif
511
513
if (num_partitions && pparts -> size ) {
512
514
SYS_LOG_DBG ("set region 0x%x 0x%x 0x%x" ,
You can’t perform that action at this time.
0 commit comments