]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/hwmon/dme1737.c
lguest: Fix Malicious Guest GDT Host Crash
[linux-2.6-omap-h63xx.git] / drivers / hwmon / dme1737.c
index be3aaa5d0b917414648dfb7cb0f38b54aea1d073..e9cbc727664d4221422be223c3c8ca082231ce67 100644 (file)
@@ -750,7 +750,7 @@ static ssize_t show_temp(struct device *dev, struct device_attribute *attr,
                res = (data->alarms >> DME1737_BIT_ALARM_TEMP[ix]) & 0x01;
                break;
        case SYS_TEMP_FAULT:
-               res = (data->temp[ix] == 0x0800);
+               res = (((u16)data->temp[ix] & 0xff00) == 0x8000);
                break;
        default:
                res = 0;