stm32: ethernet, flash: tagging some function arguments as const
This commit is contained in:
parent
9ef5860863
commit
329b611e4f
@ -713,7 +713,7 @@ void eth_smi_bit_op(uint8_t phy, uint8_t reg, uint16_t bits, uint16_t mask);
|
||||
void eth_smi_bit_clear(uint8_t phy, uint8_t reg, uint16_t clearbits);
|
||||
void eth_smi_bit_set(uint8_t phy, uint8_t reg, uint16_t setbits);
|
||||
|
||||
void eth_set_mac(uint8_t *mac);
|
||||
void eth_set_mac(const uint8_t *mac);
|
||||
void eth_desc_init(uint8_t *buf, uint32_t nTx, uint32_t nRx, uint32_t cTx,
|
||||
uint32_t cRx, bool isext);
|
||||
bool eth_tx(uint8_t *ppkt, uint32_t n);
|
||||
|
@ -134,7 +134,7 @@ void flash_program_double_word(uint32_t address, uint64_t data);
|
||||
void flash_program_word(uint32_t address, uint32_t data);
|
||||
void flash_program_half_word(uint32_t address, uint16_t data);
|
||||
void flash_program_byte(uint32_t address, uint8_t data);
|
||||
void flash_program(uint32_t address, uint8_t *data, uint32_t len);
|
||||
void flash_program(uint32_t address, const uint8_t *data, uint32_t len);
|
||||
void flash_program_option_bytes(uint32_t data);
|
||||
|
||||
END_DECLS
|
||||
|
@ -47,7 +47,7 @@ uint32_t RxBD;
|
||||
*
|
||||
* @param[in] mac uint8_t* Desired MAC
|
||||
*/
|
||||
void eth_set_mac(uint8_t *mac)
|
||||
void eth_set_mac(const uint8_t *mac)
|
||||
{
|
||||
ETH_MACAHR(0) = ((uint32_t)mac[5] << 8) | (uint32_t)mac[4] |
|
||||
ETH_MACA0HR_MACA0H;
|
||||
|
@ -330,7 +330,7 @@ was not properly erased.
|
||||
@param[in] len Length of data block.
|
||||
*/
|
||||
|
||||
void flash_program(uint32_t address, uint8_t *data, uint32_t len)
|
||||
void flash_program(uint32_t address, const uint8_t *data, uint32_t len)
|
||||
{
|
||||
/* TODO: Use dword and word size program operations where possible for
|
||||
* turbo speed.
|
||||
|
Loading…
x
Reference in New Issue
Block a user