[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20200729142003.7fe30d67@kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com>
Date: Wed, 29 Jul 2020 14:20:03 -0700
From: Jakub Kicinski <kuba@...nel.org>
To: "Li,Rongqing" <lirongqing@...du.com>
Cc: Tony Nguyen <anthony.l.nguyen@...el.com>,
"davem@...emloft.net" <davem@...emloft.net>,
"netdev@...r.kernel.org" <netdev@...r.kernel.org>,
"nhorman@...hat.com" <nhorman@...hat.com>,
"sassmann@...hat.com" <sassmann@...hat.com>,
"jeffrey.t.kirsher@...el.com" <jeffrey.t.kirsher@...el.com>,
Andrew Bowers <andrewx.bowers@...el.com>
Subject: Re: [net-next 2/6] i40e: prefetch struct page of Rx buffer
conditionally
On Wed, 29 Jul 2020 06:20:47 +0000 Li,Rongqing wrote:
> > Looks like something that belongs in a common header not (potentially
> > multiple) C sources.
>
> Not clear, how should I change?
Can you add something like:
static inline void prefetch_page_address(struct page *page)
{
#if defined(WANT_PAGE_VIRTUAL) || defined(HASHED_PAGE_VIRTUAL)
prefetch(page);
#endif
}
to mm.h or prefetch.h or i40e.h or some other header? That's preferred
over adding #ifs directly in the source code.
Powered by blists - more mailing lists