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, 20 Feb 2015 14:24:20 +0200
From:	Tomi Valkeinen <tomi.valkeinen@...com>
To:	Nicholas Mc Guire <hofrat@...dl.org>,
	Jean-Christophe Plagniol-Villard <plagnioj@...osoft.com>
CC:	Jingoo Han <jg1.han@...sung.com>,
	Daniel Vetter <daniel.vetter@...ll.ch>,
	Fabian Frederick <fabf@...net.be>,
	Laurent Pinchart <laurent.pinchart@...asonboard.com>,
	Wolfram Sang <wsa@...-dreams.de>,
	<linux-fbdev@...r.kernel.org>, <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] video: fbdev: use msecs_to_jiffies for time conversion

On 06/02/15 11:14, Nicholas Mc Guire wrote:
> This is only an API consolidation and should make things more readable
> it replaces var * HZ / 1000 by msecs_to_jiffies(var).
> 
> Signed-off-by: Nicholas Mc Guire <hofrat@...dl.org>
> ---
> 
> Patch was only compile tested with viper_defconfig (implies CONFIG_FB_PXA=m)
> 
> Patch is against 3.19.0-rc7 (localversion-next is -next-20150204)
> 
>  drivers/video/fbdev/pxafb.c |    6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/video/fbdev/pxafb.c b/drivers/video/fbdev/pxafb.c
> index da2431e..d8b4743 100644
> --- a/drivers/video/fbdev/pxafb.c
> +++ b/drivers/video/fbdev/pxafb.c
> @@ -1285,7 +1285,7 @@ static int pxafb_smart_thread(void *arg)
>  		mutex_unlock(&fbi->ctrlr_lock);
>  
>  		set_current_state(TASK_INTERRUPTIBLE);
> -		schedule_timeout(30 * HZ / 1000);
> +		schedule_timeout(msecs_to_jiffies(30));
>  	}
>  
>  	pr_debug("%s(): task ending\n", __func__);
> @@ -1460,7 +1460,7 @@ static void pxafb_disable_controller(struct pxafb_info *fbi)
>  #ifdef CONFIG_FB_PXA_SMARTPANEL
>  	if (fbi->lccr0 & LCCR0_LCDT) {
>  		wait_for_completion_timeout(&fbi->refresh_done,
> -				200 * HZ / 1000);
> +				msecs_to_jiffies(200);

That will not compile.

 Tomi



Download attachment "signature.asc" of type "application/pgp-signature" (820 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ