Re: [PATCH with title] priority fix in acpi_map_lsapic() arch/ia64/kernel/acpi.c

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

 



As above should have been its title.

Roel Kluin wrote:
> I have sent this patch before to lkml, but it appears it wasn't picked up. Also
> I have to admit this isn't tested. This is a patch against linus' tree.
> 
> ACPI_MADT_ENABLED is defined 1    (include/acpi/actbl1.h 501)
> lapic_flags: an u32 of struct acpi_madt_local_sapic (include/acpi/actbl1.h 467)
> --
> '!' has a higher priority than '&', so as was
> this won't test the first bit, but rather evaluates to false for any non-zero
> lsapic->lapic_flags.
> 
> Signed-off-by: Roel Kluin <12o3l@xxxxxxxxxx>
> ---
> diff --git a/arch/ia64/kernel/acpi.c b/arch/ia64/kernel/acpi.c
> index 3d45d24..7d78d22 100644
> --- a/arch/ia64/kernel/acpi.c
> +++ b/arch/ia64/kernel/acpi.c
> @@ -858,7 +858,7 @@ int acpi_map_lsapic(acpi_handle handle, int *pcpu)
>  	lsapic = (struct acpi_madt_local_sapic *)obj->buffer.pointer;
>  
>  	if ((lsapic->header.type != ACPI_MADT_TYPE_LOCAL_SAPIC) ||
> -	    (!lsapic->lapic_flags & ACPI_MADT_ENABLED)) {
> +	    (!(lsapic->lapic_flags & ACPI_MADT_ENABLED))) {
>  		kfree(buffer.pointer);
>  		return -EINVAL;
>  	}
> 

-
To unsubscribe from this list: send the line "unsubscribe linux-acpi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux IBM ACPI]     [Linux Power Management]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]

  Powered by Linux