Re: [PATCH v2] sunrpc: Use GFP_NOFS to prevent use of current->task_frag.

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

 



On Tue, 2022-10-11 at 17:00 +0200, Guillaume Nault wrote:
> On Mon, Oct 10, 2022 at 11:18:19PM -0700, Christoph Hellwig wrote:
> > On Mon, Oct 10, 2022 at 06:56:50PM +0200, Guillaume Nault wrote:
> > > That's what my RFC patch did. It was rejected because reading
> > > current->flags may incur a cache miss thus slowing down TCP fast
> > > path.
> > > See the discussion in the Link tag:
> > > https://lore.kernel.org/netdev/b4d8cb09c913d3e34f853736f3f5628abfd7f4b6.1656699567.git.gnault@xxxxxxxxxx/
> > 
> > As GFP_NOFS/NOIO are on their way out the networking people will
> > have to
> > do this anyway.
> 
> We can always think of a nicer solution in the future. But right now
> we
> have a real bug to fix.
> 
> Commit a1231fda7e94 ("SUNRPC: Set memalloc_nofs_save() on all
> rpciod/xprtiod jobs") introduces a bug that crashes the kernel. I
> can't
> see anything wrong with a partial revert.
> 

How about instead just adding a dedicated flag to the socket that
switches between the two page_frag modes?

That would remain future proofed, and it would give kernel users a
lever with which to do the right thing without unnecessarily
constraining the allocation modes.

-- 
Trond Myklebust
Linux NFS client maintainer, Hammerspace
trond.myklebust@xxxxxxxxxxxxxxx





[Index of Archives]     [Linux Filesystem Development]     [Linux USB Development]     [Linux Media Development]     [Video for Linux]     [Linux NILFS]     [Linux Audio Users]     [Yosemite Info]     [Linux SCSI]

  Powered by Linux