From patchwork Tue Feb 25 11:43:42 2014
Content-Type: text/plain; charset="utf-8"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
X-Patchwork-Submitter: Philipp Zabel
X-Patchwork-Id: 3715871
Return-Path:
X-Original-To: patchwork-linux-fbdev@patchwork.kernel.org
Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org
Received: from mail.kernel.org (mail.kernel.org [198.145.19.201])
by patchwork2.web.kernel.org (Postfix) with ESMTP id 09622BF13A
for ;
Tue, 25 Feb 2014 11:43:56 +0000 (UTC)
Received: from mail.kernel.org (localhost [127.0.0.1])
by mail.kernel.org (Postfix) with ESMTP id 28FCB201DD
for ;
Tue, 25 Feb 2014 11:43:55 +0000 (UTC)
Received: from vger.kernel.org (vger.kernel.org [209.132.180.67])
by mail.kernel.org (Postfix) with ESMTP id 4B6A0201C7
for ;
Tue, 25 Feb 2014 11:43:54 +0000 (UTC)
Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand
id S1752443AbaBYLnw (ORCPT
);
Tue, 25 Feb 2014 06:43:52 -0500
Received: from metis.ext.pengutronix.de ([92.198.50.35]:36368 "EHLO
metis.ext.pengutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org
with ESMTP id S1752118AbaBYLnv (ORCPT
);
Tue, 25 Feb 2014 06:43:51 -0500
Received: from pizza.hi.pengutronix.de ([10.1.0.104]
helo=pizza.pengutronix.de.)
by metis.ext.pengutronix.de with esmtp (Exim 4.72)
(envelope-from )
id 1WIGQO-0002ZU-OC; Tue, 25 Feb 2014 12:43:48 +0100
From: Philipp Zabel
To: Greg Kroah-Hartman
Cc: devel@driverdev.osuosl.org, linux-fbdev@vger.kernel.org,
Tomi Valkeinen , kernel@pengutronix.de,
Dave Airlie ,
Russell King ,
Shawn Guo , Philipp Zabel
Subject: [PATCH 2/3] imx-drm: ipu-dc: Use usleep_range instead of msleep
Date: Tue, 25 Feb 2014 12:43:42 +0100
Message-Id: <1393328624-28013-3-git-send-email-p.zabel@pengutronix.de>
X-Mailer: git-send-email 1.9.0.rc3
In-Reply-To: <1393328624-28013-1-git-send-email-p.zabel@pengutronix.de>
References: <1393328624-28013-1-git-send-email-p.zabel@pengutronix.de>
X-SA-Exim-Connect-IP: 10.1.0.104
X-SA-Exim-Mail-From: p.zabel@pengutronix.de
X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de);
SAEximRunCond expanded to false
X-PTX-Original-Recipient: linux-fbdev@vger.kernel.org
Sender: linux-fbdev-owner@vger.kernel.org
Precedence: bulk
List-ID:
X-Mailing-List: linux-fbdev@vger.kernel.org
X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI,
RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham version=3.3.1
X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org
X-Virus-Scanned: ClamAV using ClamSMTP
Since msleep(2) can sleep up to 20ms anyway, make this explicit by using
usleep_range(2000, 20000).
Signed-off-by: Philipp Zabel
---
drivers/staging/imx-drm/ipu-v3/ipu-dc.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/staging/imx-drm/ipu-v3/ipu-dc.c b/drivers/staging/imx-drm/ipu-v3/ipu-dc.c
index d0e3bc3..d5de8bb 100644
--- a/drivers/staging/imx-drm/ipu-v3/ipu-dc.c
+++ b/drivers/staging/imx-drm/ipu-v3/ipu-dc.c
@@ -262,7 +262,7 @@ void ipu_dc_disable_channel(struct ipu_dc *dc)
/* Wait for DC triple buffer to empty */
while ((readl(priv->dc_reg + DC_STAT) & val) != val) {
- msleep(2);
+ usleep_range(2000, 20000);
timeout -= 2;
if (timeout <= 0)
break;