[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CA+55aFwPcoWFxgHb2TYGO3Mh2WyPfkhpwNAw7xxbar=ncb3Nuw@mail.gmail.com>
Date: Sat, 14 Jul 2018 11:43:57 -0700
From: Linus Torvalds <torvalds@...ux-foundation.org>
To: Al Viro <viro@...iv.linux.org.uk>
Cc: Pavel Machek <pavel@....cz>, Jan Kara <jack@...e.cz>,
Andrew Morton <akpm@...ux-foundation.org>,
James Bottomley <James.Bottomley@...senpartnership.com>,
Waiman Long <longman@...hat.com>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
linux-fsdevel <linux-fsdevel@...r.kernel.org>,
Paul McKenney <paulmck@...ux.vnet.ibm.com>,
Ingo Molnar <mingo@...nel.org>,
Miklos Szeredi <mszeredi@...hat.com>,
Matthew Wilcox <willy@...radead.org>,
Larry Woodman <lwoodman@...hat.com>,
"Wangkai (Kevin,C)" <wangkai86@...wei.com>,
linux-mm <linux-mm@...ck.org>, Michal Hocko <mhocko@...nel.org>
Subject: Re: [PATCH v5 0/6] fs/dcache: Track & limit # of negative dentries
On Sat, Jul 14, 2018 at 11:36 AM Al Viro <viro@...iv.linux.org.uk> wrote:
>
> OK, this
> /*
> * No ordinary (disk based) filesystem counts links as inodes;
> * but each new link needs a new dentry, pinning lowmem, and
> * tmpfs dentries cannot be pruned until they are unlinked.
> */
> ret = shmem_reserve_inode(inode->i_sb);
> if (ret)
> goto out;
> will probably help (on ramfs it won't, though).
Nobody who cares about memory use would use ramfs and then allow
random users on it.
I think you can exhaust memory more easily on ramfs by just writing a
huge file. Do we have any limits at all?
ramfs is fine for things like initramfs, but I think the comment says it all:
* NOTE! This filesystem is probably most useful
* not as a real filesystem, but as an example of
* how virtual filesystems can be written.
and even that comment may have been more correct back in 2000 than it is today.
Linus
Powered by blists - more mailing lists