[LITMUS^RT] Function 'is_running' and 'is_current_running'

shijunjie92 shijunjie92 at gmail.com
Thu Jul 28 12:44:17 CEST 2016


Hello all:

I have noticed that you have rewritten the function 'is_running(t)' as 'is_current_running()' in the latest version. But how can we get one specific task's condition without the input to the funtion? I am confiused about the meaning of 'current'. 

#define is_current_running()                    \
        ((current)->state == TASK_RUNNING ||    \
         preempt_count() & PREEMPT_ACTIVE)

#define is_running(t)                   \
        ((t)->state == TASK_RUNNING ||  \
         task_thread_info(t)->preempt_count & PREEMPT_ACTIVE)


2016-07-28


shijunjie92 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.litmus-rt.org/pipermail/litmus-dev/attachments/20160728/e019557a/attachment.html>


More information about the litmus-dev mailing list