From patchwork Sat Feb 24 12:38:14 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stefan Wahren X-Patchwork-Id: 10241639 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id C2E0360211 for ; Mon, 26 Feb 2018 08:44:25 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id B583129D0E for ; Mon, 26 Feb 2018 08:44:25 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id AA5E529D29; Mon, 26 Feb 2018 08:44:25 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.2 required=2.0 tests=BAYES_00, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 3483C29D0E for ; Mon, 26 Feb 2018 08:44:25 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id B3B466E3F0; Mon, 26 Feb 2018 08:43:11 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mout.kundenserver.de (mout.kundenserver.de [212.227.17.10]) by gabe.freedesktop.org (Postfix) with ESMTPS id 4F1666E00A for ; Sat, 24 Feb 2018 12:38:48 +0000 (UTC) Received: from localhost.localdomain ([95.90.209.156]) by mrelayeu.kundenserver.de (mreue105 [212.227.15.183]) with ESMTPSA (Nemesis) id 0M8ztN-1f1Pbw0lh7-00CSMk; Sat, 24 Feb 2018 13:38:41 +0100 From: Stefan Wahren To: Eric Anholt , David Airlie Subject: [PATCH] drm: vc4_hdmi: Replace long udelay with usleep_range Date: Sat, 24 Feb 2018 13:38:14 +0100 Message-Id: <1519475894-11701-1-git-send-email-stefan.wahren@i2se.com> X-Mailer: git-send-email 2.7.4 X-Provags-ID: V03:K0:b/2QZ5zoSvzdKo1XcPif+W9u0p3gwB99r4z3rVLKU5JMeB1WOt+ y+A8RMph/Piz4ZxhrnuopKRdg74zE51A2o4HoLvWaymI1xwDeCuuzQPpic1uFpChI51Q/hW 1hpWx18k5BIBjRAjhryCXCx7ghsDAmoQkTd5Bc/02wzrOwy9hvG45lMPmOAHWicFW+gnF2N 66XBZ9xP+NRcaCgmj2CoA== X-UI-Out-Filterresults: notjunk:1; V01:K0:waCuHiJ0KX0=:AA8SB0zl24HlyGsYn6LnzU cIDLsa6EhhRo2iMGSORevZ6K4VGZ60IoljfaN4y6ZEIflyUrWH7Lb5VW6V+enCW2rKzMjGD0F euZjVO86PJuvHvHhel8AYgzqqVeWvt7lb101wseh5iiYdZuUhlx7rjrPTWU4taxOCchNaWdrC Vh6TMN4SkMJuPcU0j7uH0bPm4MR4yjbRfDrMDZ+PeWvLQv26L3xheWJwPy6FPXv6bytVuUcW0 YcgDvQiT5ISzs4l5H/kUuMvhadIFd7qrQkci2VI7OIszSMbRcWvjYCqzXXxkmO8kHzhBoR1oa C2KU5smqzJZQwWvtspQYdnYmNmoE+7fWFlI3L0MysjRaXFS21EmxiRMfzZjnjrTFO0QpSWEDW bNvYRzHNaKTduWtNuY+zazpaJwvTBuIJsMS0L9+mGe+JNte3FB6pZB8zFGOIJxIfQz4f4mgOv pbiae5KC2qWiftw9PHzR4sXdoB/PYWx+gVgwh1FHOJDYH4Panu+kLV34yylfCn65JDx5O8Bct 4OvLFGdO6DCYJzclvtycyEj2V7VBrRPwuw93lL5PHIlbsrRjZL0hZvi/TEERyyB+5eSBLZvS9 3JZN9LR2GnJ9FJttax2oUU1jhcp6FfxPdUFc2JYSuO+lz9LaGpxVpSuBnBT7qR4F+CDbyIMoC EaNNwZ6vWmY8nrICFcFGvZfNzbbN6fXYFZXgBNRRyYc3pNl/dbrFzI/kzA/xsY2PE2qWigEc/ DWO5qgrrOTTGUdtjgDPLY118fgSH0cCjCGtE/3L2EB29QlF7VadfMvs2u7M= X-Mailman-Approved-At: Mon, 26 Feb 2018 08:43:04 +0000 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Stefan Wahren , Boris Brezillon , dri-devel@lists.freedesktop.org MIME-Version: 1.0 Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP Since we aren't in atomic context replace this long udelay with a usleep_range. Signed-off-by: Stefan Wahren --- drivers/gpu/drm/vc4/vc4_hdmi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/vc4/vc4_hdmi.c b/drivers/gpu/drm/vc4/vc4_hdmi.c index 984501e..1a6db29 100644 --- a/drivers/gpu/drm/vc4/vc4_hdmi.c +++ b/drivers/gpu/drm/vc4/vc4_hdmi.c @@ -681,7 +681,7 @@ static void vc4_hdmi_encoder_enable(struct drm_encoder *encoder) drift & ~VC4_HDMI_FIFO_CTL_RECENTER); HDMI_WRITE(VC4_HDMI_FIFO_CTL, drift | VC4_HDMI_FIFO_CTL_RECENTER); - udelay(1000); + usleep_range(1000, 1100); HDMI_WRITE(VC4_HDMI_FIFO_CTL, drift & ~VC4_HDMI_FIFO_CTL_RECENTER); HDMI_WRITE(VC4_HDMI_FIFO_CTL,