From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753372AbcERK2N (ORCPT ); Wed, 18 May 2016 06:28:13 -0400 Received: from smtp137.dfw.emailsrvr.com ([67.192.241.137]:37720 "EHLO smtp137.dfw.emailsrvr.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753123AbcERK2L (ORCPT ); Wed, 18 May 2016 06:28:11 -0400 X-Auth-ID: abbotti@mev.co.uk X-Sender-Id: abbotti@mev.co.uk Subject: Re: [PATCH 14/14] staging: comedi: daqboard2000: prefer usleep_range() To: Hartley Sweeten , "devel@driverdev.osuosl.org" References: <1463478773-5916-1-git-send-email-abbotti@mev.co.uk> <1463478773-5916-15-git-send-email-abbotti@mev.co.uk> Cc: Greg Kroah-Hartman , "linux-kernel@vger.kernel.org" From: Ian Abbott Message-ID: <573C43B8.2090705@mev.co.uk> Date: Wed, 18 May 2016 11:28:08 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Icedove/38.6.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 17/05/16 18:42, Hartley Sweeten wrote: > On Tuesday, May 17, 2016 2:53 AM, Ian Abbott wrote: >> The checkpatch.pl warns about two `udelay(x)` calls, one of 100 >> microseconds, and one of 10 microseconds. The 100 microseconds one is >> used when waiting for FPGA to become ready to accept firmware, and is >> not that critical, so replace it with a call to `usleep_range(100, >> 1000)`. The 10 microseconds one is called as each 16-bit word of >> firmware data is written. A longer sleep would slow down firmware >> loading, so leave it alone. > > The firmware blob in comedi-nonfree-firmware/daqboard2000 is > 41236 bytes or 20618 words. With the 10 microsecond delay for > each word to total delay time is only 0.0206 seconds. I don't think a > small usleep_range() would slow down the firmware loading by much. > How about usleep_range(10, 20)? > > Regards, > Hartley Okay. -- -=( Ian Abbott @ MEV Ltd. E-mail: )=- -=( Web: http://www.mev.co.uk/ )=-