summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2017-01-05 04:30:44 +0000
committerV3n3RiX <venerix@redcorelinux.org>2017-01-05 04:30:44 +0000
commit753e48130234d58770f4d557ca45ef13d581c668 (patch)
tree3ea6f9b425afcd35e13ef355895c2dde2138ec6d
parent4d8a6dba0506daecc9e9019ba5999374393afff3 (diff)
Revert "forcefully reload dkms modules tree"
This reverts commit b5027a3f4659856dfe7c24258a2e73cfa4067e59.
-rw-r--r--eclass/redcore-kernel.eclass12
1 files changed, 8 insertions, 4 deletions
diff --git a/eclass/redcore-kernel.eclass b/eclass/redcore-kernel.eclass
index f0ac4239..cb855639 100644
--- a/eclass/redcore-kernel.eclass
+++ b/eclass/redcore-kernel.eclass
@@ -724,11 +724,15 @@ _grub2_update_grubcfg() {
fi
}
-_reload_dkms_modules() {
+_remove_dkms_modules() {
+ if [ "${PR}" == "r0" ] ; then
+ local kver="${PV}-${K_ROGKERNEL_SELF_TARBALL_NAME}"
+ else
+ local kver="${PV}-${K_ROGKERNEL_SELF_TARBALL_NAME}-${PR}"
+ fi
if [[ -x $(which dkms) ]] ; then
for i in $(dkms status | cut -d " " -f1,2 | sed -e 's/,//g' | sed -e 's/ /\//g' | sed -e 's/://g') ; do
- dkms remove $i -k --all
- dkms add $i
+ dkms remove $i -k "${kver}"
done
fi
}
@@ -763,7 +767,7 @@ redcore-kernel_pkg_postrm() {
if _is_kernel_binary; then
_dracut_initramfs_delete
fi
- _reload_dkms_modules
+ _remove_dkms_modules
_grub2_update_grubcfg
}