[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PULL 45/55] acpi: extend aml_shiftright() to accept target
From: |
Michael S. Tsirkin |
Subject: |
[Qemu-devel] [PULL 45/55] acpi: extend aml_shiftright() to accept target argument |
Date: |
Tue, 22 Dec 2015 18:54:47 +0200 |
From: Igor Mammedov <address@hidden>
it allows to express ShiftRight(A,B,C) syntax
Signed-off-by: Igor Mammedov <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>
Reviewed-by: Marcel Apfelbaum <address@hidden>
---
include/hw/acpi/aml-build.h | 2 +-
hw/acpi/aml-build.c | 4 ++--
hw/i386/acpi-build.c | 2 +-
3 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/include/hw/acpi/aml-build.h b/include/hw/acpi/aml-build.h
index c3d3fd5..365e388 100644
--- a/include/hw/acpi/aml-build.h
+++ b/include/hw/acpi/aml-build.h
@@ -229,7 +229,7 @@ Aml *aml_store(Aml *val, Aml *target);
Aml *aml_and(Aml *arg1, Aml *arg2);
Aml *aml_or(Aml *arg1, Aml *arg2);
Aml *aml_shiftleft(Aml *arg1, Aml *count);
-Aml *aml_shiftright(Aml *arg1, Aml *count);
+Aml *aml_shiftright(Aml *arg1, Aml *count, Aml *dst);
Aml *aml_lless(Aml *arg1, Aml *arg2);
Aml *aml_add(Aml *arg1, Aml *arg2, Aml *dst);
Aml *aml_subtract(Aml *arg1, Aml *arg2, Aml *dst);
diff --git a/hw/acpi/aml-build.c b/hw/acpi/aml-build.c
index f58eb01..9337b87 100644
--- a/hw/acpi/aml-build.c
+++ b/hw/acpi/aml-build.c
@@ -491,9 +491,9 @@ Aml *aml_shiftleft(Aml *arg1, Aml *count)
}
/* ACPI 1.0b: 16.2.5.4 Type 2 Opcodes Encoding: DefShiftRight */
-Aml *aml_shiftright(Aml *arg1, Aml *count)
+Aml *aml_shiftright(Aml *arg1, Aml *count, Aml *dst)
{
- return build_opcode_2arg_dst(0x7A /* ShiftRightOp */, arg1, count, NULL);
+ return build_opcode_2arg_dst(0x7A /* ShiftRightOp */, arg1, count, dst);
}
/* ACPI 1.0b: 16.2.5.4 Type 2 Opcodes Encoding: DefLLess */
diff --git a/hw/i386/acpi-build.c b/hw/i386/acpi-build.c
index 16fb168..35ea92d 100644
--- a/hw/i386/acpi-build.c
+++ b/hw/i386/acpi-build.c
@@ -667,7 +667,7 @@ static Aml *build_prt(void)
/* slot = pin >> 2 */
aml_append(while_ctx,
- aml_store(aml_shiftright(pin, aml_int(2)), slot));
+ aml_store(aml_shiftright(pin, aml_int(2), NULL), slot));
/* lnk_idx = (slot + pin) & 3 */
aml_append(while_ctx,
aml_store(aml_and(aml_add(pin, slot, NULL), aml_int(3)), lnk_idx));
--
MST
- [Qemu-devel] [PULL 36/55] acpi: add aml_sizeof, (continued)
- [Qemu-devel] [PULL 36/55] acpi: add aml_sizeof, Michael S. Tsirkin, 2015/12/22
- [Qemu-devel] [PULL 37/55] acpi: add aml_lgreater_equal(), Michael S. Tsirkin, 2015/12/22
- [Qemu-devel] [PULL 38/55] acpi: add aml_mutex(), aml_acquire(), aml_release(), Michael S. Tsirkin, 2015/12/22
- [Qemu-devel] [PULL 39/55] acpi: add aml_create_qword_field(), Michael S. Tsirkin, 2015/12/22
- [Qemu-devel] [PULL 40/55] acpi: aml: add helper for Opcode Arg2 Arg2 [Dst] AML pattern, Michael S. Tsirkin, 2015/12/22
- [Qemu-devel] [PULL 41/55] acpi: extend aml_add() to accept target argument, Michael S. Tsirkin, 2015/12/22
- [Qemu-devel] [PULL 42/55] acpi: add aml_decrement() and aml_subtract(), Michael S. Tsirkin, 2015/12/22
- [Qemu-devel] [PULL 43/55] acpi: add aml_call0() helper, Michael S. Tsirkin, 2015/12/22
- [Qemu-devel] [PULL 44/55] acpi: add aml_to_integer(), Michael S. Tsirkin, 2015/12/22
- [Qemu-devel] [PULL 46/55] acpi: add aml_alias(), Michael S. Tsirkin, 2015/12/22
- [Qemu-devel] [PULL 45/55] acpi: extend aml_shiftright() to accept target argument,
Michael S. Tsirkin <=
- [Qemu-devel] [PULL 47/55] acpi: add aml_sleep(), Michael S. Tsirkin, 2015/12/22
- [Qemu-devel] [PULL 48/55] acpi: add aml_lor(), Michael S. Tsirkin, 2015/12/22
- [Qemu-devel] [PULL 50/55] acpi: extend aml_field() to support LockRule, Michael S. Tsirkin, 2015/12/22
- [Qemu-devel] [PULL 49/55] acpi: add aml_lgreater(), Michael S. Tsirkin, 2015/12/22
- [Qemu-devel] [PULL 51/55] acpi: add aml_to_hexstring(), Michael S. Tsirkin, 2015/12/22
- [Qemu-devel] [PULL 52/55] acpi: add aml_to_buffer(), Michael S. Tsirkin, 2015/12/22
- [Qemu-devel] [PULL 53/55] acpi add aml_dma(), Michael S. Tsirkin, 2015/12/22
- [Qemu-devel] [PULL 54/55] acpi: extend aml_or() to accept target argument, Michael S. Tsirkin, 2015/12/22
- [Qemu-devel] [PULL 55/55] acpi: extend aml_and() to accept target argument, Michael S. Tsirkin, 2015/12/22
- Re: [Qemu-devel] [PULL 00/55] acpi, pc features, Peter Maydell, 2015/12/23