Messages in this thread Patch in this message | | | Date | Thu, 3 Apr 2003 13:05:05 -0800 | From | Andrew Morton <> | Subject | [patch] acpi compile fix |
| |
ACPI is performing a spin_lock() on a `void *'. That's OK when spin_lock is implemented via an inline function. But when it is implemented via macros (eg, with spinlock debugging enabled) we get:
drivers/acpi/osl.c:739: warning: dereferencing `void *' pointer drivers/acpi/osl.c:739: request for member `owner' in something not a structure or union
So cast it to the right type.
diff -puN drivers/acpi/osl.c~acpi-spinlock-casts drivers/acpi/osl.c --- 25/drivers/acpi/osl.c~acpi-spinlock-casts Thu Apr 3 13:00:54 2003 +++ 25-akpm/drivers/acpi/osl.c Thu Apr 3 13:01:25 2003 @@ -736,7 +736,7 @@ acpi_os_acquire_lock ( if (flags & ACPI_NOT_ISR) ACPI_DISABLE_IRQS(); - spin_lock(handle); + spin_lock((spinlock_t *)handle); return_VOID; } @@ -755,7 +755,7 @@ acpi_os_release_lock ( ACPI_DEBUG_PRINT ((ACPI_DB_MUTEX, "Releasing spinlock[%p] from %s level\n", handle, ((flags & ACPI_NOT_ISR) ? "non-interrupt" : "interrupt"))); - spin_unlock(handle); + spin_unlock((spinlock_t *)handle); if (flags & ACPI_NOT_ISR) ACPI_ENABLE_IRQS(); _
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |