aboutsummaryrefslogtreecommitdiffstats
path: root/copy-builtin
diff options
context:
space:
mode:
Diffstat (limited to 'copy-builtin')
-rwxr-xr-xcopy-builtin7
1 files changed, 7 insertions, 0 deletions
diff --git a/copy-builtin b/copy-builtin
index c108cfc67..ee3b081ca 100755
--- a/copy-builtin
+++ b/copy-builtin
@@ -12,9 +12,16 @@ usage()
KERNEL_DIR="$(readlink --canonicalize-existing "$1")"
MODULES=()
+
+# When integrated in to a monolithic kernel the spl module must appear
+# first. This ensures its module initialization function is run before
+# any of the other module initialization functions which depend on it.
+MODULES+="spl"
+
for MODULE_DIR in module/* module/os/linux/*
do
[ -d "$MODULE_DIR" ] || continue
+ [ "spl" = "${MODULE_DIR##*/}" ] && continue
[ "os" = "${MODULE_DIR#*/}" ] && continue
MODULES+=("${MODULE_DIR#*/}")
done