From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=209.85.214.181 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796052513; b=WYtqKwEGYKhIQuSRUdZLX2bGIaoxEg0yNTFKVkAockhiyMUU6zSQZ6CrO35ZQ5AlIVyy HtA2PRW3c2S4/S+Tiln/HiI8I4e0BqVvTRrZdQ3ut3SIytT4xtb6LVf/Mf17j0pMJ0nzW UBSyvGleTPLikK5NEsV7ZtGm5fL79dk3btJThh/MjRIRSnZbfegjdFc8VHTkXWk3EDuy/ zeacY0Y7Yn3q96oo05+XxFBf2/2g1sTJV4AuwxIreSRCGEfP48qj4bTlQZe3I+ndMUOR+ mJyILTqiTgH/k2+PvdfzzXR0mvYaVyyWcvt78BCZgFSBLEuwfR4Mrojykdd+MiqLDJw== 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=pmMG/Kdz4l+oGo5FL7ba1sPLkGDcwQWUzA58weCs6T15PKqqGl8/SBZU074GYddj++CD HsYUbcDiQDo8xGu9V/dH6kKn/Lk6ldzl/jfvV0XCJMUkg7mRSYeH+uMTNUEnQ1yd+ECzN f6PvWgC00+ZLwN+xBZtfx9/dcBM2AhQw7WSuNmMUqjt4wG1Hu61p9Z6CBDy1Fh+9cv150 ugD7Rfh3lkKE8FL5DFDcLEZJ03JlUvRIbfs2baEVKQ2ntfejD1OhX+JQ4Pb/i4HI7+M/T LrOwyAqvmw6tmS3SfSNHZdHDnjcQ8v/KrIw2ADB2QtJ1dV2kwzX1UOGcvCyFY/BWT5g== 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.181 Received: from mail-pl1-f181.google.com (mail-pl1-f181.google.com [209.85.214.181]) (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 585BD606A329 for ; Mon, 30 Nov 2026 15:28:33 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 585BD606A329 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-f181.google.com with SMTP id d9443c01a7336-2f0afdb97abso446905ad.1 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=urdXXOm/JSe2aXpHHp/vHKOdON262j/93ZZy7QxmA+UGp1ks41Be5GTqqj/YufHDct NcugKO6ayPQmx0oM3SV43zShKzKLYNoQwgM4N9VSiJ2ufty5o0amd/KSWrXkST3qTCXB Eu6JCDN+U5W3Q9czuCJJKjd7hPSZtXxvPYvPyhWUDCszEHmWL8CDvYE4dF9fJgbT7MPx FqWTLpW6X6JbcI/nMHt/wzHDLV6zoX1fud7b1L0GJm8+IFunIdazJz5vMVv5h3inNi2e w5xQWJDO8uQRCXjG2tGV5MeJI4VQN5dr5l60PG+8bfzGIv1/gvwuN1GrqVZ9jeFzD+PJ 3SGQ== X-Forwarded-Encrypted: i=1; AL+hErH+z0Lh7eDCxMq3i6z2UqGykf2YStCHU1GqCAs2dLNR4TMGAALSdnPvNyGnXyr54R6l3WP9v2CoM7w=@vger.kernel.org X-Gm-Message-State: APuU4Z+ejitNEKCvGGh0sFXRJqGozCMg39NLhSa92/ME94Lg3LEDUWVe M0Ku3Q92zEUC4nPbO7Hzvq0Pp0bzgRyOK9FAQ+okUUCVYwiWyPme6iwbDlIXxF5ZRQ== X-Gm-Gg: AZFdTZdc6AQXEBOwbE2vkNAkIoVFXxPYIgNbqDi4ziF1qSMJVc0Vbp7WhLWcOUYETBv ae+EsG0lGIT53AR0nkOk2olhFmcEudPwjAsqDu8wrcKEMlyTLITA8IYM3KcK8zyUdoNxBFl/UeJ nFIk4D/Fnh/Tq3CcCrUEoBpuBp+AqUtdP9B1zJ7tGDBbMKAGAh7w04VnGeHA9kMqel03+CGDwXd SKeXBu/QEoz2dSu8ZrBFWe9eJsXPMnuTtMNUug2oPeNd4haK9bak3ZDsuKVhZO2aqdzraJNsPFp c0Ix7i8NCoxRmy5rj76R4CH/jEpuCGcS9P8vmu2+SzDmKPso+mK/a1G8sXG3TOf4WXNS6WVBgeS 2Yv+ifDDwUWo3yN/KPqj8BpuqAq5plHfkdvk/ZpSuJmK0n8n0EDjqAVAPqQw9cf3A/v0GwppoZi ta3Sb+5HhtYGEwEQrMuYy/Drt/2IKbKb/Z7OooqH7kYgYzPNiqH36aqqDbsLnP6uyKvwjdcgyGc +u1hBknk75YnCWSK1ahZ/1eaVKgVhTygMwmFRBnLpQffSQhTwzuYpRN3xz39UU/p4FE/BM7Gl1s c6m0yJuWmbc087fspM1JUzTZu81GUc/R1526GJgGGnhhWVgGxxq9AahzrwP+G7jGa20= 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-doc@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