Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 75528106FD9A for ; Fri, 13 Mar 2026 07:48:20 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.1253346.1549612 (Exim 4.92) (envelope-from ) id 1w0xFU-0003TT-Gx; Fri, 13 Mar 2026 07:47:56 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 1253346.1549612; Fri, 13 Mar 2026 07:47:56 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1w0xFU-0003TM-EL; Fri, 13 Mar 2026 07:47:56 +0000 Received: by outflank-mailman (input) for mailman id 1253346; Fri, 13 Mar 2026 07:47:56 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1w0xFT-0003TG-T3 for xen-devel@lists.xenproject.org; Fri, 13 Mar 2026 07:47:55 +0000 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.223.130]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id f17c9c2c-1eb0-11f1-b164-2bf370ae4941; Fri, 13 Mar 2026 08:47:54 +0100 (CET) Received: from imap1.dmz-prg2.suse.org (unknown [10.150.64.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id 862AD4E3F0; Fri, 13 Mar 2026 07:47:53 +0000 (UTC) Received: from imap1.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap1.dmz-prg2.suse.org (Postfix) with ESMTPS id 4581A403F6; Fri, 13 Mar 2026 07:47:53 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap1.dmz-prg2.suse.org with ESMTPSA id b3ACDynBs2mfGAAAD6G6ig (envelope-from ); Fri, 13 Mar 2026 07:47:53 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: f17c9c2c-1eb0-11f1-b164-2bf370ae4941 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1773388073; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=vM0JxtxepxxjPoRZ8g1TfJI80befLzmI/O84xGr4URQ=; b=lDrWQ3b1XwPjnOiJAxy7BrEOi9hnp6YZcpOBTrvn+GWTGlqJidgrMP9hZQ1DAxobOqWqpy GkFItCjcS3O7PzpV4jA0E2NRaY+gJAkis5WEfGncceZhNbRkdmBEMjLUZQPZXZo2HTGHVc HnzGcj/TAWXf1pllfjxY4FyskrRff94= Authentication-Results: smtp-out1.suse.de; none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1773388073; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=vM0JxtxepxxjPoRZ8g1TfJI80befLzmI/O84xGr4URQ=; b=lDrWQ3b1XwPjnOiJAxy7BrEOi9hnp6YZcpOBTrvn+GWTGlqJidgrMP9hZQ1DAxobOqWqpy GkFItCjcS3O7PzpV4jA0E2NRaY+gJAkis5WEfGncceZhNbRkdmBEMjLUZQPZXZo2HTGHVc HnzGcj/TAWXf1pllfjxY4FyskrRff94= From: Juergen Gross To: xen-devel@lists.xenproject.org Cc: Juergen Gross , Andrew Cooper , Anthony PERARD , Michal Orzel , Jan Beulich , Julien Grall , =?UTF-8?q?Roger=20Pau=20Monn=C3=A9?= , Stefano Stabellini Subject: [PATCH 0/8] tools/xenstored: add support for watch depth feature Date: Fri, 13 Mar 2026 08:47:43 +0100 Message-ID: <20260313074751.2904215-1-jgross@suse.com> X-Mailer: git-send-email 2.53.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spamd-Result: default: False [-2.80 / 50.00]; BAYES_HAM(-3.00)[100.00%]; NEURAL_HAM_LONG(-1.00)[-1.000]; MID_CONTAINS_FROM(1.00)[]; R_MISSING_CHARSET(0.50)[]; NEURAL_HAM_SHORT(-0.20)[-1.000]; MIME_GOOD(-0.10)[text/plain]; TO_MATCH_ENVRCPT_ALL(0.00)[]; ARC_NA(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; FROM_HAS_DN(0.00)[]; MIME_TRACE(0.00)[0:+]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:mid,imap1.dmz-prg2.suse.org:helo]; FUZZY_RATELIMITED(0.00)[rspamd.com]; RCPT_COUNT_SEVEN(0.00)[9]; RCVD_COUNT_TWO(0.00)[2]; FROM_EQ_ENVFROM(0.00)[]; DKIM_SIGNED(0.00)[suse.com:s=susede1]; TO_DN_SOME(0.00)[]; RCVD_TLS_ALL(0.00)[] In order to reduce excessive number of watch events the watch depth feature has been defined, allowing the user to limit the number of node levels below the watched node to cause events. This series is implementing this feature for xenstored (including the PV and PVH stubdom variants). Possible users are: - xl/libxl: use domid information for the special @introduceDomain and @releaseDomain watches, which will be available when using depth = 1 - xenconsoled, like xl/libxl - any PV-device backends watching directories for added devices (no watch events when any device specific node is modified) - any PV-device frontend and backend watching the "state" node of the other side, in case the other side plays dirty games by building large sub-trees beneath the "state" node This series has been tested with a modified xenstore-watch client. The modification will be sent as soon as the pending series of the xs-clients has been applied. Note that the watch depth series depends on the still pending series "tools: add support for per-domain xenstore quota". Juergen Gross (8): tools/xenstored: allow domU to get own features docs: clarify Xenstore watch depth feature tools/libs/store: add support to use watches with a depth parameter tools/xenstored: add depth information to watches tools/xenstored: add depth handling to XS_WATCH tools/xenstored: replace the fire_watches() exact parameter tools/xenstored: expand special watch handling with depth feature tools/xenstored: make XENSTORE_SERVER_FEATURE_WATCHDEPTH available docs/man/xl.cfg.5.pod.in | 6 ++ docs/misc/xenstore.txt | 14 ++- tools/include/xenstore.h | 16 +++ tools/libs/store/libxenstore.map | 2 + tools/libs/store/xs.c | 116 ++++++++++++++++++---- tools/xenstored/core.c | 15 ++- tools/xenstored/domain.c | 64 +++++++++--- tools/xenstored/domain.h | 2 + tools/xenstored/lu.c | 3 + tools/xenstored/transaction.c | 14 +-- tools/xenstored/transaction.h | 4 +- tools/xenstored/watch.c | 161 ++++++++++++++++++++++--------- tools/xenstored/watch.h | 10 +- xen/include/public/io/xs_wire.h | 2 + 14 files changed, 328 insertions(+), 101 deletions(-) -- 2.53.0