mirror of https://github.com/dynup/kpatch
Merge pull request #175 from jpoimboe/kpatch-list
kpatch: show loaded modules in list command
This commit is contained in:
commit
135b438af0
|
@ -202,18 +202,24 @@ case "$1" in
|
||||||
|
|
||||||
"list")
|
"list")
|
||||||
[[ "$#" -ne 1 ]] && usage
|
[[ "$#" -ne 1 ]] && usage
|
||||||
echo "System installed patches:"
|
echo "Loaded patch modules:"
|
||||||
|
for module in /sys/kernel/kpatch/patches/*; do
|
||||||
|
if [[ -e $module ]] && [[ $(cat $module/enabled) -eq 1 ]]; then
|
||||||
|
echo_patch_name $module
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
echo ""
|
||||||
|
echo "System installed patch modules:"
|
||||||
for i in "$SYSDIR"/*.ko; do
|
for i in "$SYSDIR"/*.ko; do
|
||||||
[[ -e "$i" ]] || continue
|
[[ -e "$i" ]] || continue
|
||||||
echo_patch_name $i
|
echo_patch_name $i
|
||||||
done
|
done
|
||||||
echo ""
|
echo ""
|
||||||
echo "User installed patches:"
|
echo "User installed patch modules:"
|
||||||
for i in "$USERDIR"/*.ko; do
|
for i in "$USERDIR"/*.ko; do
|
||||||
[[ -e "$i" ]] || continue
|
[[ -e "$i" ]] || continue
|
||||||
echo_patch_name $i
|
echo_patch_name $i
|
||||||
done
|
done
|
||||||
echo ""
|
|
||||||
;;
|
;;
|
||||||
|
|
||||||
"info")
|
"info")
|
||||||
|
|
Loading…
Reference in New Issue