From patchwork Wed Mar 9 15:20:09 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Andrew Cooper X-Patchwork-Id: 12775204 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 AA5FAC433F5 for ; Wed, 9 Mar 2022 15:20:34 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.287942.488278 (Exim 4.92) (envelope-from ) id 1nRy6x-0007wn-GS; Wed, 09 Mar 2022 15:20:23 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 287942.488278; Wed, 09 Mar 2022 15:20:23 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1nRy6x-0007wg-DV; Wed, 09 Mar 2022 15:20:23 +0000 Received: by outflank-mailman (input) for mailman id 287942; Wed, 09 Mar 2022 15:20:22 +0000 Received: from se1-gles-flk1-in.inumbo.com ([94.247.172.50] helo=se1-gles-flk1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1nRy6w-0006jj-8N for xen-devel@lists.xenproject.org; Wed, 09 Mar 2022 15:20:22 +0000 Received: from esa4.hc3370-68.iphmx.com (esa4.hc3370-68.iphmx.com [216.71.155.144]) by se1-gles-flk1.inumbo.com (Halon) with ESMTPS id 6e40eb4b-9fbc-11ec-8539-5f4723681683; Wed, 09 Mar 2022 16:20:21 +0100 (CET) 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: 6e40eb4b-9fbc-11ec-8539-5f4723681683 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=citrix.com; s=securemail; t=1646839220; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=ZeIcQHUJJRtnxQDTvlTRsnnmCopd2Uwau0mRxANamAY=; b=eF9GBze7Hi/9YrVQdJ2qsFZV0vSkzEDRJ9ACtnMnLce57VMKDAxaryym 6JVKvWxxKpJ6S+88BB2/cKqTPBUCaUw2fjxkZ+xHaAdmo95gqpQaFTNLS L1ujVpKpvDzO5ATvfwW7KbL92yMNkCiC4KN+RJ22bkpkbnmrbaclokKn3 c=; Authentication-Results: esa4.hc3370-68.iphmx.com; dkim=none (message not signed) header.i=none X-SBRS: 5.1 X-MesageID: 68181396 X-Ironport-Server: esa4.hc3370-68.iphmx.com X-Remote-IP: 162.221.156.83 X-Policy: $RELAYED IronPort-Data: A9a23:AIVfbKw9bJYtBuxwGYp6t+cgxirEfRIJ4+MujC+fZmUNrF6WrkUCx mEXDTvSP/rZMWb2LdokbYnk9h5SuZHUz4NlTFBrpCAxQypGp/SeCIXCJC8cHc8zwu4v7q5Dx 59DAjUVBJlsFhcwnj/0bv656yMUOZigHtIQMsadUsxKbVIiGX9JZS5LwbZj2NYz2YnhWWthh PupyyHhEA79s9JLGjp8B5Kr8HuDa9yr5Vv0FnRnDRx6lAe2e0s9VfrzFonoR5fMeaFGH/bSe gr25OrRElU1XfsaIojNfr7TKiXmS1NJVOSEoiI+t6OK2nCuqsGuu0qS2TV1hUp/0l20c95NJ Npl7NuOey0GY4jwu+1ESh9SH39/J7N99+qSSZS/mZT7I0zudnLtx7NlDV0sPJ1e8eFyaY1M3 aVGcnZXNEnF3r/ohuLgIgVvrp1LwM3DFYUToHx/ixreCu4rW8vrSKTW/95Imjw3g6iiGN6AN 5NJMGE+MnwsZTVBJgZOI8MYjtvrl3n+dztF93S5/K8Otj27IAtZj+G2bYu9lsaxbed/k1ucp 2nG13/kGRxcP9uaoRKH/WirnfTnhj7gVcQZE7jQ3u5nhhify3IeDDUSVECnur+ph0imQdVdJ kcIvC00osAa60iDXtT7GRqirxa5UgU0AoQKVbdgsUfUl/SSs13x6nU4oiBpMZsYhuUZGBkW9 VbQhtXjCWJuqqOuRifInluLlg+aNS8QJG4EQCYLSwoZ/tXuyL0OYgLzosVLS/Ds0ICscd3k6 3XT9XVl2e1P5SIe//jjpTj6bySQSo8lp+LfziHeRSqb4wxwf+ZJjKT4uAGAvZ6swGt0J2RtX UToeeDDtIji7rnXzURhpdnh+pnzuZ5p1xWG3TZS82EJrWjFxpJaVdk4DMtCDEloKN0YXjTif VXevwhcjLcKYif0MvErOdLtV5h0pUQFKTgDfqqEBjapSsItHDJrAQk0PRLAt4wTuBNEfV4D1 WezLp/3UCdy5VVPxzuqXeYNuYLHNQhlrV4/savTlkz9uZLHPSb9Ye5cbDOmM7BohIvZ8V692 4sOaKO3J+B3DbSWjt//qtVIczjn7BETWPjLliCgXrXac1Q8Rz15VaO5LHFIU9UNopm5X9zgp hmVMnK0AnKh7ZEbAW1mskxeVY4= IronPort-HdrOrdr: A9a23:pwbWy62/uPRjfrFTxMmSZQqjBI4kLtp133Aq2lEZdPUzSL39qy nOpoV/6faaskdzZJhNo7G90cq7L080l6QFhrX5VI3KNGOKhILBFvAF0WKI+UyDJ8SRzI5gPI 5bAtFD4IKaNzNHZLzBjzVQuexQuOVvi5rFudvj X-IronPort-AV: E=Sophos;i="5.90,167,1643691600"; d="scan'208";a="68181396" From: Andrew Cooper To: Xen-devel CC: Andrew Cooper , Jan Beulich , =?utf-8?q?Roger_Pau_Monn=C3=A9?= , Wei Liu , Juergen Gross Subject: [PATCH] x86/hvm: Annotate hvm_physdev_op() with cf_check Date: Wed, 9 Mar 2022 15:20:09 +0000 Message-ID: <20220309152009.10449-1-andrew.cooper3@citrix.com> X-Mailer: git-send-email 2.11.0 MIME-Version: 1.0 This was missed previously, and would yield a fatal #CP for any HVM domain which issues a physdevop hypercall. Reported-by: Juergen Gross Signed-off-by: Andrew Cooper Reviewed-by: Jan Beulich --- CC: Jan Beulich CC: Roger Pau Monné CC: Wei Liu CC: Juergen Gross --- xen/arch/x86/hvm/hypercall.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xen/arch/x86/hvm/hypercall.c b/xen/arch/x86/hvm/hypercall.c index 030243810e48..62b5349e7d6e 100644 --- a/xen/arch/x86/hvm/hypercall.c +++ b/xen/arch/x86/hvm/hypercall.c @@ -78,7 +78,7 @@ static long cf_check hvm_grant_table_op( } #endif -static long hvm_physdev_op(int cmd, XEN_GUEST_HANDLE_PARAM(void) arg) +static long cf_check hvm_physdev_op(int cmd, XEN_GUEST_HANDLE_PARAM(void) arg) { const struct vcpu *curr = current; const struct domain *currd = curr->domain;