Remove misleading typedef and redundant suffix from struct nand_block.
}
nand->num_blocks = (nand->device->chip_size * 1024) / (nand->erase_size / 1024);
- nand->blocks = malloc(sizeof(nand_block_t) * nand->num_blocks);
+ nand->blocks = malloc(sizeof(struct nand_block) * nand->num_blocks);
for (i = 0; i < nand->num_blocks; i++)
{
#define NAND_DEVICE_COMMAND_HANDLER(name) static __NAND_DEVICE_COMMAND(name)
-typedef struct nand_block_s
+struct nand_block
{
uint32_t offset;
uint32_t size;
int is_erased;
int is_bad;
-} nand_block_t;
+};
struct nand_oobfree {
int offset;
int erase_size;
int use_raw;
int num_blocks;
- nand_block_t *blocks;
+ struct nand_block *blocks;
struct nand_device_s *next;
} nand_device_t;