1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2025-12-29 08:21:18 +01:00

Merge pull request #21836 from benpicco/cpu/sam0-eth/irq-init

cpu/sam0_eth: disable interrupts during init
This commit is contained in:
Marian Buschsieweke 2025-10-31 17:48:20 +00:00 committed by GitHub
commit 20ff9dba35
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -355,6 +355,9 @@ bool sam0_eth_has_queued_pkt(void)
int sam0_eth_init(void)
{
/* HACK: interrupting the init sequence leads to strange hangs */
unsigned state = irq_disable();
/* Enable clocks */
_enable_clock();
/* Initialize GPIOs */
@ -413,5 +416,7 @@ int sam0_eth_init(void)
/* Enable both receiver and transmitter */
GMAC->NCR.reg |= GMAC_NCR_TXEN | GMAC_NCR_RXEN;
irq_restore(state);
return 0;
}