target: Use 'bool' data type in mmu()
The variable is already used in some parts of the code as boolean value but have the wrong data type. Change-Id: I50ccbf84c6f33a3034de989789c6b17312458ea8 Signed-off-by: Marc Schink <dev@zapb.de> Reviewed-on: https://review.openocd.org/c/openocd/+/8989 Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com> Tested-by: jenkins
This commit is contained in:
committed by
Antonio Borneo
parent
a66e6fb43f
commit
325e6d38b5
@@ -650,9 +650,9 @@ static int identity_virt2phys(struct target *target,
|
||||
return ERROR_OK;
|
||||
}
|
||||
|
||||
static int no_mmu(struct target *target, int *enabled)
|
||||
static int no_mmu(struct target *target, bool *enabled)
|
||||
{
|
||||
*enabled = 0;
|
||||
*enabled = false;
|
||||
return ERROR_OK;
|
||||
}
|
||||
|
||||
@@ -1978,7 +1978,7 @@ int target_alloc_working_area_try(struct target *target, uint32_t size, struct w
|
||||
/* Reevaluate working area address based on MMU state*/
|
||||
if (!target->working_areas) {
|
||||
int retval;
|
||||
int enabled;
|
||||
bool enabled;
|
||||
|
||||
retval = target->type->mmu(target, &enabled);
|
||||
if (retval != ERROR_OK)
|
||||
|
||||
Reference in New Issue
Block a user