From b8de29feaee2a26e4a72800ed17994c9312f1735 Mon Sep 17 00:00:00 2001 From: Michal Simek Date: Thu, 24 Sep 2015 20:13:45 +0200 Subject: [PATCH] net: gem: Enable CTRL+C in wait_for_bit Enable to break waiting loop at any time. Signed-off-by: Michal Simek Acked-by: Joe Hershberger --- drivers/net/zynq_gem.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/drivers/net/zynq_gem.c b/drivers/net/zynq_gem.c index 0ee909c97f..0a41281e90 100644 --- a/drivers/net/zynq_gem.c +++ b/drivers/net/zynq_gem.c @@ -14,6 +14,7 @@ #include #include #include +#include #include #include #include @@ -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); } -- 2.30.2