Re: [PATCH net-next] mlx4: Mark PM functions as __maybe_unused

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Jul 02, 2020 at 06:27:12PM +0800, Wei Yongjun wrote:
>
>
> On 2020/7/2 17:36, Leon Romanovsky wrote:
> > On Thu, Jul 02, 2020 at 05:19:46PM +0800, Wei Yongjun wrote:
> >> In certain configurations without power management support, the
> >> following warnings happen:
> >>
> >> drivers/net/ethernet/mellanox/mlx4/main.c:4388:12:
> >>  warning: 'mlx4_resume' defined but not used [-Wunused-function]
> >>  4388 | static int mlx4_resume(struct device *dev_d)
> >>       |            ^~~~~~~~~~~
> >> drivers/net/ethernet/mellanox/mlx4/main.c:4373:12: warning:
> >>  'mlx4_suspend' defined but not used [-Wunused-function]
> >>  4373 | static int mlx4_suspend(struct device *dev_d)
> >>       |            ^~~~~~~~~~~~
> >>
> >> Mark these functions as __maybe_unused to make it clear to the
> >> compiler that this is going to happen based on the configuration,
> >> which is the standard for these types of functions.
> >>
> >> Fixes: 0e3e206a3e12 ("mlx4: use generic power management")
> >
> > I can't find this SHA-1, where did you get it?
>
> It is in the net-next tree.
>
> https://git.kernel.org/pub/scm/linux/kernel/git/netdev/net-next.git/commit/?id=0e3e206a3e12

I see, thanks

>
> > And why doesn't mlx5 need this change?
> >
> > Fixes: 86a3e5d02c20 ("net/mlx4_core: Add PCI calls for suspend/resume")
> >
> > Thanks
> >



[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Photo]     [Yosemite News]     [Yosemite Photos]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux