[coreboot-gerrit] Patch set updated for coreboot: asrock/e350m1: Remove unused smbus.asl and thermal.asl

Tobias Diedrich (ranma+coreboot@tdiedrich.de) gerrit at coreboot.org
Mon Jun 15 01:01:15 CEST 2015


Tobias Diedrich (ranma+coreboot at tdiedrich.de) just uploaded a new patch set to gerrit, which you can find at http://review.coreboot.org/10548

-gerrit

commit a78c84994dc78cfe6af5936b216624ed527ca354
Author: Tobias Diedrich <ranma+coreboot at tdiedrich.de>
Date:   Sun Jun 14 21:22:49 2015 +0200

    asrock/e350m1: Remove unused smbus.asl and thermal.asl
    
    The smbus.asl operation regions prevent the Linux i2c driver (i2c_piix4)
    for this chipset from claiming the ioport ranges and thus it fails to
    load.
    
    The methods defined in smbus.asl are only used in the thermal zone, but
    the DSDT of the vendor firmware has no thermal zone and the temperature
    reading and fan control are handled by the NCT5572D superio instead.
    
    Case in point: The fallback "smbus read failed" temperature is 40 C
    and the REACTS logs for this board all show:
    "ACPI: Thermal Zone [TZ00] (40 C)"
    e.g.
    http://review.coreboot.org/gitweb?p=board-status.git;a=blob;f=asrock/e350m1/4.0-5054-gf584218/2013-12-20T20:56:20Z/kernel_log.txt#l390
    and
    http://review.coreboot.org/gitweb?p=board-status.git;a=blob;f=asrock/e350m1/4.0-7030-g6d7de4f/2014-10-16T15:34:19Z/kernel_console.txt#l404
    and
    http://review.coreboot.org/gitweb?p=board-status.git;a=blob;f=asrock/e350m1/4.0-9989-gf2dfef0/2015-06-13T00:22:49Z/kernel_log.txt#l425
    
    In particular due to the following check in i2c-piix4.c will fail unless
    acpi_enforce_resources=no is explicitly set on the Linux kernel
    parameters:
      if (acpi_check_region(piix4_smba, SMBIOSIZE, piix4_driver.name))
              return -ENODEV;
    
    Depending on kernel options the only error message printed is
    
      ACPI Warning: SystemIO range 0x0000000000000B00-0x0000000000000B07 conflicts with OpRegion 0x0000000000000B00-0x0000000000000B0B (\SMB0) (20150410/utaddress-254)
      ACPI: If an ACPI driver is available for this device, you should use it instead of the native driver
    
    However since it does not implement a standard interface there is no
    native ACPI driver for smbus.asl.
    
    Change-Id: I05b1993e1bc5e7a1cb25c730abbb6e729487d75d
    Signed-off-by: Tobias Diedrich <ranma+coreboot at tdiedrich.de>
---
 src/mainboard/asrock/e350m1/acpi/thermal.asl | 88 ----------------------------
 src/mainboard/asrock/e350m1/dsdt.asl         |  2 -
 2 files changed, 90 deletions(-)

diff --git a/src/mainboard/asrock/e350m1/acpi/thermal.asl b/src/mainboard/asrock/e350m1/acpi/thermal.asl
deleted file mode 100644
index 440c17d..0000000
--- a/src/mainboard/asrock/e350m1/acpi/thermal.asl
+++ /dev/null
@@ -1,88 +0,0 @@
-/*
- * This file is part of the coreboot project.
- *
- * Copyright (C) 2011 Advanced Micro Devices, Inc.
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc.
- */
-
-/* THERMAL */
-Scope(\_TZ) {
-	Name (KELV, 2732)
-	Name (THOT, 800)
-	Name (TCRT, 850)
-
-	ThermalZone(TZ00) {
-		Method(_AC0,0) {	/* Active Cooling 0 (0=highest fan speed) */
-			/* DBGO("\\_TZ\\TZ00\\_AC0\n") */
-			Return(Add(0, 2730))
-		}
-		Method(_AL0,0) {	/* Returns package of cooling device to turn on */
-			/* DBGO("\\_TZ\\TZ00\\_AL0\n") */
-			Return(Package() {\_TZ.TZ00.FAN0})
-		}
-		Device (FAN0) {
-			Name(_HID, EISAID("PNP0C0B"))
-			Name(_PR0, Package() {PFN0})
-		}
-
-		PowerResource(PFN0,0,0) {
-			Method(_STA) {
-				Store(0xF,Local0)
-				Return(Local0)
-			}
-			Method(_ON) {
-				/* DBGO("\\_TZ\\TZ00\\FAN0 _ON\n") */
-			}
-			Method(_OFF) {
-				/* DBGO("\\_TZ\\TZ00\\FAN0 _OFF\n") */
-			}
-		}
-
-		Method(_HOT,0) {	/* return hot temp in tenths degree Kelvin */
-			/* DBGO("\\_TZ\\TZ00\\_HOT\n") */
-			Return (Add (THOT, KELV))
-		}
-		Method(_CRT,0) {	/* return critical temp in tenths degree Kelvin */
-			/* DBGO("\\_TZ\\TZ00\\_CRT\n") */
-			Return (Add (TCRT, KELV))
-		}
-		Method(_TMP,0) {	/* return current temp of this zone */
-			Store (SMBR (0x07, 0x4C,, 0x00), Local0)
-			If (LGreater (Local0, 0x10)) {
-				Store (Local0, Local1)
-			}
-			Else {
-				Add (Local0, THOT, Local0)
-				Return (Add (400, KELV))
-			}
-
-			Store (SMBR (0x07, 0x4C, 0x01), Local0)
-			/* only the two MSBs in the external temperature low byte are used, resolution 0.25. We ignore it */
-			/* Store (SMBR (0x07, 0x4C, 0x10), Local2) */
-			If (LGreater (Local0, 0x10)) {
-				If (LGreater (Local0, Local1)) {
-					Store (Local0, Local1)
-				}
-
-				Multiply (Local1, 10, Local1)
-				Return (Add (Local1, KELV))
-			}
-			Else {
-				Add (Local0, THOT, Local0)
-				Return (Add (400 , KELV))
-			}
-		} /* end of _TMP */
-	} /* end of TZ00 */
-}
diff --git a/src/mainboard/asrock/e350m1/dsdt.asl b/src/mainboard/asrock/e350m1/dsdt.asl
index 6dcf0a6..71ea450 100644
--- a/src/mainboard/asrock/e350m1/dsdt.asl
+++ b/src/mainboard/asrock/e350m1/dsdt.asl
@@ -57,7 +57,5 @@ DefinitionBlock (
 	#include "acpi/sleep.asl"
 
 	#include "acpi/gpe.asl"
-	#include <southbridge/amd/cimx/sb800/acpi/smbus.asl>
-	#include "acpi/thermal.asl"
 }
 /* End of ASL file */



More information about the coreboot-gerrit mailing list