Received: by 2002:ac8:7315:0:b0:429:955e:b7c6 with SMTP id x21csp209632qto; Fri, 26 Jan 2024 16:20:16 -0800 (PST) X-Google-Smtp-Source: AGHT+IG0yb8LwRNk1LVLC0fl4Vpm5UaA4uUMoiKbJV1so6yxw36wSKBeF/Rn3m1sdHodq6/Hq2Cz X-Received: by 2002:a05:620a:46aa:b0:783:4269:8e3 with SMTP id bq42-20020a05620a46aa00b00783426908e3mr648505qkb.54.1706314816110; Fri, 26 Jan 2024 16:20:16 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1706314816; cv=pass; d=google.com; s=arc-20160816; b=Sp4h2Fpu9k7h3P0e82GGaFBacnblj64RfV1EUybbb7PBbHv56RWlkDml6loGueObTL NMyO+YtEdrDbvONTNS4UjQZ1Ky2DmYxIW6ElVsobYNkIlYFCXapyA6sshDEWPW+MYiJb Wsr7rpPA+Jiv60I/3h5fSIbjEBCdaSS4KkHaQfvjbPDUjXw2t5uLevkcLfqCLZcvs9rJ gwCSnD8iwxiolvRw9gxwODws0Rmzt+2it+dYxokR3MsxqvNPLK44fpdJMudHA85YcN4k m/oI8CuI9H0LVVX4681rF+Oez/0BzReW77BMigq9OCtd17NNrQyQcZHUPGUrGVekzlD6 RZ3g== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date:dkim-signature; bh=DN8d2owzns57iSopJhp978Ll3aD6BBmAl0reMwcNfdI=; fh=ivJMw7nBmfdtcCo993vO03jVqYg37CZfV7qd6HaUqAE=; b=0DJy2a3REy1SU+KCrs3UeTrH1+RA8gbTO5pcj3+tvIOc4l3o7edjhCsWWXe5GUEqOX 4hdiaEuJakEPS7jXU404plfdHILxkXbMY9GxxYk+t7ncNQHtsAifNesnzttCKY9kcDOB 6yAhofrXH9eIsvdLogixVcs/+J2F9DHegBb7GgppaHMC1K22xN23ygPGr+VaOH//wA8p bKbbX+USXq7hWM/zx9EocdTLS55TZRR95TmJwsxB5Yc3qjjLolIf3lznY3Arg0aKSidg JgVCzkxFTFGG/7y2YdBv4wZoe6FG/nM75TlmEc9XmGmT4lG2B/yFfiHXCjttzZcnMt0i LpRw== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@infradead.org header.s=casper.20170209 header.b=rrlVeSV2; arc=pass (i=1 dkim=pass dkdomain=infradead.org); spf=pass (google.com: domain of linux-kernel+bounces-40801-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-40801-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id w20-20020a05620a095400b0078393f45c20si2454630qkw.20.2024.01.26.16.20.16 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 26 Jan 2024 16:20:16 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-40801-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@infradead.org header.s=casper.20170209 header.b=rrlVeSV2; arc=pass (i=1 dkim=pass dkdomain=infradead.org); spf=pass (google.com: domain of linux-kernel+bounces-40801-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-40801-linux.lists.archive=gmail.com@vger.kernel.org" Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 403D81C21F1A for ; Fri, 26 Jan 2024 23:04:50 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id E96F756B70; Fri, 26 Jan 2024 23:04:40 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=infradead.org header.i=@infradead.org header.b="rrlVeSV2" Received: from casper.infradead.org (casper.infradead.org [90.155.50.34]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 8606251033; Fri, 26 Jan 2024 23:04:38 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=90.155.50.34 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706310280; cv=none; b=NmCO9QnLwb03/TsppiU1IL+ZrImmOz2eP2P9xfOhXCC2ZAzoNd+P3hCTOtm5nYFhSIZQbLeHrYYdtAq+njCu2ukg4xUNoTlBrZ9EmijVEuW/TpGuPjSSsT5RgT+NrLQUtZ8CmoYG8p0IwCwiFv9ghTXmYrqoQmp2r0p6dcJrIvs= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706310280; c=relaxed/simple; bh=0gSsxB18ZgrEF2eblnqIQDWFIhAl09gsxMxKVlO6beQ=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=uqceD3c/q4XPUloTvOJHkBrRgv4mzX3DNLHemIvr3AuLgWe8+z7kXT0+GTAxFlF7kCTrBSlvoEb4WF5DPssoX9bk6OIshGK8Haa8j5d1y3Mvs0P6RphufB7gOXVTyNxs2rYYv9gDelrtmv0Zy3Tu8B8o16rx9gw331Rz+AT+XFs= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=infradead.org; spf=none smtp.mailfrom=infradead.org; dkim=pass (2048-bit key) header.d=infradead.org header.i=@infradead.org header.b=rrlVeSV2; arc=none smtp.client-ip=90.155.50.34 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=infradead.org Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=DN8d2owzns57iSopJhp978Ll3aD6BBmAl0reMwcNfdI=; b=rrlVeSV2YcrCQu1oQKlejA2XcZ awJ5SF5dZchxBzdZPwsEx1T5FCZITiwWdoVhClA1o/BVXF5OPfGAzMhVPoPvuE+CJUSjfewEUesGH DFd1HS8YxfS6WECKXBMQEbEyQlY8kw6CQM4YbrT2ssdsmulv3nur/YijiJr2umdrAJyH2jYRgV9Pj Sp6x+B4aexzxIx6xG3lpc/WACano+RlMDKkiRElscM7bRgXlj/5VTI7OUYgYLCIOkYU0Ib3dqlOpi 82amaM1sMM6mmB7eCTmo6p9Tq/fCZVL1Hcy6xvmbBoZC9NGlDRbPK/8ffwtBEV65vdt1qRHt/dnnT aaoBvXGg==; Received: from willy by casper.infradead.org with local (Exim 4.97.1 #2 (Red Hat Linux)) id 1rTVFS-0000000F7cc-3ErG; Fri, 26 Jan 2024 23:04:34 +0000 Date: Fri, 26 Jan 2024 23:04:34 +0000 From: Matthew Wilcox To: Linus Torvalds Cc: Mathieu Desnoyers , Steven Rostedt , LKML , Linux Trace Devel , Masami Hiramatsu , Christian Brauner , Ajay Kaher , Geert Uytterhoeven , linux-fsdevel Subject: Re: [PATCH] eventfs: Have inodes have unique inode numbers Message-ID: References: <20240126150209.367ff402@gandalf.local.home> <20240126162626.31d90da9@gandalf.local.home> <8547159a-0b28-4d75-af02-47fc450785fa@efficios.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: On Fri, Jan 26, 2024 at 02:48:45PM -0800, Linus Torvalds wrote: > On Fri, 26 Jan 2024 at 14:34, Matthew Wilcox wrote: > > > > On Fri, Jan 26, 2024 at 05:14:12PM -0500, Mathieu Desnoyers wrote: > > > I would suggest this straightforward solution to this: > > > > > > a) define a EVENTFS_MAX_INODES (e.g. 4096 * 8), > > > > > > b) keep track of inode allocation in a bitmap (within a single page), > > > > > > c) disallow allocating more than "EVENTFS_MAX_INODES" in eventfs. > > > > ... reinventing the IDA? > > Guysm, this is a random number that is *so* interesting that I > seriously think we shouldn't have it at all. > > End result: nobody should care. Even the general VFS layer doesn't care. > > It literally avoids inode number zero, not because it would be a bad > inode number, but simply because of some random historical oddity. > > In fact, I don't think we even have a reason for it. We have a commit > 2adc376c5519 ("vfs: avoid creation of inode number 0 in get_next_ino") > and that one calls out glibc for not deleting them. That makes no > sense to me, but whatever. Maybe we should take advantage of that historical oddity. All files in eventfs have inode number 0, problem solved.