--- trunk/virtualbox/virtualbox-config.sh 2011/06/29 14:51:30 1378 +++ trunk/virtualbox/virtualbox-config.sh 2011/06/29 23:15:17 1379 @@ -132,6 +132,14 @@ mecho "Disabled hardware performance counter NMIs ..." echo 2 > /proc/sys/kernel/perf_counter_paranoid fi + 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 + fi else echo -e ${COLRED} echo "Your current running kernel does not match the the module target."