From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-9.9 required=3.0 tests=DKIMWL_WL_MED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,USER_AGENT_SANE_1,USER_IN_DEF_DKIM_WL autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id C26E3C4BA04 for ; Tue, 25 Feb 2020 23:14:30 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 777AB2176D for ; Tue, 25 Feb 2020 23:14:30 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b="mGnOqthE" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 777AB2176D Authentication-Results: mail.kernel.org; dmarc=fail (p=reject dis=none) header.from=google.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 0BA746B000C; Tue, 25 Feb 2020 18:14:30 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 06BC46B000D; Tue, 25 Feb 2020 18:14:30 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id E9C9C6B000E; Tue, 25 Feb 2020 18:14:29 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0039.hostedemail.com [216.40.44.39]) by kanga.kvack.org (Postfix) with ESMTP id D2CDA6B000C for ; Tue, 25 Feb 2020 18:14:29 -0500 (EST) Received: from smtpin22.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay03.hostedemail.com (Postfix) with ESMTP id 78B358248D52 for ; Tue, 25 Feb 2020 23:14:29 +0000 (UTC) X-FDA: 76530205458.22.juice98_443deecec5524 X-HE-Tag: juice98_443deecec5524 X-Filterd-Recvd-Size: 7230 Received: from mail-pf1-f194.google.com (mail-pf1-f194.google.com [209.85.210.194]) by imf34.hostedemail.com (Postfix) with ESMTP for ; Tue, 25 Feb 2020 23:14:28 +0000 (UTC) Received: by mail-pf1-f194.google.com with SMTP id 84so385072pfy.6 for ; Tue, 25 Feb 2020 15:14:28 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=date:from:to:cc:subject:in-reply-to:message-id:references :user-agent:mime-version; bh=ik1zuiqE8i76YJubrnNTmer8KABpIWbp2agVMhEd0M4=; b=mGnOqthEowg2FBXNkXluMN/hRl1lQRj0tN9t5NB1i2gWmfosFiPkJONAvhfT1xHrpU oFKHf+ib2VqZgZN1/abWJvJ5NkBYY9WoXLPdrL45U4fjYYOF390hDPCIo0cwMj9846xy qb1tnlwKk8nzmFrJmtCs1aI5w/oJWQOhdTJb4L0Sv/zqZNUccZUWdoAFMVc61Xtizm0H THNvtbfv35/H2buOTn1Rtq1VkI/BbGTr6Jo15myWk9gRq4BEhEjRnEytFdJ6mue3jSfz L50sbyM4EuxkZKY0mm9oU8CcZyDzDRL8IvLxS+ejiqSOVUAOA+f1/c74w7XTKaooSDh1 VAog== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:in-reply-to:message-id :references:user-agent:mime-version; bh=ik1zuiqE8i76YJubrnNTmer8KABpIWbp2agVMhEd0M4=; b=gE+AgiL7g1lbqJr8+h/Rge4s6pfXIAaUiSwq5/e10qIGwETTEUlqYBrll6N30GdoHv i3DXprUY8lYLOME11vdEyerDG3p7uSOGFFcddh+kkA+u/4332WpnIx+zlK/i55bzBbbB 4cEQUNB2UWr8F2WXhHOqa9eQP6wgXQArTb8UlTjcalXEbwBtS/iA6qVkjujuaGIMGs9M JtnIplTFrM/T7yKFAGpNmozvrLeODyoazQh0msE+Feips8/coZM+ZVyhIkSTCDQ/v0JR socrL5yR01ytumM1KcE5GDgr5aPpBZGkvvPQNyMazuBzxwoAjE6Zoav+v5YzlXyFu7Ix 8dXg== X-Gm-Message-State: APjAAAVg1W8G9/t8V9G0OGpwRn9eywTahXTKAe4KN1WepcSw6O5iUp3F 1bDB2HgcR4FF6p3xeMV8VI5R8Q== X-Google-Smtp-Source: APXvYqwDkSgemuveBIsYIy/dIT5xtOS3wUx5uGf0cTYtvCxSEWAdnhLqNQZgETOPI9K2NzHT19/+Ug== X-Received: by 2002:a62:3892:: with SMTP id f140mr1097196pfa.190.1582672467127; Tue, 25 Feb 2020 15:14:27 -0800 (PST) Received: from [100.112.92.218] ([104.133.9.106]) by smtp.gmail.com with ESMTPSA id w8sm134400pfn.186.2020.02.25.15.14.25 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 25 Feb 2020 15:14:26 -0800 (PST) Date: Tue, 25 Feb 2020 15:14:05 -0800 (PST) From: Hugh Dickins X-X-Sender: hugh@eggly.anvils To: Chris Down cc: Hugh Dickins , Dave Chinner , Chris Mason , Amir Goldstein , Linux MM , Andrew Morton , Al Viro , Matthew Wilcox , Jeff Layton , Johannes Weiner , Tejun Heo , Mikael Magnusson , linux-fsdevel , linux-kernel , Kernel Team Subject: Re: [PATCH v5 2/2] tmpfs: Support 64-bit inums per-sb In-Reply-To: <20200120151117.GA81113@chrisdown.name> Message-ID: References: <20200107001643.GA485121@chrisdown.name> <20200107003944.GN23195@dread.disaster.area> <20200107210715.GQ23195@dread.disaster.area> <4E9DF932-C46C-4331-B88D-6928D63B8267@fb.com> <20200110164503.GA1697@chrisdown.name> <20200120151117.GA81113@chrisdown.name> User-Agent: Alpine 2.11 (LSU 23 2013-08-11) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Mon, 20 Jan 2020, Chris Down wrote: > Hi Hugh, > > Sorry this response took so long, I had some non-work issues that took a lot > of time last week. No, clearly it's I who must apologize to you for very slow response. > > Hugh Dickins writes: > > > > So the "inode64" option will be accepted but redundant on mounting, > > but exists for use as a remount option after mounting or remounting > > with "inode32": allowing the admin to switch temporarily to mask off > > the high ino bits with "inode32" when needing to run a limited binary. > > > > Documentation and commit message to alert Andrew and Linus and distros > > that we are risking some breakage with this, but supplying the antidote > > (not breakage of any distros themselves, no doubt they're all good; > > but breakage of what some users might run on them). > > Sounds good. > > > > > > > Other than that, the first patch could be similar to how it is now, > > > incorporating Hugh's improvements to the first patch to put everything > > > under > > > the same stat_lock in shmem_reserve_inode. > > > > So, I persuaded Amir to the other aspects my version, but did not > > persuade you? Well, I can live with that (or if not, can send mods > > on top of yours): but please read again why I was uncomfortable with > > yours, to check that you still prefer it (I agree that your patch is > > simpler, and none of my discomfort decisive). > > Hmm, which bit were you thinking of? The lack of batching, shmem_encode_fh(), > or the fact that nr_inodes can now be 0 on non-internal mounts? I was uncomfortable with tmpfs depleting get_next_ino()'s pool in some configurations, and wanted the (get_next_ino-like) per-cpu but per-sb batching for nr_inodes=0, to minimize its stat_lock contention. I did not have a patch to shmem_encode_fh(), had gone through thinking that 64-bit inos made an additional fix there necessary; but Amir then educated us that it is safe as is, though could be cleaned up later. nr_inodes can be 0 on non-internal mounts, for many years. > > For batching, I'm neutral. I'm happy to use the approach from your patch and > integrate it (and credit you, of course). Credit not important, but you may well want to blame me for that complication :) > > For shmem_encode_fh, I'm not totally sure I understand the concern, if that's > what you mean. My concern had been that shmem_encode_fh() builds up an fh from i_ino and more, looks well prepared for a 64-bit ino, but appeared to be announcing a 32-bit ino in its return value: Amir reassures us that that return value does not matter. > > For nr_inodes, I agree that intentional or unintentional, we should at least > handle this case for now and can adjust later if the behaviour changes. nr_inodes=0 is an intentional configuration (but 0 denoting infinity: not very clean, and I've sometimes regretted that choice). If there's any behavior change, that's a separate matter from these 64-bit ino patches; maybe I mentioned it in passing and confused us - that we seem to have recently allowed a remounting limited<->unlimited that was not permitted before, and might or might not need a fix patch. Sorry again for delaying you, Chris: not at all what I'd wanted to do. Hugh