From owner-freebsd-acpi@FreeBSD.ORG Mon Feb 2 14:53:52 2009 Return-Path: Delivered-To: freebsd-acpi@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 758C4106567B for ; Mon, 2 Feb 2009 14:53:52 +0000 (UTC) (envelope-from avg@icyb.net.ua) Received: from citadel.icyb.net.ua (citadel.icyb.net.ua [212.40.38.140]) by mx1.freebsd.org (Postfix) with ESMTP id 9B26A8FC16 for ; Mon, 2 Feb 2009 14:53:51 +0000 (UTC) (envelope-from avg@icyb.net.ua) Received: from odyssey.starpoint.kiev.ua (alpha-e.starpoint.kiev.ua [212.40.38.101]) by citadel.icyb.net.ua (8.8.8p3/ICyb-2.3exp) with ESMTP id QAA20026 for ; Mon, 02 Feb 2009 16:53:49 +0200 (EET) (envelope-from avg@icyb.net.ua) Message-ID: <498708FD.9030404@icyb.net.ua> Date: Mon, 02 Feb 2009 16:53:49 +0200 From: Andriy Gapon User-Agent: Thunderbird 2.0.0.19 (X11/20090110) MIME-Version: 1.0 To: freebsd-acpi@FreeBSD.org Content-Type: multipart/mixed; boundary="------------000900040103080300000503" Cc: Subject: piix4 and C2: patch for BRLD_EN_BM/ACPI_BITREG_BUS_MASTER_RLD X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 02 Feb 2009 14:53:52 -0000 This is a multi-part message in MIME format. --------------000900040103080300000503 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Another patch for acpi_cpu code related to PIIX4 chipset. We do not support C3 with this chipset and as such we never touch ACPI_BITREG_BUS_MASTER_RLD when running on it. It's also possible (probable) that we never reset ACPI_BITREG_BUS_MASTER_STATUS (because of CPU_QUIRK_NO_BM_CTRL). So, if BIOS configures ACPI_BITREG_BUS_MASTER_RLD to 1 and ACPI_BITREG_BUS_MASTER_STATUS gets set to 1, we would get a situation where the system would always immediately break out of C2 state should we ever attempt to enter it. Actually, ACPI spec says that bus master activity need not break out of C2 state (only interrupts must do that). Given all of the above, it seems to be safe and desired to reset ACPI_BITREG_BUS_MASTER_RLD to zero with this chipset. The patch is successfully tested on a real system that exhibited the above behavior (immediate backout from cx_lowest of C2 to C1). -- Andriy Gapon --------------000900040103080300000503 Content-Type: text/plain; name="piix4_c2.diff" Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename="piix4_c2.diff" ZGlmZiAtLWdpdCBhL3N5cy9kZXYvYWNwaWNhL2FjcGlfY3B1LmMgYi9zeXMvZGV2L2FjcGlj YS9hY3BpX2NwdS5jCmluZGV4IDNjNGFkNGUuLjczZjVlOWMgMTAwNjQ0Ci0tLSBhL3N5cy9k ZXYvYWNwaWNhL2FjcGlfY3B1LmMKKysrIGIvc3lzL2Rldi9hY3BpY2EvYWNwaV9jcHUuYwpA QCAtMTA2Miw2ICsxMDYyLDEwIEBAIGFjcGlfY3B1X3F1aXJrcyh2b2lkKQogCSAqCiAJICog QWxzbywgbWFrZSBzdXJlIHRoYXQgYWxsIGludGVycnVwdHMgY2F1c2UgYSAiU3RvcCBCcmVh ayIKIAkgKiBldmVudCB0byBleGl0IGZyb20gQzIgc3RhdGUuCisJICogQWxzbywgQlJMRF9F Tl9CTSAoQUNQSV9CSVRSRUdfQlVTX01BU1RFUl9STEQgaW4gQUNQSS1zcGVhaykKKwkgKiBz aG91bGQgYmUgc2V0IHRvIHplcm8sIG90aGVyd2lzZSBpdCBjYXVzZXMgQzIgdG8gc2hvcnQt c2xlZXAuCisJICogUElJWDQgZG9lc24ndCBwcm9wZXJseSBzdXBwb3J0IEMzIGFuZCBidXMg bWFzdGVyIGFjdGl2aXR5CisJICogbmVlZCBub3QgYnJlYWsgb3V0IG9mIEMyLgogCSAqLwog CWNhc2UgUENJX1JFVklTSU9OX0FfU1RFUDoKIAljYXNlIFBDSV9SRVZJU0lPTl9CX1NURVA6 CkBAIC0xMDc0LDEwICsxMDc4LDE2IEBAIGFjcGlfY3B1X3F1aXJrcyh2b2lkKQogCSAgICB2 YWwgPSBwY2lfcmVhZF9jb25maWcoYWNwaV9kZXYsIFBJSVg0X0RFVkFDVEJfUkVHLCA0KTsK IAkgICAgaWYgKCh2YWwgJiBQSUlYNF9TVE9QX0JSRUFLX01BU0spICE9IFBJSVg0X1NUT1Bf QlJFQUtfTUFTSykgewogCQlBQ1BJX0RFQlVHX1BSSU5UKChBQ1BJX0RCX0lORk8sCi0JCSAg ICAiUElJWDQ6IGVuYWJsaW5nIElSUXMgdG8gZ2VuZXJhdGUgU3RvcCBCcmVha1xuIikpOwor CQkgICAgImFjcGlfY3B1OiBQSUlYNDogZW5hYmxpbmcgSVJRcyB0byBnZW5lcmF0ZSBTdG9w IEJyZWFrXG4iKSk7CiAJICAgIAl2YWwgfD0gUElJWDRfU1RPUF9CUkVBS19NQVNLOwogCQlw Y2lfd3JpdGVfY29uZmlnKGFjcGlfZGV2LCBQSUlYNF9ERVZBQ1RCX1JFRywgdmFsLCA0KTsK IAkgICAgfQorCSAgICBBY3BpR2V0UmVnaXN0ZXIoQUNQSV9CSVRSRUdfQlVTX01BU1RFUl9S TEQsICZ2YWwpOworCSAgICBpZiAodmFsKSB7CisJCUFDUElfREVCVUdfUFJJTlQoKEFDUElf REJfSU5GTywKKwkJICAgICJhY3BpX2NwdTogUElJWDQ6IHJlc2V0IEJSTERfRU5fQk1cbiIp KTsKKwkJQWNwaVNldFJlZ2lzdGVyKEFDUElfQklUUkVHX0JVU19NQVNURVJfUkxELCAwKTsK KwkgICAgfQogCSAgICBicmVhazsKIAlkZWZhdWx0OgogCSAgICBicmVhazsK --------------000900040103080300000503--