On Mon, Feb 21, 2005 at 04:16:38PM +0530, Mandeep Sandhu hit keys to express the following: > Hi all, > > Can someone suggest a reliable way of calculating the amount of time > spent inside an ISR? > > one way i figured was to store the jiffies value on entering and exiting > the ISR and subtract these to get the time spent inside a drivers ISR. Will that work? jiffies are updated only when a timer interrupt (0) occurs. If you have called sti() there will not be any timer interrupt and consequently no jiffies increment. May be a better way is to use rdtsc() (for reading time stamp counter ) in the beginning and at the end and find out the milli/micro seconds spent. HTH, Om. -- It's fabulous! We haven't seen anything like it in the last half an hour! -- Macy's -- Kernelnewbies: Help each other learn about the Linux kernel. Archive: http://mail.nl.linux.org/kernelnewbies/ FAQ: http://kernelnewbies.org/faq/