diff --git a/include/Makefile.am b/include/Makefile.am index 6fb9650482..b84da9a8ee 100644 --- a/include/Makefile.am +++ b/include/Makefile.am @@ -1,7 +1,7 @@ EXTRA_DIST = spl.h +EXTRA_DIST += spl-condvar.h spl-kmem.h spl-random.h spl-thread.h +EXTRA_DIST += spl-types.h spl-cred.h spl-kstat.h spl-rwlock.h +EXTRA_DIST += spl-time.h spl-callb.h spl-generic.h spl-mutex.h +EXTRA_DIST += spl-taskq.h spl-timer.h EXTRA_DIST += splat-ctl.h -EXTRA_DIST += linux-condvar.h linux-kmem.h linux-random.h linux-thread.h -EXTRA_DIST += linux-types.h linux-cred.h linux-kstat.h linux-rwlock.h -EXTRA_DIST += linux-time.h linux-callb.h linux-generic.h linux-mutex.h -EXTRA_DIST += linux-taskq.h linux-timer.h EXTRA_DIST += list.h diff --git a/include/linux-callb.h b/include/spl-callb.h similarity index 97% rename from include/linux-callb.h rename to include/spl-callb.h index 0a34ad2cfa..4480b42023 100644 --- a/include/linux-callb.h +++ b/include/spl-callb.h @@ -6,7 +6,7 @@ extern "C" { #endif #include -#include +#include "spl-mutex.h" #define DEBUG_CALLB diff --git a/include/linux-condvar.h b/include/spl-condvar.h similarity index 100% rename from include/linux-condvar.h rename to include/spl-condvar.h diff --git a/include/linux-cred.h b/include/spl-cred.h similarity index 100% rename from include/linux-cred.h rename to include/spl-cred.h diff --git a/include/linux-generic.h b/include/spl-generic.h similarity index 100% rename from include/linux-generic.h rename to include/spl-generic.h diff --git a/include/linux-kmem.h b/include/spl-kmem.h similarity index 100% rename from include/linux-kmem.h rename to include/spl-kmem.h diff --git a/include/linux-kstat.h b/include/spl-kstat.h similarity index 99% rename from include/linux-kstat.h rename to include/spl-kstat.h index eb65811efe..5fc95ccaa4 100644 --- a/include/linux-kstat.h +++ b/include/spl-kstat.h @@ -6,7 +6,8 @@ extern "C" { #endif #include -#include +#include "spl-types.h" +#include "spl-time.h" /* XXX - The minimum functionality here is stubbed out but nothing works. */ diff --git a/include/linux-mutex.h b/include/spl-mutex.h similarity index 99% rename from include/linux-mutex.h rename to include/spl-mutex.h index 46406cf595..a937a1de20 100644 --- a/include/linux-mutex.h +++ b/include/spl-mutex.h @@ -6,6 +6,7 @@ extern "C" { #endif #include +#include "spl-types.h" /* See the "Big Theory Statement" in solaris mutex.c. * diff --git a/include/linux-random.h b/include/spl-random.h similarity index 100% rename from include/linux-random.h rename to include/spl-random.h diff --git a/include/linux-rwlock.h b/include/spl-rwlock.h similarity index 99% rename from include/linux-rwlock.h rename to include/spl-rwlock.h index d212059e7e..305ccdf2b6 100644 --- a/include/linux-rwlock.h +++ b/include/spl-rwlock.h @@ -5,7 +5,7 @@ #include #include #include -#include +#include "spl-types.h" #ifdef __cplusplus extern "C" { diff --git a/include/linux-taskq.h b/include/spl-taskq.h similarity index 99% rename from include/linux-taskq.h rename to include/spl-taskq.h index 90081b25ee..bf6e244385 100644 --- a/include/linux-taskq.h +++ b/include/spl-taskq.h @@ -24,7 +24,7 @@ extern "C" { #include #include #include -#include +#include "spl-types.h" #undef DEBUG_TASKQ_UNIMPLEMENTED diff --git a/include/linux-thread.h b/include/spl-thread.h similarity index 95% rename from include/linux-thread.h rename to include/spl-thread.h index bcee08e476..567d397e1b 100644 --- a/include/linux-thread.h +++ b/include/spl-thread.h @@ -8,8 +8,8 @@ extern "C" { #include #include #include -#include -#include +#include "spl-types.h" +#include "spl-generic.h" /* * Thread interfaces diff --git a/include/linux-time.h b/include/spl-time.h similarity index 98% rename from include/linux-time.h rename to include/spl-time.h index 2bbc7b257c..8fe1e59aac 100644 --- a/include/linux-time.h +++ b/include/spl-time.h @@ -12,7 +12,7 @@ extern "C" { #include #include -#include +#include "spl-types.h" extern unsigned long long monotonic_clock(void); typedef struct timespec timestruc_t; /* definition per SVr4 */ diff --git a/include/linux-timer.h b/include/spl-timer.h similarity index 100% rename from include/linux-timer.h rename to include/spl-timer.h diff --git a/include/linux-types.h b/include/spl-types.h similarity index 100% rename from include/linux-types.h rename to include/spl-types.h diff --git a/include/spl.h b/include/spl.h index 26e6b8712c..d069fd94dd 100644 --- a/include/spl.h +++ b/include/spl.h @@ -1,4 +1,19 @@ #ifndef _SPL_H #define _SPL_H +#include "spl-callb.h" +#include "spl-condvar.h" +#include "spl-cred.h" +#include "spl-generic.h" +#include "spl-kmem.h" +#include "spl-kstat.h" +#include "spl-mutex.h" +#include "spl-random.h" +#include "spl-rwlock.h" +#include "spl-taskq.h" +#include "spl-thread.h" +#include "spl-time.h" +#include "spl-timer.h" +#include "spl-types.h" + #endif /* _SPL_H */ diff --git a/modules/spl/Makefile.in b/modules/spl/Makefile.in index 134d88227f..09e934e4f9 100644 --- a/modules/spl/Makefile.in +++ b/modules/spl/Makefile.in @@ -2,18 +2,18 @@ MODULES := spl DISTFILES = Makefile.in \ - linux-kmem.c linux-rwlock.c linux-taskq.c \ - linux-thread.c linux-generic.c + spl-kmem.c spl-rwlock.c spl-taskq.c \ + spl-thread.c spl-generic.c CPPFLAGS += @KERNELCPPFLAGS@ # Solaris porting layer module obj-m := spl.o -spl-objs += linux-kmem.o -spl-objs += linux-thread.o -spl-objs += linux-taskq.o -spl-objs += linux-rwlock.o -spl-objs += linux-generic.o +spl-objs += spl-kmem.o +spl-objs += spl-thread.o +spl-objs += spl-taskq.o +spl-objs += spl-rwlock.o +spl-objs += spl-generic.o splmodule := spl.ko splmoduledir := @kmoduledir@/kernel/lib/ diff --git a/modules/spl/linux-generic.c b/modules/spl/spl-generic.c similarity index 93% rename from modules/spl/linux-generic.c rename to modules/spl/spl-generic.c index e139c351b9..8a84356940 100644 --- a/modules/spl/linux-generic.c +++ b/modules/spl/spl-generic.c @@ -1,4 +1,4 @@ -#include "linux-generic.h" +#include "spl-generic.h" #include "config.h" /* diff --git a/modules/spl/linux-kmem.c b/modules/spl/spl-kmem.c similarity index 99% rename from modules/spl/linux-kmem.c rename to modules/spl/spl-kmem.c index 4dc7c01d8a..9b8ba26a7e 100644 --- a/modules/spl/linux-kmem.c +++ b/modules/spl/spl-kmem.c @@ -1,4 +1,4 @@ -#include "linux-kmem.h" +#include "spl-kmem.h" /* * Memory allocation interfaces diff --git a/modules/spl/linux-rwlock.c b/modules/spl/spl-rwlock.c similarity index 95% rename from modules/spl/linux-rwlock.c rename to modules/spl/spl-rwlock.c index 24775c4140..cafdd9b1c1 100644 --- a/modules/spl/linux-rwlock.c +++ b/modules/spl/spl-rwlock.c @@ -1,4 +1,4 @@ -#include +#include int rw_lock_held(krwlock_t *rwlp) diff --git a/modules/spl/linux-taskq.c b/modules/spl/spl-taskq.c similarity index 98% rename from modules/spl/linux-taskq.c rename to modules/spl/spl-taskq.c index ddcf57c3cd..d20ae59bdd 100644 --- a/modules/spl/linux-taskq.c +++ b/modules/spl/spl-taskq.c @@ -1,4 +1,4 @@ -#include +#include /* * Task queue interface diff --git a/modules/spl/linux-thread.c b/modules/spl/spl-thread.c similarity index 96% rename from modules/spl/linux-thread.c rename to modules/spl/spl-thread.c index 9785d50d34..b55f8c6af1 100644 --- a/modules/spl/linux-thread.c +++ b/modules/spl/spl-thread.c @@ -1,4 +1,4 @@ -#include +#include /* * Thread interfaces @@ -90,8 +90,7 @@ __thread_create(caddr_t stk, size_t stksize, void (*proc)(void *), /* Solaris says this must never fail so we try forever */ while ((pid = kernel_thread(thread_generic_wrapper, (void *)&tp, 0)) < 0) - printk(KERN_ERR "linux-thread: Unable to create thread; " - "pid = %ld\n", pid); + printk(KERN_ERR "Unable to create thread; pid = %ld\n", pid); /* All signals are ignored due to sleeping TASK_UNINTERRUPTIBLE */ for (;;) { diff --git a/modules/splat/splat-internal.h b/modules/splat/splat-internal.h index 4e017e01e5..a64b711fed 100644 --- a/modules/splat/splat-internal.h +++ b/modules/splat/splat-internal.h @@ -18,22 +18,8 @@ #include #include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include +#include "spl.h" +#include "splat-ctl.h" #define SPLAT_SUBSYSTEM_INIT(type) \ ({ splat_subsystem_t *_sub_; \