mirror of https://github.com/ARMmbed/mbed-os.git
TARGET_STM_EMAC astyle
parent
057142167b
commit
6391b7f2fa
|
@ -18,8 +18,7 @@
|
|||
|
||||
void _eth_config_mac(ETH_HandleTypeDef *heth)
|
||||
{
|
||||
ETH_MACInitTypeDef macconf =
|
||||
{
|
||||
ETH_MACInitTypeDef macconf = {
|
||||
.Watchdog = ETH_WATCHDOG_ENABLE,
|
||||
.Jabber = ETH_JABBER_ENABLE,
|
||||
.InterFrameGap = ETH_INTERFRAMEGAP_96BIT,
|
||||
|
|
|
@ -18,8 +18,7 @@
|
|||
|
||||
void _eth_config_mac(ETH_HandleTypeDef *heth)
|
||||
{
|
||||
ETH_MACInitTypeDef macconf =
|
||||
{
|
||||
ETH_MACInitTypeDef macconf = {
|
||||
.Watchdog = ETH_WATCHDOG_ENABLE,
|
||||
.Jabber = ETH_JABBER_ENABLE,
|
||||
.InterFrameGap = ETH_INTERFRAMEGAP_96BIT,
|
||||
|
|
|
@ -18,8 +18,7 @@
|
|||
|
||||
void _eth_config_mac(ETH_HandleTypeDef *heth)
|
||||
{
|
||||
ETH_MACInitTypeDef macconf =
|
||||
{
|
||||
ETH_MACInitTypeDef macconf = {
|
||||
.Watchdog = ETH_WATCHDOG_ENABLE,
|
||||
.Jabber = ETH_JABBER_ENABLE,
|
||||
.InterFrameGap = ETH_INTERFRAMEGAP_96BIT,
|
||||
|
|
|
@ -18,8 +18,7 @@
|
|||
|
||||
void _eth_config_mac(ETH_HandleTypeDef *heth)
|
||||
{
|
||||
ETH_MACInitTypeDef macconf =
|
||||
{
|
||||
ETH_MACInitTypeDef macconf = {
|
||||
.Watchdog = ETH_WATCHDOG_ENABLE,
|
||||
.Jabber = ETH_JABBER_ENABLE,
|
||||
.InterFrameGap = ETH_INTERFRAMEGAP_96BIT,
|
||||
|
|
|
@ -18,8 +18,7 @@
|
|||
|
||||
void _eth_config_mac(ETH_HandleTypeDef *heth)
|
||||
{
|
||||
ETH_MACInitTypeDef macconf =
|
||||
{
|
||||
ETH_MACInitTypeDef macconf = {
|
||||
.Watchdog = ETH_WATCHDOG_ENABLE,
|
||||
.Jabber = ETH_JABBER_ENABLE,
|
||||
.InterFrameGap = ETH_INTERFRAMEGAP_96BIT,
|
||||
|
|
|
@ -432,7 +432,8 @@ void STM32_EMAC::disable_interrupts(void)
|
|||
* @param mac A 6-byte array to write the MAC address
|
||||
*/
|
||||
|
||||
void mbed_mac_address(char *mac) {
|
||||
void mbed_mac_address(char *mac)
|
||||
{
|
||||
if (mbed_otp_mac_address(mac)) {
|
||||
return;
|
||||
} else {
|
||||
|
@ -441,11 +442,13 @@ void mbed_mac_address(char *mac) {
|
|||
return;
|
||||
}
|
||||
|
||||
__weak uint8_t mbed_otp_mac_address(char *mac) {
|
||||
__weak uint8_t mbed_otp_mac_address(char *mac)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
void mbed_default_mac_address(char *mac) {
|
||||
void mbed_default_mac_address(char *mac)
|
||||
{
|
||||
unsigned char ST_mac_addr[3] = {0x00, 0x80, 0xe1}; // default STMicro mac address
|
||||
|
||||
// Read unic id
|
||||
|
@ -560,12 +563,14 @@ void STM32_EMAC::set_memory_manager(EMACMemoryManager &mem_mngr)
|
|||
memory_manager = &mem_mngr;
|
||||
}
|
||||
|
||||
STM32_EMAC &STM32_EMAC::get_instance() {
|
||||
STM32_EMAC &STM32_EMAC::get_instance()
|
||||
{
|
||||
static STM32_EMAC emac;
|
||||
return emac;
|
||||
}
|
||||
|
||||
// Weak so a module can override
|
||||
MBED_WEAK EMAC &EMAC::get_default_instance() {
|
||||
MBED_WEAK EMAC &EMAC::get_default_instance()
|
||||
{
|
||||
return STM32_EMAC::get_instance();
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue