From patchwork Tue Mar 25 13:50:27 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: wei.sern.chan@intel.com X-Patchwork-Id: 3926031 Return-Path: X-Original-To: patchwork-ltsi-dev@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 4DD269F334 for ; Wed, 2 Apr 2014 00:29:30 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 588C520425 for ; Wed, 2 Apr 2014 00:29:29 +0000 (UTC) Received: from mail.linuxfoundation.org (mail.linuxfoundation.org [140.211.169.12]) by mail.kernel.org (Postfix) with ESMTP id 2179720499 for ; Wed, 2 Apr 2014 00:29:18 +0000 (UTC) Received: from mail.linux-foundation.org (localhost [IPv6:::1]) by mail.linuxfoundation.org (Postfix) with ESMTP id 14F2AAE6; Wed, 2 Apr 2014 00:28:52 +0000 (UTC) X-Original-To: ltsi-dev@lists.linuxfoundation.org Delivered-To: ltsi-dev@mail.linuxfoundation.org Received: from smtp1.linuxfoundation.org (smtp1.linux-foundation.org [172.17.192.35]) by mail.linuxfoundation.org (Postfix) with ESMTP id 3388D96E for ; Tue, 25 Mar 2014 05:53:36 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by smtp1.linuxfoundation.org (Postfix) with ESMTP id 8EAE0202AB for ; Tue, 25 Mar 2014 05:53:35 +0000 (UTC) Received: from orsmga001.jf.intel.com ([10.7.209.18]) by orsmga102.jf.intel.com with ESMTP; 24 Mar 2014 22:48:59 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="4.97,726,1389772800"; d="scan'208";a="479324403" Received: from ilab-virtual-machine.png.intel.com ([172.30.240.55]) by orsmga001.jf.intel.com with ESMTP; 24 Mar 2014 22:53:33 -0700 From: wei.sern.chan@intel.com To: ltsi-dev@lists.linuxfoundation.org Date: Tue, 25 Mar 2014 21:50:27 +0800 Message-Id: <1395755430-346-3-git-send-email-wei.sern.chan@intel.com> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: <1395755430-346-1-git-send-email-wei.sern.chan@intel.com> References: <1395755430-346-1-git-send-email-wei.sern.chan@intel.com> X-Spam-Status: No, score=-0.5 required=5.0 tests=BAYES_00, DATE_IN_FUTURE_06_12, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Mailman-Approved-At: Wed, 02 Apr 2014 00:28:48 +0000 Cc: darren.hart@intel.com, wei.sern.chan@intel.com, chiau.ee.chew@intel.com Subject: [LTSI-dev] [PATCH 2/5] serial: 8250: don't change the fifo trigger level when using dma X-BeenThere: ltsi-dev@lists.linuxfoundation.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: "A list to discuss patches, development, and other things related to the LTSI project" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: ltsi-dev-bounces@lists.linuxfoundation.org Errors-To: ltsi-dev-bounces@lists.linuxfoundation.org X-Virus-Scanned: ClamAV using ClamSMTP From: Heikki Krogerus DMA engines usually expect the fifo trigger level to be aligned with the burst size. It should not be changed even with small baud rates. This will fix an issue with Designware DMA engine where the data can not be transferred over UART with lower baud rates then 2400. Signed-off-by: Heikki Krogerus Signed-off-by: Greg Kroah-Hartman (cherry picked from commit 2797f6fb6727d8ac5127f88aee1fd059db0be24b) Signed-off-by: Maurice Petallo --- 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 d28d7af..3d508f3 100644 --- a/drivers/tty/serial/8250/8250_core.c +++ b/drivers/tty/serial/8250/8250_core.c @@ -2322,7 +2322,7 @@ serial8250_do_set_termios(struct uart_port *port, struct ktermios *termios, if (up->capabilities & UART_CAP_FIFO && port->fifosize > 1) { fcr = uart_config[port->type].fcr; - if (baud < 2400 || fifo_bug) { + if ((baud < 2400 && !up->dma) || fifo_bug) { fcr &= ~UART_FCR_TRIGGER_MASK; fcr |= UART_FCR_TRIGGER_1; }