[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH v2 11/47] acpi: add acpi_arg0(), acpi_arg1(), acpi_a
From: |
Igor Mammedov |
Subject: |
[Qemu-devel] [PATCH v2 11/47] acpi: add acpi_arg0(), acpi_arg1(), acpi_arg2(), acpi_arg3() terms |
Date: |
Thu, 22 Jan 2015 14:49:55 +0000 |
Signed-off-by: Igor Mammedov <address@hidden>
---
hw/acpi/acpi-build-utils.c | 32 ++++++++++++++++++++++++++++++++
include/hw/acpi/acpi-build-utils.h | 5 +++++
2 files changed, 37 insertions(+)
diff --git a/hw/acpi/acpi-build-utils.c b/hw/acpi/acpi-build-utils.c
index df5880f..6e10712 100644
--- a/hw/acpi/acpi-build-utils.c
+++ b/hw/acpi/acpi-build-utils.c
@@ -348,6 +348,38 @@ AcpiAml acpi_name_decl(const char *name, AcpiAml val)
return var;
}
+/* ACPI 5.0: 20.2.6.1 Arg Objects Encoding: Arg0Op */
+AcpiAml acpi_arg0(void)
+{
+ AcpiAml var = aml_allocate_internal(0, NON_BLOCK);
+ build_append_byte(var.buf, 0x68); /* ARG0 op */
+ return var;
+}
+
+/* ACPI 5.0: 20.2.6.1 Arg Objects Encoding: Arg1Op */
+AcpiAml acpi_arg1(void)
+{
+ AcpiAml var = aml_allocate_internal(0, NON_BLOCK);
+ build_append_byte(var.buf, 0x69); /* ARG1 op */
+ return var;
+}
+
+/* ACPI 5.0: 20.2.6.1 Arg Objects Encoding: Arg2Op */
+AcpiAml acpi_arg2(void)
+{
+ AcpiAml var = aml_allocate_internal(0, NON_BLOCK);
+ build_append_byte(var.buf, 0x6A); /* ARG2 op */
+ return var;
+}
+
+/* ACPI 5.0: 20.2.6.1 Arg Objects Encoding: Arg3Op */
+AcpiAml acpi_arg3(void)
+{
+ AcpiAml var = aml_allocate_internal(0, NON_BLOCK);
+ build_append_byte(var.buf, 0x6B); /* ARG3 op */
+ return var;
+}
+
/* ACPI 5.0: 20.2.5.3 Type 1 Opcodes Encoding: DefIfElse */
AcpiAml acpi_if(AcpiAml predicate)
{
diff --git a/include/hw/acpi/acpi-build-utils.h
b/include/hw/acpi/acpi-build-utils.h
index 9e9ef1a..18d9efa 100644
--- a/include/hw/acpi/acpi-build-utils.h
+++ b/include/hw/acpi/acpi-build-utils.h
@@ -26,6 +26,11 @@ AcpiAml acpi_return(AcpiAml val);
AcpiAml acpi_int(const uint64_t val);
AcpiAml GCC_FMT_ATTR(1, 2) acpi_name(const char *name_format, ...);
AcpiAml acpi_name_decl(const char *name, AcpiAml val);
+AcpiAml acpi_arg0(void);
+AcpiAml acpi_arg1(void);
+AcpiAml acpi_arg2(void);
+AcpiAml acpi_arg3(void);
+
/* Block ASL object primitives */
AcpiAml acpi_if(AcpiAml predicate);
AcpiAml acpi_method(const char *name, int arg_count);
--
1.8.3.1
- [Qemu-devel] [PATCH v2 44/47] pc: acpi-build: drop remaining ssdt_misc template and use acpi_def_block(), (continued)
- [Qemu-devel] [PATCH v2 44/47] pc: acpi-build: drop remaining ssdt_misc template and use acpi_def_block(), Igor Mammedov, 2015/01/22
- [Qemu-devel] [PATCH v2 45/47] acpi: add acpi_iqr_no_flags() term, Igor Mammedov, 2015/01/22
- [Qemu-devel] [PATCH v2 46/47] pc: export applesmc IO port/len, Igor Mammedov, 2015/01/22
- [Qemu-devel] [PATCH v2 43/47] pc: acpi-build: prepare to make ACPI tables blob opaque for table building functions, Igor Mammedov, 2015/01/22
- [Qemu-devel] [PATCH v2 47/47] pc: acpi-build: drop template patching and create Device(SMC) dynamically, Igor Mammedov, 2015/01/22
- [Qemu-devel] [PATCH v2 17/47] acpi: add acpi_package() term, Igor Mammedov, 2015/01/22
- [Qemu-devel] [PATCH v2 06/47] acpi: add acpi_name() & acpi_name_decl() term, Igor Mammedov, 2015/01/22
- [Qemu-devel] [PATCH v2 11/47] acpi: add acpi_arg0(), acpi_arg1(), acpi_arg2(), acpi_arg3() terms,
Igor Mammedov <=
- Re: [Qemu-devel] [PATCH v2 11/47] acpi: add acpi_arg0(), acpi_arg1(), acpi_arg2(), acpi_arg3() terms, Marcel Apfelbaum, 2015/01/23
- Re: [Qemu-devel] [PATCH v2 11/47] acpi: add acpi_arg0(), acpi_arg1(), acpi_arg2(), acpi_arg3() terms, Michael S. Tsirkin, 2015/01/23
- Re: [Qemu-devel] [PATCH v2 11/47] acpi: add acpi_arg0(), acpi_arg1(), acpi_arg2(), acpi_arg3() terms, Igor Mammedov, 2015/01/23
- [Qemu-devel] [PATCH v2 10/47] acpi: add acpi_return() term, Igor Mammedov, 2015/01/22
- [Qemu-devel] [PATCH v2 01/47] acpi: introduce AML composer aml_append(), Igor Mammedov, 2015/01/22
- Re: [Qemu-devel] [PATCH v2 01/47] acpi: introduce AML composer aml_append(), Michael S. Tsirkin, 2015/01/23