aboutsummaryrefslogtreecommitdiff
path: root/hw
diff options
context:
space:
mode:
authorMarcel Apfelbaum <marcel@redhat.com>2015-05-25 18:33:45 +0300
committerMichael S. Tsirkin <mst@redhat.com>2015-06-01 14:18:54 +0200
commitaf39d5363f373e6c1168a0e84658d6e4ef57fa8c (patch)
tree9b59faec0e00f53444fa751d2bbf886e0396d656 /hw
parentf7bd7b8eb6573ed22bfc51e148455a1c0a1e36d0 (diff)
acpi: add aml_increment() term
Add encoding for ACPI DefIncrement Opcode. Reviewed-by: Shannon Zhao <zhaoshenglong@huawei.com> Reviewed-by: Igor Mammedov <imammedo@redhat.com> Signed-off-by: Marcel Apfelbaum <marcel@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'hw')
-rw-r--r--hw/acpi/aml-build.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/hw/acpi/aml-build.c b/hw/acpi/aml-build.c
index 045a4e2ee3..f26466aedd 100644
--- a/hw/acpi/aml-build.c
+++ b/hw/acpi/aml-build.c
@@ -494,6 +494,14 @@ Aml *aml_add(Aml *arg1, Aml *arg2)
return var;
}
+/* ACPI 1.0b: 16.2.5.4 Type 2 Opcodes Encoding: DefIncrement */
+Aml *aml_increment(Aml *arg)
+{
+ Aml *var = aml_opcode(0x75 /* IncrementOp */);
+ aml_append(var, arg);
+ return var;
+}
+
/* ACPI 1.0b: 16.2.5.4 Type 2 Opcodes Encoding: DefIndex */
Aml *aml_index(Aml *arg1, Aml *idx)
{