From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=209.85.214.171 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796052513; b=yC5WWuOXkiWBUQQxZjSOuMXUKusOFcshscLmfZgnXI+6SaWr9/osS9xdREufKN17PuEr UTCN9geEE4FRcf3YZzj/V32AwrICfDGfgUKFv1jLyxn3j9qyHbiintlRL0LmjQQ9zosf4 Na+GwBShq8t/K3zp6I4slYH1uQEMH38cxb8GTctGHcT2Tgw10kskRDgpZi/s/B1OnzjWL 9ZbKzNC6+W+shOL4SxpvpgAE2/LNjKh/0zIbMD3QTOsf1tqj7zCQxp3GCDKgdfyomY6Sf f1uwz+3OuhL/1+Xzcz7P9zTRII9YgZGpGj8OacEa7WySvDBXv+DFzwcwIwUNmvtJA0Q== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796052513; h=DMARC-Filter:Received:DKIM-Signature:X-Google-DKIM-Signature: X-Forwarded-Encrypted:X-Gm-Message-State:X-Gm-Gg:X-Received:Received: Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; bh=d8vKOm7VnbyhZx+y5NJ/tPt1nRv5OjF7AlTfX+7bj0c=; b=cRX9K1KCuISMSB+4KOqbgfTLKfzpzmDjocFrdaJpLFaTRrnHjcMIG3rl0+l4IhD39p17 bxEdHEge7ly9Q+N/piy+jJ3IgB5l5/9Gz/PH26AJknCLEcvGGLJBK80ALD9Xgoygr+1b2 JEoHaMg8ZVqs3k6OIYxcOnT2Je5/O3ZE+s2Sx5OF2jLlIFoj81hIGaW1D5WI5CRiKD6U5 s2Em0Xb3XDiwEUMDBZFPbMha6xN8wbw1oLPz2No4d9StXMsBBm4GylolcBWtE9eKjRgiN pcndfQlctYw5Gr+5ZgSo2iVPXYlTiD5DMs/5r6VIPxhpabvwKd4ddXhjQ7nCuXqr4hQ== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass header.from=google.com; spf=pass smtp.mailfrom=google.com; dkim=pass header.d=google.com header.i=@google.com header.a=rsa-sha256 header.s=20260707 header.b=JH5oQ6dC; arc=none smtp.remote-ip=209.85.214.171 Received: from mail-pl1-f171.google.com (mail-pl1-f171.google.com [209.85.214.171]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 4DF3E606A31C for ; Mon, 30 Nov 2026 15:28:33 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 4DF3E606A31C Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=google.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.a=rsa-sha256 header.s=20260707 header.b=JH5oQ6dC Received: by mail-pl1-f171.google.com with SMTP id d9443c01a7336-2f048bc09d7so532055ad.0 for ; Mon, 30 Nov 2026 07:28:33 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20260707; t=1796052513; x=1796657313; darn=vger.kernel.org; h=in-reply-to:content-disposition:content-type:mime-version :references:message-id:subject:cc:to:from:date:from:to:cc:subject :date:message-id:reply-to:content-type; bh=d8vKOm7VnbyhZx+y5NJ/tPt1nRv5OjF7AlTfX+7bj0c=; b=JH5oQ6dCX7cxRLoOuo3fa3mCUGXjB/ztNYi5E5h5Gjb1LjyRQdNiBzFUUKVHkjVPeY gaKMir1g50GfMTYvic1RaahY2w2+saGXVeuHsoOBqf9ZqFPYdDxSMG0EAIXMyL41zxGY BFp4oQ4mvnwDAi96zH+vKviC2+EMaHKra4xH1awpwPH2yvGLZ/TxfMJWJ2j+p4RABw/b Wn5Po8YLs3g5dk42laJZK7lGY48T/gbavni6Yrv78cnIOAuT61FNpTY0Y5cuMzhuhcZ3 NodnTwBjKddI7CX+MwpUGR0Y4WxFjVQgrj4Wg5G8DTPFSrpCtiZQqTNN8oaO5MYO+gx6 DXmg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1796052513; x=1796657313; h=in-reply-to:content-disposition:content-type:mime-version :references:message-id:subject:cc:to:from:date:x-gm-gg :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to :content-type; bh=d8vKOm7VnbyhZx+y5NJ/tPt1nRv5OjF7AlTfX+7bj0c=; b=LENBxoWeh9KIgQUjU5MmzG5u1ml4fpIVaBvUXKEnEnHh7Z5rR+smqrL3cim7tK8+2v bkDpOWZQCp6N67jv3OjK7yaTbYP8f02GIH9pRGNztWJA2KGLNCFgWK8BcFmFz79s6ShO a6EQaPqZGJF+et0YuyuduwG6Vq2zqOEUdQsUB28FaeqrjD4gZEQ8NaaqlyLBlPYSeHbj uV/7pJvxFS1y3ttQ6xDjaXOsZXJiVVliK3xczb/K1+uApMxwR5X//PTuE3JyPx+P6cxX zKl2Lqwo7m2Wk2e6d4FMnRU4QH7vh2CTBROu8ShlIIcpcBZTdw5dsBpqrGBj+zYyTKYy fe3g== X-Forwarded-Encrypted: i=1; AL+hErEbbagCGxgBbaocCPafv9whrbGfCd8oHQ9QSeWJvgrcjs/Lef3SaObx4G3PyfGX3VBJUCwbxPvra3k0qLyk@vger.kernel.org X-Gm-Message-State: APuU4Z8y57iWW6gUf308kypDPKH4McGJh+yJ7o2pUiKD4zxjRneDjr/J KL6vsuQdYsNND6DRd5XIURUi7lfSK+Epj/kWQOq+SEqsL7EQxlG+TuvWW28qizgd6Q== X-Gm-Gg: AZFdTZfHA8hL3NQ5iI0XghgSsuAOJhIlqe8wBWwTuxuCEDq/kp7HWjORQUkmZ2dE1hs mtQlCt++AQjhLMx+YIY4IDsKhApH3p4E30UY1bvWCqxpP6QHRLtYvS0+MgkqUs4vK9kYALKVDMI fMSRBjsKMwYhZ4mkmajb3zurtsZF3rdaoTjBearDJti1QRtB+7EshRTbvpm1ip3nUu8F/TpJGD+ g0oX48o6wo0f2xExgVVd632dmyI/E20vOGl+pJNbWqJhMEMIVQXchwKiU/yPmVRbSBHO+M47EpK +X5+jF1HWMV9vGxI3jQrcYqn0rhTdZgP+uQPk/dcM8LexFAjoJy7d4z3D7oH0mvY8qLhrkMcgNE v19H3ano+9wM5ooQwyLTY/2wcDWTsZ/M0WooYiecorWgZ8cvvb+oFdfA+rLW9AIk//lA1xRDloj KLe9HN2YHfMIeKgZRQnCngUuTR7MM5QvRyRARPUEudV2i5dmuzxi6hcj0xD8hZO9Mmsc38rxSS9 W1utXIPS0phoqDFeqkO0y7acT91cbuEzMj7vXQzeY3hI1NU4bpDSVhhxtzz4InyofNpv3GltE2L i78sVMTIVb84ASc7ltvdHCs/LGQ0H9t+5ld8QgWc3Z61dJB7MacT1/c/jNnxUwi/tqU= X-Received: by 2002:a17:902:cf42:b0:2eb:19f0:6e2a with SMTP id d9443c01a7336-2f066571064mr29044095ad.8.1796052512113; Mon, 30 Nov 2026 07:28:32 -0800 (PST) Received: from google.com (105.211.142.34.bc.googleusercontent.com. [34.142.211.105]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-2f03f1207f1sm167915035ad.64.2026.11.30.07.28.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 30 Nov 2026 07:28:30 -0800 (PST) Date: Mon, 30 Nov 2026 15:28:22 +0000 From: Pranjal Shrivastava To: David Matlack Cc: Joerg Roedel , Will Deacon , Robin Murphy , Jason Gunthorpe , Kevin Tian , Alex Williamson , Jonathan Corbet , Shuah Khan , Randy Dunlap , Mostafa Saleh , Daniel Mentz , Samiullah Khawaja , iommu@lists.linux.dev, kvm@vger.kernel.org, linux-kselftest@vger.kernel.org, linux-doc@vger.kernel.org, Logan Odell , linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [RFC PATCH 7/7] vfio/selftests: Add observability test for IO page table usage Message-ID: References: <20261001224531.765278-1-praan@google.com> <20261001224531.765278-8-praan@google.com> X-Mailing-List: linux-fsdevel@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: On Wed, Nov 25, 2026 at 04:33:32PM -0800, David Matlack wrote: > On Thu Oct 1, 2026 at 3:45 PM PDT, Pranjal Shrivastava wrote: > > Add a new selftest, vfio_nr_pages_test, to validate the iommu-nr-pages > > fdinfo metric across all IOMMU backends (Type 1 and IOMMUFD native/compat). > > What's the status of this series? Should we expect another version > (e.g. after the discussion on the shrinker RFC and at LPC)? > > nit: Please use "vfio: selftests:" as the shortlog prefix for VFIO > selftests (see Documentation/driver-api/vfio-selftests.rst). > Yes. Following the discussion at LPC, Jason would prefer to expose this only through iommufd rather than VFIO type1, so I'm reworking the series along those lines and plan to post it soon. That drops the type1 fdinfo patch and this VFIO selftest. > I gave this a try in QEMU with an emulated Intel IOMMU (which uses > generic_pt, so it reports iommu-nr-pages), on top of this series. It > fails in every mode except iommufd, which skips. Details below. > > [...] > Thanks a lot for testing this, and you're right about both the fd selection and the PROT_NONE mapping. Your point about the final assertion carries over though: I'll make the iommufd selftest check that the count goes back down after a full-table unmap, rather than asserting that it stays up. Thanks, Praan