lkml.org 
[lkml]   [2021]   [Oct]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH net-next] net/mlx5i: avoid unused function warning for mlx5i_flow_type_mask
Date
On Fri, 2021-10-22 at 08:47 +0200, Arnd Bergmann wrote:
> From: Arnd Bergmann <arnd@arndb.de>
>
> Without CONFIG_MLX5_EN_RXNFC, the function is unused, breaking the
> build with CONFIG_WERROR:
>
> mlx5/core/ipoib/ethtool.c:36:12: error: unused function
> 'mlx5i_flow_type_mask' [-Werror,-Wunused-function]
> static u32 mlx5i_flow_type_mask(u32 flow_type)
>
> We could add another #ifdef or mark this function inline, but
> replacing the existing #ifdef with a __maybe_unused seems best
> because that improves build coverage and avoids introducing
> similar problems the next time this code changes.
>

Hi Arnd, thanks for your patch,
we have a pending patch that simply moves mlx5i_flow_type_mask() into
the #ifdef, where this function is only used

will submit it shortly.

Thanks again for your patch.

\
 
 \ /
  Last update: 2021-10-25 22:03    [W:0.103 / U:0.168 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site