aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/stmmac/dwmac_lib.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/stmmac/dwmac_lib.c')
-rw-r--r--drivers/net/stmmac/dwmac_lib.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/net/stmmac/dwmac_lib.c b/drivers/net/stmmac/dwmac_lib.c
index d4adb1eaa447..0a504adb7eb3 100644
--- a/drivers/net/stmmac/dwmac_lib.c
+++ b/drivers/net/stmmac/dwmac_lib.c
@@ -227,6 +227,13 @@ int dwmac_dma_interrupt(unsigned long ioaddr,
227 return ret; 227 return ret;
228} 228}
229 229
230void dwmac_dma_flush_tx_fifo(unsigned long ioaddr)
231{
232 u32 csr6 = readl(ioaddr + DMA_CONTROL);
233 writel((csr6 | DMA_CONTROL_FTF), ioaddr + DMA_CONTROL);
234
235 do {} while ((readl(ioaddr + DMA_CONTROL) & DMA_CONTROL_FTF));
236}
230 237
231void stmmac_set_mac_addr(unsigned long ioaddr, u8 addr[6], 238void stmmac_set_mac_addr(unsigned long ioaddr, u8 addr[6],
232 unsigned int high, unsigned int low) 239 unsigned int high, unsigned int low)