Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp1617014ybi; Sun, 30 Jun 2019 20:21:33 -0700 (PDT) X-Google-Smtp-Source: APXvYqzXTSEz8CRnBhtUMhVTX1e5nsJn913jd/SiHCEXZ6byXGf7v+57/txQqjyIbfmq4o5VWPrb X-Received: by 2002:a65:538d:: with SMTP id x13mr22399375pgq.190.1561951293012; Sun, 30 Jun 2019 20:21:33 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1561951293; cv=none; d=google.com; s=arc-20160816; b=qNNRVo7dOm9F6PYI7NKXn1Gse6D9JVQzyoeCtI39bTqlehe2uMxJZS3a80bNQRZJyI SSXLjTphAOYlOoswuRXZXZwGFo96xD8VGHHUJksSBarsc2j9KmNIHXblE36Gkvqb89NR Jl+fD/CxjxfCqlEEHuVoSUM4Vnje7GauiDbpPc7u27R12riw95M7pC94dtF7vmAnWr1j UgepvIhCupDN7R3xV19uvv+QZl8m4zF21ZKk+BP1tFLFUzHJzSchV4lQ4v8rxMnM7vcW 7XDCXgO9rg7QxNk/Gka5V6x4YcuN/jhPvhyR2M/g12ZzlBUO6jujX3LjUyc3a+SOTnRG 5p3Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature; bh=IHOctcrnamPZlDOqkWx9gP7HKz6z4cfFnI1BHiO0w78=; b=Ji1YpmnKaCP4Ujuu9RQdcJOEWNtIS8naqCApY4OIZ/y/9yFxOC0xa0SMJwEEcjTlT4 F4IaJnGlRXK1P0ZYwq6s2phTwwA1EoeTkdfE3EoITacnjhVAifP4HbiNF3ssT6La6Afr FDpgTdkkHZF3TRJQVyxqBKnG7BJFSuK9GchNzV8hO1bGEoOgM2d86nh9Oe9k43sn/Bvr h8IQNyRCIx5s2QJEdhkCZMWVUAHABEt72OeXXsmgnxif6zr3pM0S+zHA1FSxKDP5yHQ2 7UcuV5O9BfonQuIgYpmUXg/huGrX3njprjd8NVY7z61bvbVrb97rgK+K9Dc0JeB0xMsO m//w== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=MKHZDli9; 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 b21si9327522pjo.49.2019.06.30.20.21.16; Sun, 30 Jun 2019 20:21:32 -0700 (PDT) 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=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=MKHZDli9; 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 S1727111AbfGAC7l (ORCPT + 99 others); Sun, 30 Jun 2019 22:59:41 -0400 Received: from bombadil.infradead.org ([198.137.202.133]:54944 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726472AbfGAC7l (ORCPT ); Sun, 30 Jun 2019 22:59:41 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20170209; h=Content-Transfer-Encoding: Content-Type:In-Reply-To:MIME-Version:Date:Message-ID:From:References:Cc:To: Subject:Sender:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=IHOctcrnamPZlDOqkWx9gP7HKz6z4cfFnI1BHiO0w78=; b=MKHZDli96OWvWZf7Ml4qTTeTS ADyGVjgEjt6ySSV9VdCosU1hi/21jcTscAC72nDZep1VKznI9fOx5A3N3iQPcPQy90pnC1WC+eC1S Rr7xFMdssx1hm0W+7gNoMx1ZjX+NiaShGwa47IjtziyeHwzGGep8ZAN86u3cCfovTY2F7wuumVf87 txn5FMi7ZWCH/Z/lgAMKc90KP7QwzvTaqGRrZNGra+ZSPqK40+DWONlvWDTT8RVbu20a0hZVH3uxk H2OilOPm03NJt7KIxOKf2aPx1YW4NfG8NGsQC+FAYu1tdnITXha3MxrdrMgG9/RcGNspO6MR5oPXD 8OeSFCLlA==; Received: from static-50-53-52-16.bvtn.or.frontiernet.net ([50.53.52.16] helo=dragon.dunlab) by bombadil.infradead.org with esmtpsa (Exim 4.92 #3 (Red Hat Linux)) id 1hhmXZ-0007q7-Pi; Mon, 01 Jul 2019 02:59:37 +0000 Subject: Re: [PATCH 2/6] Adjust watch_queue documentation to mention mount and superblock watches. [ver #5] To: David Howells , viro@zeniv.linux.org.uk Cc: Casey Schaufler , Stephen Smalley , Greg Kroah-Hartman , nicolas.dichtel@6wind.com, raven@themaw.net, Christian Brauner , keyrings@vger.kernel.org, linux-usb@vger.kernel.org, linux-security-module@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-api@vger.kernel.org, linux-block@vger.kernel.org, linux-kernel@vger.kernel.org References: <156173701358.15650.8735203424342507015.stgit@warthog.procyon.org.uk> <156173703546.15650.14319137940607993268.stgit@warthog.procyon.org.uk> From: Randy Dunlap Message-ID: <7a288c2c-11a1-87df-9550-b247d6ce3010@infradead.org> Date: Sun, 30 Jun 2019 19:59:33 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.7.2 MIME-Version: 1.0 In-Reply-To: <156173703546.15650.14319137940607993268.stgit@warthog.procyon.org.uk> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi David, On 6/28/19 8:50 AM, David Howells wrote: > Signed-off-by: David Howells > --- > > Documentation/watch_queue.rst | 20 +++++++++++++++++++- > drivers/misc/Kconfig | 5 +++-- > 2 files changed, 22 insertions(+), 3 deletions(-) > > diff --git a/Documentation/watch_queue.rst b/Documentation/watch_queue.rst > index 4087a8e670a8..1bec2018d549 100644 > --- a/Documentation/watch_queue.rst > +++ b/Documentation/watch_queue.rst > @@ -13,6 +13,10 @@ receive notifications from the kernel. This can be used in conjunction with:: > > * USB subsystem event notifications > > + * Mount topology change notifications > + > + * Superblock event notifications > + > > The notifications buffers can be enabled by: > > @@ -324,6 +328,19 @@ Any particular buffer can be fed from multiple sources. Sources include: > for buses and devices. Watchpoints of this type are set on the global > device watch list. > > + * WATCH_TYPE_MOUNT_NOTIFY > + > + Notifications of this type indicate mount tree topology changes and mount > + attribute changes. A watch can be set on a particular file or directory > + and notifications from the path subtree rooted at that point will be > + intercepted. > + > + * WATCH_TYPE_SB_NOTIFY > + > + Notifications of this type indicate superblock events, such as quota limits > + being hit, I/O errors being produced or network server loss/reconnection. > + Watches of this type are set directly on superblocks. > + > > Event Filtering > =============== > @@ -365,7 +382,8 @@ Where: > (watch.info & info_mask) == info_filter > > This could be used, for example, to ignore events that are not exactly on > - the watched point in a mount tree. > + the watched point in a mount tree by specifying NOTIFY_MOUNT_IN_SUBTREE > + must be 0. I'm having a little trouble parsing that sentence. Could you clarify it or maybe rewrite/modify it? Thanks. > > * ``subtype_filter`` is a bitmask indicating the subtypes that are of > interest. Bit 0 of subtype_filter[0] corresponds to subtype 0, bit 1 to -- ~Randy