Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

ACPICA: MSVC6: Fix build issue for variable argument macros

ACPICA commit 72f5a358f28c5d154ed613c142c7dca03192c5ee

This patch intoduces generic variable macro detection support and fixes
build breakage issue with macros using __VA_ARGS__ feature defined in
C99.

This patch fixes this build issue. Lv Zheng.

This patch doesn't affect Linux kernel.

Link: https://github.com/acpica/acpica/commit/72f5a358
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>

authored by

Lv Zheng and committed by
Rafael J. Wysocki
7b09d8fd 0ea61381

+15 -2
+11 -2
include/acpi/acoutput.h
··· 294 294 295 295 /* DEBUG_PRINT functions */ 296 296 297 - #define ACPI_DEBUG_PRINT(plist) ACPI_ACTUAL_DEBUG plist 298 - #define ACPI_DEBUG_PRINT_RAW(plist) ACPI_ACTUAL_DEBUG_RAW plist 297 + #ifndef COMPILER_VA_MACRO 298 + 299 + #define ACPI_DEBUG_PRINT(plist) acpi_debug_print plist 300 + #define ACPI_DEBUG_PRINT_RAW(plist) acpi_debug_print_raw plist 301 + 302 + #else 299 303 300 304 /* Helper macros for DEBUG_PRINT */ 301 305 ··· 318 314 #define ACPI_ACTUAL_DEBUG_RAW(level, line, filename, modulename, component, ...) \ 319 315 ACPI_DO_DEBUG_PRINT (acpi_debug_print_raw, level, line, \ 320 316 filename, modulename, component, __VA_ARGS__) 317 + 318 + #define ACPI_DEBUG_PRINT(plist) ACPI_ACTUAL_DEBUG plist 319 + #define ACPI_DEBUG_PRINT_RAW(plist) ACPI_ACTUAL_DEBUG_RAW plist 320 + 321 + #endif 321 322 322 323 /* 323 324 * Function entry tracing
+4
include/acpi/platform/acgcc.h
··· 75 75 #undef strchr 76 76 #endif 77 77 78 + /* GCC supports __VA_ARGS__ in macros */ 79 + 80 + #define COMPILER_VA_MACRO 1 81 + 78 82 #endif /* __ACGCC_H__ */