Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp806187pxa; Wed, 5 Aug 2020 13:14:23 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwJIUuMGQPps2+rPEoTv6W7NsNf7jZN0Cr1lrggQrNU6KvFE/wN7j93Jad/Wfqq9xckhjkJ X-Received: by 2002:aa7:cdd0:: with SMTP id h16mr1012629edw.116.1596658463364; Wed, 05 Aug 2020 13:14:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1596658463; cv=none; d=google.com; s=arc-20160816; b=UgivedQPvaTYWiHqu6T1B6MR8rGIQQ9JgnqsC5kTntumpjSLlQ8+AdhZNp6AF9nwTq BUx5pPi+wSEgYgGpto+IlF6SJfx2sBQ+1tIQW2aNZAGrkSWUhJdQVbSysWwtvgzNWq0V V6fugk1YeGe6pciRdMNZby1gQszDybDY8OKbunuTkUuvR1IMkojs5JBNWHKfoM2xx1Yf xDcLrUPw8EGzxvwzt5kLzNLhgYzueUI5t20ODzG8RK9pX1AeN+EWjbXaj8tSBN7PZ2hA n5DszvwzvtY9puzbLjOKagqxudsB5vcgVTfwr+BJNjJCsE6Qpdejq1qBhS68uBsRiDRT rLTA== 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:mime-version :user-agent:references:in-reply-to:date:cc:to:from:subject :message-id:dkim-signature:dkim-signature; bh=TV/ywlemDl0JIUauxpySAysG0pozcgKEtLbmEq/dGCI=; b=VxwvwBSDouEoaSWCTtZsOvLk6tx/eb54pUCaQ/YtNIqnuGnOO9KIZwJgKzyepQb9Yw 8a6d5l25dRjey1F0XrAKD3Zj70sRNnwkB156G9jxQp0PvU6GCKWcwQ0qV+DOdqHi23Jf n05HZwHzS3kj61BrMp8VHuIElMZrWrpbrzKtGsFxCOlIRiDFQlcuhSijbr05fxvBFGSt 9oCh+Z/ezsiuRbRUDeAM9WCw5Fq4u3tqXeFDmRWBu0suHT3gtZpSmzOKd2mW82LqAI1K SRvwRWL4/eIMkRXuKusI/hIkxGA6ahQtZAMiqniEWCDGU7D3sBNYoIjRhK5b0KlJHhBq lULQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@themaw.net header.s=fm3 header.b=AwFBpkUn; dkim=pass header.i=@messagingengine.com header.s=fm3 header.b=lGi918tC; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id k23si451836ejg.514.2020.08.05.13.14.01; Wed, 05 Aug 2020 13:14:23 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@themaw.net header.s=fm3 header.b=AwFBpkUn; dkim=pass header.i=@messagingengine.com header.s=fm3 header.b=lGi918tC; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726380AbgHEUNv (ORCPT + 99 others); Wed, 5 Aug 2020 16:13:51 -0400 Received: from wnew3-smtp.messagingengine.com ([64.147.123.17]:37003 "EHLO wnew3-smtp.messagingengine.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726629AbgHEQX0 (ORCPT ); Wed, 5 Aug 2020 12:23:26 -0400 Received: from compute2.internal (compute2.nyi.internal [10.202.2.42]) by mailnew.west.internal (Postfix) with ESMTP id 37C75970; Wed, 5 Aug 2020 07:36:16 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute2.internal (MEProxy); Wed, 05 Aug 2020 07:36:17 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=themaw.net; h= message-id:subject:from:to:cc:date:in-reply-to:references :content-type:mime-version:content-transfer-encoding; s=fm3; bh= TV/ywlemDl0JIUauxpySAysG0pozcgKEtLbmEq/dGCI=; b=AwFBpkUnA5Q3eZVP GUBhoB/ilhwXI9VqrBWf6R5OCpprqNbp8Idwbc0ORpfdwf9XRzKHxTAwASOBHloP C8kELv06f6HkCdmM7o/reWrBy3ZFHjtS93RPzrtwzpS9px9u0fikYwf5UfAk8BZ5 RcJHbvLqHaFZmmEjgxmdm0rRJiF6rzz0BWYeVdJTPAjS1R2mxJunWX3eTVWhiAW/ 6Ap9JaHp1kY6tvHneM1y6nxLkgmPIl/GLPbviB/kmezKdXUMUKBQ6umnfBH0G58f uP7AT57ilb7hRJHyP0HqrNRGP3Aw+xdw/wbrLXYX5oE44K2eyZIzhipL3rbEpcmc S1RKug== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm3; bh=TV/ywlemDl0JIUauxpySAysG0pozcgKEtLbmEq/dG CI=; b=lGi918tCPuQclchc60ZkZQcFuFeLnuEaz5oFvKYw47Yf6N9duODX99vQ0 v2wjcf/SgbslZcfvhprEmRgqBL19HB/1eb/JYzoYuP5jz2HFYgT/ak9IDUfwnhAJ YkJIqH/75jxgyxwt67ZoBjpJqUEoP+E/n89yydB8voI+I/O7zCc7QhLrKKOuLxd8 vDlll4NR2YcE16zazVrfdI/a8y3gt5FGnB5CxQbKvQx0Q1/68uU+NYGdXE8gcVBZ bHzmSNEbRP2lrp6vbGU5+8EiHmA2mQO1uyjzA/m5uW9PHXNgxKUgFedSPlxBTu5F R1D43CcSiAfHDm04i23VAV+1VwUBw== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduiedrjeekgdeggecutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenuc fjughrpefkuffhvfffjghftggfggfgsehtjeertddtreejnecuhfhrohhmpefkrghnucfm vghnthcuoehrrghvvghnsehthhgvmhgrfidrnhgvtheqnecuggftrfgrthhtvghrnhepfe efteetvdeguddvveefveeftedtffduudehueeihfeuvefgveehffeludeggfejnecukfhp peehkedrjedrvdehhedrvddvtdenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmh epmhgrihhlfhhrohhmpehrrghvvghnsehthhgvmhgrfidrnhgvth X-ME-Proxy: Received: from mickey.themaw.net (58-7-255-220.dyn.iinet.net.au [58.7.255.220]) by mail.messagingengine.com (Postfix) with ESMTPA id 1578A30600B1; Wed, 5 Aug 2020 07:36:08 -0400 (EDT) Message-ID: <013e9bb3cb1536c73a5b58c5ff000b3b00629561.camel@themaw.net> Subject: Re: [PATCH 13/17] watch_queue: Implement mount topology and attribute change notifications [ver #5] From: Ian Kent To: Miklos Szeredi Cc: David Howells , Linus Torvalds , Al Viro , Casey Schaufler , Stephen Smalley , Nicolas Dichtel , Christian Brauner , andres@anarazel.de, Jeff Layton , dray@redhat.com, Karel Zak , keyrings@vger.kernel.org, Linux API , linux-fsdevel@vger.kernel.org, LSM , linux-kernel@vger.kernel.org Date: Wed, 05 Aug 2020 19:36:05 +0800 In-Reply-To: References: <158454378820.2863966.10496767254293183123.stgit@warthog.procyon.org.uk> <158454391302.2863966.1884682840541676280.stgit@warthog.procyon.org.uk> <1293241.1595501326@warthog.procyon.org.uk> <43c061d26ddef2aa3ca1ac726da7db9ab461e7be.camel@themaw.net> Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.34.4 (3.34.4-1.fc31) MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 2020-08-05 at 09:43 +0200, Miklos Szeredi wrote: > On Wed, Aug 5, 2020 at 3:54 AM Ian Kent wrote: > > > > It's way more useful to have these in the notification than > > > > obtainable > > > > via fsinfo() IMHO. > > > > > > What is it useful for? > > > > Only to verify that you have seen all the notifications. > > > > If you have to grab that info with a separate call then the count > > isn't necessarily consistent because other notifications can occur > > while you grab it. > > No, no no. The watch queue will signal an overflow, without any > additional overhead for the normal case. If you think of this as a > protocol stack, then the overflow detection happens on the transport > layer, instead of the application layer. The application layer is > responsible for restoring state in case of a transport layer error, > but detection of that error is not the responsibility of the > application layer. I can see in the kernel code that an error is returned if the message buffer is full when trying to add a message, I just can't see where to get it in the libmount code. That's not really a communication protocol problem. Still I need to work out how to detect it, maybe it is seen by the code in libmount already and I simply can't see what I need to do to recognise it ... So I'm stuck wanting to verify I have got everything that was sent and am having trouble moving on from that. Ian