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:	Thu, 7 Jan 2016 07:37:29 -0800
From:	Nish Aravamudan <nish.aravamudan@...onical.com>
To:	Nicholas Mc Guire <hofrat@...dl.org>
Cc:	Corey Minyard <minyard@....org>,
	openipmi-developer@...ts.sourceforge.net,
	linux-kernel@...r.kernel.org
Subject: Re: [Openipmi-developer] [PATCH] ipmi: pass timeout as HZ
 independent value

On 07.01.2016 [14:52:37 +0100], Nicholas Mc Guire wrote:
> schedule_timeout_* takes a timeout in jiffies but the code currently is
> passing in a constant which makes this timeout HZ dependent, so pass it
> through msecs_to_jiffies() to fix this up.
> 
> Signed-off-by: Nicholas Mc Guire <hofrat@...dl.org>
> ---
> patch was compile tested with x86_64_defconfig + CONFIG_IPMI_HANDLER=m
> 
> Patch is against 4.4-rc8 (localversion-next is -next-20160107)
> 
>  drivers/char/ipmi/ipmi_si_intf.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/char/ipmi/ipmi_si_intf.c b/drivers/char/ipmi/ipmi_si_intf.c
> index 9fda22e..251d546 100644
> --- a/drivers/char/ipmi/ipmi_si_intf.c
> +++ b/drivers/char/ipmi/ipmi_si_intf.c
> @@ -1099,7 +1099,8 @@ static int ipmi_thread(void *data)
>  			schedule();
>  		else if (smi_result == SI_SM_IDLE) {
>  			if (atomic_read(&smi_info->need_watch)) {
> -				schedule_timeout_interruptible(100);
> +				schedule_timeout_interruptible(
> +							msecs_to_jiffies(100));

I believe you can use msleep_interruptible() for this.

-Nish
--
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

Powered by Openwall GNU/*/Linux Powered by OpenVZ