flash/nor/pic32mx: Use 'bool' data type

Change-Id: I9a0b60bc07781401f26df31303b8c04822b7ddc2
Signed-off-by: Marc Schink <dev@zapb.de>
Reviewed-on: http://openocd.zylin.com/5747
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
This commit is contained in:
Marc Schink 2020-07-01 10:26:12 +02:00 committed by Antonio Borneo
parent ad8e1507eb
commit 37196876f6
1 changed files with 4 additions and 4 deletions

View File

@ -95,7 +95,7 @@
#define MX_17x_27x 2 /* PIC32mx17x/27x */ #define MX_17x_27x 2 /* PIC32mx17x/27x */
struct pic32mx_flash_bank { struct pic32mx_flash_bank {
int probed; bool probed;
int dev_type; /* Default 0. 1 for Pic32MX1XX/2XX variant */ int dev_type; /* Default 0. 1 for Pic32MX1XX/2XX variant */
}; };
@ -211,7 +211,7 @@ FLASH_BANK_COMMAND_HANDLER(pic32mx_flash_bank_command)
pic32mx_info = malloc(sizeof(struct pic32mx_flash_bank)); pic32mx_info = malloc(sizeof(struct pic32mx_flash_bank));
bank->driver_priv = pic32mx_info; bank->driver_priv = pic32mx_info;
pic32mx_info->probed = 0; pic32mx_info->probed = false;
pic32mx_info->dev_type = 0; pic32mx_info->dev_type = 0;
return ERROR_OK; return ERROR_OK;
@ -700,7 +700,7 @@ static int pic32mx_probe(struct flash_bank *bank)
uint32_t device_id; uint32_t device_id;
int page_size; int page_size;
pic32mx_info->probed = 0; pic32mx_info->probed = false;
device_id = ejtag_info->idcode; device_id = ejtag_info->idcode;
LOG_INFO("device id = 0x%08" PRIx32 " (manuf 0x%03x dev 0x%04x, ver 0x%02x)", LOG_INFO("device id = 0x%08" PRIx32 " (manuf 0x%03x dev 0x%04x, ver 0x%02x)",
@ -792,7 +792,7 @@ static int pic32mx_probe(struct flash_bank *bank)
bank->sectors[i].is_protected = 1; bank->sectors[i].is_protected = 1;
} }
pic32mx_info->probed = 1; pic32mx_info->probed = true;
return ERROR_OK; return ERROR_OK;
} }