From patchwork Mon May 27 00:59:20 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kuninori Morimoto X-Patchwork-Id: 2617081 Return-Path: X-Original-To: patchwork-spi-devel-general@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork1.kernel.org Received: from lists.sourceforge.net (lists.sourceforge.net [216.34.181.88]) by patchwork1.kernel.org (Postfix) with ESMTP id C30413FD2B for ; Mon, 27 May 2013 00:59:34 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=sfs-ml-2.v29.ch3.sourceforge.com) by sfs-ml-2.v29.ch3.sourceforge.com with esmtp (Exim 4.76) (envelope-from ) id 1Uglmd-0005rT-U9; Mon, 27 May 2013 00:59:31 +0000 Received: from sog-mx-1.v43.ch3.sourceforge.com ([172.29.43.191] helo=mx.sourceforge.net) by sfs-ml-2.v29.ch3.sourceforge.com with esmtp (Exim 4.76) (envelope-from ) id 1Uglmd-0005rO-E9 for spi-devel-general@lists.sourceforge.net; Mon, 27 May 2013 00:59:31 +0000 Received-SPF: pass (sog-mx-1.v43.ch3.sourceforge.com: domain of gmail.com designates 209.85.160.53 as permitted sender) client-ip=209.85.160.53; envelope-from=kuninori.morimoto.gx@gmail.com; helo=mail-pb0-f53.google.com; Received: from mail-pb0-f53.google.com ([209.85.160.53]) by sog-mx-1.v43.ch3.sourceforge.com with esmtps (TLSv1:RC4-SHA:128) (Exim 4.76) id 1UglmZ-0006JN-8O for spi-devel-general@lists.sourceforge.net; Mon, 27 May 2013 00:59:31 +0000 Received: by mail-pb0-f53.google.com with SMTP id un4so6140768pbc.26 for ; Sun, 26 May 2013 17:59:21 -0700 (PDT) X-Received: by 10.68.24.232 with SMTP id x8mr27588805pbf.150.1369616361258; Sun, 26 May 2013 17:59:21 -0700 (PDT) Received: from morimoto-Dell-XPS420.gmail.com (49.14.32.202.bf.2iij.net. [202.32.14.49]) by mx.google.com with ESMTPSA id gh9sm26168944pbc.37.2013.05.26.17.59.18 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Sun, 26 May 2013 17:59:20 -0700 (PDT) Date: Sun, 26 May 2013 17:59:20 -0700 (PDT) Message-ID: <87k3ml8cgr.wl%kuninori.morimoto.gx@renesas.com> To: Mark Brown , Simon Horman , Grant Likely In-Reply-To: <20130526132848.GG11134@verge.net.au> References: <87li7fwgk8.wl%kuninori.morimoto.gx@renesas.com> <87d2si4cdn.wl%kuninori.morimoto.gx@renesas.com> <87bo824cbu.wl%kuninori.morimoto.gx@renesas.com> <20130525014739.GA28458@verge.net.au> <20130525143219.GE7660@sirena.org.uk> <20130526132848.GG11134@verge.net.au> From: Kuninori Morimoto Subject: [PATCH] spi: hspi: fixup long delay time MIME-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") X-Spam-Score: -1.5 (-) X-Spam-Report: Spam Filtering performed by mx.sourceforge.net. See http://spamassassin.org/tag/ for more details. -1.5 SPF_CHECK_PASS SPF reports sender host as permitted sender for sender-domain 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (kuninori.morimoto.gx[at]gmail.com) -0.0 SPF_PASS SPF: sender matches SPF record 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature X-Headers-End: 1UglmZ-0006JN-8O Cc: spi-devel-general@lists.sourceforge.net, Magnus , Kuninori Morimoto , Linux-SH 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 Current HSPI driver is using msleep(20) on hspi_status_check_timeout(), but it was too long delay for SPI device. Bock-W board SPI access was too slow without this patch. This patch uses udelay(10) for it. Tested-by: Yusuke Goda Signed-off-by: Kuninori Morimoto --- drivers/spi/spi-sh-hspi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/spi/spi-sh-hspi.c b/drivers/spi/spi-sh-hspi.c index 60cfae5..eab593e 100644 --- a/drivers/spi/spi-sh-hspi.c +++ b/drivers/spi/spi-sh-hspi.c @@ -89,7 +89,7 @@ static int hspi_status_check_timeout(struct hspi_priv *hspi, u32 mask, u32 val) if ((mask & hspi_read(hspi, SPSR)) == val) return 0; - msleep(20); + udelay(10); } dev_err(hspi->dev, "timeout\n");