From: Chris Down <chris@chrisdown.name>
To: Amir Goldstein <amir73il@gmail.com>
Cc: linux-fsdevel <linux-fsdevel@vger.kernel.org>,
Al Viro <viro@zeniv.linux.org.uk>,
Matthew Wilcox <willy@infradead.org>,
Jeff Layton <jlayton@kernel.org>,
Johannes Weiner <hannes@cmpxchg.org>, Tejun Heo <tj@kernel.org>,
linux-kernel <linux-kernel@vger.kernel.org>,
kernel-team@fb.com
Subject: Re: [PATCH v2 1/2] tmpfs: Add per-superblock i_ino support
Date: Thu, 2 Jan 2020 20:00:52 +0000 [thread overview]
Message-ID: <20200102200052.GA1181932@chrisdown.name> (raw)
In-Reply-To: <CAOQ4uxi0v4WL30gpedUbex-TD5wN8p8kCop_3VDYV0UBJGB21w@mail.gmail.com>
Amir Goldstein writes:
>Wouldn't it be easier to check max_inodes instead of passing this
>use_sb_ino arg?
>Is there any case where they *need* to differ?
Hmm, I suppose probably not? In that case should I just check against
SB_KERNMOUNT, since max_inodes can only be 0 in that case?
>> @@ -3378,6 +3411,8 @@ enum shmem_param {
>> Opt_nr_inodes,
>> Opt_size,
>> Opt_uid,
>> + Opt_inode32,
>> + Opt_inode64,
>
>Does not belong to this patch..
>
>> };
>>
>> static const struct fs_parameter_spec shmem_param_specs[] = {
>> @@ -3389,6 +3424,8 @@ static const struct fs_parameter_spec shmem_param_specs[] = {
>> fsparam_string("nr_inodes", Opt_nr_inodes),
>> fsparam_string("size", Opt_size),
>> fsparam_u32 ("uid", Opt_uid),
>> + fsparam_flag ("inode32", Opt_inode32),
>> + fsparam_flag ("inode64", Opt_inode64),
>
>Ditto
Bleh, I'll fix this and send v3.
>> {}
>> };
>>
>> @@ -3690,7 +3727,8 @@ static int shmem_fill_super(struct super_block *sb, struct fs_context *fc)
>> #endif
>> uuid_gen(&sb->s_uuid);
>>
>> - inode = shmem_get_inode(sb, NULL, S_IFDIR | sbinfo->mode, 0, VM_NORESERVE);
>> + inode = shmem_get_inode(sb, NULL, S_IFDIR | sbinfo->mode, 0,
>> + VM_NORESERVE, true);
>
>Should usb_sb_ino be true for the kern_mount??
>In any case, it wouldn't matter if it was false, hence no need to pass
>an argument
>and can either check for sbinfo->max_inodes or the SB_KERNMOUNT flag in
>shmem_get_inode().
Ok, cool. I'll fix these up and send v3. Thanks!
next prev parent reply other threads:[~2020-01-02 20:00 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-01-02 18:48 [PATCH v2 0/2] tmpfs: Reduce risk of inum overflow Chris Down
2020-01-02 18:49 ` [PATCH v2 1/2] tmpfs: Add per-superblock i_ino support Chris Down
2020-01-02 19:48 ` Amir Goldstein
2020-01-02 20:00 ` Chris Down [this message]
2020-01-02 20:08 ` Amir Goldstein
2020-01-02 18:50 ` [PATCH v2 2/2] tmpfs: Support 64-bit inums per-sb Chris Down
2020-01-02 20:07 ` Amir Goldstein
2020-01-02 20:14 ` Chris Down
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200102200052.GA1181932@chrisdown.name \
--to=chris@chrisdown.name \
--cc=amir73il@gmail.com \
--cc=hannes@cmpxchg.org \
--cc=jlayton@kernel.org \
--cc=kernel-team@fb.com \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=tj@kernel.org \
--cc=viro@zeniv.linux.org.uk \
--cc=willy@infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).