1/* 2 * Copyright 2009, Colin G��nther, coling@gmx.de. 3 * All rights reserved. Distributed under the terms of the MIT License. 4 */ 5#ifndef _FBSD_COMPAT_SYS_PCPU_H_ 6#define _FBSD_COMPAT_SYS_PCPU_H_ 7 8 9#include <OS.h> 10#include <sys/smp.h> 11 12 13struct thread; 14 15#define curthread ((struct thread*)NULL) 16 /* NOTE: Dereferencing curthread will crash, which is intentional. There is 17 no FreeBSD compatible struct thread and Haiku's should not be used as it 18 is only valid for the current thread or with proper locking. Currently 19 only priv_check() expects a struct thread parameter and ignores it. Using 20 NULL will show us when other uses appear. */ 21 22 23#endif /* _FBSD_COMPAT_SYS_PCPU_H_ */ 24