|
|
8be556 |
From 73b5c1135210b7fc12743bf8e92089e7e1a869ec Mon Sep 17 00:00:00 2001
|
|
|
8be556 |
From: Andrew Jones <drjones@redhat.com>
|
|
|
8be556 |
Date: Tue, 16 Jun 2015 11:48:33 +0200
|
|
|
8be556 |
Subject: [PATCH 071/217] hw/acpi/aml-build: Add aml_or() term
|
|
|
8be556 |
|
|
|
8be556 |
Message-id: <1434455325-23399-22-git-send-email-drjones@redhat.com>
|
|
|
8be556 |
Patchwork-id: 66255
|
|
|
8be556 |
O-Subject: [AArch64 RHEL-7.2 qemu-kvm-rhev PATCH 21/33] hw/acpi/aml-build: Add aml_or() term
|
|
|
8be556 |
Bugzilla: 1231719
|
|
|
8be556 |
RH-Acked-by: Miroslav Rezanina <mrezanin@redhat.com>
|
|
|
8be556 |
RH-Acked-by: Wei Huang <wei@redhat.com>
|
|
|
8be556 |
RH-Acked-by: Igor Mammedov <imammedo@redhat.com>
|
|
|
8be556 |
RH-Acked-by: Laszlo Ersek <lersek@redhat.com>
|
|
|
8be556 |
|
|
|
8be556 |
Author: Shannon Zhao <shannon.zhao@linaro.org>
|
|
|
8be556 |
|
|
|
8be556 |
Signed-off-by: Shannon Zhao <zhaoshenglong@huawei.com>
|
|
|
8be556 |
Signed-off-by: Shannon Zhao <shannon.zhao@linaro.org>
|
|
|
8be556 |
Reviewed-by: Igor Mammedov <imammedo@redhat.com>
|
|
|
8be556 |
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
|
|
|
8be556 |
Message-id: 1432522520-8068-17-git-send-email-zhaoshenglong@huawei.com
|
|
|
8be556 |
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
|
|
|
8be556 |
(cherry picked from commit 922cc8823e484733021a7be5b0e876eba2218623)
|
|
|
8be556 |
Signed-off-by: Andrew Jones <drjones@redhat.com>
|
|
|
8be556 |
Signed-off-by: Miroslav Rezanina <mrezanin@redhat.com>
|
|
|
8be556 |
---
|
|
|
8be556 |
hw/acpi/aml-build.c | 10 ++++++++++
|
|
|
8be556 |
include/hw/acpi/aml-build.h | 1 +
|
|
|
8be556 |
2 files changed, 11 insertions(+)
|
|
|
8be556 |
|
|
|
8be556 |
diff --git a/hw/acpi/aml-build.c b/hw/acpi/aml-build.c
|
|
|
8be556 |
index e2f5845..882f34c 100644
|
|
|
8be556 |
--- a/hw/acpi/aml-build.c
|
|
|
8be556 |
+++ b/hw/acpi/aml-build.c
|
|
|
8be556 |
@@ -456,6 +456,16 @@ Aml *aml_and(Aml *arg1, Aml *arg2)
|
|
|
8be556 |
return var;
|
|
|
8be556 |
}
|
|
|
8be556 |
|
|
|
8be556 |
+/* ACPI 1.0b: 16.2.5.4 Type 2 Opcodes Encoding: DefOr */
|
|
|
8be556 |
+Aml *aml_or(Aml *arg1, Aml *arg2)
|
|
|
8be556 |
+{
|
|
|
8be556 |
+ Aml *var = aml_opcode(0x7D /* OrOp */);
|
|
|
8be556 |
+ aml_append(var, arg1);
|
|
|
8be556 |
+ aml_append(var, arg2);
|
|
|
8be556 |
+ build_append_byte(var->buf, 0x00 /* NullNameOp */);
|
|
|
8be556 |
+ return var;
|
|
|
8be556 |
+}
|
|
|
8be556 |
+
|
|
|
8be556 |
/* ACPI 1.0b: 16.2.5.3 Type 1 Opcodes Encoding: DefNotify */
|
|
|
8be556 |
Aml *aml_notify(Aml *arg1, Aml *arg2)
|
|
|
8be556 |
{
|
|
|
8be556 |
diff --git a/include/hw/acpi/aml-build.h b/include/hw/acpi/aml-build.h
|
|
|
8be556 |
index 29b7dbe..fbd0d0c 100644
|
|
|
8be556 |
--- a/include/hw/acpi/aml-build.h
|
|
|
8be556 |
+++ b/include/hw/acpi/aml-build.h
|
|
|
8be556 |
@@ -201,6 +201,7 @@ Aml *aml_int(const uint64_t val);
|
|
|
8be556 |
Aml *aml_arg(int pos);
|
|
|
8be556 |
Aml *aml_store(Aml *val, Aml *target);
|
|
|
8be556 |
Aml *aml_and(Aml *arg1, Aml *arg2);
|
|
|
8be556 |
+Aml *aml_or(Aml *arg1, Aml *arg2);
|
|
|
8be556 |
Aml *aml_notify(Aml *arg1, Aml *arg2);
|
|
|
8be556 |
Aml *aml_call1(const char *method, Aml *arg1);
|
|
|
8be556 |
Aml *aml_call2(const char *method, Aml *arg1, Aml *arg2);
|
|
|
8be556 |
--
|
|
|
8be556 |
1.8.3.1
|
|
|
8be556 |
|