mirror of
https://github.com/AsahiLinux/u-boot
synced 2025-02-18 06:58:54 +00:00
net/designware: add error message on DMA reset timeout
If for some reason DMA module fails to reset user oserves only this: --->--- # dhcp Trying dwmac.e0018000 FAIL --->--- This message makes not much sense. With proposed change error message will be more helpful: --->--- # dhcp Trying dwmac.e0018000 DMA reset timeout FAIL --->--- For example user may do power toggle to recover board functionality. Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com> Cc: Chin Liang See <clsee@altera.com> Cc: Dinh Nguyen <dinguyen@altera.com> Cc: Albert Aribaud <albert.u.boot@aribaud.net> Cc: Tom Rini <trini@ti.com> Cc: Wolfgang Denk <wd@denx.de> Cc: Pavel Machek <pavel@denx.de> Cc: Joe Hershberger <joe.hershberger@gmail.com> Cc: Ian Campbell <ijc@hellion.org.uk> Cc: Marek Vasut <marex@denx.de> Reviewed-by: Tom Rini <trini@ti.com> Acked-by: Pavel Machek <pavel@denx.de> Acked-by: Joe Hershberger <joe.hershberger@ni.com> Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
This commit is contained in:
parent
b7a5b08438
commit
875143f324
1 changed files with 3 additions and 1 deletions
|
@ -236,8 +236,10 @@ static int dw_eth_init(struct eth_device *dev, bd_t *bis)
|
|||
|
||||
start = get_timer(0);
|
||||
while (readl(&dma_p->busmode) & DMAMAC_SRST) {
|
||||
if (get_timer(start) >= CONFIG_MACRESET_TIMEOUT)
|
||||
if (get_timer(start) >= CONFIG_MACRESET_TIMEOUT) {
|
||||
printf("DMA reset timeout\n");
|
||||
return -1;
|
||||
}
|
||||
|
||||
mdelay(100);
|
||||
};
|
||||
|
|
Loading…
Add table
Reference in a new issue