From patchwork Tue Apr 2 17:06:12 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrew Cooper X-Patchwork-Id: 13614425 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 5FF68CD1284 for ; Tue, 2 Apr 2024 17:06:41 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.700227.1093029 (Exim 4.92) (envelope-from ) id 1rrhaU-0004Mn-CP; Tue, 02 Apr 2024 17:06:18 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 700227.1093029; Tue, 02 Apr 2024 17:06:18 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1rrhaU-0004MN-9u; Tue, 02 Apr 2024 17:06:18 +0000 Received: by outflank-mailman (input) for mailman id 700227; Tue, 02 Apr 2024 17:06:16 +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 1rrhaS-0004MH-SL for xen-devel@lists.xenproject.org; Tue, 02 Apr 2024 17:06:16 +0000 Received: from mail-ed1-x52b.google.com (mail-ed1-x52b.google.com [2a00:1450:4864:20::52b]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id 507f0ddd-f113-11ee-afe5-a90da7624cb6; Tue, 02 Apr 2024 19:06:15 +0200 (CEST) Received: by mail-ed1-x52b.google.com with SMTP id 4fb4d7f45d1cf-5684db9147dso6052758a12.2 for ; Tue, 02 Apr 2024 10:06:15 -0700 (PDT) Received: from andrewcoop.citrite.net (default-46-102-197-194.interdsl.co.uk. [46.102.197.194]) by smtp.gmail.com with ESMTPSA id t18-20020a17090616d200b00a4664e6ad8esm6720392ejd.169.2024.04.02.10.06.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 02 Apr 2024 10:06:14 -0700 (PDT) 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: 507f0ddd-f113-11ee-afe5-a90da7624cb6 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=citrix.com; s=google; t=1712077574; x=1712682374; darn=lists.xenproject.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=QUBlmUWv7LiNRjLFrjOMUxED6POsgobYLpj2gCO8DwA=; b=PpdSXMZgMkHYRz21GjoqDqmpk97qd9aqjFXzh/6bta7nvQ/kZNvArMabubbrsTt7+n litMW+WJ0cD7FsJNs9tVFQt8q8QbV1ZetpBcqhZ7jHlfEWmzolkM23YwzbMYBLuASysK GhtuKFE0cM6Ok6bT55DfClrVwKaIbN2M7g7fo= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1712077574; x=1712682374; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=QUBlmUWv7LiNRjLFrjOMUxED6POsgobYLpj2gCO8DwA=; b=wTvay9j/nymGxf2+/ObySflxlsn513Nyw4zVk+pInY6l6rPPIHSX2bs2xP5yGJk0nZ 0hO7goQD6ftNC5rccKLdJKkKvEdW5lIywgNuIj2Dvk1TfIpDtMRoQ1slgY9UYxCWbHwq StlansHvedKHPbQHiwD6WFVDB1c3qRZv6nLqqv72rVSH7lZdNDyW13AJPkWHP0tei1vr 4mcBlESYuLdMPrJtmWo+8hMSVKD2zleKkO62Pt0BlGI2ASSbKet2S3SAfh/e1VNbvOOk WWs2WF7IcoG/Ql9EhJNB2sZKQ8HFhUdt5B6DgkGStt+25CMDJO9kvY+/xKno7dS7pY5s MutA== X-Gm-Message-State: AOJu0YzzdusIudvMuCaJCITkVW0x8o0vBHJHywOpCMiA5ORC0+kYppa4 Q480GR/d7PzfstgDPU8zXK+hW/X5ev6zgBE/u1Btm9KgNAtDIG/cu+Ohz1J4FLFQAHdIWBTycTg ehzA= X-Google-Smtp-Source: AGHT+IHGGhbFnk3JSYFJaNCHupKszT9iWapTMyudX5dBh+kxJaqC05P9ZoWcj0YOEQyF2bfqYGyyAw== X-Received: by 2002:a17:906:2b5b:b0:a4e:60c0:6a98 with SMTP id b27-20020a1709062b5b00b00a4e60c06a98mr252775ejg.55.1712077574465; Tue, 02 Apr 2024 10:06:14 -0700 (PDT) From: Andrew Cooper To: Xen-devel Cc: Andrew Cooper , George Dunlap , Jan Beulich , Stefano Stabellini , Julien Grall , Daniel Smith Subject: [PATCH] Revert "evtchn: refuse EVTCHNOP_status for Xen-bound event channels" Date: Tue, 2 Apr 2024 18:06:12 +0100 Message-Id: <20240402170612.2477791-1-andrew.cooper3@citrix.com> X-Mailer: git-send-email 2.30.2 MIME-Version: 1.0 The commit makes a claim without any kind of justification. The claim is false, and the commit broke lsevtchn in dom0. It is also quite obvious from XSM_TARGET that it has broken device model stubdoms too. Whether to return information about a xen-owned evtchn is a matter of policy, and it's not acceptable to short circuit the XSM on the matter. This reverts commit f60ab5337f968e2f10c639ab59db7afb0fe4f7c3. Fixes: f60ab5337f96 ("evtchn: refuse EVTCHNOP_status for Xen-bound event channels") Signed-off-by: Andrew Cooper Acked-by: Daniel P. Smith --- CC: George Dunlap CC: Jan Beulich CC: Stefano Stabellini CC: Julien Grall CC: Daniel Smith --- xen/common/event_channel.c | 6 ------ 1 file changed, 6 deletions(-) base-commit: 7a09966e7b2823b70f6d56d0cf66c11124f4a3c1 diff --git a/xen/common/event_channel.c b/xen/common/event_channel.c index 20f586cf5ecd..ae6c2f902645 100644 --- a/xen/common/event_channel.c +++ b/xen/common/event_channel.c @@ -1040,12 +1040,6 @@ int evtchn_status(evtchn_status_t *status) read_lock(&d->event_lock); - if ( consumer_is_xen(chn) ) - { - rc = -EACCES; - goto out; - } - rc = xsm_evtchn_status(XSM_TARGET, d, chn); if ( rc ) goto out;