From: Ram Gupta Date: Tue, 15 Aug 2006 06:05:29 +0000 (-0700) Subject: [SERIAL] returning proper error from serial core driver X-Git-Tag: v2.6.19-rc1~215^2~8 X-Git-Url: http://www.pilppa.org/gitweb/gitweb.cgi?a=commitdiff_plain;h=80e3c2b659515ef236f33f691ff5b22ae90ae8e4;p=linux-2.6-omap-h63xx.git [SERIAL] returning proper error from serial core driver Fix the issue of returning 0 even in case of error from uart_set_info function. Now it returns the error EBUSY when it can not set new port. Signed-off-by: Ram Gupta Signed-off-by: Andrew Morton Signed-off-by: Russell King --- diff --git a/drivers/serial/serial_core.c b/drivers/serial/serial_core.c index d7e28ab4c31..d814bb1dcb0 100644 --- a/drivers/serial/serial_core.c +++ b/drivers/serial/serial_core.c @@ -792,6 +792,7 @@ static int uart_set_info(struct uart_state *state, * We failed anyway. */ retval = -EBUSY; + goto exit; // Added to return the correct error -Ram Gupta } }