[dpdk-dev] [PATCH] e1000/base: Add missing braces to the 'if' statements

Lu, Wenzhuo wenzhuo.lu at intel.com
Fri Jun 24 02:43:40 CEST 2016


Hi Markos,


> -----Original Message-----
> From: dev [mailto:dev-bounces at dpdk.org] On Behalf Of Markos Chandras
> Sent: Thursday, June 23, 2016 5:26 PM
> To: dev at dpdk.org
> Cc: Markos Chandras
> Subject: [dpdk-dev] [PATCH] e1000/base: Add missing braces to the 'if'
> statements
> 
> Add the missing braces to the 'if' statements to fix the misleading identation.
> This also fixes the following build errors when building with gcc >= 6:
> 
> drivers/net/e1000/base/e1000_phy.c:4156:2:
> error: this 'if' clause does not guard... [-Werror=misleading-indentation] if
> (locked) ^~
> 
> drivers/net/e1000/base/e1000_phy.c:4158:3:
> note: ...this statement, but the latter is misleadingly indented as if it is guarded
> by the 'if'
> if (!ready)
> ^~
> 
> drivers/net/e1000/base/e1000_phy.c: In function 'e1000_write_phy_reg_mphy':
> drivers/net/e1000/base/e1000_phy.c:4221:2:
> error: this 'if' clause does not guard... [-Werror=misleading-indentation] if
> (locked) ^~
> 
> drivers/net/e1000/base/e1000_phy.c:4223:3:
> note: ...this statement, but the latter is misleadingly indented as if it is guarded
> by the 'if'
> if (!ready)
> ^~
> 
> Signed-off-by: Markos Chandras <mchandras at suse.de>
Thanks for this patch. But normally the code in the base directory is synced from the kernel driver. So we don't change it if there's no critical issue. It's easy for us to maintain it. Thanks.



More information about the dev mailing list