Received: by 2002:a05:7412:9c07:b0:fa:6e18:a558 with SMTP id lr7csp449421rdb; Sat, 27 Jan 2024 13:48:16 -0800 (PST) X-Google-Smtp-Source: AGHT+IFBXAgbDQNmWhY5y+faQGtG/CcQ5pUrunwlYR3N7lbZbLWpjC8ABcVcDGkmfSgzoajL2e29 X-Received: by 2002:a05:6a00:d49:b0:6dd:8014:e7f4 with SMTP id n9-20020a056a000d4900b006dd8014e7f4mr1914272pfv.28.1706392096140; Sat, 27 Jan 2024 13:48:16 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1706392096; cv=pass; d=google.com; s=arc-20160816; b=RhRV46zVQiO8nkJOh18xTDTDcsArG50+Kdqe98knvzhV4T4C82WpidP9PsYkAnigVD gGBgg3Td8fdxck1UAMQ+rwz+2U2Nhf4pzu6yWMojw4EHGaYM/0oamNM0OMyX+6OEQt8I FLvPj/6wtCp0mbWXELSW968laXyezWekbcEQ2Flma9kDgznKyTVhdQ0BG9OQRwds5UgU 5k6Pjbnoesg8CIIVMBY0JEpWz3S7YhM6M8KLAnKMJ1m/YHnztuv2VxVxvGYKIlT8bjsQ ns0UruFqjadsL+CYBopwvWIfLP/65sztV6gEO0RrB79wvVDKchVK0PPEO5lTr6XbXPsm Jyhw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :dkim-signature; bh=YJaXnA9SaBOMDvn0nFXjX3qZzDFfCPfxhRCkv0UC/L0=; fh=/UjTo4bfwJfh9HwGQEzXk71mKRYuCJWZmdLhJ70erPw=; b=0RtwU7hpgnsHRdVVxkKdb4nT0peu65/mE441pBcLTbSOYjoN6liV5L5LTBV0q8Fisu 1vBtDwkK/foohsssIi8GrRypAf+xVXij0OP02ocdSvJsGahoOrytnR6R/TfPTei/XxnB JBDVJww3DYtMTLEA5Nx4h0f333qs1OU44mSZJdZOydZ/r2CnyeIT1pQtZZ+GRxr35rsS jadxFmAGgSIYwzO+3dpKKtQkb78lZMqZ2Hv2B49Iuxm8yLlq9io6Zl0FpO7HcswCrjQ4 vdaDv+NVRuDcX0H0KkX2j4wxP9w1GwzveI+p6fT6bo7aweJ7qhbC3DFSlOi+m+tclqsF GJjw== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@linux-foundation.org header.s=google header.b=PcR1edxN; arc=pass (i=1 spf=pass spfdomain=linuxfoundation.org dkim=pass dkdomain=linux-foundation.org); spf=pass (google.com: domain of linux-kernel+bounces-41406-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-41406-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id k8-20020aa79d08000000b006d99fca81d2si3322671pfp.382.2024.01.27.13.48.15 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 27 Jan 2024 13:48:16 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-41406-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) client-ip=147.75.48.161; Authentication-Results: mx.google.com; dkim=pass header.i=@linux-foundation.org header.s=google header.b=PcR1edxN; arc=pass (i=1 spf=pass spfdomain=linuxfoundation.org dkim=pass dkdomain=linux-foundation.org); spf=pass (google.com: domain of linux-kernel+bounces-41406-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-41406-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 sy.mirrors.kernel.org (Postfix) with ESMTPS id 8013EB22BD1 for ; Sat, 27 Jan 2024 21:48:09 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id E662A1B80B; Sat, 27 Jan 2024 21:47:57 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linux-foundation.org header.i=@linux-foundation.org header.b="PcR1edxN" Received: from mail-wr1-f50.google.com (mail-wr1-f50.google.com [209.85.221.50]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 6B59B1B275 for ; Sat, 27 Jan 2024 21:47:53 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.221.50 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706392076; cv=none; b=j45ODW1uXWuAjLfKiIzwx/1WY+/yOoS5nf6P7z5Ur9I+rk7h3LL9c2hTpcsQpKr4iKfs9jjTGLnYsJDqvoKbuVGutiinWFlVJD9s3tJDKyvmWBCxEEoTiY8ffUIzj99NH5M9Iwuuy3PDD9AjS3Q4MiKG1l4YJEJymzSnlF6oYTQ= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706392076; c=relaxed/simple; bh=cWMIXOib9nzT4MkyOUG6ixPqlyMdXgTkM+grMrK09KQ=; h=MIME-Version:References:In-Reply-To:From:Date:Message-ID:Subject: To:Cc:Content-Type; b=dbVkUkiNpW8Zq0GDWQdZ2JjdgPcjCAdIwj3srFUz7NK320fomGhUk4fb1keH7daO0PmcKkeVQyXSsyGQ8UhO5Pg3n5lu273cDKclDk8EFEoBQrdbsY8FPVYw4k4WySx5o/0qJcrs3qyP9yaaxj4NRoqv1Ed/6Q96IXk7wuGeISw= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=linux-foundation.org; spf=pass smtp.mailfrom=linuxfoundation.org; dkim=pass (1024-bit key) header.d=linux-foundation.org header.i=@linux-foundation.org header.b=PcR1edxN; arc=none smtp.client-ip=209.85.221.50 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=linux-foundation.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linuxfoundation.org Received: by mail-wr1-f50.google.com with SMTP id ffacd0b85a97d-33921b8988fso1571640f8f.3 for ; Sat, 27 Jan 2024 13:47:53 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux-foundation.org; s=google; t=1706392071; x=1706996871; darn=vger.kernel.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=YJaXnA9SaBOMDvn0nFXjX3qZzDFfCPfxhRCkv0UC/L0=; b=PcR1edxNVXO2i1ZYw3PAL5Eg3pfmGEK64e8hS2wSyWg9VmYEF8grxx3LHD9inFLZ/N ceU/2wQve1J8UntOaCQWiQnB6PVedySx51/CUDd9+cAeGrynsp48FxVSCNz7NZC9CgsH F72gUR9TocNfuIQrwr4naZ+uPBrQunZzlVrBM= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1706392071; x=1706996871; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=YJaXnA9SaBOMDvn0nFXjX3qZzDFfCPfxhRCkv0UC/L0=; b=kLnqt1T4UHb1LouEHFcMSIV+aj47F4/xINYN+ahTEFMxj68h4RE1mc8/pEdmoZxEBu pBIJMmAzarCmNukQP/P8v9DHJHdDTd0+fG3lb8r5xnI+v0O0UHLrqfwB9WA4zcRJXANt qFFSXmVFlYs1oJr6g46DCMHlIOZVmH3uUuHny/jtZG0vQVJl1TNlCB7h4RL2wu52tOig 3ekTdoXILr0GfyLakdiLvZoa+ywED3432u5RrzMiyAI49M7C5gGdZVvRfVzUOQ7zIgN9 sYS0xReOLk7Fph2JRQIXf/sRcSimsUI6WspUMv3Aeml0S8IQfs/q14116NdxLuZmg1dO U1Og== X-Gm-Message-State: AOJu0YxYMIdNM6Fy6U+PC7BL16z1gUkx2RCv/oySUKTH9EK6zDFNIRP7 JZr0M0KZKrYl23U1lBpL0j0zxHHih5LWY5ltkCbEoCv5D49UbP6661J3JDtgfat0WXLTwXhYrYT NNzypOg== X-Received: by 2002:a05:6000:194f:b0:336:6b11:c77f with SMTP id e15-20020a056000194f00b003366b11c77fmr1461890wry.113.1706392071188; Sat, 27 Jan 2024 13:47:51 -0800 (PST) Received: from mail-ed1-f52.google.com (mail-ed1-f52.google.com. [209.85.208.52]) by smtp.gmail.com with ESMTPSA id b11-20020aa7c6cb000000b005593c83bdafsm2018026eds.45.2024.01.27.13.47.49 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sat, 27 Jan 2024 13:47:49 -0800 (PST) Received: by mail-ed1-f52.google.com with SMTP id 4fb4d7f45d1cf-55a035669d5so1630525a12.2 for ; Sat, 27 Jan 2024 13:47:49 -0800 (PST) X-Received: by 2002:a05:6402:b10:b0:55e:dc7a:1f14 with SMTP id bm16-20020a0564020b1000b0055edc7a1f14mr207718edb.25.1706392068765; Sat, 27 Jan 2024 13:47:48 -0800 (PST) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 References: <20240126150209.367ff402@gandalf.local.home> <20240126162626.31d90da9@gandalf.local.home> In-Reply-To: From: Linus Torvalds Date: Sat, 27 Jan 2024 13:47:32 -0800 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH] eventfs: Have inodes have unique inode numbers To: Steven Rostedt , Masami Hiramatsu , Mathieu Desnoyers Cc: LKML , Linux Trace Devel , Christian Brauner , Ajay Kaher , Geert Uytterhoeven , linux-fsdevel Content-Type: multipart/mixed; boundary="0000000000001ba36b060ff45d93" --0000000000001ba36b060ff45d93 Content-Type: text/plain; charset="UTF-8" On Fri, 26 Jan 2024 at 13:49, Linus Torvalds wrote: > > For example, what purpose does 'e->dentry' and 'ei->d_childen[]' have? > Isn't that entirely a left-over from the bad old days? > > So please try to look at things to *fix* and simplify, not at things > to mess around with and make more complicated. So here's an attempt at some fairly trivial but entirely untested cleanup. I have *not* tested this at all, and I assume you have some extensive test-suite that you run. So these are "signed-off' in the sense that the patch looks fine, it builds in one configuration for me, but maybe there's something really odd going on. The first patch is trivial dead code removal. The second patch is because I really do not understand the reason for the 'ei->dentry' pointer, and it just looks messy. It looks _particularly_ messy when it is mixed up in operations that really do not need it and really shouldn't use it. The eventfs_find_events() code was using the dentry parent pointer to find the parent (fine, and simple), then looking up the tracefs inode using that (fine so far), but then it looked up the dentry using *that*. But it already *had* the dentry - it's that parent dentry it just used to find the tracefs inode. The code looked nonsensical. Similarly, it then (in the set_top_events_ownership() helper) used 'ei->dentry' to update the events attr, but all that really wants is the superblock root. So instead of passing a dentry, just pass the superblock pointer, which you can find in either the dentry or in the VFS inode, depending on which level you're working at. There are tons of other 'ei->dentry' uses, and I didn't look at those. Baby steps. But this *seems* like an obvious cleanup, and many small obvious cleanups later and perhaps the 'ei->dentry' pointer (and the '->d_children[]' array) can eventually go away. They should all be entirely useless - there's really no reason for a filesystem to hold on to back-pointers of dentries. Anybody willing to run the test-suite on this? Linus --0000000000001ba36b060ff45d93 Content-Type: text/x-patch; charset="US-ASCII"; name="0001-tracefs-remove-stale-update_gid-code.patch" Content-Disposition: attachment; filename="0001-tracefs-remove-stale-update_gid-code.patch" Content-Transfer-Encoding: base64 Content-ID: X-Attachment-Id: f_lrwlqrt70 RnJvbSBkNzQxY2JmMDM4MDM0ZTM5YTY3YzllNjFjYzljZGMzOTMxYjJhN2EzIE1vbiBTZXAgMTcg MDA6MDA6MDAgMjAwMQpGcm9tOiBMaW51cyBUb3J2YWxkcyA8dG9ydmFsZHNAbGludXgtZm91bmRh dGlvbi5vcmc+CkRhdGU6IFNhdCwgMjcgSmFuID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pX3N0YXR1c19mcmVlKHN0cnVjdCB0 cmFjZWZzX2lub2RlICp0aSwgc3RydWN0IGRlbnRyeSAqZGVudHJ5KTsKIAogI2VuZGlmIC8qIF9U UkFDRUZTX0lOVEVSTkFMX0ggKi8KLS0gCjIuNDMuMC41LmczOGZiMTM3YmRiCgo= --0000000000001ba36b060ff45d93 Content-Type: text/x-patch; charset="US-ASCII"; name="0002-tracefs-avoid-using-the-ei-dentry-pointer-unnecessar.patch" Content-Disposition: attachment; filename="0002-tracefs-avoid-using-the-ei-dentry-pointer-unnecessar.patch" Content-Transfer-Encoding: base64 Content-ID: X-Attachment-Id: f_lrwlr2bz1 RnJvbSA0OWIwMDg0ZTAyMjM1OWYwOTdjMDk1NjljMTk5ZmM3ZGZlY2Q0N2U5IE1vbiBTZXAgMTcg MDA6MDA6MDAgMjAwMQpGcm9tOiBMaW51cyBUb3J2YWxkcyA8dG9ydmFsZHNAbGludXgtZm91bmRh dGlvbi5vcmc+CkRhdGU6IFNhdCwgMjcgSmFuIDIwMjQgMTM6Mjc6MDEgLTA4MDAKU3ViamVjdDog W1BBVENIIDIvMl0gdHJhY2VmczogYXZvaWQgdXNpbmcgdGhlIGVpLT5kZW50cnkgcG9pbnRlciB1 bm5lY2Vzc2FyaWx5CgpUaGUgZXZlbnRmc19maW5kX2V2ZW50cygpIGNvZGUgdHJpZXMgdG8gd2Fs ayB1cCB0aGUgdHJlZSB0byBmaW5kIHRoZQpldmVudCBkaXJlY3RvcnkgdGhhdCBhIGRlbnRyeSBi ZWxvbmdzIHRvLCBpbiBvcmRlciB0byB0aGVuIGZpbmQgdGhlCmV2ZW50ZnMgaW5vZGUgdGhhdCBp cyBhc3NvY2lhdGVkIHdpdGggdGhhdCBldmVudCBkaXJlY3RvcnkuCgpIb3dldmVyLCBpdCB1c2Vz IGFuIG9kZCBjb21iaW5hdGlvbiBvZiB3YWxraW5nIHRoZSBkZW50cnkgcGFyZW50LApsb29raW5n IHVwIHRoZSBldmVudGZzIGlub2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