Re: CONFIG_PRINTK_TIME and initial value for jiffies?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Sergei Shtylyov wrote:
>    sched_clock() defined in arch/i386/kernel/timers/timer_tsc.c can
> hardly provide 0-based time if it's using TSC (at least I can't see
> where the TSC is cleared). Even if it's not using TSC, jiffies_64 is not
> 0-based as we saw, and neither it's set to -300 secs because of the
> double cast to ulong and then to u64 which should clear the high word.
> Probably something somewhere clears TSC but I can see the related code
> only in arch/i386/kernel/smpboot.c...

I've worked a lot with the printk_times feature, and it's not unusual
on many systems to see weird values before time_init().  On x86 with a
TSC-based sched_clock() you may see values based on whatever
the TSC happens to be after firmware initialization up until time_init().

Note that you can re-base the timings to an arbitrary printk line
using scripts/show_delta.  See
http://tree.celinuxforum.org/CelfPubWiki/PrintkTimesSample2

=============================
Tim Bird
Architecture Group Chair, CE Linux Forum
Senior Staff Engineer, Sony Electronics
=============================


[Index of Archives]     [Linux MIPS Home]     [LKML Archive]     [Linux ARM Kernel]     [Linux ARM]     [Linux]     [Git]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux