Re: [PATCH] acpi: remove dead code

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

 



On Tue, Oct 19, 2010 at 12:49 AM, Len Brown <lenb@xxxxxxxxxx> wrote:
> On Mon, 18 Oct 2010, Stephen Hemminger wrote:
>
>> Found by running make namespacecheck on linux-next
>>
>> Signed-off-by: Stephen Hemminger <shemminger@xxxxxxxxxx>
>>
>> --- a/drivers/acpi/osl.c      2010-10-06 13:42:58.722974685 +0900
> ...
>>  /*
>> - * Allocate the memory for a spinlock and initialize it.
>> - */
>> -acpi_status acpi_os_create_lock(acpi_spinlock * handle)
>> -{
>> -     spin_lock_init(*handle);
>> -
>> -     return AE_OK;
>> -}
>
> ACPICA declares acpi_os_create_lock in acpiosxf.h,
> but never calls it.  Bob, can we do away with it?

In ACPICA code (AcpiUtMutexInitialize),

    Status = AcpiOsCreateLock (&AcpiGbl_GpeLock);
    if (ACPI_FAILURE (Status))
    {
        return_ACPI_STATUS (Status);
    }

    Status = AcpiOsCreateLock (&AcpiGbl_HardwareLock);
    if (ACPI_FAILURE (Status))
    {
        return_ACPI_STATUS (Status);
    }

In Linux code (acpi_ut_mutex_initialize)

        spin_lock_init(acpi_gbl_gpe_lock);
        spin_lock_init(acpi_gbl_hardware_lock);

This is another divergence between ACPICA and Linux code.

Lin Ming
--
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