Re: [PATCH net-next] net/mlnx5: Use generic code for page_pool statistics.

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

 



On 2025-03-05 18:43:39 [+0100], Andrew Lunn wrote:
> > diff --git a/include/net/page_pool/types.h b/include/net/page_pool/types.h
> > index f45d55e6e8643..78984b9286c6b 100644
> > --- a/include/net/page_pool/types.h
> > +++ b/include/net/page_pool/types.h
> > @@ -143,10 +143,14 @@ struct page_pool_recycle_stats {
> >   */
> >  struct page_pool_stats {
> >  	struct page_pool_alloc_stats alloc_stats;
> >  	struct page_pool_recycle_stats recycle_stats;
> >  };
> > +
> > +#else /* !CONFIG_PAGE_POOL_STATS */
> > +
> > +struct page_pool_stats { };
> >  #endif
>   
> Please do add this, in a separate patch. But i wounder how other
> drivers handle this. Do they also have #ifdef?

veth.c, fec_main.c, yes.
mvneta.c, mtk_eth_soc.c, no. But then they select PAGE_POOL_STATS so it
is not exactly a fair comparison.

>     Andrew

Sebastian




[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