From patchwork Wed Nov 23 15:45:20 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Roger_Pau_Monn=C3=A9?= X-Patchwork-Id: 13053883 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 DCB7CC433FE for ; Wed, 23 Nov 2022 15:46:09 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.447633.704085 (Exim 4.92) (envelope-from ) id 1oxrwa-0000IH-SQ; Wed, 23 Nov 2022 15:45:48 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 447633.704085; Wed, 23 Nov 2022 15:45:48 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1oxrwa-0000IA-Pl; Wed, 23 Nov 2022 15:45:48 +0000 Received: by outflank-mailman (input) for mailman id 447633; Wed, 23 Nov 2022 15:45:47 +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 1oxrwZ-0008Tc-2G for xen-devel@lists.xenproject.org; Wed, 23 Nov 2022 15:45:47 +0000 Received: from esa3.hc3370-68.iphmx.com (esa3.hc3370-68.iphmx.com [216.71.145.155]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id e3846b7b-6b45-11ed-91b6-6bf2151ebd3b; Wed, 23 Nov 2022 16:45:45 +0100 (CET) Received: from mail-mw2nam04lp2177.outbound.protection.outlook.com (HELO NAM04-MW2-obe.outbound.protection.outlook.com) ([104.47.73.177]) by ob1.hc3370-68.iphmx.com with ESMTP/TLS/ECDHE-RSA-AES128-GCM-SHA256; 23 Nov 2022 10:45:41 -0500 Received: from SJ0PR03MB6360.namprd03.prod.outlook.com (2603:10b6:a03:395::11) by DM4PR03MB6935.namprd03.prod.outlook.com (2603:10b6:8:47::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5834.15; Wed, 23 Nov 2022 15:45:39 +0000 Received: from SJ0PR03MB6360.namprd03.prod.outlook.com ([fe80::740b:4e0a:7de4:5ab1]) by SJ0PR03MB6360.namprd03.prod.outlook.com ([fe80::740b:4e0a:7de4:5ab1%7]) with mapi id 15.20.5834.015; Wed, 23 Nov 2022 15:45:39 +0000 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: e3846b7b-6b45-11ed-91b6-6bf2151ebd3b DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=citrix.com; s=securemail; t=1669218344; h=from:to:cc:subject:date:message-id:in-reply-to: references:content-transfer-encoding:mime-version; bh=IvQbbGWxta8BOU6NuWUtOzHVaS0IfJ/5pqW/Sjjha+0=; b=ZT9Z2ehWaxW/+tnNR+EqLjE2wgqJa7bHpvKDYbpUDgWHmmQGwBruOJh7 MT+6ox1ad0Q/JSxzpsS4hxynOor/srNzQyGpH5X/JATjGZaZ+gYlyHc/C ExeePRAXwDNwPRp+QpH0cBCAPQAdCGq/GinOHMeId9bNhRYr/k+rdvEoH I=; X-IronPort-RemoteIP: 104.47.73.177 X-IronPort-MID: 85425892 X-IronPort-Reputation: None X-IronPort-Listener: OutboundMail X-IronPort-SenderGroup: RELAY_O365 X-IronPort-MailFlowPolicy: $RELAYED IronPort-Data: A9a23:H92EDa1erck4eEgpcfbD5T1wkn2cJEfYwER7XKvMYLTBsI5bp2ME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bnmJE42igYy5LrF4sP+tFKH PQ3LswmxOQPVAsKuirDHgMWObO4/XNiZLdeBYDQzI39QWUijusybjiVzyVxA0XXT9jyaortT GtqX2y2oyT99WAjjPM3W7a6Jpb3PPn19t4HcSJzuQFNzn2jQ6sRYJ5H5mPpio8ru2D4Esj1P PMvxAjFcJu7G65RBD/nTLdny3blBo+4X7rzlGVxVPlvMzCXTo/T+5Mn5hQfBf141cp+IgU6t MC40up875sST/QliX04NbFEzlsi0qPuHIn1coelWZWX4cyYKJY6aYf4ERWOpEdGz+S0vFvLM BeSOXnoNpGe1KTaH7U+kFp3dyXR3w2WiyLR0AT0/blpgR+rTRc9Q811cYflnAP+NYWUJ9f/d nJNaxuifVnUtIWRbgVPpZOfeKHTkj2BT7cOmObJlrqUIsdPWjWlpLx6LIpoMm3ZZ0zyocokp ipaiIWiYcLQTOvNSSy5uwJzviUK1/NHwgFi/suq6SRg4eMBYYCaka4ORUTe8jJmYRsPiSUYY f2BHtsOY6SEYLfI/c24+TAYegiFZBnarxyhj8aYSP7niuZEPycisXrNNDuGZHKLREIHkvCP1 prZkmBGCwH1DHnZkPF X-IronPort-AV: E=Sophos;i="5.96,187,1665460800"; d="scan'208";a="85425892" ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=bJNNP/A1EP399rVzYLncv4RFnxE5LnSEYxAokaCTDBcy6AhGDZeJSThiX9gZEnJh/G55wqsdfnAszO46o+s0qWaCbYlYutPa8PpJpPNZLOxMxpVF11I4qDWf/lVDdB9xY6NZPsOBG+Mx/UnVibihZhR1nkgxAW+VfQHnrSa3VdNHU80CTfI4/nKLC8qonoww2yLaZbrPZ+b7nYH8cLbzRWQMPhiZ8gfiRrMEDJ0R7Ku4UqlPEi0wKrRNwD2LREkMkXV+ZmRdA7nMc1Q4e5OfZR4bojHasMMEqPiDwtPjoYgVDC7Zp5BNlLGO1PRU4IFo4uGuIh9uWKS992G6JPGT1w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=ijoTp2u9ZjfF4M3JsrM4RqHyGjKHHh5FQnpmKT5pXL8=; b=WVRIw6Bwn9wABibvjF5Bt1sF9UyvmyoN4s/n+G81aocW9xuKHA4IIwm1kX1qmy7ldX3efpBPkfhcSZbeN5PJNx8v3UdyBQ/8ElrsHDhvwHD83qKvn6qCB3hHpzPHgdzt3JS3Vwk9w516zFhilaVrtc7Ummbr9SfQdHANfOz0SG/TK6DWeDIDiHSDzCwpyMoA0KhMSz9T2nJvsM8vyVEirbGT+XtujJV0CK+0MjjPap5a2UYRzyGeQSk5WyNI1RMESFH/5GjiYsgn5cz6W0h8LLOfUOr+2QjKzABpHJ0K/CuVNrimx7I84TAcUfc7rEd3RNdVa9zDvoGbeyjmYLqIzQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=citrix.com; dmarc=pass action=none header.from=citrix.com; dkim=pass header.d=citrix.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=citrix.onmicrosoft.com; s=selector2-citrix-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=ijoTp2u9ZjfF4M3JsrM4RqHyGjKHHh5FQnpmKT5pXL8=; b=jRxKeSP3Gl+fmWAwE4+FF3vbTY6zG9fDjDC63OXgbAdmMxPopD5jaCNDbeD12NttSrdvtvFSOp2L20tXGM30UhqUrmmUUn6KsXIjfChsJ3+fut7ZN2inTUfpzsxLYHQtgT9hvQZnBEKRr38meqcHhrk6NPGa1PVkDo0zzdLdbzg= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=citrix.com; From: Roger Pau Monne To: xen-devel@lists.xenproject.org Cc: marmarek@invisiblethingslab.com, Roger Pau Monne , Jan Beulich , Andrew Cooper , Wei Liu , George Dunlap , Julien Grall , Stefano Stabellini Subject: [PATCH 1/5] x86/platform: introduce hypercall to get initial video console settings Date: Wed, 23 Nov 2022 16:45:20 +0100 Message-Id: <20221123154525.63068-2-roger.pau@citrix.com> X-Mailer: git-send-email 2.37.3 In-Reply-To: <20221123154525.63068-1-roger.pau@citrix.com> References: <20221123154525.63068-1-roger.pau@citrix.com> X-ClientProxiedBy: LO4P123CA0534.GBRP123.PROD.OUTLOOK.COM (2603:10a6:600:2c5::19) To SJ0PR03MB6360.namprd03.prod.outlook.com (2603:10b6:a03:395::11) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SJ0PR03MB6360:EE_|DM4PR03MB6935:EE_ X-MS-Office365-Filtering-Correlation-Id: 1c6fcbc1-6e5d-4547-8d5e-08dacd69c52c X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: EYHDaoyi020U3R0Vs3XR2TVA7oK3rE2HaB7ZdMmIEbV4D93tVl/nZU69nKdrOd/BVtWyFqlNOQvBfPhNsaj2DZUyh5BTDDUa0NWF8uMpxWtAemDfJWyDteAHphW8/QNaBHDoo/zTI3TUt3MLoDCLy45D4p/cg7grmqD7GQG4PAJ1kasAXX5gy2AERcaz8WwS+xgMUyw1EtjR+mnAnLWmU/7bs+Gd7Ucvds0zh9Zqm63q3LCeaDd0aDiUPJmLea2JlrCChrTtMoH+qFeIpjaUZ59CwjeCesXd1WCQewVccr36bQrHvIpv8KA2RZXcLW2to7sBKMn8u6/oTfkCZV/YmT0kviQ2+BfLrILJcNanuniMwPr8dlPCbjn/E2kYJTPfwK3HLuU+/kPnUZwnynarDn5Stc4wdjmubqoaZrKMSs6CA4GOG3TnimlV5KmhYeuLB/TrIp/rkqxmYuB/l0+2WpfxaGfpRV3MSNGvl4A04ALa5VZAYxXIwpAo197BIzhw7S7qti9dV9oWSyWnslzlLXlfVh0hBLJEJvRmMhX5+NxY7rl12lEMTkTPKdVPqkTuGDchZ8G7lyrpU1ucNMXSMxNROTgau2DMuuo2nnFHPHWnMDhSFfOTKMqWh6BJF87uq5pP2q66RMrCmUqko7Cy7g== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:SJ0PR03MB6360.namprd03.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230022)(4636009)(136003)(376002)(39860400002)(396003)(346002)(366004)(451199015)(36756003)(86362001)(41300700001)(66556008)(66946007)(316002)(66476007)(4326008)(8676002)(82960400001)(38100700002)(6486002)(83380400001)(54906003)(6916009)(478600001)(186003)(2906002)(5660300002)(8936002)(6506007)(2616005)(1076003)(26005)(6512007)(6666004);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?q?xacX7CkSOqnKbRCQj00nUdLPqQJ2?= =?utf-8?q?D3C1Ifn13Cio1G+TmtGv5d93iM3I4IASmtEJmhF0GiLSoG2q3iIFUdYRpYhfhoPPz?= =?utf-8?q?Kr0qh3l20IZoA2tZtSVbqaVAWWrSIYTPt9PQ5gA172IREN7c4fRpentrRINLYw5pG?= =?utf-8?q?Ww8zBNwA5xYvNBZHJi6oIecgSIpkckiVIoj8DIG5qXKlER0evbQSi5IGciqVxgcJC?= =?utf-8?q?f/c6eygumYP8xan50fJEkx0aACeijB8B5dFfv/1FsP43DOyCVSQGzAKAOPvgxHhN9?= =?utf-8?q?y1HBsp3h0mVq/3ZarO6WHa82j8OTLHDzCP4bjmnjg8bp3FC1qg14yg/k1ouevgjDC?= =?utf-8?q?2rD5wEvrs3ocW0a4oWzeLqrXG57A2d+qy/OomlLsmQqy4raT27cOuav07oAFC8SMP?= =?utf-8?q?I8RlkV5iMHhWrIxf7jsTUrZpt5ivyIN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55hsHoiS+OCBNucGCX3LQqv?= =?utf-8?q?eDELRBEdQQVjoaiJGyx6xVN6AfRNddHpfN65hMnN7gAfBM3c4Nw2nFIONto+A2oXa?= =?utf-8?q?CnNtq2bDefFzHD+eTTIBvT+rYr7pDwOaLiYDtawneLFTYyK67wmKT9/X9Vt3tlK2Z?= =?utf-8?q?TK/vfz6+RugLNzutKuR3m1FYiwQNKcG3jzawXUpgtj3E7IR7OAGHnjHo4IPcQ1xRq?= =?utf-8?q?Mdxl8muPwlPQ?= X-MS-Exchange-AntiSpam-ExternalHop-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-ExternalHop-MessageData-0: =?utf-8?q?CiWIHElLHMBNysUU?= =?utf-8?q?1VzjBGyub7hm0/i5WRcJIpLputCx7/ki5OAQLU941w+dEGxMSjlBCPo4KefrlIoR9?= =?utf-8?q?C4YhPu6SFZOOaonTmViRqN62HcYU+3aZ/GdXHe4UEexh5nnrXLglPd0DV00oZjxNc?= =?utf-8?q?Cu6dQefEn06XumTgrmVHQ1lZUoyDl+t6KyNNsthiRG3dD7YKYMTwVYD79jET0ExsI?= =?utf-8?q?TcrJgojiIq+rfak3umyWDXype9ieiKYHHtxUp7wYEKh3A74cZahrg94uBp2LER4L1?= =?utf-8?q?MaDmn0FOz2MO2Zm27Up0sGyGTzpvGJDDEaa3HKKw4hS8fFfnmydAYthPQqvtP4UtM?= =?utf-8?q?wggVZjV5dVHC7PEF4fn9a3ff2Vm1fmc9hk8BF6CVL690pef+llyAqYy3xW+dwAbYa?= =?utf-8?q?BkRYmIA56PboXqEwrFyanGndrANRxFwwT3tfl+fnwzHZ1tKFYSBnQ4YOatEBFoTE5?= =?utf-8?q?0nCKuDTCjp9Zqs7Edim3dkGi7nu07iuS6lJZq0kwGKbj179/ljs9xleRsMn38Y/6y?= =?utf-8?q?O+GCMbSWkeZpNH/c3pq9B0vNRTwzC+5TvjbjCTgMgWHnW1Gnu0tHHCrJQhbRJc/1A?= =?utf-8?q?EeGU1KuNK67/XAE/MwrbPr8UtBvxZiqDMBu89jkBsZupKGRiUNx+HjtJDy7hxnWxx?= =?utf-8?q?XGde94CQWCX/Aq6qVLfRTPUpEht+7PnQJfaHucocaG2HnffD9yW7SYr8PhQJVSVNN?= =?utf-8?q?oAXl5BeONfX18FWGeRwUmf8uEOynrGA4e3OosXfApwQi1c8QOaqbUePAFOtIciZlI?= =?utf-8?q?gP6F/3XE+lfXu/CWSaOduMyc73j/koGVMC2/d7rcb5tcOWvNeD1sGnYG335Q5aEGQ?= =?utf-8?q?q7w9jzUpqt/enhSQ8wzcbjkGM5oNPepfbXNjI5xkIkLiOWhC4YrqxVAr+ds5zjXks?= =?utf-8?q?wogKtoqhp2VQn1W81GJq1GOsHwctiPvY+b?= X-OriginatorOrg: citrix.com X-MS-Exchange-CrossTenant-Network-Message-Id: 1c6fcbc1-6e5d-4547-8d5e-08dacd69c52c X-MS-Exchange-CrossTenant-AuthSource: SJ0PR03MB6360.namprd03.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Nov 2022 15:45:39.2137 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 335836de-42ef-43a2-b145-348c2ee9ca5b X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: 6ZrmzDV8EVFYEjS9rROJ+VFh9NztKUJCrrOQ2DyLtgirDyN+gSwDbnbGWGX52HW7zrIrcUNzjndy67GcN5RO0A== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM4PR03MB6935 This is required so PVH dom0 can get the initial video console state as handled by Xen. PV dom0 will get this as part of the start_info, but it doesn't seem necessary to place such information in the HVM start info. Signed-off-by: Roger Pau Monné Reviewed-by: Jan Beulich --- xen/arch/x86/platform_hypercall.c | 11 +++++++++++ xen/drivers/video/vga.c | 2 +- xen/include/public/platform.h | 6 ++++++ 3 files changed, 18 insertions(+), 1 deletion(-) diff --git a/xen/arch/x86/platform_hypercall.c b/xen/arch/x86/platform_hypercall.c index a7341dc3d7..3f0d0389af 100644 --- a/xen/arch/x86/platform_hypercall.c +++ b/xen/arch/x86/platform_hypercall.c @@ -839,6 +839,17 @@ ret_t do_platform_op( } break; + case XENPF_get_dom0_console: + if ( !fill_console_start_info(&op->u.dom0_console) ) + { + ret = -ENODEV; + break; + } + + if ( copy_field_to_guest(u_xenpf_op, op, u.dom0_console) ) + ret = -EFAULT; + break; + default: ret = -ENOSYS; break; diff --git a/xen/drivers/video/vga.c b/xen/drivers/video/vga.c index 29a88e8241..0a03508bee 100644 --- a/xen/drivers/video/vga.c +++ b/xen/drivers/video/vga.c @@ -205,7 +205,7 @@ static void cf_check vga_text_puts(const char *s, size_t nr) } } -int __init fill_console_start_info(struct dom0_vga_console_info *ci) +int fill_console_start_info(struct dom0_vga_console_info *ci) { memcpy(ci, &vga_console_info, sizeof(*ci)); return 1; diff --git a/xen/include/public/platform.h b/xen/include/public/platform.h index 5e1494fe9a..14784dfa77 100644 --- a/xen/include/public/platform.h +++ b/xen/include/public/platform.h @@ -605,6 +605,11 @@ struct xenpf_symdata { typedef struct xenpf_symdata xenpf_symdata_t; DEFINE_XEN_GUEST_HANDLE(xenpf_symdata_t); +/* Fetch the video console information and mode setup by Xen. */ +#define XENPF_get_dom0_console 64 +typedef struct dom0_vga_console_info xenpf_dom0_console_t; +DEFINE_XEN_GUEST_HANDLE(xenpf_dom0_console_t); + /* * ` enum neg_errnoval * ` HYPERVISOR_platform_op(const struct xen_platform_op*); @@ -635,6 +640,7 @@ struct xen_platform_op { xenpf_core_parking_t core_parking; xenpf_resource_op_t resource_op; xenpf_symdata_t symdata; + xenpf_dom0_console_t dom0_console; uint8_t pad[128]; } u; };