Finding out the time elapsed between a disk I/O request generation and servicing.
We want to find out the time elapsed between a disk I/O request generated and it being serviced.
We tried to do so by using the difference between jiffies but many disk I/O requests are serviced before a "jiffy" is elapsed. So the difference returned 0.
Another approach is to use do_gettimeofday() function from time.h but we feel that the overhead in finding the time would be pretty huge if this function is fired for each request.
Please hint us on how to proceed with this so as to optimize the process.
We want to find this time because we need to monitor the workload on a system.
|