mirror of
https://git.codelinaro.org/clo/qsdk/oss/boot/u-boot-2016.git
synced 2026-03-14 21:10:27 +01:00
net: gem: Enable CTRL+C in wait_for_bit
Enable to break waiting loop at any time. Signed-off-by: Michal Simek <michal.simek@xilinx.com> Acked-by: Joe Hershberger <joe.hershberger@ni.com>
This commit is contained in:
parent
596e5782e7
commit
b8de29feae
1 changed files with 6 additions and 0 deletions
|
|
@ -14,6 +14,7 @@
|
|||
#include <net.h>
|
||||
#include <netdev.h>
|
||||
#include <config.h>
|
||||
#include <console.h>
|
||||
#include <malloc.h>
|
||||
#include <asm/io.h>
|
||||
#include <phy.h>
|
||||
|
|
@ -469,6 +470,11 @@ static int wait_for_bit(const char *func, u32 *reg, const u32 mask,
|
|||
if (get_timer(start) > timeout)
|
||||
break;
|
||||
|
||||
if (ctrlc()) {
|
||||
puts("Abort\n");
|
||||
return -EINTR;
|
||||
}
|
||||
|
||||
udelay(1);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue