Re: [PATCH] cs4231-lib: replace common delay loop by function

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 09/05/2007 07:09 PM, Krzysztof Helt wrote:

> From: Krzysztof Helt <krzysztof.h1@xxxxx>
> 
> This patch replaces a common delay loop by a function.
> It also uses ARRAY_SIZE macro for the rates table.
> 
> Signed-off-by: Krzysztof Helt <krzysztof.h1@xxxxx>
> ---

> +static void snd_cs4231_wait(struct snd_cs4231 *chip)
>  {
>  	int timeout;
> -	unsigned char tmp;
>  
>  	for (timeout = 250;
>  	     timeout > 0 && (cs4231_inb(chip, CS4231P(REGSEL)) & CS4231_INIT);
>  	     timeout--)
>  	     	udelay(100);
> +}

Like the inb() pulled out into the body of the for as you did for ad1848 a 
bit better, but otherwise:

Acked-by: Rene Herman <rene.herman@xxxxxxxxx>
_______________________________________________
Alsa-devel mailing list
Alsa-devel@xxxxxxxxxxxxxxxx
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel

[Index of Archives]     [ALSA User]     [Linux Audio Users]     [Kernel Archive]     [Asterisk PBX]     [Photo Sharing]     [Linux Sound]     [Video 4 Linux]     [Gimp]     [Yosemite News]

  Powered by Linux