arm: Use different enum for core_type and core_mode

The fields core_type and core_mode use the same enum arm_mode
but encode different information, making the code less immediate
to read.

Use a different enum arm_core_type for the field core_type.
The code behavior is not changed.

Change-Id: I60f2095ea6801dfe22f6da81ec295ca71ef90466
Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
Reviewed-on: http://openocd.zylin.com/5258
Tested-by: jenkins
This commit is contained in:
Antonio Borneo
2019-06-24 17:15:33 +02:00
parent f447c31b30
commit fba438fde7
7 changed files with 33 additions and 24 deletions

View File

@@ -2787,7 +2787,7 @@ static int cortex_a_examine_first(struct target *target)
}
}
armv7a->arm.core_type = ARM_MODE_MON;
armv7a->arm.core_type = ARM_CORE_TYPE_SEC_EXT;
/* Avoid recreating the registers cache */
if (!target_was_examined(target)) {