public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
From: lushifex <shifeix.a.lu@intel.com>
To: edk2-devel@lists.01.org
Cc: david.wei@intel.com;
Subject: [Patch][edk2-platforms] Vlv2DeviceRefCodePkg: Fixed thermal issue.
Date: Tue, 07 Feb 2017 21:04:09 -0800	[thread overview]
Message-ID: <03d5a230-f082-4285-ac7a-ff2dbd9dd028@SHWDEOPENPSI011.local> (raw)

Fixed System auto shutdown when it reached minus 20 degree.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: lushifex <shifeix.a.lu@intel.com>
---
 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




             reply	other threads:[~2017-02-08  5:07 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-02-08  5:04 lushifex [this message]
2017-02-08  5:45 ` [Patch][edk2-platforms] Vlv2DeviceRefCodePkg: Fixed thermal issue Wei, David
  -- strict thread matches above, loose matches on Subject: below --
2017-01-18  0:47 lushifex
2017-01-18  5:58 ` Wei, David

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-list from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=03d5a230-f082-4285-ac7a-ff2dbd9dd028@SHWDEOPENPSI011.local \
    --to=devel@edk2.groups.io \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox