From patchwork Tue Jan 19 03:20:01 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Feng Tang X-Patchwork-Id: 73798 Received: from lists.sourceforge.net (lists.sourceforge.net [216.34.181.88]) by demeter.kernel.org (8.14.3/8.14.2) with ESMTP id o0J3OI4M002846 for ; Tue, 19 Jan 2010 03:24:18 GMT Received: from localhost ([127.0.0.1] helo=sfs-ml-3.v29.ch3.sourceforge.com) by sfs-ml-3.v29.ch3.sourceforge.com with esmtp (Exim 4.69) (envelope-from ) id 1NX4hR-0006vo-Rp; Tue, 19 Jan 2010 03:24:13 +0000 Received: from sfi-mx-4.v28.ch3.sourceforge.com ([172.29.28.124] helo=mx.sourceforge.net) by sfs-ml-3.v29.ch3.sourceforge.com with esmtp (Exim 4.69) (envelope-from ) id 1NX4hQ-0006vg-DB for spi-devel-general@lists.sourceforge.net; Tue, 19 Jan 2010 03:24:12 +0000 X-ACL-Warn: Received: from mga14.intel.com ([143.182.124.37]) by sfi-mx-4.v28.ch3.sourceforge.com with esmtp (Exim 4.69) id 1NX4hP-0002Hd-9S for spi-devel-general@lists.sourceforge.net; Tue, 19 Jan 2010 03:24:12 +0000 Received: from azsmga001.ch.intel.com ([10.2.17.19]) by azsmga102.ch.intel.com with ESMTP; 18 Jan 2010 19:24:05 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="4.47,316,1257148800"; d="scan'208,223";a="234180079" Received: from pgsmsx602.gar.corp.intel.com ([10.221.43.81]) by azsmga001.ch.intel.com with ESMTP; 18 Jan 2010 19:24:03 -0800 Received: from shzsmsx502.ccr.corp.intel.com (10.239.4.97) by pgsmsx602.gar.corp.intel.com (10.221.43.81) with Microsoft SMTP Server (TLS) id 8.2.176.0; Tue, 19 Jan 2010 11:23:02 +0800 Received: from feng-desktop (10.239.14.69) by shzsmsx502.ccr.corp.intel.com (10.239.4.97) with Microsoft SMTP Server (TLS) id 8.2.176.0; Tue, 19 Jan 2010 11:23:01 +0800 Date: Tue, 19 Jan 2010 11:20:01 +0800 From: Feng Tang To: spi-devel-list , Grant Likely , David Brownell Message-ID: <20100119112001.6c391ea7@feng-desktop> Organization: intel X-Mailer: Claws Mail 3.6.1 (GTK+ 2.16.1; i486-pc-linux-gnu) MIME-Version: 1.0 X-Spam-Score: -4.0 (----) X-Spam-Report: Spam Filtering performed by mx.sourceforge.net. See http://spamassassin.org/tag/ for more details. -4.0 RCVD_IN_DNSWL_MED RBL: Sender listed at http://www.dnswl.org/, medium trust [143.182.124.37 listed in list.dnswl.org] X-Headers-End: 1NX4hP-0002Hd-9S Subject: [spi-devel-general] [PATCH 1/3] spi: dw_spi: fix a bug in wait_till_not_busy() X-BeenThere: spi-devel-general@lists.sourceforge.net X-Mailman-Version: 2.1.9 Precedence: list List-Id: Linux SPI core/device drivers discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: spi-devel-general-bounces@lists.sourceforge.net diff --git a/drivers/spi/dw_spi.c b/drivers/spi/dw_spi.c index 31620fa..521d680 100644 --- a/drivers/spi/dw_spi.c +++ b/drivers/spi/dw_spi.c @@ -161,7 +161,7 @@ static inline void mrst_spi_debugfs_remove(struct dw_spi *dws) static void wait_till_not_busy(struct dw_spi *dws) { - unsigned long end = jiffies + usecs_to_jiffies(1000); + unsigned long end = jiffies + 1 + usecs_to_jiffies(1000); while (time_before(jiffies, end)) { if (!(dw_readw(dws, sr) & SR_BUSY))