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=-0.9 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS 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 87895C3F2D2 for ; Mon, 2 Mar 2020 10:34:15 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 59D4721739 for ; Mon, 2 Mar 2020 10:34:15 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b="NsjoU95o" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727365AbgCBKeP (ORCPT ); Mon, 2 Mar 2020 05:34:15 -0500 Received: from us-smtp-delivery-1.mimecast.com ([207.211.31.120]:46446 "EHLO us-smtp-1.mimecast.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1727228AbgCBKeO (ORCPT ); Mon, 2 Mar 2020 05:34:14 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1583145254; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=TnovkU9TRaPZCsU6BNaYIoozjytGGGEjCSLnwzS1uVA=; b=NsjoU95o9fnVJW/Vdm9ZpAZWjpmX8yKiDmKP5MG8qHxOeL4Jx0/MYE0dMyVm2T3fa8LIeS iaUhghid6qV7YH/iwKiUvp3qmjkGJMf1KOiyJGG0/rFgnE/Lx6TcZIRfdhhJf6vhsWYf7c xRxIj3eczxSD+x/fwz9oDkkTiWmLCq0= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-65-tECFLaW-PiulY-HJ6apnyg-1; Mon, 02 Mar 2020 05:34:10 -0500 X-MC-Unique: tECFLaW-PiulY-HJ6apnyg-1 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 81C8410824EE; Mon, 2 Mar 2020 10:34:07 +0000 (UTC) Received: from ws.net.home (ovpn-204-202.brq.redhat.com [10.40.204.202]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 97F465DA2C; Mon, 2 Mar 2020 10:34:03 +0000 (UTC) Date: Mon, 2 Mar 2020 11:34:00 +0100 From: Karel Zak To: Miklos Szeredi Cc: Greg Kroah-Hartman , Ian Kent , Miklos Szeredi , James Bottomley , Steven Whitehouse , David Howells , viro , Christian Brauner , Jann Horn , "Darrick J. Wong" , Linux API , linux-fsdevel , lkml , Lennart Poettering , Zbigniew =?utf-8?Q?J=C4=99drzejewski-Szmek?= , util-linux@vger.kernel.org Subject: Re: [PATCH 00/17] VFS: Filesystem information and notifications [ver #17] Message-ID: <20200302103400.vk3cki7agfq2zhpv@ws.net.home> References: <1c8db4e2b707f958316941d8edd2073ee7e7b22c.camel@themaw.net> <3e656465c427487e4ea14151b77d391d52cd6bad.camel@themaw.net> <20200227151421.3u74ijhqt6ekbiss@ws.net.home> <20200228122712.GA3013026@kroah.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 Sender: linux-api-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-api@vger.kernel.org On Fri, Feb 28, 2020 at 05:24:23PM +0100, Miklos Szeredi wrote: > ned-By: MIMEDefang 2.78 on 10.11.54.4 > > On Fri, Feb 28, 2020 at 1:27 PM Greg Kroah-Hartman > wrote: > > > > Superblocks and mounts could get enumerated by a unique identifier. > > > mnt_id seems to be good for mounts, s_dev may or may not be good for > > > superblock, but s_id (as introduced in this patchset) could be used > > > instead. > > > > So what would the sysfs tree look like with this? > > For a start something like this: > > mounts/$MOUNT_ID/ > parent -> ../$PARENT_ID > super -> ../../supers/$SUPER_ID > root: path from mount root to fs root (could be optional as usually > they are the same) > mountpoint -> $MOUNTPOINT > flags: mount flags > propagation: mount propagation > children/$CHILD_ID -> ../../$CHILD_ID > > supers/$SUPER_ID/ > type: fstype > source: mount source (devname) > options: What about use-cases where I have no ID, but I have mountpoint path (e.g. "umount /foo")? In this case I have to go to open() + fsinfo() and then sysfs does not make sense for me, right? Karel -- Karel Zak http://karelzak.blogspot.com