qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH v2 45/47] acpi: add acpi_iqr_no_flags() term


From: Claudio Fontana
Subject: Re: [Qemu-devel] [PATCH v2 45/47] acpi: add acpi_iqr_no_flags() term
Date: Tue, 27 Jan 2015 16:37:45 +0100
User-agent: Mozilla/5.0 (Windows NT 6.1; rv:24.0) Gecko/20100101 Thunderbird/24.0.1

Hi,

I think you have to replace "iqr" with "irq" in the function definition and in 
the commit message.

Ciao,

Claudio

On 22.01.2015 15:50, Igor Mammedov wrote:
> Signed-off-by: Igor Mammedov <address@hidden>
> ---
>  hw/acpi/acpi-build-utils.c         | 18 ++++++++++++++++++
>  include/hw/acpi/acpi-build-utils.h |  1 +
>  2 files changed, 19 insertions(+)
> 
> diff --git a/hw/acpi/acpi-build-utils.c b/hw/acpi/acpi-build-utils.c
> index 58f88cd..59873e3 100644
> --- a/hw/acpi/acpi-build-utils.c
> +++ b/hw/acpi/acpi-build-utils.c
> @@ -511,6 +511,24 @@ AcpiAml acpi_io(acpiIODecode dec, uint16_t min_base, 
> uint16_t max_base,
>      return var;
>  }
>  
> +/*
> + * ACPI 5.0: 19.5.64 IRQNoFlags (Interrupt Resource Descriptor Macro)
> + *           6.4.2.1 IRQ Descriptor
> +*/
> +AcpiAml acpi_iqr_no_flags(uint8_t irq)
> +{
> +    uint16_t irq_mask;
> +    AcpiAml var = aml_allocate_internal(0, NON_BLOCK);
> +
> +    assert(irq < 16);
> +    build_append_byte(var.buf, 0x22); /* IRQ descriptor 2 byte form */
> +
> +    irq_mask = 1U << irq;
> +    build_append_byte(var.buf, irq_mask & 0xFF); /* IRQ mask bits[7:0] */
> +    build_append_byte(var.buf, irq_mask >> 8); /* IRQ mask bits[15:8] */
> +    return var;
> +}
> +
>  /* ACPI 5.0: 20.2.5.4 Type 2 Opcodes Encoding: DefLEqual */
>  AcpiAml acpi_equal(AcpiAml arg1, AcpiAml arg2)
>  {
> diff --git a/include/hw/acpi/acpi-build-utils.h 
> b/include/hw/acpi/acpi-build-utils.h
> index 868d439..d39b5b1 100644
> --- a/include/hw/acpi/acpi-build-utils.h
> +++ b/include/hw/acpi/acpi-build-utils.h
> @@ -117,6 +117,7 @@ AcpiAml acpi_call4(const char *method, AcpiAml arg1, 
> AcpiAml arg2,
>                     AcpiAml arg3, AcpiAml arg4);
>  AcpiAml acpi_io(acpiIODecode dec, uint16_t min_base, uint16_t max_base,
>                  uint8_t aln, uint8_t len);
> +AcpiAml acpi_iqr_no_flags(uint8_t irq);
>  AcpiAml acpi_operation_region(const char *name, acpiRegionSpace rs,
>                                uint32_t offset, uint32_t len);
>  AcpiAml acpi_named_field(const char *name, unsigned length);
> 





reply via email to

[Prev in Thread] Current Thread [Next in Thread]