aboutsummaryrefslogtreecommitdiff
path: root/hw/acpi/aml-build.c
diff options
context:
space:
mode:
authorIgor Mammedov <imammedo@redhat.com>2015-02-18 19:14:40 +0000
committerMichael S. Tsirkin <mst@redhat.com>2015-02-26 13:04:16 +0100
commit15e44e56d7da9d4569c10aa8de5f109a71570670 (patch)
treeecddff045901e8d8809081b281e4855b56dfe3da /hw/acpi/aml-build.c
parenta678508e46ac806d81bd401a483aef1b98734ae4 (diff)
acpi: add aml_equal() term
Signed-off-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'hw/acpi/aml-build.c')
-rw-r--r--hw/acpi/aml-build.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/hw/acpi/aml-build.c b/hw/acpi/aml-build.c
index 36aafe4bfb..97b027c380 100644
--- a/hw/acpi/aml-build.c
+++ b/hw/acpi/aml-build.c
@@ -514,6 +514,16 @@ Aml *aml_io(AmlIODecode dec, uint16_t min_base, uint16_t max_base,
return var;
}
+/* ACPI 1.0b: 16.2.5.4 Type 2 Opcodes Encoding: DefLEqual */
+Aml *aml_equal(Aml *arg1, Aml *arg2)
+{
+ Aml *var = aml_opcode(0x93 /* LequalOp */);
+ aml_append(var, arg1);
+ aml_append(var, arg2);
+ build_append_int(var->buf, 0x00); /* NullNameOp */
+ return var;
+}
+
/* ACPI 1.0b: 16.2.5.3 Type 1 Opcodes Encoding: DefIfElse */
Aml *aml_if(Aml *predicate)
{