lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Fri, 26 Apr 2013 07:40:00 +0200
From:	Takashi Iwai <tiwai@...e.de>
To:	Arnd Bergmann <arnd@...db.de>
Cc:	linux-arm-kernel@...ts.infradead.org, linux-kernel@...r.kernel.org,
	alsa-devel@...a-project.org
Subject: Re: [PATCH 06/21] ALSA: ali5451: use mdelay instead of large udelay constants

At Thu, 25 Apr 2013 19:28:49 +0200,
Arnd Bergmann wrote:
> 
> ARM cannot handle udelay for more than 2 miliseconds, so we
> should use mdelay instead for those.
> 
> Signed-off-by: Arnd Bergmann <arnd@...db.de>
> Cc: Takashi Iwai <tiwai@...e.de>
> Cc: alsa-devel@...a-project.org

Thanks, applied to sound git tree.


Takashi


> ---
>  sound/pci/ali5451/ali5451.c | 8 ++++----
>  1 file changed, 4 insertions(+), 4 deletions(-)
> 
> diff --git a/sound/pci/ali5451/ali5451.c b/sound/pci/ali5451/ali5451.c
> index e760af9..53754f5 100644
> --- a/sound/pci/ali5451/ali5451.c
> +++ b/sound/pci/ali5451/ali5451.c
> @@ -451,10 +451,10 @@ static int snd_ali_reset_5451(struct snd_ali *codec)
>  	if (pci_dev) {
>  		pci_read_config_dword(pci_dev, 0x7c, &dwVal);
>  		pci_write_config_dword(pci_dev, 0x7c, dwVal | 0x08000000);
> -		udelay(5000);
> +		mdelay(5);
>  		pci_read_config_dword(pci_dev, 0x7c, &dwVal);
>  		pci_write_config_dword(pci_dev, 0x7c, dwVal & 0xf7ffffff);
> -		udelay(5000);
> +		mdelay(5);
>  	}
>  	
>  	pci_dev = codec->pci;
> @@ -463,14 +463,14 @@ static int snd_ali_reset_5451(struct snd_ali *codec)
>  	udelay(500);
>  	pci_read_config_dword(pci_dev, 0x44, &dwVal);
>  	pci_write_config_dword(pci_dev, 0x44, dwVal & 0xfffbffff);
> -	udelay(5000);
> +	mdelay(5);
>  	
>  	wCount = 200;
>  	while(wCount--) {
>  		wReg = snd_ali_codec_peek(codec, 0, AC97_POWERDOWN);
>  		if ((wReg & 0x000f) == 0x000f)
>  			return 0;
> -		udelay(5000);
> +		mdelay(5);
>  	}
>  
>  	/* non-fatal if you have a non PM capable codec */
> -- 
> 1.8.1.2
> 
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists