ACPICA: Use uintptr_t and offsetof() in Linux kernel builds
To avoid "performing pointer subtraction with a null pointer has undefined behavior" compiler warnings, use uintptr_t and offsetof() that are always available during Linux kernel builds to define acpi_uintptr_t and the ACPI_TO_INTEGER() and ACPI_OFFSET() macros. Based on earlier proposal from Arnd Bergmann. Link: https://lore.kernel.org/linux-acpi/20210927121338.938994-1-arnd@kernel.orgSigned-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com> Reviewed-by: NArnd Bergmann <arnd@arndb.de>
Showing
想要评论请 注册 或 登录