str9x_flash_bank_t -> struct str9x_flash_bank
Remove misleading typedef and redundant suffix from struct str9x_flash_bank.
This commit is contained in:
parent
774d71f2cf
commit
6aa82891b6
|
@ -35,7 +35,7 @@ static uint32_t bank1start = 0x00080000;
|
||||||
|
|
||||||
static int str9x_build_block_list(struct flash_bank_s *bank)
|
static int str9x_build_block_list(struct flash_bank_s *bank)
|
||||||
{
|
{
|
||||||
str9x_flash_bank_t *str9x_info = bank->driver_priv;
|
struct str9x_flash_bank *str9x_info = bank->driver_priv;
|
||||||
|
|
||||||
int i;
|
int i;
|
||||||
int num_sectors;
|
int num_sectors;
|
||||||
|
@ -118,7 +118,7 @@ static int str9x_build_block_list(struct flash_bank_s *bank)
|
||||||
*/
|
*/
|
||||||
FLASH_BANK_COMMAND_HANDLER(str9x_flash_bank_command)
|
FLASH_BANK_COMMAND_HANDLER(str9x_flash_bank_command)
|
||||||
{
|
{
|
||||||
str9x_flash_bank_t *str9x_info;
|
struct str9x_flash_bank *str9x_info;
|
||||||
|
|
||||||
if (argc < 6)
|
if (argc < 6)
|
||||||
{
|
{
|
||||||
|
@ -126,7 +126,7 @@ FLASH_BANK_COMMAND_HANDLER(str9x_flash_bank_command)
|
||||||
return ERROR_FLASH_BANK_INVALID;
|
return ERROR_FLASH_BANK_INVALID;
|
||||||
}
|
}
|
||||||
|
|
||||||
str9x_info = malloc(sizeof(str9x_flash_bank_t));
|
str9x_info = malloc(sizeof(struct str9x_flash_bank));
|
||||||
bank->driver_priv = str9x_info;
|
bank->driver_priv = str9x_info;
|
||||||
|
|
||||||
str9x_build_block_list(bank);
|
str9x_build_block_list(bank);
|
||||||
|
@ -139,7 +139,7 @@ FLASH_BANK_COMMAND_HANDLER(str9x_flash_bank_command)
|
||||||
static int str9x_protect_check(struct flash_bank_s *bank)
|
static int str9x_protect_check(struct flash_bank_s *bank)
|
||||||
{
|
{
|
||||||
int retval;
|
int retval;
|
||||||
str9x_flash_bank_t *str9x_info = bank->driver_priv;
|
struct str9x_flash_bank *str9x_info = bank->driver_priv;
|
||||||
target_t *target = bank->target;
|
target_t *target = bank->target;
|
||||||
|
|
||||||
int i;
|
int i;
|
||||||
|
@ -348,7 +348,7 @@ static int str9x_protect(struct flash_bank_s *bank,
|
||||||
static int str9x_write_block(struct flash_bank_s *bank,
|
static int str9x_write_block(struct flash_bank_s *bank,
|
||||||
uint8_t *buffer, uint32_t offset, uint32_t count)
|
uint8_t *buffer, uint32_t offset, uint32_t count)
|
||||||
{
|
{
|
||||||
str9x_flash_bank_t *str9x_info = bank->driver_priv;
|
struct str9x_flash_bank *str9x_info = bank->driver_priv;
|
||||||
target_t *target = bank->target;
|
target_t *target = bank->target;
|
||||||
uint32_t buffer_size = 8192;
|
uint32_t buffer_size = 8192;
|
||||||
working_area_t *source;
|
working_area_t *source;
|
||||||
|
@ -632,7 +632,7 @@ static int str9x_info(struct flash_bank_s *bank, char *buf, int buf_size)
|
||||||
|
|
||||||
COMMAND_HANDLER(str9x_handle_flash_config_command)
|
COMMAND_HANDLER(str9x_handle_flash_config_command)
|
||||||
{
|
{
|
||||||
str9x_flash_bank_t *str9x_info;
|
struct str9x_flash_bank *str9x_info;
|
||||||
target_t *target = NULL;
|
target_t *target = NULL;
|
||||||
|
|
||||||
if (argc < 5)
|
if (argc < 5)
|
||||||
|
|
|
@ -25,13 +25,13 @@
|
||||||
|
|
||||||
#include "flash.h"
|
#include "flash.h"
|
||||||
|
|
||||||
typedef struct str9x_flash_bank_s
|
struct str9x_flash_bank
|
||||||
{
|
{
|
||||||
uint32_t *sector_bits;
|
uint32_t *sector_bits;
|
||||||
int variant;
|
int variant;
|
||||||
int bank1;
|
int bank1;
|
||||||
working_area_t *write_algorithm;
|
working_area_t *write_algorithm;
|
||||||
} str9x_flash_bank_t;
|
};
|
||||||
|
|
||||||
enum str9x_status_codes
|
enum str9x_status_codes
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue