flash_driver_t -> struct flash_driver

Remove misleading typedef and redundant suffix from struct flash_driver.
This commit is contained in:
Zachary T Welch 2009-11-13 07:38:01 -08:00
parent fb59ec739a
commit 632fd663a8
22 changed files with 42 additions and 42 deletions

View File

@ -114,7 +114,7 @@ static bool writeLog = true;
char hwaddr[512];
extern flash_driver_t *flash_drivers[];
extern struct flash_driver *flash_drivers[];
extern target_type_t *target_types[];
#ifdef CYGPKG_PROFILE_GPROF

View File

@ -422,7 +422,7 @@ static int aduc702x_check_flash_completion(target_t* target, unsigned int timeou
else return ERROR_OK;
}
flash_driver_t aduc702x_flash = {
struct flash_driver aduc702x_flash = {
.name = "aduc702x",
.flash_bank_command = &aduc702x_flash_bank_command,
.erase = &aduc702x_erase,

View File

@ -2500,7 +2500,7 @@ sam3_register_commands(struct command_context_s *cmd_ctx)
return ERROR_OK;
}
flash_driver_t at91sam3_flash = {
struct flash_driver at91sam3_flash = {
.name = "at91sam3",
.register_commands = &sam3_register_commands,
.flash_bank_command = &sam3_flash_bank_command,

View File

@ -20,4 +20,4 @@
// nothing to do here other then export this.
extern flash_driver_t at91sam3_flash;
extern struct flash_driver at91sam3_flash;

View File

@ -1191,7 +1191,7 @@ static int at91sam7_register_commands(struct command_context_s *cmd_ctx)
return ERROR_OK;
}
flash_driver_t at91sam7_flash = {
struct flash_driver at91sam7_flash = {
.name = "at91sam7",
.register_commands = &at91sam7_register_commands,
.flash_bank_command = &at91sam7_flash_bank_command,

View File

@ -461,7 +461,7 @@ static int avrf_register_commands(struct command_context_s *cmd_ctx)
return ERROR_OK;
}
flash_driver_t avr_flash = {
struct flash_driver avr_flash = {
.name = "avr",
.register_commands = &avrf_register_commands,
.flash_bank_command = &avrf_flash_bank_command,

View File

@ -2626,7 +2626,7 @@ static int cfi_info(struct flash_bank_s *bank, char *buf, int buf_size)
return ERROR_OK;
}
flash_driver_t cfi_flash = {
struct flash_driver cfi_flash = {
.name = "cfi",
.register_commands = &cfi_register_commands,
.flash_bank_command = &cfi_flash_bank_command,

View File

@ -435,7 +435,7 @@ static int ecosflash_handle_gpnvm_command(struct command_context_s *cmd_ctx, cha
}
#endif
flash_driver_t ecosflash_flash = {
struct flash_driver ecosflash_flash = {
.name = "ecosflash",
.register_commands = &ecosflash_register_commands,
.flash_bank_command = &ecosflash_flash_bank_command,

View File

@ -128,7 +128,7 @@ static int faux_probe(struct flash_bank_s *bank)
return ERROR_OK;
}
flash_driver_t faux_flash = {
struct flash_driver faux_flash = {
.name = "faux",
.register_commands = &faux_register_commands,
.flash_bank_command = &faux_flash_bank_command,

View File

@ -35,26 +35,26 @@ static int flash_write_unlock(target_t *target, image_t *image, uint32_t *writte
/* flash drivers
*/
extern flash_driver_t lpc2000_flash;
extern flash_driver_t lpc288x_flash;
extern flash_driver_t lpc2900_flash;
extern flash_driver_t cfi_flash;
extern flash_driver_t at91sam3_flash;
extern flash_driver_t at91sam7_flash;
extern flash_driver_t str7x_flash;
extern flash_driver_t str9x_flash;
extern flash_driver_t aduc702x_flash;
extern flash_driver_t stellaris_flash;
extern flash_driver_t str9xpec_flash;
extern flash_driver_t stm32x_flash;
extern flash_driver_t tms470_flash;
extern flash_driver_t ecosflash_flash;
extern flash_driver_t ocl_flash;
extern flash_driver_t pic32mx_flash;
extern flash_driver_t avr_flash;
extern flash_driver_t faux_flash;
extern struct flash_driver lpc2000_flash;
extern struct flash_driver lpc288x_flash;
extern struct flash_driver lpc2900_flash;
extern struct flash_driver cfi_flash;
extern struct flash_driver at91sam3_flash;
extern struct flash_driver at91sam7_flash;
extern struct flash_driver str7x_flash;
extern struct flash_driver str9x_flash;
extern struct flash_driver aduc702x_flash;
extern struct flash_driver stellaris_flash;
extern struct flash_driver str9xpec_flash;
extern struct flash_driver stm32x_flash;
extern struct flash_driver tms470_flash;
extern struct flash_driver ecosflash_flash;
extern struct flash_driver ocl_flash;
extern struct flash_driver pic32mx_flash;
extern struct flash_driver avr_flash;
extern struct flash_driver faux_flash;
flash_driver_t *flash_drivers[] = {
struct flash_driver *flash_drivers[] = {
&lpc2000_flash,
&lpc288x_flash,
&lpc2900_flash,

View File

@ -82,7 +82,7 @@ struct flash_bank_s;
* corresponding static <code>flash_driver_<i>callback</i>()</code>
* routine in flash.c.
*/
typedef struct flash_driver_s
struct flash_driver
{
/**
* Gives a human-readable name of this flash driver,
@ -224,7 +224,7 @@ typedef struct flash_driver_s
* @returns ERROR_OK if successful; otherwise, an error code.
*/
int (*auto_probe)(struct flash_bank_s *bank);
} flash_driver_t;
};
#define FLASH_BANK_COMMAND_HANDLER(name) static __FLASH_BANK_COMMAND(name)
@ -242,7 +242,7 @@ typedef struct flash_bank_s
{
struct target_s *target; /**< Target to which this bank belongs. */
flash_driver_t *driver; /**< Driver for this bank. */
struct flash_driver *driver; /**< Driver for this bank. */
void *driver_priv; /**< Private driver storage pointer */
int bank_number; /**< The 'bank' (or chip number) of this instance. */

View File

@ -788,7 +788,7 @@ static int lpc2000_register_commands(struct command_context_s *cmd_ctx)
return ERROR_OK;
}
flash_driver_t lpc2000_flash = {
struct flash_driver lpc2000_flash = {
.name = "lpc2000",
.register_commands = &lpc2000_register_commands,
.flash_bank_command = &lpc2000_flash_bank_command,

View File

@ -471,7 +471,7 @@ static int lpc288x_protect(struct flash_bank_s *bank, int set, int first, int la
return ERROR_OK;
}
flash_driver_t lpc288x_flash = {
struct flash_driver lpc288x_flash = {
.name = "lpc288x",
.flash_bank_command = &lpc288x_flash_bank_command,
.erase = &lpc288x_erase,

View File

@ -1830,7 +1830,7 @@ static int lpc2900_info(struct flash_bank_s *bank, char *buf, int buf_size)
}
flash_driver_t lpc2900_flash =
struct flash_driver lpc2900_flash =
{
.name = "lpc2900",
.register_commands = lpc2900_register_commands,

View File

@ -348,7 +348,7 @@ static int ocl_auto_probe(struct flash_bank_s *bank)
return ERROR_OK;
}
flash_driver_t ocl_flash = {
struct flash_driver ocl_flash = {
.name = "ocl",
.flash_bank_command = &ocl_flash_bank_command,
.erase = &ocl_erase,

View File

@ -904,7 +904,7 @@ static int pic32mx_register_commands(struct command_context_s *cmd_ctx)
return ERROR_OK;
}
flash_driver_t pic32mx_flash = {
struct flash_driver pic32mx_flash = {
.name = "pic32mx",
.register_commands = &pic32mx_register_commands,
.flash_bank_command = &pic32mx_flash_bank_command,

View File

@ -1172,7 +1172,7 @@ static int stellaris_register_commands(struct command_context_s *cmd_ctx)
}
flash_driver_t stellaris_flash = {
struct flash_driver stellaris_flash = {
.name = "stellaris",
.register_commands = &stellaris_register_commands,
.flash_bank_command = &stellaris_flash_bank_command,

View File

@ -1205,7 +1205,7 @@ static int stm32x_register_commands(struct command_context_s *cmd_ctx)
return ERROR_OK;
}
flash_driver_t stm32x_flash = {
struct flash_driver stm32x_flash = {
.name = "stm32x",
.register_commands = &stm32x_register_commands,
.flash_bank_command = &stm32x_flash_bank_command,

View File

@ -683,7 +683,7 @@ static int str7x_register_commands(struct command_context_s *cmd_ctx)
return ERROR_OK;
}
flash_driver_t str7x_flash = {
struct flash_driver str7x_flash = {
.name = "str7x",
.register_commands = &str7x_register_commands,
.flash_bank_command = &str7x_flash_bank_command,

View File

@ -687,7 +687,7 @@ static int str9x_register_commands(struct command_context_s *cmd_ctx)
return ERROR_OK;
}
flash_driver_t str9x_flash = {
struct flash_driver str9x_flash = {
.name = "str9x",
.register_commands = &str9x_register_commands,
.flash_bank_command = &str9x_flash_bank_command,

View File

@ -1205,7 +1205,7 @@ static int str9xpec_register_commands(struct command_context_s *cmd_ctx)
return ERROR_OK;
}
flash_driver_t str9xpec_flash = {
struct flash_driver str9xpec_flash = {
.name = "str9xpec",
.register_commands = &str9xpec_register_commands,
.flash_bank_command = &str9xpec_flash_bank_command,

View File

@ -1236,7 +1236,7 @@ FLASH_BANK_COMMAND_HANDLER(tms470_flash_bank_command)
return ERROR_OK;
}
flash_driver_t tms470_flash = {
struct flash_driver tms470_flash = {
.name = "tms470",
.register_commands = &tms470_register_commands,
.flash_bank_command = &tms470_flash_bank_command,