diff options
author | Jordan Hargrave <jordan@cvs.openbsd.org> | 2008-06-12 20:30:10 +0000 |
---|---|---|
committer | Jordan Hargrave <jordan@cvs.openbsd.org> | 2008-06-12 20:30:10 +0000 |
commit | 2197f0bfd36a3c2815caf90dca5d46cd30c06b03 (patch) | |
tree | 25d28eb10c24aeb4b791c27b606b21b3d6a74a91 /sys/dev/acpi | |
parent | c5092916f095f75a47968be440edfd0380a3de6e (diff) |
Fixed AMLOP_LOAD for _PSS on Thinkpad
ok @gwk
Diffstat (limited to 'sys/dev/acpi')
-rw-r--r-- | sys/dev/acpi/dsdt.c | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/sys/dev/acpi/dsdt.c b/sys/dev/acpi/dsdt.c index 5969ac82dd9..2bf9ffb4309 100644 --- a/sys/dev/acpi/dsdt.c +++ b/sys/dev/acpi/dsdt.c @@ -1,4 +1,4 @@ -/* $OpenBSD: dsdt.c,v 1.124 2008/06/12 19:05:42 jordan Exp $ */ +/* $OpenBSD: dsdt.c,v 1.125 2008/06/12 20:30:09 jordan Exp $ */ /* * Copyright (c) 2005 Jordan Hargrave <jordan@openbsd.org> * @@ -4244,11 +4244,13 @@ aml_xparse(struct aml_scope *scope, int ret_type, const char *stype) tmp->v_opregion.iospace != GAS_SYSTEM_MEMORY) { aml_die("LOAD: not a memory region!\n"); } -#if 0 + /* Create buffer and read from memory */ + _aml_setvalue(opargs[1], AML_OBJTYPE_BUFFER, + tmp->v_opregion.iolen, NULL); aml_xgasio(tmp->v_opregion.iospace, tmp->v_opregion.iobase, - tmp->v_opregion.iolen, - opargs[1], ACPI_IOREAD); + tmp->v_opregion.iolen, + opargs[1]->v_buffer, ACPI_IOREAD, 8, ""); /* Validate that this is a SSDT */ if (!valid_acpihdr(opargs[1]->v_buffer, opargs[1]->length, @@ -4256,10 +4258,10 @@ aml_xparse(struct aml_scope *scope, int ret_type, const char *stype) aml_die("LOAD: Not a SSDT!\n"); } - /* Parse block */ + /* Parse block: set header bytes to NOP */ + memset(opargs[1]->v_buffer, AMLOP_NOP, sizeof(struct acpi_table_header)); mscope = aml_xpushscope(scope, opargs[1], scope->node, AMLOP_SCOPE); -#endif break; case AMLOP_UNLOAD: /* DDBHandle */ |