OpenOCD
|
This file implements the basic functions to run flashing commands from the TCL interface. It allows the user to flash the Freescale 5680xx DSP. More...
Go to the source code of this file.
Functions | |
static int | dsp5680xx_build_sector_list (struct flash_bank *bank) |
static int | dsp5680xx_flash_erase (struct flash_bank *bank, unsigned int first, unsigned int last) |
The flash module (FM) on the dsp5680xx supports both individual sector and mass erase of the flash memory. More... | |
static int | dsp5680xx_flash_erase_check (struct flash_bank *bank) |
The flash module (FM) on the dsp5680xx support a blank check function. More... | |
static int | dsp5680xx_flash_protect (struct flash_bank *bank, int set, unsigned int first, unsigned int last) |
Protection functionality is not implemented. More... | |
static int | dsp5680xx_flash_protect_check (struct flash_bank *bank) |
A memory mapped register (PROT) holds information regarding sector protection. More... | |
static int | dsp5680xx_flash_write (struct flash_bank *bank, const uint8_t *buffer, uint32_t offset, uint32_t count) |
The dsp5680xx use word addressing. More... | |
static int | dsp5680xx_probe (struct flash_bank *bank) |
FLASH_BANK_COMMAND_HANDLER (dsp5680xx_flash_bank_command) | |
Variables | |
const struct flash_driver | dsp5680xx_flash |
This file implements the basic functions to run flashing commands from the TCL interface. It allows the user to flash the Freescale 5680xx DSP.
Definition in file dsp5680xx_flash.c.
|
static |
Definition at line 35 of file dsp5680xx_flash.c.
References bank, ERROR_OK, HFM_SECTOR_SIZE, and LOG_USER.
Referenced by FLASH_BANK_COMMAND_HANDLER().
|
static |
The flash module (FM) on the dsp5680xx supports both individual sector and mass erase of the flash memory.
If this function is called with first == last == 0 or if first is the first sector (#0) and last is the last sector then the mass erase command is executed (much faster than erasing each sector individually).
bank | |
first | |
last |
Definition at line 174 of file dsp5680xx_flash.c.
References bank, and dsp5680xx_f_erase().
|
static |
The flash module (FM) on the dsp5680xx support a blank check function.
This function executes the FM's blank check functionality on each and every sector.
bank |
Definition at line 188 of file dsp5680xx_flash.c.
|
static |
Protection functionality is not implemented.
The current implementation applies/removes security on the chip. The chip is effectively secured/unsecured after the first reset following the execution of this function.
bank | |
set | Apply or remove security on the chip. |
first | This parameter is ignored. |
last | This parameter is ignored. |
This applies security to flash module after next reset, it does not actually apply protection (protection refers to undesired access from the core)
Definition at line 108 of file dsp5680xx_flash.c.
References bank, dsp5680xx_f_lock(), and dsp5680xx_f_unlock().
|
static |
A memory mapped register (PROT) holds information regarding sector protection.
Protection refers to undesired core access. The value in this register is loaded from flash upon reset.
bank |
Definition at line 70 of file dsp5680xx_flash.c.
References bank, dsp5680xx_f_protect_check(), ERROR_OK, and HFM_SECTOR_COUNT.
|
static |
The dsp5680xx use word addressing.
The "/2" that appear in the following code are a workaround for the fact that OpenOCD uses byte addressing.
bank | |
buffer | Data to write to flash. |
offset | |
count | In bytes (2 bytes per address). |
Writing to odd addresses not supported. This chip uses word addressing, Openocd only supports byte addressing. The workaround results in disabling writing to odd byte addresses
Definition at line 136 of file dsp5680xx_flash.c.
References bank, buffer, count, dsp5680xx_f_wr(), ERROR_FAIL, LOG_ERROR, and offset.
|
static |
Definition at line 155 of file dsp5680xx_flash.c.
FLASH_BANK_COMMAND_HANDLER | ( | dsp5680xx_flash_bank_command | ) |
Definition at line 51 of file dsp5680xx_flash.c.
References bank, dsp5680xx_build_sector_list(), ERROR_OK, HFM_FLASH_BASE_ADDR, HFM_SECTOR_COUNT, and HFM_SIZE_BYTES.
const struct flash_driver dsp5680xx_flash |
Definition at line 188 of file dsp5680xx_flash.c.