From patchwork Wed Oct 28 12:56:16 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ari Kauppi X-Patchwork-Id: 56282 Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id n9SCuRHI007506 for ; Wed, 28 Oct 2009 12:56:27 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752316AbZJ1M4U (ORCPT ); Wed, 28 Oct 2009 08:56:20 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1752369AbZJ1M4U (ORCPT ); Wed, 28 Oct 2009 08:56:20 -0400 Received: from smtp.nokia.com ([192.100.105.134]:27650 "EHLO mgw-mx09.nokia.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752269AbZJ1M4T (ORCPT ); Wed, 28 Oct 2009 08:56:19 -0400 Received: from esebh106.NOE.Nokia.com (esebh106.ntc.nokia.com [172.21.138.213]) by mgw-mx09.nokia.com (Switch-3.3.3/Switch-3.3.3) with ESMTP id n9SCuLnm028850 for ; Wed, 28 Oct 2009 07:56:24 -0500 Received: from vaebh104.NOE.Nokia.com ([10.160.244.30]) by esebh106.NOE.Nokia.com with Microsoft SMTPSVC(6.0.3790.3959); Wed, 28 Oct 2009 14:56:18 +0200 Received: from mgw-sa01.ext.nokia.com ([147.243.1.47]) by vaebh104.NOE.Nokia.com over TLS secured channel with Microsoft SMTPSVC(6.0.3790.3959); Wed, 28 Oct 2009 14:56:18 +0200 Received: from [172.23.119.51] (ouped11951.nmp.nokia.com [172.23.119.51]) by mgw-sa01.ext.nokia.com (Switch-3.3.3/Switch-3.3.3) with ESMTP id n9SCuGtx032667 for ; Wed, 28 Oct 2009 14:56:17 +0200 Subject: Re: [PATCHv2 1/3] OMAP UART: Add omap-serial driver support. From: "Kauppi Ari (EXT-Ixonos/Oulu)" To: linux-omap@vger.kernel.org In-Reply-To: <35817.192.168.10.88.1256713979.squirrel@dbdmail.itg.ti.com> References: <35817.192.168.10.88.1256713979.squirrel@dbdmail.itg.ti.com> Date: Wed, 28 Oct 2009 14:56:16 +0200 Message-Id: <1256734576.31092.23.camel@kauppi-desktop> Mime-Version: 1.0 X-Mailer: Evolution 2.26.1 X-OriginalArrivalTime: 28 Oct 2009 12:56:18.0200 (UTC) FILETIME=[0A598980:01CA57CE] X-Nokia-AV: Clean Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org diff --git a/drivers/serial/omap-serial.c b/drivers/serial/omap-serial.c index 0239209..2a65a36 100644 --- a/drivers/serial/omap-serial.c +++ b/drivers/serial/omap-serial.c @@ -483,8 +483,8 @@ static int serial_omap_startup(struct uart_port *port) /* * Clear the interrupt registers. */ - (void) serial_in(up, UART_LSR); - (void) serial_in(up, UART_RX); + if (serial_in(up, UART_LSR) & UART_LSR_DR) + (void) serial_in(up, UART_RX); (void) serial_in(up, UART_IIR); (void) serial_in(up, UART_MSR);