Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Assuming that you are only doing this for debugging purposes until you fix the interrupt line, you could try calling your ISR (minus its context saving code) inside <code>timer_interrupt</code> in <code>arch/*/kernel/time.c</code> before that code re-enables interrupts. You will have to add some code to make it fire only one out of Y ticks if you need a slower rate than the tick source.</p> <p>If running the ISR in interrupt context is not your objective and you just want to get the bottom half driver code to run periodically you could use the timer API instead of hacking <code>timer_interrupt</code>. In this case your ISR code won't be executing in interrupt context.</p> <p>If you need a faster rate than the tick source you will probably need to use a highres timer. Here again, you won't actually be executing in interrupt context.</p> <p>There is a good introduction highres timers and the timer API by <a href="https://export.writer.zoho.com/public/rreginelli/Chapter-5---High-Resolution-Timers-Final1/fullpage" rel="nofollow noreferrer">here</a>. There is an example user space timer in the <a href="http://man7.org/linux/man-pages/man2/timer_create.2.html" rel="nofollow noreferrer"><code>timer_create( )</code> man page</a>. For kernel space timers you need <code>hrtimer_init()</code>, and <code>hrtimer_start()</code>. There is an example hrtimer <a href="http://www.ibm.com/developerworks/linux/library/l-timers-list/" rel="nofollow noreferrer">here</a> . To get this to work periodically I guess you would just reset the timer each time it fires or use the <code>hrtimer_forward( )</code> solution in this <a href="https://stackoverflow.com/questions/13214197/hrtimer-repeating-task-in-the-linux-kernel">SE post</a>.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload