summaryrefslogtreecommitdiffstats
path: root/scripts/zfs.sh
diff options
context:
space:
mode:
authorGiuseppe Di Natale <[email protected]>2017-09-18 14:23:09 -0700
committerBrian Behlendorf <[email protected]>2017-09-18 14:23:09 -0700
commitea49beba66106dcb272b43323fad147df1df13fd (patch)
tree968b728491e8db5d289f2084253b4ce0944a083d /scripts/zfs.sh
parenta35b4cc8cca6eed5e93d54aa9ca2c72273a8943b (diff)
Correct shellcheck errors
The ZFS buildbot moved to using Ubuntu 17.04 for the STYLE builder which has a newer version of shellcheck. Correct the new issues it discovers. Reviewed-by: loli10K <[email protected]> Reviewed-by: Brian Behlendorf <[email protected]> Signed-off-by: Giuseppe Di Natale <[email protected]> Closes #6647
Diffstat (limited to 'scripts/zfs.sh')
-rwxr-xr-xscripts/zfs.sh18
1 files changed, 9 insertions, 9 deletions
diff --git a/scripts/zfs.sh b/scripts/zfs.sh
index 7dbb51a17..8ece6ef5f 100755
--- a/scripts/zfs.sh
+++ b/scripts/zfs.sh
@@ -72,8 +72,8 @@ kill_zed() {
}
check_modules() {
- local LOADED_MODULES=""
- local MISSING_MODULES=""
+ LOADED_MODULES=""
+ MISSING_MODULES=""
for KMOD in $KMOD_SPL $KMOD_SPLAT $KMOD_ZAVL $KMOD_ZNVPAIR \
$KMOD_ZUNICODE $KMOD_ZCOMMON $KMOD_ICP $KMOD_ZFS; do
@@ -104,7 +104,7 @@ check_modules() {
}
load_module() {
- local KMOD=$1
+ KMOD=$1
FILE=$(modinfo "$KMOD" | awk '/^filename:/ {print $2}')
VERSION=$(modinfo "$KMOD" | awk '/^version:/ {print $2}')
@@ -146,7 +146,7 @@ load_modules() {
}
unload_module() {
- local KMOD=$1
+ KMOD=$1
NAME=$(basename "$KMOD" .ko)
FILE=$(modinfo "$KMOD" | awk '/^filename:/ {print $2}')
@@ -188,8 +188,8 @@ unload_modules() {
}
stack_clear() {
- local STACK_MAX_SIZE=/sys/kernel/debug/tracing/stack_max_size
- local STACK_TRACER_ENABLED=/proc/sys/kernel/stack_tracer_enabled
+ STACK_MAX_SIZE=/sys/kernel/debug/tracing/stack_max_size
+ STACK_TRACER_ENABLED=/proc/sys/kernel/stack_tracer_enabled
if [ -e "$STACK_MAX_SIZE" ]; then
echo 1 >"$STACK_TRACER_ENABLED"
@@ -198,9 +198,9 @@ stack_clear() {
}
stack_check() {
- local STACK_MAX_SIZE=/sys/kernel/debug/tracing/stack_max_size
- local STACK_TRACE=/sys/kernel/debug/tracing/stack_trace
- local STACK_LIMIT=7600
+ STACK_MAX_SIZE=/sys/kernel/debug/tracing/stack_max_size
+ STACK_TRACE=/sys/kernel/debug/tracing/stack_trace
+ STACK_LIMIT=7600
if [ -e "$STACK_MAX_SIZE" ]; then
STACK_SIZE=$(cat "$STACK_MAX_SIZE")