Fork us on GitHub Follow us on Facebook Follow us on Twitter

Changeset 2fa10f6 in mainline for kernel/generic/src/ddi/ddi.c


Ignore:
Timestamp:
2010-09-11T22:28:59Z (12 years ago)
Author:
Jakub Jermar <jakub@…>
Branches:
lfn, master, serial
Children:
5203efb1
Parents:
7431b665
Message:

Remove syscall for controlling preemption.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/generic/src/ddi/ddi.c

    r7431b665 r2fa10f6  
    258258}
    259259
    260 /** Disable or enable preemption.
    261  *
    262  * @param enable If non-zero, the preemption counter will be decremented,
    263  *               leading to potential enabling of preemption. Otherwise
    264  *               the preemption counter will be incremented, preventing
    265  *               preemption from occurring.
    266  *
    267  * @return Zero on success or EPERM if callers capabilities are not sufficient.
    268  *
    269  */
    270 unative_t sys_preempt_control(int enable)
    271 {
    272         if (!(cap_get(TASK) & CAP_PREEMPT_CONTROL))
    273                 return EPERM;
    274        
    275         if (enable)
    276                 preemption_enable();
    277         else
    278                 preemption_disable();
    279        
    280         return 0;
    281 }
    282 
    283260/** @}
    284261 */
Note: See TracChangeset for help on using the changeset viewer.