Re: CONFIG_PRINTK_TIME woes

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

 



Nick Piggin <[email protected]> wrote:
>
> Andrew Morton wrote:
> > Andrew Morton <[email protected]> wrote:
> > 
> >>How about we give each arch a printk_clock()?
> > 
> > 
> > Which might be as simple as this..
> > 
> > 
> 
> sched_clock() shouldn't really be taken outside kernel/sched.c,
> especially for things like this.
> 
> It actually has some fundamental problems even in its current
> use in the scheduler (which need to be fixed). But basically it
> is a very nasty interface with a rather tenuous relationship to
> time.

yup.

> Why not use something like do_gettimeofday? (or I'm sure one
> of our time keepers can suggest the right thing to use).

do_gettimeofday() takes locks, so a) we can't do printk from inside it and
b) if you do a printk-from-interupt and the interrupted code was running
do_gettimeofday(), deadlock.
-
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]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]
  Powered by Linux