Blame SOURCES/rhbz1650594.patch

958cb3
commit 734f5acf6c568c02254a33730c6f0fff016bdd09
958cb3
Author: Martin Cermak <mcermak@redhat.com>
958cb3
Date:   Wed Jan 20 22:09:49 2021 +0100
958cb3
958cb3
    systemtap-service onboot: Skip updating the bootloader
958cb3
    
958cb3
    It shows up that just modifying the default initrd is good enough,
958cb3
    no need to call kernel-install or new-kernel-pkg.  This speeds up
958cb3
    the systemtap-service onboot operation.
958cb3
958cb3
diff --git a/initscript/systemtap.in b/initscript/systemtap.in
958cb3
index 713f7a680..b1621ae2f 100755
958cb3
--- a/initscript/systemtap.in
958cb3
+++ b/initscript/systemtap.in
958cb3
@@ -46,8 +46,6 @@ STAPRUN=@bindir@/staprun
958cb3
 UNAME=/bin/uname
958cb3
 LSMOD=/sbin/lsmod
958cb3
 DRACUT=`which dracut`
958cb3
-NEWKERNELPKG=/sbin/new-kernel-pkg
958cb3
-KERNELINSTALL=/usr/bin/kernel-install
958cb3
 
958cb3
 # Not actually used directly, but needed by
958cb3
 # stap dracut module for inclusion in initramfs
958cb3
@@ -839,10 +837,6 @@ backup_initramfs() {
958cb3
 
958cb3
 onboot () {
958cb3
   local s ret ss
958cb3
-  if [ ! -f "$NEWKERNELPKG" -a ! -f "$KERNELINSTALL" ]; then
958cb3
-    do_failure "Could not find $NEWKERNELPKG nor $KERNELINSTALL"
958cb3
-    return 1
958cb3
-  fi
958cb3
   if [ ! -f "$DRACUT" ]; then
958cb3
     do_failure "$DRACUT not found"
958cb3
     return 1
958cb3
@@ -940,20 +934,6 @@ onboot () {
958cb3
     return 0
958cb3
   fi
958cb3
   clog "done"
958cb3
-  # We're installing the initramfs in the default location, so user
958cb3
-  # expects the next boot to use it. Let's also update the bootloader.
958cb3
-  clog " Updating bootloader ... " -n
958cb3
-  if [ -x "$NEWKERNELPKG" ]; then
958cb3
-      logex $NEWKERNELPKG --initrdfile="$INITRAMFS" \
958cb3
-            --update $KRELEASE
958cb3
-  else
958cb3
-      logex $KERNELINSTALL add $KRELEASE /boot/vmlinuz-$KRELEASE
958cb3
-  fi
958cb3
-  if [ $? -ne 0 ]; then
958cb3
-    do_failure "bootloader update exited with nonzero status"
958cb3
-    return 1
958cb3
-  fi
958cb3
-  might_success "initramfs created and bootloader updated"
958cb3
   return 0
958cb3
 }
958cb3