From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753288AbbCIHpl (ORCPT ); Mon, 9 Mar 2015 03:45:41 -0400 Received: from szxga02-in.huawei.com ([119.145.14.65]:43084 "EHLO szxga02-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752787AbbCIHpg (ORCPT ); Mon, 9 Mar 2015 03:45:36 -0400 Message-ID: <54FD4EE6.7000408@huawei.com> Date: Mon, 9 Mar 2015 15:42:30 +0800 From: Zhang Zhen User-Agent: Mozilla/5.0 (Windows NT 6.1; rv:16.0) Gecko/20121010 Thunderbird/16.0.1 MIME-Version: 1.0 To: , CC: , , , , Subject: [PATCH] serial: 8250: fix a sparse warning References: <1425886615-78601-1-git-send-email-zhenzhang.zhang@huawei.com> In-Reply-To: <1425886615-78601-1-git-send-email-zhenzhang.zhang@huawei.com> X-Forwarded-Message-Id: <1425886615-78601-1-git-send-email-zhenzhang.zhang@huawei.com> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 8bit X-Originating-IP: [10.111.68.57] X-CFilter-Loop: Reflected Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org drivers/tty/serial/8250/8250_core.c: In function ‘serial8250_console_write’: drivers/tty/serial/8250/8250_core.c:3244: warning: ‘flags’ may be used u unitialized in this function Signed-off-by: Zhang Zhen --- drivers/tty/serial/8250/8250_core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/tty/serial/8250/8250_core.c b/drivers/tty/serial/8250/8250_core.c index deae122..50702e2 100644 --- a/drivers/tty/serial/8250/8250_core.c +++ b/drivers/tty/serial/8250/8250_core.c @@ -3241,7 +3241,7 @@ serial8250_console_write(struct console *co, const char *s, unsigned int count) { struct uart_8250_port *up = &serial8250_ports[co->index]; struct uart_port *port = &up->port; - unsigned long flags; + unsigned long flags = 0; unsigned int ier; int locked = 1; -- 1.8.5.5 . From mboxrd@z Thu Jan 1 00:00:00 1970 From: Zhang Zhen Subject: [PATCH] serial: 8250: fix a sparse warning Date: Mon, 9 Mar 2015 15:42:30 +0800 Message-ID: <54FD4EE6.7000408@huawei.com> References: <1425886615-78601-1-git-send-email-zhenzhang.zhang@huawei.com> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: QUOTED-PRINTABLE Return-path: In-Reply-To: <1425886615-78601-1-git-send-email-zhenzhang.zhang@huawei.com> Sender: linux-kernel-owner@vger.kernel.org To: linux-serial@vger.kernel.org, linux-kernel@vger.kernel.org Cc: tim.kryger@linaro.org, gregkh@linuxfoundation.org, jamie@jamieiles.com, alan@linux.intel.com, arnd@arndb.de List-Id: linux-serial@vger.kernel.org drivers/tty/serial/8250/8250_core.c: In function =E2=80=98serial8250_co= nsole_write=E2=80=99: drivers/tty/serial/8250/8250_core.c:3244: warning: =E2=80=98flags=E2=80= =99 may be used u unitialized in this function Signed-off-by: Zhang Zhen --- drivers/tty/serial/8250/8250_core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/tty/serial/8250/8250_core.c b/drivers/tty/serial/8= 250/8250_core.c index deae122..50702e2 100644 --- a/drivers/tty/serial/8250/8250_core.c +++ b/drivers/tty/serial/8250/8250_core.c @@ -3241,7 +3241,7 @@ serial8250_console_write(struct console *co, cons= t char *s, unsigned int count) { struct uart_8250_port *up =3D &serial8250_ports[co->index]; struct uart_port *port =3D &up->port; - unsigned long flags; + unsigned long flags =3D 0; unsigned int ier; int locked =3D 1; --=20 1.8.5.5 =2E