X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=drivers%2Fnet%2Fnetconsole.c;h=677c89f0486f2a19f334db02b45a58a443b3e2da;hb=9d86c8dc960c6f4e7e349a41cd2757098da6a92f;hp=df8ab07b945f6c317308cc516359d7b3e72994fd;hpb=5b9c79a81db80c3f9e50c77477957cd803429af8;p=u-boot diff --git a/drivers/net/netconsole.c b/drivers/net/netconsole.c index df8ab07b94..677c89f048 100644 --- a/drivers/net/netconsole.c +++ b/drivers/net/netconsole.c @@ -184,7 +184,9 @@ static void nc_send_packet(const char *buf, int len) return; /* inside net loop */ output_packet = buf; output_packet_len = len; + input_recursion = 1; NetLoop(NETCONS); /* wait for arp reply and send packet */ + input_recursion = 0; output_packet_len = 0; return; } @@ -213,7 +215,7 @@ static void nc_send_packet(const char *buf, int len) } } -static int nc_start(void) +static int nc_start(struct stdio_dev *dev) { int retval; @@ -233,7 +235,7 @@ static int nc_start(void) return 0; } -static void nc_putc(char c) +static void nc_putc(struct stdio_dev *dev, char c) { if (output_recursion) return; @@ -244,7 +246,7 @@ static void nc_putc(char c) output_recursion = 0; } -static void nc_puts(const char *s) +static void nc_puts(struct stdio_dev *dev, const char *s) { int len; @@ -254,7 +256,7 @@ static void nc_puts(const char *s) len = strlen(s); while (len) { - int send_len = min(len, sizeof(input_buffer)); + int send_len = min(len, (int)sizeof(input_buffer)); nc_send_packet(s, send_len); len -= send_len; s += send_len; @@ -263,7 +265,7 @@ static void nc_puts(const char *s) output_recursion = 0; } -static int nc_getc(void) +static int nc_getc(struct stdio_dev *dev) { uchar c; @@ -284,7 +286,7 @@ static int nc_getc(void) return c; } -static int nc_tstc(void) +static int nc_tstc(struct stdio_dev *dev) { struct eth_device *eth;