summaryrefslogtreecommitdiff
path: root/src/flash
diff options
context:
space:
mode:
Diffstat (limited to 'src/flash')
-rw-r--r--src/flash/at91sam3.c4
-rw-r--r--src/flash/at91sam7.c2
-rw-r--r--src/flash/avrf.c2
-rw-r--r--src/flash/cfi.c2
-rw-r--r--src/flash/davinci_nand.c2
-rw-r--r--src/flash/ecos.c6
-rw-r--r--src/flash/faux.c2
-rw-r--r--src/flash/flash.c8
-rw-r--r--src/flash/flash.h8
-rw-r--r--src/flash/lpc2000.c2
-rw-r--r--src/flash/lpc2900.c2
-rw-r--r--src/flash/lpc3180_nand_controller.c2
-rw-r--r--src/flash/mflash.c4
-rw-r--r--src/flash/mflash.h4
-rw-r--r--src/flash/mx3_nand.c2
-rw-r--r--src/flash/nand.c6
-rw-r--r--src/flash/nand.h8
-rw-r--r--src/flash/orion_nand.c2
-rw-r--r--src/flash/pic32mx.c2
-rw-r--r--src/flash/s3c24xx_nand.c2
-rw-r--r--src/flash/s3c24xx_nand.h2
-rw-r--r--src/flash/stellaris.c2
-rw-r--r--src/flash/stm32x.c2
-rw-r--r--src/flash/str7x.c2
-rw-r--r--src/flash/str9x.c2
-rw-r--r--src/flash/str9xpec.c2
-rw-r--r--src/flash/tms470.c2
27 files changed, 43 insertions, 43 deletions
diff --git a/src/flash/at91sam3.c b/src/flash/at91sam3.c
index b756e48f..4459364e 100644
--- a/src/flash/at91sam3.c
+++ b/src/flash/at91sam3.c
@@ -231,7 +231,7 @@ struct sam3_reg_list {
static struct sam3_chip *all_sam3_chips;
static struct sam3_chip *
-get_current_sam3(struct command_context_s *cmd_ctx)
+get_current_sam3(struct command_context *cmd_ctx)
{
struct target *t;
static struct sam3_chip *p;
@@ -2472,7 +2472,7 @@ COMMAND_HANDLER(sam3_handle_slowclk_command)
static int sam3_registered;
static int
-sam3_register_commands(struct command_context_s *cmd_ctx)
+sam3_register_commands(struct command_context *cmd_ctx)
{
command_t *pCmd;
diff --git a/src/flash/at91sam7.c b/src/flash/at91sam7.c
index 8f870bc0..18cfb986 100644
--- a/src/flash/at91sam7.c
+++ b/src/flash/at91sam7.c
@@ -1178,7 +1178,7 @@ COMMAND_HANDLER(at91sam7_handle_gpnvm_command)
return ERROR_OK;
}
-static int at91sam7_register_commands(struct command_context_s *cmd_ctx)
+static int at91sam7_register_commands(struct command_context *cmd_ctx)
{
command_t *at91sam7_cmd = register_command(cmd_ctx, NULL, "at91sam7",
NULL, COMMAND_ANY, NULL);
diff --git a/src/flash/avrf.c b/src/flash/avrf.c
index 9df254ea..ea9f0833 100644
--- a/src/flash/avrf.c
+++ b/src/flash/avrf.c
@@ -449,7 +449,7 @@ COMMAND_HANDLER(avrf_handle_mass_erase_command)
return ERROR_OK;
}
-static int avrf_register_commands(struct command_context_s *cmd_ctx)
+static int avrf_register_commands(struct command_context *cmd_ctx)
{
command_t *avr_cmd = register_command(cmd_ctx, NULL, "avr",
NULL, COMMAND_ANY, "avr flash specific commands");
diff --git a/src/flash/cfi.c b/src/flash/cfi.c
index dd393de2..d49ddf31 100644
--- a/src/flash/cfi.c
+++ b/src/flash/cfi.c
@@ -588,7 +588,7 @@ static int cfi_intel_info(struct flash_bank *bank, char *buf, int buf_size)
return ERROR_OK;
}
-static int cfi_register_commands(struct command_context_s *cmd_ctx)
+static int cfi_register_commands(struct command_context *cmd_ctx)
{
/*command_t *cfi_cmd = */
register_command(cmd_ctx, NULL, "cfi", NULL, COMMAND_ANY, "flash bank cfi <base> <size> <chip_width> <bus_width> <targetNum> [jedec_probe/x16_as_x8]");
diff --git a/src/flash/davinci_nand.c b/src/flash/davinci_nand.c
index 4cef4084..413bcda4 100644
--- a/src/flash/davinci_nand.c
+++ b/src/flash/davinci_nand.c
@@ -78,7 +78,7 @@ static int halted(struct target *target, const char *label)
return false;
}
-static int davinci_register_commands(struct command_context_s *cmd_ctx)
+static int davinci_register_commands(struct command_context *cmd_ctx)
{
return ERROR_OK;
}
diff --git a/src/flash/ecos.c b/src/flash/ecos.c
index da354073..0525fbe3 100644
--- a/src/flash/ecos.c
+++ b/src/flash/ecos.c
@@ -30,7 +30,7 @@
static uint32_t ecosflash_get_flash_status(struct flash_bank *bank);
static void ecosflash_set_flash_mode(struct flash_bank *bank,int mode);
static uint32_t ecosflash_wait_status_busy(struct flash_bank *bank, uint32_t waitbits, int timeout);
-static int ecosflash_handle_gpnvm_command(struct command_context_s *cmd_ctx, char *cmd, char **args, int argc);
+static int ecosflash_handle_gpnvm_command(struct command_context *cmd_ctx, char *cmd, char **args, int argc);
#endif
struct ecosflash_flash_bank
@@ -334,7 +334,7 @@ static int ecosflash_probe(struct flash_bank *bank)
return ERROR_OK;
}
-static int ecosflash_register_commands(struct command_context_s *cmd_ctx)
+static int ecosflash_register_commands(struct command_context *cmd_ctx)
{
register_command(cmd_ctx, NULL, "ecosflash", NULL, COMMAND_ANY, NULL);
@@ -429,7 +429,7 @@ static uint32_t ecosflash_wait_status_busy(struct flash_bank *bank, uint32_t wai
return ERROR_OK;
}
-static int ecosflash_handle_gpnvm_command(struct command_context_s *cmd_ctx, char *cmd, char **args, int argc)
+static int ecosflash_handle_gpnvm_command(struct command_context *cmd_ctx, char *cmd, char **args, int argc)
{
return ERROR_OK;
}
diff --git a/src/flash/faux.c b/src/flash/faux.c
index 55e9892c..b048fcb0 100644
--- a/src/flash/faux.c
+++ b/src/flash/faux.c
@@ -87,7 +87,7 @@ FLASH_BANK_COMMAND_HANDLER(faux_flash_bank_command)
return ERROR_OK;
}
-static int faux_register_commands(struct command_context_s *cmd_ctx)
+static int faux_register_commands(struct command_context *cmd_ctx)
{
return ERROR_OK;
}
diff --git a/src/flash/flash.c b/src/flash/flash.c
index 96c63d54..32c1f490 100644
--- a/src/flash/flash.c
+++ b/src/flash/flash.c
@@ -199,7 +199,7 @@ struct flash_bank *get_flash_bank_by_num(int num)
}
int flash_command_get_bank_by_num(
- struct command_context_s *cmd_ctx, const char *str, struct flash_bank **bank)
+ struct command_context *cmd_ctx, const char *str, struct flash_bank **bank)
{
unsigned bank_num;
COMMAND_PARSE_NUMBER(uint, str, bank_num);
@@ -511,7 +511,7 @@ COMMAND_HANDLER(handle_flash_protect_check_command)
return ERROR_OK;
}
-static int flash_check_sector_parameters(struct command_context_s *cmd_ctx,
+static int flash_check_sector_parameters(struct command_context *cmd_ctx,
uint32_t first, uint32_t last, uint32_t num_sectors)
{
if (!(first <= last)) {
@@ -1217,7 +1217,7 @@ int default_flash_blank_check(struct flash_bank *bank)
return ERROR_OK;
}
-int flash_init_drivers(struct command_context_s *cmd_ctx)
+int flash_init_drivers(struct command_context *cmd_ctx)
{
register_jim(cmd_ctx, "ocd_flash_banks",
jim_flash_banks, "return information about the flash banks");
@@ -1267,7 +1267,7 @@ int flash_init_drivers(struct command_context_s *cmd_ctx)
return ERROR_OK;
}
-int flash_register_commands(struct command_context_s *cmd_ctx)
+int flash_register_commands(struct command_context *cmd_ctx)
{
flash_cmd = register_command(cmd_ctx, NULL, "flash",
NULL, COMMAND_ANY, NULL);
diff --git a/src/flash/flash.h b/src/flash/flash.h
index 202a5e52..4651fc36 100644
--- a/src/flash/flash.h
+++ b/src/flash/flash.h
@@ -97,7 +97,7 @@ struct flash_driver
*
* @returns ERROR_OK if successful; otherwise, an error code.
*/
- int (*register_commands)(struct command_context_s *cmd_ctx);
+ int (*register_commands)(struct command_context *cmd_ctx);
/**
* Finish the "flash bank" command for @a bank. The
@@ -265,9 +265,9 @@ struct flash_bank
};
/// Registers the 'flash' subsystem commands
-int flash_register_commands(struct command_context_s *cmd_ctx);
+int flash_register_commands(struct command_context *cmd_ctx);
/// Initializes the 'flash' subsystem drivers
-int flash_init_drivers(struct command_context_s *cmd_ctx);
+int flash_init_drivers(struct command_context *cmd_ctx);
/**
* Erases @a length bytes in the @a target flash, starting at @a addr.
@@ -323,7 +323,7 @@ struct flash_bank *get_flash_bank_by_num(int num);
* @param bank On output, contians a pointer to the bank or NULL.
* @returns ERROR_OK on success, or an error indicating the problem.
*/
-int flash_command_get_bank_by_num(struct command_context_s *cmd_ctx,
+int flash_command_get_bank_by_num(struct command_context *cmd_ctx,
const char *str, struct flash_bank **bank);
/**
* Returns the flash bank like get_flash_bank_by_num(), without probing.
diff --git a/src/flash/lpc2000.c b/src/flash/lpc2000.c
index 36ebc0ec..f3d7e5b4 100644
--- a/src/flash/lpc2000.c
+++ b/src/flash/lpc2000.c
@@ -776,7 +776,7 @@ COMMAND_HANDLER(lpc2000_handle_part_id_command)
return ERROR_OK;
}
-static int lpc2000_register_commands(struct command_context_s *cmd_ctx)
+static int lpc2000_register_commands(struct command_context *cmd_ctx)
{
command_t *lpc2000_cmd = register_command(cmd_ctx, NULL, "lpc2000",
NULL, COMMAND_ANY, NULL);
diff --git a/src/flash/lpc2900.c b/src/flash/lpc2900.c
index d385a302..4cf20921 100644
--- a/src/flash/lpc2900.c
+++ b/src/flash/lpc2900.c
@@ -952,7 +952,7 @@ COMMAND_HANDLER(lpc2900_handle_secure_jtag_command)
/**
* Register private command handlers.
*/
-static int lpc2900_register_commands(struct command_context_s *cmd_ctx)
+static int lpc2900_register_commands(struct command_context *cmd_ctx)
{
command_t *lpc2900_cmd = register_command(cmd_ctx, NULL, "lpc2900",
NULL, COMMAND_ANY, NULL);
diff --git a/src/flash/lpc3180_nand_controller.c b/src/flash/lpc3180_nand_controller.c
index 4a15e364..ffa50557 100644
--- a/src/flash/lpc3180_nand_controller.c
+++ b/src/flash/lpc3180_nand_controller.c
@@ -873,7 +873,7 @@ COMMAND_HANDLER(handle_lpc3180_select_command)
return ERROR_OK;
}
-static int lpc3180_register_commands(struct command_context_s *cmd_ctx)
+static int lpc3180_register_commands(struct command_context *cmd_ctx)
{
command_t *lpc3180_cmd = register_command(cmd_ctx, NULL, "lpc3180", NULL, COMMAND_ANY, "commands specific to the LPC3180 NAND flash controllers");
diff --git a/src/flash/mflash.c b/src/flash/mflash.c
index 698cd16e..029178d1 100644
--- a/src/flash/mflash.c
+++ b/src/flash/mflash.c
@@ -1265,7 +1265,7 @@ COMMAND_HANDLER(mg_config_cmd)
}
}
-int mflash_init_drivers(struct command_context_s *cmd_ctx)
+int mflash_init_drivers(struct command_context *cmd_ctx)
{
if (mflash_bank) {
register_command(cmd_ctx, mflash_cmd, "probe", mg_probe_cmd, COMMAND_EXEC, NULL);
@@ -1320,7 +1320,7 @@ COMMAND_HANDLER(mg_bank_cmd)
return ERROR_OK;
}
-int mflash_register_commands(struct command_context_s *cmd_ctx)
+int mflash_register_commands(struct command_context *cmd_ctx)
{
mflash_cmd = register_command(cmd_ctx, NULL, "mflash", NULL, COMMAND_ANY, NULL);
register_command(cmd_ctx, mflash_cmd, "bank", mg_bank_cmd, COMMAND_CONFIG,
diff --git a/src/flash/mflash.h b/src/flash/mflash.h
index a2bd5b3a..ed4a2cdd 100644
--- a/src/flash/mflash.h
+++ b/src/flash/mflash.h
@@ -141,8 +141,8 @@ struct mflash_bank
struct mg_drv_info *drv_info;
};
-int mflash_register_commands(struct command_context_s *cmd_ctx);
-int mflash_init_drivers(struct command_context_s *cmd_ctx);
+int mflash_register_commands(struct command_context *cmd_ctx);
+int mflash_init_drivers(struct command_context *cmd_ctx);
#define MG_MFLASH_SECTOR_SIZE (0x200) /* 512Bytes = 2^9 */
#define MG_MFLASH_SECTOR_SIZE_MASK (0x200-1)
diff --git a/src/flash/mx3_nand.c b/src/flash/mx3_nand.c
index 6c699179..45d2a323 100644
--- a/src/flash/mx3_nand.c
+++ b/src/flash/mx3_nand.c
@@ -315,7 +315,7 @@ static int imx31_nand_ready (struct nand_device *nand, int timeout)
return imx31_controller_ready (nand, timeout);
}
-static int imx31_register_commands (struct command_context_s *cmd_ctx)
+static int imx31_register_commands (struct command_context *cmd_ctx)
{
return ERROR_OK;
}
diff --git a/src/flash/nand.c b/src/flash/nand.c
index 48f65206..4094effc 100644
--- a/src/flash/nand.c
+++ b/src/flash/nand.c
@@ -279,7 +279,7 @@ COMMAND_HANDLER(handle_nand_device_command)
return ERROR_OK;
}
-int nand_register_commands(struct command_context_s *cmd_ctx)
+int nand_register_commands(struct command_context *cmd_ctx)
{
nand_cmd = register_command(cmd_ctx, NULL, "nand", NULL, COMMAND_ANY, "NAND specific commands");
@@ -304,7 +304,7 @@ struct nand_device *get_nand_device_by_num(int num)
return NULL;
}
-int nand_command_get_device_by_num(struct command_context_s *cmd_ctx,
+int nand_command_get_device_by_num(struct command_context *cmd_ctx,
const char *str, struct nand_device **nand)
{
unsigned num;
@@ -1602,7 +1602,7 @@ COMMAND_HANDLER(handle_nand_raw_access_command)
return ERROR_OK;
}
-int nand_init(struct command_context_s *cmd_ctx)
+int nand_init(struct command_context *cmd_ctx)
{
if (!nand_devices)
return ERROR_OK;
diff --git a/src/flash/nand.h b/src/flash/nand.h
index 80963095..afec9a77 100644
--- a/src/flash/nand.h
+++ b/src/flash/nand.h
@@ -36,7 +36,7 @@ struct nand_flash_controller
{
char *name;
__NAND_DEVICE_COMMAND((*nand_device_command));
- int (*register_commands)(struct command_context_s *cmd_ctx);
+ int (*register_commands)(struct command_context *cmd_ctx);
int (*init)(struct nand_device *nand);
int (*reset)(struct nand_device *nand);
int (*command)(struct nand_device *nand, uint8_t command);
@@ -226,11 +226,11 @@ int nand_calculate_ecc(struct nand_device *nand,
int nand_calculate_ecc_kw(struct nand_device *nand,
const uint8_t *dat, uint8_t *ecc_code);
-int nand_register_commands(struct command_context_s *cmd_ctx);
-int nand_init(struct command_context_s *cmd_ctx);
+int nand_register_commands(struct command_context *cmd_ctx);
+int nand_init(struct command_context *cmd_ctx);
/// helper for parsing a nand device command argument string
-int nand_command_get_device_by_num(struct command_context_s *cmd_ctx,
+int nand_command_get_device_by_num(struct command_context *cmd_ctx,
const char *str, struct nand_device **nand);
diff --git a/src/flash/orion_nand.c b/src/flash/orion_nand.c
index 0d4e1ea8..4235b085 100644
--- a/src/flash/orion_nand.c
+++ b/src/flash/orion_nand.c
@@ -120,7 +120,7 @@ static int orion_nand_controller_ready(struct nand_device *nand, int timeout)
return 1;
}
-static int orion_nand_register_commands(struct command_context_s *cmd_ctx)
+static int orion_nand_register_commands(struct command_context *cmd_ctx)
{
return ERROR_OK;
}
diff --git a/src/flash/pic32mx.c b/src/flash/pic32mx.c
index e19ee950..bb3d69c1 100644
--- a/src/flash/pic32mx.c
+++ b/src/flash/pic32mx.c
@@ -883,7 +883,7 @@ COMMAND_HANDLER(pic32mx_handle_pgm_word_command)
return ERROR_OK;
}
-static int pic32mx_register_commands(struct command_context_s *cmd_ctx)
+static int pic32mx_register_commands(struct command_context *cmd_ctx)
{
command_t *pic32mx_cmd = register_command(cmd_ctx, NULL, "pic32mx",
NULL, COMMAND_ANY, "pic32mx flash specific commands");
diff --git a/src/flash/s3c24xx_nand.c b/src/flash/s3c24xx_nand.c
index 5b2d191f..75b8700c 100644
--- a/src/flash/s3c24xx_nand.c
+++ b/src/flash/s3c24xx_nand.c
@@ -52,7 +52,7 @@ S3C24XX_DEVICE_COMMAND()
return ERROR_OK;
}
-int s3c24xx_register_commands(struct command_context_s *cmd_ctx)
+int s3c24xx_register_commands(struct command_context *cmd_ctx)
{
return ERROR_OK;
}
diff --git a/src/flash/s3c24xx_nand.h b/src/flash/s3c24xx_nand.h
index 41c95f52..4829c7c4 100644
--- a/src/flash/s3c24xx_nand.h
+++ b/src/flash/s3c24xx_nand.h
@@ -59,7 +59,7 @@ S3C24XX_DEVICE_COMMAND();
return retval; \
} while (0)
-int s3c24xx_register_commands(struct command_context_s *cmd_ctx);
+int s3c24xx_register_commands(struct command_context *cmd_ctx);
int s3c24xx_reset(struct nand_device *nand);
diff --git a/src/flash/stellaris.c b/src/flash/stellaris.c
index efda8590..910d047d 100644
--- a/src/flash/stellaris.c
+++ b/src/flash/stellaris.c
@@ -1160,7 +1160,7 @@ COMMAND_HANDLER(stellaris_handle_mass_erase_command)
return ERROR_OK;
}
-static int stellaris_register_commands(struct command_context_s *cmd_ctx)
+static int stellaris_register_commands(struct command_context *cmd_ctx)
{
command_t *stm32x_cmd = register_command(cmd_ctx, NULL, "stellaris",
NULL, COMMAND_ANY, "stellaris flash specific commands");
diff --git a/src/flash/stm32x.c b/src/flash/stm32x.c
index cf842fcf..abbf6cb6 100644
--- a/src/flash/stm32x.c
+++ b/src/flash/stm32x.c
@@ -1181,7 +1181,7 @@ COMMAND_HANDLER(stm32x_handle_mass_erase_command)
return ERROR_OK;
}
-static int stm32x_register_commands(struct command_context_s *cmd_ctx)
+static int stm32x_register_commands(struct command_context *cmd_ctx)
{
command_t *stm32x_cmd = register_command(cmd_ctx, NULL, "stm32x",
NULL, COMMAND_ANY, "stm32x flash specific commands");
diff --git a/src/flash/str7x.c b/src/flash/str7x.c
index fa235509..83070134 100644
--- a/src/flash/str7x.c
+++ b/src/flash/str7x.c
@@ -671,7 +671,7 @@ COMMAND_HANDLER(str7x_handle_disable_jtag_command)
return ERROR_OK;
}
-static int str7x_register_commands(struct command_context_s *cmd_ctx)
+static int str7x_register_commands(struct command_context *cmd_ctx)
{
command_t *str7x_cmd = register_command(cmd_ctx, NULL, "str7x",
NULL, COMMAND_ANY, "str7x flash specific commands");
diff --git a/src/flash/str9x.c b/src/flash/str9x.c
index b3e8dffc..a06bd1ec 100644
--- a/src/flash/str9x.c
+++ b/src/flash/str9x.c
@@ -675,7 +675,7 @@ COMMAND_HANDLER(str9x_handle_flash_config_command)
return ERROR_OK;
}
-static int str9x_register_commands(struct command_context_s *cmd_ctx)
+static int str9x_register_commands(struct command_context *cmd_ctx)
{
command_t *str9x_cmd = register_command(cmd_ctx, NULL, "str9x",
NULL, COMMAND_ANY, "str9x flash commands");
diff --git a/src/flash/str9xpec.c b/src/flash/str9xpec.c
index 6c42ce3e..03a8ea2e 100644
--- a/src/flash/str9xpec.c
+++ b/src/flash/str9xpec.c
@@ -1163,7 +1163,7 @@ COMMAND_HANDLER(str9xpec_handle_flash_disable_turbo_command)
return ERROR_OK;
}
-static int str9xpec_register_commands(struct command_context_s *cmd_ctx)
+static int str9xpec_register_commands(struct command_context *cmd_ctx)
{
command_t *str9xpec_cmd = register_command(cmd_ctx, NULL, "str9xpec",
NULL, COMMAND_ANY, "str9xpec flash specific commands");
diff --git a/src/flash/tms470.c b/src/flash/tms470.c
index 6e1516f3..a5f2f36a 100644
--- a/src/flash/tms470.c
+++ b/src/flash/tms470.c
@@ -817,7 +817,7 @@ static int tms470_erase_sector(struct flash_bank *bank, int sector)
Implementation of Flash Driver Interfaces
---------------------------------------------------------------------- */
-static int tms470_register_commands(struct command_context_s *cmd_ctx)
+static int tms470_register_commands(struct command_context *cmd_ctx)
{
command_t *tms470_cmd = register_command(cmd_ctx, NULL, "tms470", NULL, COMMAND_ANY, "applies to TI tms470 family");