Skip to content
This repository has been archived by the owner on May 3, 2024. It is now read-only.

Commit

Permalink
CORTX-30751: Codacy code cleanup (#1606)
Browse files Browse the repository at this point in the history
This patch fixes some of the codacy warnings.
warning fixed : "Double quote to prevent globing and words splitting".

Signed-off-by: Rinku Kothiya <rinku.kothiya@seagate.com>
  • Loading branch information
rkothiya committed Aug 20, 2022
1 parent 12ecf22 commit f08decb
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions scripts/systemtap/kem/kem_run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
#
# $ make

KEM_DIR="$(readlink -f $0)"
KEM_DIR=$(readlink -f "$0")
KEM_DIR="${KEM_DIR%/*}"

if [ "$EUID" -ne 0 ]; then
Expand All @@ -34,15 +34,15 @@ if [ "$EUID" -ne 0 ]; then
fi

echo Inserting kemd.ko
insmod $KEM_DIR/kemd.ko
insmod "$KEM_DIR/kemd.ko"

for i in $(seq 0 $(($(nproc)-1)))
do
mknod /dev/kemd$i c 60 $i
mknod "/dev/kemd$i" c 60 "$i"
done

echo Running Systemtap
stap -g $KEM_DIR/kemd.stp &
stap -g "$KEM_DIR/kemd.stp" &
stapPID=$!

# Wait stap for start
Expand All @@ -51,7 +51,7 @@ sleep 20
echo Running KEM clients
for i in $(seq 0 $(($(nproc)-1)))
do
$KEM_DIR/m0kemc $i > kemc_cpu$i.log 2>&1 &
"$KEM_DIR/m0kemc" "$i" > kemc_cpu"$i".log 2>&1 &
kemcPIDs[$i]=$!
done

Expand All @@ -70,14 +70,14 @@ sleep 2

for i in $(seq 0 $(($(nproc)-1)))
do
rm -f /dev/kemd$i
rm -f "/dev/kemd$i"
done

echo Removing kemd.ko
rmmod $KEM_DIR/kemd.ko
rmmod "$KEM_DIR/kemd.ko"

for i in $(seq 0 $(($(nproc)-1)))
do
$KEM_DIR/../../../utils/m0run m0addb2dump $PWD/_kemc$i/o/100000000000000:2 | grep pagefault -A 1 | head -n 40
$KEM_DIR/../../../utils/m0run m0addb2dump $PWD/_kemc$i/o/100000000000000:2 | grep ctx_switch -A 1 | head -n 40
"$KEM_DIR/../../../utils/m0run m0addb2dump" "$PWD"/_kemc"$i"/o/100000000000000:2 | grep pagefault -A 1 | head -n 40
"$KEM_DIR/../../../utils/m0run m0addb2dump" "$PWD"/_kemc"$i"/o/100000000000000:2 | grep ctx_switch -A 1 | head -n 40
done

0 comments on commit f08decb

Please sign in to comment.