Follow @Openwall on Twitter for new release announcements and other news
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Thu, 13 Feb 2020 14:47:48 -0800
From: Linus Torvalds <>
To: Al Viro <>
Cc: "Eric W. Biederman" <>, LKML <>, 
	Kernel Hardening <>, Linux API <>, 
	Linux FS Devel <>, 
	Linux Security Module <>, 
	Akinobu Mita <>, Alexey Dobriyan <>, 
	Andrew Morton <>, Andy Lutomirski <>, 
	Daniel Micay <>, Djalal Harouni <>, 
	"Dmitry V . Levin" <>, Greg Kroah-Hartman <>, 
	Ingo Molnar <>, "J . Bruce Fields" <>, 
	Jeff Layton <>, Jonathan Corbet <>, 
	Kees Cook <>, Oleg Nesterov <>, 
	Solar Designer <>
Subject: Re: [PATCH v8 07/11] proc: flush task dcache entries from all procfs instances

On Thu, Feb 13, 2020 at 2:23 PM Al Viro <> wrote:
> I'd been thinking of ->d_fsdata pointing to a structure with list_head
> and a (non-counting) task_struct pointer for those guys.  Allocated
> on lookup, of course (as well as readdir ;-/) and put on the list
> at the same time.

Hmm. That smells like potentially a lot of small allocations, and
making readdir() even nastier.

Do we really want to create the dentries at readdir time? We do now
(with proc_fill_cache()) but do we actually _need_ to?

I guess a lot of readdir users end up doing a stat on it immediately
afterwards. I think right now we do it to get the inode number, and
maybe that is a basic requirement (even if I don't think it's really
stable - an inode could be evicted and then the ino changes, no?)

Ho humm. This all doesn't make me happy. But I guess the proof is in
the pudding - and if you come up with a good patch, I won't complain.


Powered by blists - more mailing lists

Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.