[Intel-wired-lan] [PATCH] i40e: mark PM functions as __maybe_unused

Bowers, AndrewX andrewx.bowers at intel.com
Tue Oct 10 17:32:16 UTC 2017


> -----Original Message-----
> From: Intel-wired-lan [mailto:intel-wired-lan-bounces at osuosl.org] On
> Behalf Of Arnd Bergmann
> Sent: Tuesday, October 10, 2017 1:18 AM
> To: Kirsher, Jeffrey T <jeffrey.t.kirsher at intel.com>
> Cc: Arnd Bergmann <arnd at arndb.de>; netdev at vger.kernel.org; Williams,
> Mitch A <mitch.a.williams at intel.com>; linux-kernel at vger.kernel.org; intel-
> wired-lan at lists.osuosl.org; David S. Miller <davem at davemloft.net>
> Subject: [Intel-wired-lan] [PATCH] i40e: mark PM functions as
> __maybe_unused
> 
> A cleanup of the PM code left an incorrect #ifdef in place, leading to a
> harmless build warning:
> 
> drivers/net/ethernet/intel/i40e/i40e_main.c:12223:12: error: 'i40e_resume'
> defined but not used [-Werror=unused-function]
> drivers/net/ethernet/intel/i40e/i40e_main.c:12185:12: error: 'i40e_suspend'
> defined but not used [-Werror=unused-function]
> 
> It's easier to use __maybe_unused attributes here, since you can't pick the
> wrong one.
> 
> Fixes: 0e5d3da40055 ("i40e: use newer generic PM support instead of legacy
> PM callbacks")
> Signed-off-by: Arnd Bergmann <arnd at arndb.de>
> ---
>  drivers/net/ethernet/intel/i40e/i40e_main.c | 11 ++---------
>  1 file changed, 2 insertions(+), 9 deletions(-)

Tested-by: Andrew Bowers <andrewx.bowers at intel.com>




More information about the Intel-wired-lan mailing list