diff options
author | Igor Mammedov <imammedo@redhat.com> | 2015-02-18 19:14:36 +0000 |
---|---|---|
committer | Michael S. Tsirkin <mst@redhat.com> | 2015-02-26 13:04:15 +0100 |
commit | b8a5d6894d94c8f7e815c64adff78b0d28a98ca6 (patch) | |
tree | 0114d10dbbb6dc486cc4f7e9df4ad2864c38752b /hw/acpi | |
parent | 214ae59f8e1c33db0f3fbbc4347bb3dacc6ce876 (diff) |
acpi: add aml_local() 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')
-rw-r--r-- | hw/acpi/aml-build.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/hw/acpi/aml-build.c b/hw/acpi/aml-build.c index b91141e320..fabd0adf28 100644 --- a/hw/acpi/aml-build.c +++ b/hw/acpi/aml-build.c @@ -596,3 +596,14 @@ Aml *aml_field(const char *name, AmlFieldFlags flags) build_append_byte(var->buf, flags); return var; } + +/* ACPI 1.0b: 16.2.6.2 Local Objects Encoding */ +Aml *aml_local(int num) +{ + Aml *var; + uint8_t op = 0x60 /* Local0Op */ + num; + + assert(num <= 7); + var = aml_opcode(op); + return var; +} |