From patchwork Tue Nov 15 11:05:29 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Wolfgang Ocker X-Patchwork-Id: 694975 Return-Path: X-Original-To: incoming-imx@patchwork.ozlabs.org Delivered-To: patchwork-incoming-imx@bilbo.ozlabs.org Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2001:1868:205::9]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3tJ4Sv2PNBz9t1H for ; Tue, 15 Nov 2016 22:11:11 +1100 (AEDT) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.85_2 #1 (Red Hat Linux)) id 1c6bau-0002F8-1p; Tue, 15 Nov 2016 11:08:04 +0000 Received: from schu.reccoware.net ([87.106.213.85]) by bombadil.infradead.org with esmtps (Exim 4.85_2 #1 (Red Hat Linux)) id 1c6bap-00028P-Ex for linux-arm-kernel@lists.infradead.org; Tue, 15 Nov 2016 11:08:00 +0000 Received: from localhost.localdomain (hemsut.reccoware.net [87.106.210.115]) (authenticated bits=0) by schu.reccoware.net (8.13.8/8.13.8/Recconet-2012062401) with ESMTP id uAFB5TdZ028223 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 15 Nov 2016 12:05:29 +0100 Message-ID: <1479207929.4985.25.camel@reccoware.de> Subject: [PATCH] mxs-auart: count FIFO overrun errors From: Wolfgang Ocker To: linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-serial@vger.kernel.org Date: Tue, 15 Nov 2016 12:05:29 +0100 Organization: Reccoware Systems X-Mailer: Evolution 3.18.5.2 (3.18.5.2-1.fc23) Mime-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20161115_030759_962983_A5548ED7 X-CRM114-Status: UNSURE ( 9.30 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -1.9 (-) X-Spam-Report: SpamAssassin version 3.4.0 on bombadil.infradead.org summary: Content analysis details: (-1.9 points) pts rule name description ---- ---------------------- -------------------------------------------------- -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.20 Precedence: list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Greg Kroah-Hartman , Jiri Slaby Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+incoming-imx=patchwork.ozlabs.org@lists.infradead.org List-Id: linux-imx-kernel.lists.patchwork.ozlabs.org The mxs-auart driver does not count FIFO overrun errors. These errors never appear in /proc/tty/driver/ttyAPP. This is because the OERR status bit is masked by read_status_mask in the rx interrupt function, but the AUART_STAT_OERR bit is never set in read_status_mask. The patch enables the counting of overrun errors. Signed-off-by: Wolfgang Ocker ---  drivers/tty/serial/mxs-auart.c | 2 +-  1 file changed, 1 insertion(+), 1 deletion(-) --  2.10.0 diff --git a/drivers/tty/serial/mxs-auart.c b/drivers/tty/serial/mxs-auart.c index 770454e0dfa3..8c1c9112b3fd 100644 --- a/drivers/tty/serial/mxs-auart.c +++ b/drivers/tty/serial/mxs-auart.c @@ -1016,7 +1016,7 @@ static void mxs_auart_settermios(struct uart_port *u,   ctrl |= AUART_LINECTRL_EPS;   }   - u->read_status_mask = 0; + u->read_status_mask = AUART_STAT_OERR;     if (termios->c_iflag & INPCK)   u->read_status_mask |= AUART_STAT_PERR;