summaryrefslogtreecommitdiff
path: root/eclass
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2016-12-28 01:20:49 +0000
committerV3n3RiX <venerix@redcorelinux.org>2016-12-28 01:20:49 +0000
commitb5027a3f4659856dfe7c24258a2e73cfa4067e59 (patch)
treee7266ca828ab54ef8d6a0a7be8e37e5679150066 /eclass
parent3f0dab6f6a7426001d8b1ebbab89d8c314cff2c4 (diff)
forcefully reload dkms modules tree
Diffstat (limited to 'eclass')
-rw-r--r--eclass/redcore-kernel.eclass12
1 files changed, 4 insertions, 8 deletions
diff --git a/eclass/redcore-kernel.eclass b/eclass/redcore-kernel.eclass
index cb855639..f0ac4239 100644
--- a/eclass/redcore-kernel.eclass
+++ b/eclass/redcore-kernel.eclass
@@ -724,15 +724,11 @@ _grub2_update_grubcfg() {
fi
}
-_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
+_reload_dkms_modules() {
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 "${kver}"
+ dkms remove $i -k --all
+ dkms add $i
done
fi
}
@@ -767,7 +763,7 @@ redcore-kernel_pkg_postrm() {
if _is_kernel_binary; then
_dracut_initramfs_delete
fi
- _remove_dkms_modules
+ _reload_dkms_modules
_grub2_update_grubcfg
}