aboutsummaryrefslogtreecommitdiffstats
path: root/include/acpi/acpixf.h
diff options
context:
space:
mode:
authorLv Zheng <lv.zheng@intel.com>2013-10-28 21:30:16 -0400
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2013-10-31 09:35:43 -0400
commit4506bf2329cab39d41f027cdccb1cf455de2bf79 (patch)
tree1a528e4514f9eff4548fe1d0d241a501d9ae1e4b /include/acpi/acpixf.h
parentd21f600b0e4d5a694a338688e61d95f08dbf0afb (diff)
ACPICA: Prevent possible build issues for use of ACPI_PRINTF_LIKE macro
The following build error: ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ CC arch/x86/kernel/setup.o In file included from include/acpi/acpi.h:64:0, from include/linux/iscsi_ibft.h:24, from arch/x86/kernel/setup.c:43: include/acpi/acpixf.h:543:1: error: expected ',' or ';' before '{' token include/acpi/acpixf.h:540:1: warning: 'acpi_error' declared 'static' but never defined [-Wunused-function] make[2]: *** [arch/x86/kernel/setup.o] Error 1 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ can be triggerred by the following stub function (if implemented): ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ static inline void ACPI_INTERNAL_VAR_XFACE acpi_error(const char *module_name, u32 line_number, const char *format, ...) ACPI_PRINTF_LIKE(3) { } ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ This patch changes the position of ACPI_PRINTF_LIKE(x) to follow the style of __printf(x, x+1) used in Linux to prevent such issues from happening. Lv Zheng. 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>
Diffstat (limited to 'include/acpi/acpixf.h')
-rw-r--r--include/acpi/acpixf.h29
1 files changed, 16 insertions, 13 deletions
diff --git a/include/acpi/acpixf.h b/include/acpi/acpixf.h
index ddde61b43041..9759bd5f4777 100644
--- a/include/acpi/acpixf.h
+++ b/include/acpi/acpixf.h
@@ -530,50 +530,53 @@ ACPI_HW_DEPENDENT_RETURN_STATUS(acpi_status
530/* 530/*
531 * Error/Warning output 531 * Error/Warning output
532 */ 532 */
533ACPI_PRINTF_LIKE(3)
533void ACPI_INTERNAL_VAR_XFACE 534void ACPI_INTERNAL_VAR_XFACE
534acpi_error(const char *module_name, 535acpi_error(const char *module_name, u32 line_number, const char *format, ...);
535 u32 line_number, const char *format, ...) ACPI_PRINTF_LIKE(3);
536 536
537ACPI_PRINTF_LIKE(4)
537void ACPI_INTERNAL_VAR_XFACE 538void ACPI_INTERNAL_VAR_XFACE
538acpi_exception(const char *module_name, 539acpi_exception(const char *module_name,
539 u32 line_number, 540 u32 line_number, acpi_status status, const char *format, ...);
540 acpi_status status, const char *format, ...) ACPI_PRINTF_LIKE(4);
541 541
542ACPI_PRINTF_LIKE(3)
542void ACPI_INTERNAL_VAR_XFACE 543void ACPI_INTERNAL_VAR_XFACE
543acpi_warning(const char *module_name, 544acpi_warning(const char *module_name, u32 line_number, const char *format, ...);
544 u32 line_number, const char *format, ...) ACPI_PRINTF_LIKE(3);
545 545
546ACPI_PRINTF_LIKE(3)
546void ACPI_INTERNAL_VAR_XFACE 547void ACPI_INTERNAL_VAR_XFACE
547acpi_info(const char *module_name, 548acpi_info(const char *module_name, u32 line_number, const char *format, ...);
548 u32 line_number, const char *format, ...) ACPI_PRINTF_LIKE(3);
549 549
550ACPI_PRINTF_LIKE(3)
550void ACPI_INTERNAL_VAR_XFACE 551void ACPI_INTERNAL_VAR_XFACE
551acpi_bios_error(const char *module_name, 552acpi_bios_error(const char *module_name,
552 u32 line_number, const char *format, ...) ACPI_PRINTF_LIKE(3); 553 u32 line_number, const char *format, ...);
553 554
555ACPI_PRINTF_LIKE(3)
554void ACPI_INTERNAL_VAR_XFACE 556void ACPI_INTERNAL_VAR_XFACE
555acpi_bios_warning(const char *module_name, 557acpi_bios_warning(const char *module_name,
556 u32 line_number, const char *format, ...) ACPI_PRINTF_LIKE(3); 558 u32 line_number, const char *format, ...);
557 559
558/* 560/*
559 * Debug output 561 * Debug output
560 */ 562 */
561#ifdef ACPI_DEBUG_OUTPUT 563#ifdef ACPI_DEBUG_OUTPUT
562 564
565ACPI_PRINTF_LIKE(6)
563void ACPI_INTERNAL_VAR_XFACE 566void ACPI_INTERNAL_VAR_XFACE
564acpi_debug_print(u32 requested_debug_level, 567acpi_debug_print(u32 requested_debug_level,
565 u32 line_number, 568 u32 line_number,
566 const char *function_name, 569 const char *function_name,
567 const char *module_name, 570 const char *module_name,
568 u32 component_id, const char *format, ...) ACPI_PRINTF_LIKE(6); 571 u32 component_id, const char *format, ...);
569 572
573ACPI_PRINTF_LIKE(6)
570void ACPI_INTERNAL_VAR_XFACE 574void ACPI_INTERNAL_VAR_XFACE
571acpi_debug_print_raw(u32 requested_debug_level, 575acpi_debug_print_raw(u32 requested_debug_level,
572 u32 line_number, 576 u32 line_number,
573 const char *function_name, 577 const char *function_name,
574 const char *module_name, 578 const char *module_name,
575 u32 component_id, 579 u32 component_id, const char *format, ...);
576 const char *format, ...) ACPI_PRINTF_LIKE(6);
577#endif 580#endif
578 581
579#endif /* __ACXFACE_H__ */ 582#endif /* __ACXFACE_H__ */