From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796033147; b=I5jk43dxaf0oSg8IYPKPPjb4iK/2q7fFA9FV7Z+Ta9JatprCs9UevM6bxv8jyKg3oTE8 H+eVCMTV1k7jBrDGdVr+RDeSQYfV0r1mFdXXHcHAZWYYcPEY+n3qxGUUIzqqATLtisDuX DoDjlLchZpvVBCM2ZfpIG4vKk4JnSQlQL6Ct1Zb674qA8Zgpu1+qodbbAUEdp3DYeJ0AZ oFsVosDyomziJ430s7WjIyZD8biZKvJKD+iWP3DWAg3APMG6lG0YLJfy8S/stiFay34lv w3qXqqPQ8n9w/5TG8Fy3HSxwy68Lj7P7ZjudrtI4vCFCrfCv+3roM9DzCugI74wtupg== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796033147; h=Received:DKIM-Signature:Message-ID:From:Subject:Reply-To:To:Cc: In-Reply-To:References:Content-Type:Content-Transfer-Encoding:Date; bh=d7sDs+8Qpj8zaekSgsfu/fmP3sPNmXwPzScmfVQ8KlY=; b=HS2kezpy6o66IxGYaiIOVO1w6VzBs0jMxaRBWqR7HWj93c0eVVPbSXfNrd/l/thzL+ek 42Kfj+C8WIlSqb49PJKDnY8I60OQYbgjUqFLHYlLEsxmVwfoW20QOLdKJ/PflKvRVopkJ H/8dgAk0GDlWfOeadOnii9QU+8xGbHdcFmUUvf+RxXyg8fkTRX9RexxX/QTc0Y1MUbU9Z dd6dYFs6WI9SZF5Kh1GkRQFrIOAEMSFCDl8cZNpCqK/nvvdq7xKqrVUyQ6lhT7CPoEnkB al+XMhL/OZ2Bc7aUt4zOHtnB0kTDW0owSHPWniWlHRJP3B2AhC+9Uv6U6xcc/Y7F1cA== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=lNaBjUGO; arc=none smtp.remote-ip=100.103.45.18 Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 2C3F0606A31C for ; Mon, 30 Nov 2026 10:05:46 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=lNaBjUGO Received: by smtp.kernel.org (Postfix) with ESMTPSA id 16B0C1F00896; Mon, 30 Nov 2026 10:05:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1796033146; bh=d7sDs+8Qpj8zaekSgsfu/fmP3sPNmXwPzScmfVQ8KlY=; h=From:Subject:Reply-To:To:Cc:In-Reply-To:References:Date; b=lNaBjUGOEDZhPwiWGpzH/gTYFR9xlZ/2/GzitkwMH6BjtRo8uazIwD2kDH2tEROrD t9bQFN/I8YEFLAKi+cj5k9ie/OZBLbHWBWu/2K0ifwCTYC4z9L2LDoJQF/ZHtoJv6g sBZAAj8Ib1blok2hIahCSeH/hKNv9aQWr18DVI2icSpPs/+AYPi0LVwZOrqpSAj995 njxS3I9ug/07R5WNsDtG/+y0pZkYbEYYoiENW9N0WqTZyRc7T1zq7XHkpe1TK+EI+u 69MM9i7KN16pe/osRTfTdjUWfNU83nOj9UKOYCX8vugRWkr/gxOjefPaUpjyuibfZG 8ZJiEEsOs063Q== Message-ID: From: sashiko-bot@kernel.org Subject: Re: [PATCH v3] vduse: don't set VM_IO on the domain file mapping Reply-To: sashiko-reviews@lists.linux.dev To: "chenglong ma" Cc: virtualization@lists.linux.dev, "Michael S. Tsirkin" , "Eugenio Perez" In-Reply-To: <20261130095135.862-1-longpareto@gmail.com> References: <20261126062915.209-1-longpareto@gmail.com> <20261130095135.862-1-longpareto@gmail.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Date: Mon, 30 Nov 2026 10:05:45 +0000 X-Mailing-List: virtualization@lists.linux.dev List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list > Commit bb2e6f166547 ("vduse: fix VA/PA confusion in the coherent page > fault path") set VM_IO on the domain mapping to keep vhost-vdpa from > importing it. Since 99fd6bf43d5d, the MM rejects VM_IO on mm-managed > mappings. As a result, mmap() of the domain file warns and returns > -EINVAL, breaking VDUSE userspace. >=20 > Drop VM_IO so that userspace can mmap the domain file again. This also > makes shared mappings of VDUSE domain files eligible for import through > vhost-vdpa. The existing file pointer comparison rejects the target > domain's own file but allows a file belonging to another VDUSE domain. > Each imported entry holds a file reference, so accepting another > domain's file would allow the two domains to hold references to each > other. >=20 > All VDUSE domain files use vduse_domain_fops. Check the file operations > at import time and reject any such file before taking a reference. >=20 > Fixes: bb2e6f166547 ("vduse: fix VA/PA confusion in the coherent page fau= lt path") > Cc: stable@vger.kernel.org > Reported-by: Lorenzo Stoakes (ARM) > Closes: https://lore.kernel.org/r/awWOpS3HR_2FTN3I@gremlin > Suggested-by: Lorenzo Stoakes (ARM) > Signed-off-by: chenglong ma Sashiko has reviewed this patch and found no issues. --=20 Sashiko AI review =C2=B7 https://sashiko.dev/#/patchset/20261130095135.862-= 1-longpareto@gmail.com?part=3D1