Received: by 2002:a25:c205:0:0:0:0:0 with SMTP id s5csp3228468ybf; Tue, 3 Mar 2020 01:59:33 -0800 (PST) X-Google-Smtp-Source: ADFU+vvw19fh7ofNuhpHvbyXTyr0czCkbeWJGmbI2aIFwI8HJvBQ0ZzPkPZ+yuPMaWN20fYkV9TZ X-Received: by 2002:a05:6830:231d:: with SMTP id u29mr1775383ote.1.1583229573204; Tue, 03 Mar 2020 01:59:33 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1583229573; cv=none; d=google.com; s=arc-20160816; b=twvBqzQ42U6ilVYW02ChObTLPA46WDL9b3DmU04OKvkbb5EF6ObOC99XbnbW0V6iBd +zMj8kpg9sCEjrLzY/n8k+wqVpaeCdVK+PAHePuUzTYn3j0EA9vM2yl7JRu05mSU6jfg r6okQK3ExngSX6EKUYkoCSK9Y9xREco05BbJukX2jkMsrf65AlaLBKSf5sbHvQP0AEmK g4ybHZuIdijmFQVFB3YH6B5jbAbCbbuHYXMOKwsLd6oTjgIFeIYoss5peRkjL1Ic2dZ8 NIUrjva5hyJIAx25XPDvQA1QNtGf+IXiqrnmar4bzmIikHkCsYPkBigpfTLq3felCQFX 1Xzw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=tmUyb7I5QZ5m7l+map6/TTENM00J/X4NTs6U2t9bq9A=; b=nifqXCHoQlOF2Zc3ZMyoLDlG5uFxOq5DO84B+fvfMBk4Ozg0PITligtE1juLvBOai2 B5lW1fEkkAlo9sZXZ4fSZbZbFeOGQg62POBH/oqTQvfW+jpTc8gIA03Nij/OvBVV9ZgL WwKqWfgNQwPTeHlF+eWU1NZaWlU+cS590a2A3gW62yTssremIgiXHuiIK93AbX9UH+IB JzcXW2fByjzLz3i6HQgL9UUDuLB6ETNgzNoFQhe0acYne8LViwwWEbFMY+VnGrOwuiVL E9wMucSyLYuzZc+GpZhblhGFd7qVtYiNrX3905DWcLYUBMKXMsQ/F/aTNzwTuHgAYwVK pkeA== ARC-Authentication-Results: i=1; mx.google.com; dkim=temperror (no key for signature) header.i=@szeredi.hu header.s=google header.b=UnASBZv2; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id l12si3804318otn.66.2020.03.03.01.59.21; Tue, 03 Mar 2020 01:59:33 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=temperror (no key for signature) header.i=@szeredi.hu header.s=google header.b=UnASBZv2; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727974AbgCCJsN (ORCPT + 99 others); Tue, 3 Mar 2020 04:48:13 -0500 Received: from mail-io1-f68.google.com ([209.85.166.68]:45589 "EHLO mail-io1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727818AbgCCJsN (ORCPT ); Tue, 3 Mar 2020 04:48:13 -0500 Received: by mail-io1-f68.google.com with SMTP id w9so2807463iob.12 for ; Tue, 03 Mar 2020 01:48:12 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=szeredi.hu; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=tmUyb7I5QZ5m7l+map6/TTENM00J/X4NTs6U2t9bq9A=; b=UnASBZv2HlRYHTnSbEdv3S4dGBVCqpFO4bwftl15quBrWH6ERWwR//dlevRkFdHY8u Y1NGzPTLB9xA+UewKqkD/sN3CSE6cUYJqxDKljs3apGO9RPeOZ5k4nfs7l8GKFHMahrT 564xMuqnPGrSdkI6+TAepvlKpFkwSitRCuoro= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=tmUyb7I5QZ5m7l+map6/TTENM00J/X4NTs6U2t9bq9A=; b=JPaxodjX08kwRONYmMjYoCu0NfkRItC2KSoZHzBjl9ZxPwrxpk+czGqTX+5nZEi/dV BaRz9+SORGfmHRSZ95j8eL7bjR6TVrrNIuI6poVChkXZdEOF+4xEsy8lWzUgif0a74dK /M7u2tMHNjHPUmNBEOV5Vq2NVU88D9jXLsnpNXxGFypYnBevhDk864B+ZXZ6uT5cRDqo 21ykG6gumua9XPqTFixvy3CLw04EtO88ek5k6BVZmJIShZeafsjPyQityZKJY9VfHBcj BZYWd4GO0uVLctWliIPl3TFwH/Nmbgo3We/ahamroDH1gW/jVCN0s8lNnoB5nrtCxo4b RWRw== X-Gm-Message-State: ANhLgQ1WhsVlI1SvkUWyZqlWuT3mglMkkDXzoStDQStEbyGyjpmFTYwS kfi0O1vYKevqJWcobtIBW0Cqp1jjdtG946PRIbD4mw== X-Received: by 2002:a02:6a10:: with SMTP id l16mr3126436jac.77.1583228892582; Tue, 03 Mar 2020 01:48:12 -0800 (PST) MIME-Version: 1.0 References: <158230810644.2185128.16726948836367716086.stgit@warthog.procyon.org.uk> <1582316494.3376.45.camel@HansenPartnership.com> <1582556135.3384.4.camel@HansenPartnership.com> <1582644535.3361.8.camel@HansenPartnership.com> <20200228155244.k4h4hz3dqhl7q7ks@wittgenstein> <107666.1582907766@warthog.procyon.org.uk> <0403cda7345e34c800eec8e2870a1917a8c07e5c.camel@themaw.net> <1509948.1583226773@warthog.procyon.org.uk> In-Reply-To: From: Miklos Szeredi Date: Tue, 3 Mar 2020 10:48:01 +0100 Message-ID: Subject: Re: [PATCH 00/17] VFS: Filesystem information and notifications [ver #17] To: David Howells Cc: Ian Kent , Christian Brauner , James Bottomley , Steven Whitehouse , Miklos Szeredi , viro , Christian Brauner , Jann Horn , "Darrick J. Wong" , Linux API , linux-fsdevel , lkml , Greg Kroah-Hartman Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Mar 3, 2020 at 10:26 AM Miklos Szeredi wrote: > > On Tue, Mar 3, 2020 at 10:13 AM David Howells wrote: > > > > Miklos Szeredi wrote: > > > > > I'm doing a patch. Let's see how it fares in the face of all these > > > preconceptions. > > > > Don't forget the efficiency criterion. One reason for going with fsinfo(2) is > > that scanning /proc/mounts when there are a lot of mounts in the system is > > slow (not to mention the global lock that is held during the read). BTW, I do feel that there's room for improvement in userspace code as well. Even quite big mount table could be scanned for *changes* very efficiently. l.e. cache previous contents of /proc/self/mountinfo and compare with new contents, line-by-line. Only need to parse the changed/added/removed lines. Also it would be pretty easy to throttle the number of updates so systemd et al. wouldn't hog the system with unnecessary processing. Thanks, Miklos