--- trunk/virtualbox/virtualbox-guest-config.sh 2012/03/04 12:29:58 1685 +++ trunk/virtualbox/virtualbox-guest-config.sh 2012/03/04 12:32:49 1686 @@ -147,13 +147,13 @@ # calc module dependencies mecho "Calculating module dependencies ..." depmod -a ${KERNEL_VERSION} +fi - # re-read udev rules to grant the right permissions - if [[ -x $(which udevadm) ]] - then - mecho "Reloading udev configuration ..." - udevadm control --reload-rules - fi +# re-read udev rules to grant the right permissions +if [[ -x $(which udevadm) ]] +then + mecho "Reloading udev configuration ..." + udevadm control --reload-rules fi # load the module @@ -164,23 +164,6 @@ mecho "Loading kernel-module ${module} ..." modprobe ${module} done - - if [ $(echo ${KERNEL_VERSION%%-*} | sed 's:\.::g') -ge 2639 ] - then - # fixes NMI warnings with kernels >=2.6.31: - # vboxdrv: Warning: 2.6.31+ kernel detected. Most likely the hardware performance - # vboxdrv: counter framework which can generate NMIs is active. - mecho "Disabled hardware performance counter NMIs ..." - echo 2 > /proc/sys/kernel/perf_event_paranoid - - elif [ $(echo ${KERNEL_VERSION%%-*} | sed 's:\.::g') -ge 2631 ] - then - # fixes NMI warnings with kernels >=2.6.31: - # vboxdrv: Warning: 2.6.31+ kernel detected. Most likely the hardware performance - # vboxdrv: counter framework which can generate NMIs is active. - mecho "Disabled hardware performance counter NMIs ..." - echo 2 > /proc/sys/kernel/perf_counter_paranoid - fi else echo -e ${COLRED} echo "Your current running kernel does not match the the module target."