From df870a697fc8669d63534b27a108335269a7884f Mon Sep 17 00:00:00 2001 From: Brian Behlendorf Date: Fri, 2 Nov 2012 15:29:44 -0700 Subject: [PATCH] splat: Cleanup headers Restructure the the SPLAT headers such that each test only includes the minimal set of headers it requires. Signed-off-by: Brian Behlendorf --- include/sys/kmem.h | 1 - include/sys/types.h | 2 ++ module/splat/splat-atomic.c | 2 ++ module/splat/splat-condvar.c | 1 + module/splat/splat-cred.c | 1 + module/splat/splat-ctl.c | 8 +++++++ module/splat/splat-generic.c | 1 + module/splat/splat-internal.h | 41 ----------------------------------- module/splat/splat-kmem.c | 2 ++ module/splat/splat-kobj.c | 1 + module/splat/splat-linux.c | 1 + module/splat/splat-list.c | 2 ++ module/splat/splat-mutex.c | 2 ++ module/splat/splat-random.c | 2 ++ module/splat/splat-rwlock.c | 3 +++ module/splat/splat-taskq.c | 2 ++ module/splat/splat-thread.c | 2 ++ module/splat/splat-time.c | 1 + module/splat/splat-vnode.c | 2 +- module/splat/splat-zlib.c | 3 +++ 20 files changed, 37 insertions(+), 43 deletions(-) diff --git a/include/sys/kmem.h b/include/sys/kmem.h index 0149e754c3..e71a443a09 100644 --- a/include/sys/kmem.h +++ b/include/sys/kmem.h @@ -28,7 +28,6 @@ #include #include #include -#include #include #include #include diff --git a/include/sys/types.h b/include/sys/types.h index 0c3d88ec37..35905eb973 100644 --- a/include/sys/types.h +++ b/include/sys/types.h @@ -42,6 +42,8 @@ #include #include #include +#include +#include #ifndef HAVE_UINTPTR_T typedef unsigned long uintptr_t; diff --git a/module/splat/splat-atomic.c b/module/splat/splat-atomic.c index 6162d6abfe..cdb3353f9c 100644 --- a/module/splat/splat-atomic.c +++ b/module/splat/splat-atomic.c @@ -24,6 +24,8 @@ * Solaris Porting LAyer Tests (SPLAT) Atomic Tests. \*****************************************************************************/ +#include +#include #include "splat-internal.h" #define SPLAT_ATOMIC_NAME "atomic" diff --git a/module/splat/splat-condvar.c b/module/splat/splat-condvar.c index 14000adbd9..69fefc9557 100644 --- a/module/splat/splat-condvar.c +++ b/module/splat/splat-condvar.c @@ -24,6 +24,7 @@ * Solaris Porting LAyer Tests (SPLAT) Condition Variable Tests. \*****************************************************************************/ +#include #include "splat-internal.h" #define SPLAT_CONDVAR_NAME "condvar" diff --git a/module/splat/splat-cred.c b/module/splat/splat-cred.c index db36ece980..0efabd8541 100644 --- a/module/splat/splat-cred.c +++ b/module/splat/splat-cred.c @@ -24,6 +24,7 @@ * Solaris Porting LAyer Tests (SPLAT) Credential Tests. \*****************************************************************************/ +#include #include "splat-internal.h" #define SPLAT_CRED_NAME "cred" diff --git a/module/splat/splat-ctl.c b/module/splat/splat-ctl.c index 399b09c4d3..53bf51dd62 100644 --- a/module/splat/splat-ctl.c +++ b/module/splat/splat-ctl.c @@ -43,6 +43,14 @@ * of regression tests or particular tests. \*****************************************************************************/ +#include +#include +#include +#include +#include +#include +#include +#include #include "splat-internal.h" static spl_class *splat_class; diff --git a/module/splat/splat-generic.c b/module/splat/splat-generic.c index f9c3c7ec54..38df14d3b1 100644 --- a/module/splat/splat-generic.c +++ b/module/splat/splat-generic.c @@ -24,6 +24,7 @@ * Solaris Porting LAyer Tests (SPLAT) Generic Tests. \*****************************************************************************/ +#include #include "splat-internal.h" #define SPLAT_GENERIC_NAME "generic" diff --git a/module/splat/splat-internal.h b/module/splat/splat-internal.h index 501e42c32d..b15db65e2f 100644 --- a/module/splat/splat-internal.h +++ b/module/splat/splat-internal.h @@ -25,47 +25,6 @@ #ifndef _SPLAT_INTERNAL_H #define _SPLAT_INTERNAL_H -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - #include "spl-device.h" #include "spl-debug.h" #include "splat-ctl.h" diff --git a/module/splat/splat-kmem.c b/module/splat/splat-kmem.c index d0ad9a6664..f1c4613fad 100644 --- a/module/splat/splat-kmem.c +++ b/module/splat/splat-kmem.c @@ -24,6 +24,8 @@ * Solaris Porting LAyer Tests (SPLAT) Kmem Tests. \*****************************************************************************/ +#include +#include #include "splat-internal.h" #define SPLAT_KMEM_NAME "kmem" diff --git a/module/splat/splat-kobj.c b/module/splat/splat-kobj.c index f0720dbf55..c767954182 100644 --- a/module/splat/splat-kobj.c +++ b/module/splat/splat-kobj.c @@ -24,6 +24,7 @@ * Solaris Porting LAyer Tests (SPLAT) Kobj Tests. \*****************************************************************************/ +#include #include "splat-internal.h" #define SPLAT_KOBJ_NAME "kobj" diff --git a/module/splat/splat-linux.c b/module/splat/splat-linux.c index 07126411ab..5303df4e03 100644 --- a/module/splat/splat-linux.c +++ b/module/splat/splat-linux.c @@ -23,6 +23,7 @@ * Solaris Porting LAyer Tests (SPLAT) Kernel Compatibility Tests. \*****************************************************************************/ +#include #include "splat-internal.h" #define SPLAT_LINUX_NAME "linux" diff --git a/module/splat/splat-list.c b/module/splat/splat-list.c index d517e7d226..34b570f393 100644 --- a/module/splat/splat-list.c +++ b/module/splat/splat-list.c @@ -24,6 +24,8 @@ * Solaris Porting LAyer Tests (SPLAT) List Tests. \*****************************************************************************/ +#include +#include #include "splat-internal.h" #define SPLAT_LIST_NAME "list" diff --git a/module/splat/splat-mutex.c b/module/splat/splat-mutex.c index d134e49ced..9e6b24708e 100644 --- a/module/splat/splat-mutex.c +++ b/module/splat/splat-mutex.c @@ -24,6 +24,8 @@ * Solaris Porting LAyer Tests (SPLAT) Mutex Tests. \*****************************************************************************/ +#include +#include #include "splat-internal.h" #define SPLAT_MUTEX_NAME "mutex" diff --git a/module/splat/splat-random.c b/module/splat/splat-random.c index 3ee580df78..63d96444f6 100644 --- a/module/splat/splat-random.c +++ b/module/splat/splat-random.c @@ -24,6 +24,8 @@ * Solaris Porting LAyer Tests (SPLAT) Random Number Generator Tests. \*****************************************************************************/ +#include +#include #include "splat-internal.h" #define SPLAT_KRNG_NAME "krng" diff --git a/module/splat/splat-rwlock.c b/module/splat/splat-rwlock.c index 2b9dee939e..9e335d7565 100644 --- a/module/splat/splat-rwlock.c +++ b/module/splat/splat-rwlock.c @@ -24,6 +24,9 @@ * Solaris Porting LAyer Tests (SPLAT) Read/Writer Lock Tests. \*****************************************************************************/ +#include +#include +#include #include "splat-internal.h" #define SPLAT_RWLOCK_NAME "rwlock" diff --git a/module/splat/splat-taskq.c b/module/splat/splat-taskq.c index 73142f9b65..38b563cc11 100644 --- a/module/splat/splat-taskq.c +++ b/module/splat/splat-taskq.c @@ -24,6 +24,8 @@ * Solaris Porting LAyer Tests (SPLAT) Task Queue Tests. \*****************************************************************************/ +#include +#include #include "splat-internal.h" #define SPLAT_TASKQ_NAME "taskq" diff --git a/module/splat/splat-thread.c b/module/splat/splat-thread.c index 0f504836fe..c54cbcd8ac 100644 --- a/module/splat/splat-thread.c +++ b/module/splat/splat-thread.c @@ -24,6 +24,8 @@ * Solaris Porting LAyer Tests (SPLAT) Thread Tests. \*****************************************************************************/ +#include +#include #include "splat-internal.h" #define SPLAT_THREAD_NAME "thread" diff --git a/module/splat/splat-time.c b/module/splat/splat-time.c index 3b06b9ef2a..e6f8dc682d 100644 --- a/module/splat/splat-time.c +++ b/module/splat/splat-time.c @@ -24,6 +24,7 @@ * Solaris Porting LAyer Tests (SPLAT) Time Tests. \*****************************************************************************/ +#include #include "splat-internal.h" #define SPLAT_TIME_NAME "time" diff --git a/module/splat/splat-vnode.c b/module/splat/splat-vnode.c index a57edf0def..7d1c75f179 100644 --- a/module/splat/splat-vnode.c +++ b/module/splat/splat-vnode.c @@ -24,8 +24,8 @@ * Solaris Porting LAyer Tests (SPLAT) Vnode Tests. \*****************************************************************************/ +#include #include "splat-internal.h" -#include #define SPLAT_VNODE_NAME "vnode" #define SPLAT_VNODE_DESC "Kernel Vnode Tests" diff --git a/module/splat/splat-zlib.c b/module/splat/splat-zlib.c index 465d340917..852cf818fb 100644 --- a/module/splat/splat-zlib.c +++ b/module/splat/splat-zlib.c @@ -24,6 +24,9 @@ * Solaris Porting LAyer Tests (SPLAT) Zlib Compression Tests. \*****************************************************************************/ +#include +#include +#include #include "splat-internal.h" #define SPLAT_ZLIB_NAME "zlib"