From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751315AbdJBLne (ORCPT ); Mon, 2 Oct 2017 07:43:34 -0400 Received: from mail-pf0-f194.google.com ([209.85.192.194]:38132 "EHLO mail-pf0-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750957AbdJBLnd (ORCPT ); Mon, 2 Oct 2017 07:43:33 -0400 X-Google-Smtp-Source: AOwi7QAQuGNflue5ciqRHGud9WC4Vwfvn6hlCzoNeXSQK0HqL5bPNQcq4AgRrfmhjx1lMpBR9hf8BQ== Date: Mon, 2 Oct 2017 17:13:22 +0530 From: Keerthi Reddy To: outreachy-kernel@googlegroups.com Cc: devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org, gregkh@linuxfoundation.org Subject: [PATCH] staging: rts5208: use usleep_range instead of udelay Message-ID: <20171002114322.GA8908@manoharreddy> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Since a its a slow device, allow a small range of 100 Signed-off-by: Keerthi Reddy --- drivers/staging/rts5208/rtsx_card.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/staging/rts5208/rtsx_card.c b/drivers/staging/rts5208/rtsx_card.c index a6b7bff..418e29d 100644 --- a/drivers/staging/rts5208/rtsx_card.c +++ b/drivers/staging/rts5208/rtsx_card.c @@ -825,7 +825,7 @@ int switch_normal_clock(struct rtsx_chip *chip, int clk) } if (sd_vpclk_phase_reset) { - udelay(200); + usleep_range(200, 300); retval = rtsx_write_register(chip, SD_VPCLK0_CTL, PHASE_NOT_RESET, PHASE_NOT_RESET); if (retval) { @@ -838,7 +838,7 @@ int switch_normal_clock(struct rtsx_chip *chip, int clk) rtsx_trace(chip); return retval; } - udelay(200); + usleep_range(200, 300); } retval = rtsx_write_register(chip, CLK_CTL, 0xFF, 0); if (retval) { -- 2.7.4