VirtualBox

Changeset 19912 in vbox for trunk/src/VBox/Runtime/r0drv


Ignore:
Timestamp:
May 22, 2009 2:00:33 PM (16 years ago)
Author:
vboxsync
Message:

iprt/linux: RTThreadPreemptIsPending update.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Runtime/r0drv/linux/thread2-r0drv-linux.c

    r19907 r19912  
    5757RTDECL(bool) RTThreadPreemptIsPending(RTTHREAD hThread)
    5858{
    59 # if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 5, 4)
     59    Assert(hThread == NIL_RTTHREAD);
     60#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 5, 4)
    6061    return test_tsk_thread_flag(current, TIF_NEED_RESCHED);
     62
     63#elif LINUX_VERSION_CODE >= KERNEL_VERSION(2, 4, 20)
     64    return need_resched();
     65
     66#elif LINUX_VERSION_CODE >= KERNEL_VERSION(2, 1, 110)
     67    return current->need_resched != 0;
     68
    6169#else
    62     /** @todo get back to this if it matters. */
    63     return false;
     70    return need_resched != 0;
    6471#endif
    6572}
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette