From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 5366981F6E for ; Tue, 7 Feb 2017 21:07:56 -0800 (PST) Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by fmsmga102.fm.intel.com with ESMTP; 07 Feb 2017 21:07:55 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.33,346,1477983600"; d="scan'208";a="63151475" Received: from shwdeopenpsi011.ccr.corp.intel.com (HELO SHWDEOPENPSI011.local) ([10.239.9.8]) by fmsmga006.fm.intel.com with SMTP; 07 Feb 2017 21:07:55 -0800 Date: Tue, 07 Feb 2017 21:04:09 -0800 From: lushifex CC: david.wei@intel.com; Sender: lushifex To: edk2-devel@lists.01.org Message-ID: <03d5a230-f082-4285-ac7a-ff2dbd9dd028@SHWDEOPENPSI011.local> X-Mailer: TortoiseGit MIME-Version: 1.0 Subject: [Patch][edk2-platforms] Vlv2DeviceRefCodePkg: Fixed thermal issue. X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 08 Feb 2017 05:07:56 -0000 Content-Type: text/plain; Fixed System auto shutdown when it reached minus 20 degree. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: lushifex --- Vlv2DeviceRefCodePkg/AcpiTablesPCAT/THERMAL.ASL | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/Vlv2DeviceRefCodePkg/AcpiTablesPCAT/THERMAL.ASL b/Vlv2DeviceRefCodePkg/AcpiTablesPCAT/THERMAL.ASL index e63f5bc..fecc040 100644 --- a/Vlv2DeviceRefCodePkg/AcpiTablesPCAT/THERMAL.ASL +++ b/Vlv2DeviceRefCodePkg/AcpiTablesPCAT/THERMAL.ASL @@ -5,7 +5,7 @@ ;* Family of Customer Reference Boards. *; ;* *; ;* *; -;* Copyright (c) 1999 - 2014, Intel Corporation. All rights reserved *; +;* Copyright (c) 1999 - 2017, Intel Corporation. All rights reserved *; ; ; This program and the accompanying materials are licensed and made available under ; the terms and conditions of the BSD License that accompanies this distribution. @@ -69,7 +69,12 @@ Scope(\_TZ) { Store(DTS1,Local0) } - Return(Add(2732,Multiply(Local0,10))) + If (LEqual(And(Local0, 0x80), 0)) { + Return(Add(2732,Multiply(Local0,10))) + } else { + Add(Subtract(255, Local0), 1, Local0) + Return(Subtract(2732,Multiply(Local0,10))) + } // // Else return a static value if both EC and DTS are unavailable. // -- 2.7.0.windows.1