Re: [PATCH part2 3/4] acpi: Remove "continue" in macro INVALID_TABLE().

2013-08-12 Thread Tang Chen
On 08/12/2013 10:21 PM, Tejun Heo wrote: On Thu, Aug 08, 2013 at 07:09:53AM -0700, Joe Perches wrote: If you really think that the #define is better, use something like HW_ERR does and embed that #define in the pr_err. #define ACPI_OVERRIDE "ACPI OVERRIDE: " pr_err(ACPI_OVERRIDE

Re: [PATCH part2 3/4] acpi: Remove "continue" in macro INVALID_TABLE().

2013-08-12 Thread Tejun Heo
On Thu, Aug 08, 2013 at 07:09:53AM -0700, Joe Perches wrote: > If you really think that the #define is better, use > something like HW_ERR does and embed that #define > in the pr_err. > > #define ACPI_OVERRIDE "ACPI OVERRIDE: " > > pr_err(ACPI_OVERRIDE "Table smaller than ACPI header

Re: [PATCH part2 3/4] acpi: Remove continue in macro INVALID_TABLE().

2013-08-12 Thread Tejun Heo
On Thu, Aug 08, 2013 at 07:09:53AM -0700, Joe Perches wrote: If you really think that the #define is better, use something like HW_ERR does and embed that #define in the pr_err. #define ACPI_OVERRIDE ACPI OVERRIDE: pr_err(ACPI_OVERRIDE Table smaller than ACPI header [%s%s]\n,

Re: [PATCH part2 3/4] acpi: Remove continue in macro INVALID_TABLE().

2013-08-12 Thread Tang Chen
On 08/12/2013 10:21 PM, Tejun Heo wrote: On Thu, Aug 08, 2013 at 07:09:53AM -0700, Joe Perches wrote: If you really think that the #define is better, use something like HW_ERR does and embed that #define in the pr_err. #define ACPI_OVERRIDE ACPI OVERRIDE: pr_err(ACPI_OVERRIDE Table

Re: [PATCH part2 3/4] acpi: Remove "continue" in macro INVALID_TABLE().

2013-08-08 Thread Joe Perches
On Thu, 2013-08-08 at 20:18 +0800, Tang Chen wrote: > Hi Joe, Hello Tang. > On 08/08/2013 01:27 PM, Joe Perches wrote: > > On Thu, 2013-08-08 at 13:03 +0800, Tang Chen wrote: > > > >> Change it to the style like other macros: > >> > >> #define INVALID_TABLE(x, path, name)

Re: [PATCH part2 3/4] acpi: Remove "continue" in macro INVALID_TABLE().

2013-08-08 Thread Tang Chen
Hi Joe, On 08/08/2013 01:27 PM, Joe Perches wrote: On Thu, 2013-08-08 at 13:03 +0800, Tang Chen wrote: Change it to the style like other macros: #define INVALID_TABLE(x, path, name)\ do { pr_err("ACPI OVERRIDE: " x " [%s%s]\n", path, name); }

Re: [PATCH part2 3/4] acpi: Remove continue in macro INVALID_TABLE().

2013-08-08 Thread Tang Chen
Hi Joe, On 08/08/2013 01:27 PM, Joe Perches wrote: On Thu, 2013-08-08 at 13:03 +0800, Tang Chen wrote: Change it to the style like other macros: #define INVALID_TABLE(x, path, name)\ do { pr_err(ACPI OVERRIDE: x [%s%s]\n, path, name); }

Re: [PATCH part2 3/4] acpi: Remove continue in macro INVALID_TABLE().

2013-08-08 Thread Joe Perches
On Thu, 2013-08-08 at 20:18 +0800, Tang Chen wrote: Hi Joe, Hello Tang. On 08/08/2013 01:27 PM, Joe Perches wrote: On Thu, 2013-08-08 at 13:03 +0800, Tang Chen wrote: Change it to the style like other macros: #define INVALID_TABLE(x, path, name)\

Re: [PATCH part2 3/4] acpi: Remove "continue" in macro INVALID_TABLE().

2013-08-07 Thread Joe Perches
On Thu, 2013-08-08 at 13:03 +0800, Tang Chen wrote: > Change it to the style like other macros: > > #define INVALID_TABLE(x, path, name)\ > do { pr_err("ACPI OVERRIDE: " x " [%s%s]\n", path, name); } while (0) Single statement macros do _not_ need

[PATCH part2 3/4] acpi: Remove "continue" in macro INVALID_TABLE().

2013-08-07 Thread Tang Chen
The macro INVALID_TABLE() is defined like this: #define INVALID_TABLE(x, path, name)\ { pr_err("ACPI OVERRIDE: " x " [%s%s]\n", path, name); continue; } And it is used like this: for (...) { ... if (...)

[PATCH part2 3/4] acpi: Remove continue in macro INVALID_TABLE().

2013-08-07 Thread Tang Chen
The macro INVALID_TABLE() is defined like this: #define INVALID_TABLE(x, path, name)\ { pr_err(ACPI OVERRIDE: x [%s%s]\n, path, name); continue; } And it is used like this: for (...) { ... if (...)

Re: [PATCH part2 3/4] acpi: Remove continue in macro INVALID_TABLE().

2013-08-07 Thread Joe Perches
On Thu, 2013-08-08 at 13:03 +0800, Tang Chen wrote: Change it to the style like other macros: #define INVALID_TABLE(x, path, name)\ do { pr_err(ACPI OVERRIDE: x [%s%s]\n, path, name); } while (0) Single statement macros do _not_ need to use