Skip to content

Commit

Permalink
Merge pull request #13232 from kfessel/master
Browse files Browse the repository at this point in the history
cpu/stm32/eth: Use luid_get_eui48 to generate local, non group EUI
  • Loading branch information
miri64 authored Jan 30, 2020
2 parents a4c4c25 + b4b9ffe commit 3d4977c
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions cpu/stm32_common/periph/eth.c
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,6 @@ static void _init_buffer(void)

int stm32_eth_init(void)
{
char hwaddr[ETHERNET_ADDR_LEN];
/* enable APB2 clock */
RCC->APB2ENR |= RCC_APB2ENR_SYSCFGEN;

Expand Down Expand Up @@ -226,8 +225,9 @@ int stm32_eth_init(void)
stm32_eth_set_mac(eth_config.mac);
}
else {
luid_get(hwaddr, ETHERNET_ADDR_LEN);
stm32_eth_set_mac(hwaddr);
eui48_t hwaddr;
luid_get_eui48(&hwaddr);
stm32_eth_set_mac((const char *)hwaddr.uint8);
}

_init_buffer();
Expand Down

0 comments on commit 3d4977c

Please sign in to comment.