Improve AF hard disk detection
[zfs.git] / include / sys / zfs_context.h
index 4abafcc..98b216f 100644 (file)
@@ -60,6 +60,8 @@
 #include <sys/zfs_debug.h>
 #include <sys/fm/fs/zfs.h>
 #include <sys/sunddi.h>
+#include <sys/ctype.h>
+#include <sys/disp.h>
 #include <linux/dcache_compat.h>
 
 #else /* _KERNEL */
@@ -92,6 +94,7 @@
 #include <atomic.h>
 #include <dirent.h>
 #include <time.h>
+#include <ctype.h>
 #include <sys/note.h>
 #include <sys/types.h>
 #include <sys/cred.h>
@@ -134,10 +137,9 @@ extern int aok;
  * ZFS debugging
  */
 
-#ifdef ZFS_DEBUG
 extern void dprintf_setup(int *argc, char **argv);
-#endif /* ZFS_DEBUG */
-
+extern void __dprintf(const char *file, const char *func,
+    int line, const char *fmt, ...);
 extern void cmn_err(int, const char *, ...);
 extern void vcmn_err(int, const char *, __va_list);
 extern void panic(const char *, ...);
@@ -227,6 +229,9 @@ extern kthread_t *zk_thread_create(caddr_t stk, size_t  stksize,
        proc_t *pp, int state, pri_t pri);
 extern void zk_thread_join(kt_did_t tid);
 
+#define        kpreempt_disable()      ((void)0)
+#define        kpreempt_enable()       ((void)0)
+
 #define        PS_NONE         -1
 
 #define        issig(why)      (FALSE)
@@ -383,7 +388,6 @@ typedef struct taskq_ent {
 #define        TASKQ_DYNAMIC           0x0004  /* Use dynamic thread scheduling */
 #define        TASKQ_THREADS_CPU_PCT   0x0008  /* Scale # threads by # cpus */
 #define        TASKQ_DC_BATCH          0x0010  /* Mark threads as batch */
-#define        TASKQ_NORECLAIM         0x0020  /* Disable direct memory reclaim */
 
 #define        TQ_SLEEP        KM_SLEEP        /* Can block for memory */
 #define        TQ_NOSLEEP      KM_NOSLEEP      /* cannot block for memory; may fail */