summaryrefslogtreecommitdiff
path: root/sys/dev
diff options
context:
space:
mode:
authorCan Erkin Acar <canacar@cvs.openbsd.org>2006-06-14 16:30:08 +0000
committerCan Erkin Acar <canacar@cvs.openbsd.org>2006-06-14 16:30:08 +0000
commitfacacdb06253c7da2e5d300623028f757ffbd6be (patch)
treedc50b45d3c848b0b643c0cadb37b1c43dbf5bf67 /sys/dev
parent7a21f3c3a3b4b42062e32070a35c3ff85d3ca907 (diff)
Allow changes to a Name initialized with a 'static' value.
Problem report (PR5149), and debugging by jj.roh at thurnherr dot ch ok marco@
Diffstat (limited to 'sys/dev')
-rw-r--r--sys/dev/acpi/dsdt.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/sys/dev/acpi/dsdt.c b/sys/dev/acpi/dsdt.c
index 3e01996ce08..91bb4c876af 100644
--- a/sys/dev/acpi/dsdt.c
+++ b/sys/dev/acpi/dsdt.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: dsdt.c,v 1.46 2006/05/31 14:02:12 canacar Exp $ */
+/* $OpenBSD: dsdt.c,v 1.47 2006/06/14 16:30:07 canacar Exp $ */
/*
* Copyright (c) 2005 Jordan Hargrave <jordan@openbsd.org>
*
@@ -1722,6 +1722,8 @@ aml_addvname(struct acpi_context *ctx, const char *name, int opcode,
pn->opcode = opcode;
pn->mnem = aml_opname(opcode);
if (val != NULL) {
+ if (val->type == AML_OBJTYPE_STATICINT)
+ val = aml_allocvalue(AML_OBJTYPE_INTEGER, val->v_integer, NULL);
val->name = name;
val->node = pn;
}