diff --git a/microcode_ctl.spec b/microcode_ctl.spec index 03b4543..e58680b 100644 --- a/microcode_ctl.spec +++ b/microcode_ctl.spec @@ -78,6 +78,16 @@ fi /sbin/chkconfig --add microcode_ctl %triggerpostun -- kernel-utils +# Only enable on Intel machines. +vendor=`cat /proc/cpuinfo | grep "^vendor_id" | sort -u | awk -F ": " '{ print $2 }'` +if [ "$vendor" != "GenuineIntel" ]; then + exit 0; +fi +# Microcode wasn't available until 686's. +family=`cat /proc/cpuinfo | grep "^cpu family" | sort -u | awk -F ": " '{ print $2 }'` +if [ $family -lt 6 ]; then + exit 0; +fi /sbin/chkconfig --add microcode_ctl exit 0