Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tree: fix latest shellcheck complaints #1418

Merged
merged 1 commit into from
Oct 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions kpatch-build/kpatch-build
Original file line number Diff line number Diff line change
Expand Up @@ -1167,7 +1167,7 @@ if [[ -n "$CONFIG_LIVEPATCH" ]] && (kernel_is_rhel || kernel_version_gte 4.9.0);
if use_klp_arch; then
USE_KLP_ARCH=1
KPATCH_LDFLAGS="--unique=.parainstructions --unique=.altinstructions"
CDO_FLAGS="--klp-arch"
CDO_FLAGS+=("--klp-arch")
fi

if [[ "$KLP_REPLACE" -eq 1 ]] ; then
Expand Down Expand Up @@ -1421,7 +1421,7 @@ for i in $FILES; do

# create-diff-object orig.o patched.o parent-name parent-symtab
# Module.symvers patch-mod-name output.o
"$TOOLSDIR"/create-diff-object $CDO_FLAGS "orig/$i" "patched/$i" "$KOBJFILE_NAME" \
"$TOOLSDIR"/create-diff-object "${CDO_FLAGS[@]}" "orig/$i" "patched/$i" "$KOBJFILE_NAME" \
"$SYMTAB" "$SYMVERS_FILE" "${MODNAME//-/_}" \
"output/$i" 2>&1 | logger 1
check_pipe_status create-diff-object
Expand Down Expand Up @@ -1491,7 +1491,7 @@ cd "$TEMPDIR/patch" || die

# We no longer need kpatch-cc
for ((idx=0; idx<${#MAKEVARS[@]}; idx++)); do
MAKEVARS[$idx]=${MAKEVARS[$idx]/${KPATCH_CC_PREFIX}/}
MAKEVARS[idx]=${MAKEVARS[idx]/${KPATCH_CC_PREFIX}/}
done

export KPATCH_BUILD="$KERNEL_SRCDIR" KPATCH_NAME="$MODNAME" \
Expand All @@ -1504,10 +1504,10 @@ make "${MAKEVARS[@]}" 2>&1 | logger || die

if [[ "$USE_KLP" -eq 1 ]]; then
if [[ "$USE_KLP_ARCH" -eq 0 ]]; then
extra_flags="--no-klp-arch-sections"
extra_flags+=("--no-klp-arch-sections")
fi
cp -f "$TEMPDIR/patch/$MODNAME.ko" "$TEMPDIR/patch/tmp.ko" || die
"$TOOLSDIR"/create-klp-module $extra_flags "$TEMPDIR/patch/tmp.ko" "$TEMPDIR/patch/$MODNAME.ko" 2>&1 | logger 1
"$TOOLSDIR"/create-klp-module "${extra_flags[@]}" "$TEMPDIR/patch/tmp.ko" "$TEMPDIR/patch/$MODNAME.ko" 2>&1 | logger 1
check_pipe_status create-klp-module
[[ "$rc" -ne 0 ]] && die "create-klp-module: exited with return code: $rc"
fi
Expand Down
1 change: 0 additions & 1 deletion kpatch/kpatch
Original file line number Diff line number Diff line change
Expand Up @@ -355,7 +355,6 @@ load_module () {
i=$((i+1))
if [[ $i -eq $MAX_LOAD_ATTEMPTS ]]; then
die "failed to load module $module"
break
else
warn "retrying..."
sleep $RETRY_INTERVAL
Expand Down
2 changes: 1 addition & 1 deletion test/integration/lib.sh
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ kpatch_photon_dependencies()
if [[ -z "$flavor" ]]; then
tdnf install -y linux-debuginfo
else
tdnf install -y linux-$flavor-debuginfo
tdnf install -y linux-"$flavor"-debuginfo
fi
}

Expand Down
Loading