[U-Boot] [PATCH] net: gem: Enable CTRL+C in wait_for_bit
Joe Hershberger
joe.hershberger at gmail.com
Mon Nov 30 21:36:00 CET 2015
Hi Michal,
On Thu, Nov 26, 2015 at 3:46 AM, Michal Simek <michal.simek at xilinx.com> wrote:
> Enable to break waiting loop at any time.
>
> Signed-off-by: Michal Simek <michal.simek at xilinx.com>
> ---
>
> drivers/net/zynq_gem.c | 5 +++++
> 1 file changed, 5 insertions(+)
>
> diff --git a/drivers/net/zynq_gem.c b/drivers/net/zynq_gem.c
> index 858093f0d7e2..ee4169107e5b 100644
> --- a/drivers/net/zynq_gem.c
> +++ b/drivers/net/zynq_gem.c
> @@ -447,6 +447,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 -1;
Maybe this should return -EINTR?
> + }
> +
> udelay(1);
> }
>
> --
> 1.9.1
>
> _______________________________________________
> U-Boot mailing list
> U-Boot at lists.denx.de
> http://lists.denx.de/mailman/listinfo/u-boot
More information about the U-Boot
mailing list