From patchwork Thu Feb 6 01:08:39 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stefano Stabellini X-Patchwork-Id: 13962090 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 1E4B6C02192 for ; Thu, 6 Feb 2025 01:09:05 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.882390.1292528 (Exim 4.92) (envelope-from ) id 1tfqO1-0007hh-HP; Thu, 06 Feb 2025 01:08:57 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 882390.1292528; Thu, 06 Feb 2025 01:08:57 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1tfqO1-0007ha-Ea; Thu, 06 Feb 2025 01:08:57 +0000 Received: by outflank-mailman (input) for mailman id 882390; Thu, 06 Feb 2025 01:08:56 +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 1tfqO0-00072L-06 for xen-devel@lists.xenproject.org; Thu, 06 Feb 2025 01:08:56 +0000 Received: from NAM11-CO1-obe.outbound.protection.outlook.com (mail-co1nam11on2062f.outbound.protection.outlook.com [2a01:111:f403:2416::62f]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id efa3cc62-e426-11ef-a0e7-8be0dac302b0; Thu, 06 Feb 2025 02:08:55 +0100 (CET) Received: from BYAPR01CA0066.prod.exchangelabs.com (2603:10b6:a03:94::43) by SJ2PR12MB7824.namprd12.prod.outlook.com (2603:10b6:a03:4c4::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8398.25; Thu, 6 Feb 2025 01:08:51 +0000 Received: from CO1PEPF000066EB.namprd05.prod.outlook.com (2603:10b6:a03:94:cafe::70) by BYAPR01CA0066.outlook.office365.com (2603:10b6:a03:94::43) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.20.8398.25 via Frontend Transport; Thu, 6 Feb 2025 01:08:51 +0000 Received: from SATLEXMB04.amd.com (165.204.84.17) by CO1PEPF000066EB.mail.protection.outlook.com (10.167.249.7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.8398.14 via Frontend Transport; Thu, 6 Feb 2025 01:08:51 +0000 Received: from SATLEXMB05.amd.com (10.181.40.146) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.39; Wed, 5 Feb 2025 19:08:49 -0600 Received: from SATLEXMB03.amd.com (10.181.40.144) by SATLEXMB05.amd.com (10.181.40.146) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.39; Wed, 5 Feb 2025 19:08:49 -0600 Received: from smtp.xilinx.com (10.180.168.240) by SATLEXMB03.amd.com (10.181.40.144) with Microsoft SMTP Server id 15.1.2507.39 via Frontend Transport; Wed, 5 Feb 2025 19:08:48 -0600 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: efa3cc62-e426-11ef-a0e7-8be0dac302b0 ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=H1MVvYLK0MnIDLTR9XILBhPvG7MHmJVct1Qb/DUnhN13azJ7Yk1aFJwUErh3tJkmIoQjwEXcctnOYBX0SZh/z1xEQ8bYuMTSDE7cps6vT3G0gn94NBP5CAYHijAL4fDa4CB6zLBFW3tYS0cR+jJeMT7sEqGABc+6uewCxhv7X2YXkB0aRRUBgLAXullGOqMukeRkdy6UtAFqA2yb7t7K6yyAUIS3PKCJqF+NGk/YYhKVHWntstgOJwLk90ONor6OrUJOPM/5pVRktT1j+ZvCnzF61xYmQpn26XqvRqlbKFAEgoqSlvtsLMF04DHwe/zWaTD4b4XxqEvEsNDU8R6fMw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; 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=bm9n7d0lv39csuk5HxxqaBGOy78rYQuqOosnK5AZnWo=; b=NuN6EKtVjsH0LGTi02OkAV7iyB0RybPlpecKxbVHBHt3VhA8GkfdKOaR1l5LGTh7Yc1vLZ2NV7WLQgVIdv1YzHgZsMj5bBom4fGGNR3qVqTGBJDUmF3p70vw2DlHWhueZLJVlu1POLJ/pDGkGOJHuOOO6MoAPfMjdhPTH+V1UCT+ytDnKN80AqjtKLE3yRRiDuYyWIZdX0w3tcpjp+b8rSYwAB/M83poO1UEo4K5fICGbtnMQxuPo+dC/mFfiImRpleXWaK1RODfkfnzSWujs5y6Rz0P8D1fsRofkl2Xw3hdvZRHjpM+jM6v3isr9HUTJWGC8TlPZcc3ia2G3hmEIw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=lists.xenproject.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none (0) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=bm9n7d0lv39csuk5HxxqaBGOy78rYQuqOosnK5AZnWo=; b=hofMgEO3Vmws0LjG9Pbs5Oq7uvkHVQpGjWlGw0ixElpqFuE3Pjs0zx7VqnOrjk5XqEK/RQfIkLg6B2CvS4U8jXDwMUayNuN7A7UGVu8T1H5cU7Pq5fhyzPd72kBMLuGBhRfdV2+66g8fDQhH08MRZlKtRB70NUkuH3uEqdF4dpU= X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB04.amd.com; pr=C From: Stefano Stabellini To: CC: , , , , , Henry Wang Subject: [PATCH v5 5/9] docs/features/dom0less: Update the late XenStore init protocol Date: Wed, 5 Feb 2025 17:08:39 -0800 Message-ID: <20250206010843.618280-5-stefano.stabellini@amd.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: References: MIME-Version: 1.0 Received-SPF: None (SATLEXMB05.amd.com: stefano.stabellini@amd.com does not designate permitted sender hosts) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: CO1PEPF000066EB:EE_|SJ2PR12MB7824:EE_ X-MS-Office365-Filtering-Correlation-Id: 0693b1f3-b470-45fb-edf9-08dd464ad1c1 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|36860700013|82310400026|376014|1800799024; X-Microsoft-Antispam-Message-Info: g/oa4K21HW+dKkukW3XSqtvozEXtefoLSDVLZJVbMy78oBDxDZFCRD3v76P2sRkopHzppQGPdVTe+uZBx1TqGmCK4peFz2PTc4CxVROivGCN/IGdXU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wcZX8P9nPUhZi0/kezTAyzlIZhKuPnVoKZikI/3PtDdNwV08TAcfsBj5OQ5sprpoPbh4v1bx96gWJw9bhJM/KneR1J0JNdxQCZdBKHdMTgsitYzLZuKrraZvAwEsH1RPJWT8MAHMCfTVg+QvwaUIuuZkwJ4eg1t1Ky13oppyp7tuOxCRv0mMzUdee8paKAGVcH27MMzlRadm3SvWU64k0g1uksLRmdvzqU/7lKYg+qK55PttOhgmCRhOF5rwy44aSWAqcMim4Ad6mYEmbfMZUpYHX9OxRAb/TR6npAu8i2ReWNE563jWoUwPSNktdR7rgo= X-Forefront-Antispam-Report: CIP:165.204.84.17;CTRY:US;LANG:en;SCL:1;SRV:;IPV:CAL;SFV:NSPM;H:SATLEXMB04.amd.com;PTR:InfoDomainNonexistent;CAT:NONE;SFS:(13230040)(36860700013)(82310400026)(376014)(1800799024);DIR:OUT;SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 06 Feb 2025 01:08:51.5431 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 0693b1f3-b470-45fb-edf9-08dd464ad1c1 X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d;Ip=[165.204.84.17];Helo=[SATLEXMB04.amd.com] X-MS-Exchange-CrossTenant-AuthSource: CO1PEPF000066EB.namprd05.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: SJ2PR12MB7824 From: Henry Wang With the new allocation strategy of Dom0less DomUs XenStore page, update the doc of the late XenStore init protocol accordingly. Signed-off-by: Henry Wang --- docs/features/dom0less.pandoc | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/docs/features/dom0less.pandoc b/docs/features/dom0less.pandoc index 725afa0558..8b178edee0 100644 --- a/docs/features/dom0less.pandoc +++ b/docs/features/dom0less.pandoc @@ -110,9 +110,10 @@ hotplug PV drivers to dom0less guests. E.g. xl network-attach domU. The implementation works as follows: - Xen allocates the xenstore event channel for each dom0less domU that has the "xen,enhanced" property, and sets HVM_PARAM_STORE_EVTCHN -- Xen does *not* allocate the xenstore page and sets HVM_PARAM_STORE_PFN - to ~0ULL (invalid) -- Dom0less domU kernels check that HVM_PARAM_STORE_PFN is set to invalid +- Xen allocates the xenstore page and sets HVM_PARAM_STORE_PFN as well + as the connection status to XENSTORE_RECONNECT. +- Dom0less domU kernels check that HVM_PARAM_STORE_PFN is set to + ~0ULL (invalid) or the connection status is *not* XENSTORE_CONNECTED. - Old kernels will continue without xenstore support (Note: some old buggy kernels might crash because they don't check the validity of HVM_PARAM_STORE_PFN before using it! Disable "xen,enhanced" in @@ -121,13 +122,14 @@ The implementation works as follows: channel (HVM_PARAM_STORE_EVTCHN) before continuing with the initialization - Once dom0 is booted, init-dom0less is executed: - - it allocates the xenstore shared page and sets HVM_PARAM_STORE_PFN + - it gets the xenstore shared page from HVM_PARAM_STORE_PFN - it calls xs_introduce_domain - Xenstored notices the new domain, initializes interfaces as usual, and sends an event channel notification to the domain using the xenstore event channel (HVM_PARAM_STORE_EVTCHN) - The Linux domU kernel receives the event channel notification, checks - HVM_PARAM_STORE_PFN again and continue with the initialization + HVM_PARAM_STORE_PFN and the connection status again and continue with + the initialization Limitations