1 /* 2 * Copyright 2007 Haiku Inc. All rights reserved. 3 * Distributed under the terms of the MIT License. 4 */ 5 #ifndef _FBSD_COMPAT_SYS__TASK_H_ 6 #define _FBSD_COMPAT_SYS__TASK_H_ 7 8 9 /* Haiku's list management */ 10 #include <util/list.h> 11 12 13 typedef void (*task_fn_t)(void *context, int pending); 14 15 struct task { 16 int ta_pending; 17 int ta_priority; 18 int ta_flags; 19 task_fn_t ta_handler; 20 void *ta_argument; 21 22 struct list_link ta_link; 23 }; 24 25 26 #define TASK_NEEDSGIANT (1 << 0) /* Haiku extension, OpenBSD compatibility */ 27 28 29 #endif 30