]> git.proxmox.com Git - mirror_ubuntu-artful-kernel.git/commitdiff
Revert "Thermal/int340x: prevent speculative execution"
authorAndy Whitcroft <apw@canonical.com>
Wed, 31 Jan 2018 15:38:28 +0000 (15:38 +0000)
committerKleber Sacilotto de Souza <kleber.souza@canonical.com>
Mon, 5 Feb 2018 15:53:00 +0000 (16:53 +0100)
CVE-2017-5753 (revert embargoed)
CVE-2017-5715 (revert embargoed)

This reverts commit 3904f4cadeeaa9370f0635eb2f66194ca238325b.

Signed-off-by: Andy Whitcroft <apw@canonical.com>
Signed-off-by: Kleber Sacilotto de Souza <kleber.souza@canonical.com>
drivers/thermal/int340x_thermal/int340x_thermal_zone.c

index 4f9917ef3c118aacebbf1acd463005d0ec03d93f..145a5c53ff5c0fd16c579352124394ece156c0eb 100644 (file)
@@ -57,16 +57,15 @@ static int int340x_thermal_get_trip_temp(struct thermal_zone_device *zone,
        if (d->override_ops && d->override_ops->get_trip_temp)
                return d->override_ops->get_trip_temp(zone, trip, temp);
 
-       if (trip < d->aux_trip_nr) {
-               gmb();
+       if (trip < d->aux_trip_nr)
                *temp = d->aux_trips[trip];
-       } else if (trip == d->crt_trip_id) {
+       else if (trip == d->crt_trip_id)
                *temp = d->crt_temp;
-       } else if (trip == d->psv_trip_id) {
+       else if (trip == d->psv_trip_id)
                *temp = d->psv_temp;
-       } else if (trip == d->hot_trip_id) {
+       else if (trip == d->hot_trip_id)
                *temp = d->hot_temp;
-       else {
+       else {
                for (i = 0; i < INT340X_THERMAL_MAX_ACT_TRIP_COUNT; i++) {
                        if (d->act_trips[i].valid &&
                            d->act_trips[i].id == trip) {