On Fri, 2006-03-03 at 11:44 +0900, Atsushi Nemoto wrote:
> >>>>> On Thu, 2 Mar 2006 11:09:16 -0800 (PST), Christoph Lameter <[email protected]> said:
> >> In kernel 2.6, update_times() is called directly in timer
> >> interrupt, so there is no point calculating ticks here. This also
> >> get rid of difference of jiffies and jiffies_64 due to compiler's
> >> optimization (which was reported previously with subject
> >> "jiffies_64 vs. jiffies").
>
> clameter> If update_wall_time() and calc_load() are always called with
> clameter> the constant one then you may be able to optimize these two
> clameter> functions as well.
>
> Sure. I tried to do only one thing at a time, but it might be better
> to clean them up together. Patch revised.
>
>
> In kernel 2.6, update_times() is called directly in timer interrupt,
> so there is no point calculating ticks here. Then update_wall_time()
> and calc_load() can also be optimized. This also get rid of
> difference of jiffies and jiffies_64 due to compiler's optimization
> (which was reported previously with subject "jiffies_64 vs. jiffies").
I'm not opposed to this change, but I'm not sure if the barrier with a
clear comment as to why its needed might be better in the short term.
> Also adjust x86_64 timer interrupt handler with this change.
>
> Signed-off-by: Atsushi Nemoto <[email protected]>
>
> diff --git a/arch/x86_64/kernel/time.c b/arch/x86_64/kernel/time.c
> index 3080f84..7a1d790 100644
> --- a/arch/x86_64/kernel/time.c
> +++ b/arch/x86_64/kernel/time.c
> @@ -423,7 +423,8 @@ void main_timer_handler(struct pt_regs *
>
> if (lost > 0) {
> handle_lost_ticks(lost, regs);
> - jiffies += lost;
> + while (lost--)
> + do_timer(regs);
> }
i386 also has lost tick processing that will need to be handed as well.
thanks
-john
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[Index of Archives]
[Kernel Newbies]
[Netfilter]
[Bugtraq]
[Photo]
[Stuff]
[Gimp]
[Yosemite News]
[MIPS Linux]
[ARM Linux]
[Linux Security]
[Linux RAID]
[Video 4 Linux]
[Linux for the blind]
[Linux Resources]