Reload the decrementer with a smaller value, and read the decrementer value
at the beginning of every timer_interrupt. Timekeeping only depends on the
timebase on PPC (I wrote most of the code), taking additional decrementer
interrupts does not harm. Actually the simplest and most efficient way
to perform a self IPI on PPC is to write 0 to the decrementer (2 machine
instructions).
Actually, a way to measure the longest time during which interrupts are masked
would be:
- when disabling interrupts, set decrementer to zero if they
were previously enabled.
- read the decrementer on every timer/external interrupt,
if the value is negative and too large print the value
and the point at which the interrupts were reenabled.
That's not perfect (it will generate not too many false positives but
quite some overhead, but it should work).
Gabriel
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/