lkml.org 
[lkml]   [2004]   [May]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: MSEC_TO_JIFFIES is messed up...
Date

On May 13, 2004, at 21:11, Andrew Morton wrote:

> Paul Wagland <paul@wagland.net> wrote:
>> This changes behaviour when HZ==(z)000
>>
>> JIFFIES_TO_MSECS goes from
>> ((x) * 1000) / (z)000 to (((x) + (z) - 1)/(z))
>>
>> i.e. for x=1, z=2 this goes from ((1)*1000)/2000)=0 to
>> (((1)+(2)-1)/2)=1
>
> hm, so you're saying that we now round 0.5 up to 1 rather than down to
> zero?

More precisely, we round .x up, where before it was rounded down, but
yeah, _and_ only when HZ is a multiple of 1000, and greater than 1000.
This is also only the case for the patch as proposed by wli, currently
I don't know of any architectures that have a HZ of 2000 or more... but
I just note that it _is_ a behaviour change in those cases, whether or
not it is important is for other people to decide :-)

Cheers,
Paul
[unhandled content-type:application/pgp-signature]
\
 
 \ /
  Last update: 2005-03-22 14:03    [W:0.064 / U:0.196 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site