From nobody Thu Dec 26 16:15:55 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) client-ip=192.237.175.120; envelope-from=xen-devel-bounces@lists.xenproject.org; helo=lists.xenproject.org; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=pass(p=reject dis=none) header.from=citrix.com ARC-Seal: i=1; a=rsa-sha256; t=1732209334; cv=none; d=zohomail.com; s=zohoarc; b=Ryq9nKM9/2g7luU9mWg7EX8b38ReY3J0ei2dX7H9xjU9VGI9q+8TKjgvqQwMWUOOcCOsPuTb86te5arMStTA0xOTrPmiQeIqhEDFb+5DHb8RoujsU0A44vclyH8mRObdK1SyXwWF606LpxQJzBuEc8QYb+sJuZD8kqhBLrQbYuw= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1732209334; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:List-Subscribe:List-Post:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=Qf+rhY3gob46gd7mrmGyvYrcqtND5JxDHsXGngonTSI=; b=M4vQ+InEfp8w09JaaoRm9xPJ857F3KrZrCV8Qj5c2UBH2W6oH9bhUf6y8rp+QP6drP2UASL0Of9FwEEDkrZhEJ3czlDU3MoOyUIF0NOGNI+havSuHhujubG+t12oxI5Rdg5U0qXTDgEEMl/L2F0281UvY1QxynurdBomlaYCUwo= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=pass header.from= (p=reject dis=none) Return-Path: Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) by mx.zohomail.com with SMTPS id 173220933455861.81046032721315; Thu, 21 Nov 2024 09:15:34 -0800 (PST) Received: from list by lists.xenproject.org with outflank-mailman.841630.1257120 (Exim 4.92) (envelope-from ) id 1tEAlx-00050a-Rn; Thu, 21 Nov 2024 17:15:17 +0000 Received: by outflank-mailman (output) from mailman id 841630.1257120; Thu, 21 Nov 2024 17:15:17 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1tEAlx-00050T-Mz; Thu, 21 Nov 2024 17:15:17 +0000 Received: by outflank-mailman (input) for mailman id 841630; Thu, 21 Nov 2024 17:15: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 1tEAlw-00050N-HD for xen-devel@lists.xenproject.org; Thu, 21 Nov 2024 17:15:16 +0000 Received: from mail-ed1-x532.google.com (mail-ed1-x532.google.com [2a00:1450:4864:20::532]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id 2b947cb7-a82c-11ef-a0cc-8be0dac302b0; Thu, 21 Nov 2024 18:15:13 +0100 (CET) Received: by mail-ed1-x532.google.com with SMTP id 4fb4d7f45d1cf-5cfa9979cd1so2003144a12.1 for ; Thu, 21 Nov 2024 09:15:13 -0800 (PST) Received: from localhost ([213.195.123.63]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-aa4f42d2f86sm100805166b.110.2024.11.21.09.15.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 21 Nov 2024 09:15:12 -0800 (PST) X-Outflank-Mailman: Message body and most headers restored to incoming version 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: 2b947cb7-a82c-11ef-a0cc-8be0dac302b0 X-Custom-Connection: eyJyZW1vdGVpcCI6IjJhMDA6MTQ1MDo0ODY0OjIwOjo1MzIiLCJoZWxvIjoibWFpbC1lZDEteDUzMi5nb29nbGUuY29tIn0= X-Custom-Transaction: eyJpZCI6IjJiOTQ3Y2I3LWE4MmMtMTFlZi1hMGNjLThiZTBkYWMzMDJiMCIsInRzIjoxNzMyMjA5MzEzLjkyNDI5NSwic2VuZGVyIjoicm9nZXIucGF1QGNsb3VkLmNvbSIsInJlY2lwaWVudCI6Inhlbi1kZXZlbEBsaXN0cy54ZW5wcm9qZWN0Lm9yZyJ9 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=citrix.com; s=google; t=1732209313; x=1732814113; 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=Qf+rhY3gob46gd7mrmGyvYrcqtND5JxDHsXGngonTSI=; b=RGZdK50Nzo99o9FIAmLZ1Q4PHpLcCkkGBIybsa5IXlFm3g0ZYQUztvxYf+cCXaj6BC oOsFuP1acyb2pDEKfMF9nx7qyJbyDi4WGwx4AmATM+/bgiI+yCCWSOTs8iwnVba6jFh0 KUVYr4HPFPCY/BOq4BQujJF4JEsHZlsfBdx68= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1732209313; x=1732814113; 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=Qf+rhY3gob46gd7mrmGyvYrcqtND5JxDHsXGngonTSI=; b=Zu5/HwhliJ0EtEdPl1ZQB4F+szd0a6jGKNtO5Pxq7nP7B3LPw4BQJzDBUGDWCAxAa+ wTDj+UGgwEH4YBn+kvTiH3W9VfJ0/IwE5ELYkWEmmD9Rbjkse7jpqL+/6zEP4zdkm0Oy d0zPdb3ozwX4tkyChIBw1yYAU7Z5xQRCsWA6BNmH3a7ZzkHa9Mu50FYpydimHNrlYMN4 DBf2tv+pjWXzbs26xAyuEh1/kcWMnCHjw2RQQeR22vZuszVVRi0hM16/kMNyxPbQR/gs ejDVhWhi/iBnkOG+BaeGBBnqjzIypEs3ZXVyZgrzV35XFuBCUhOjnyFE16g5co6njcXl yWBg== X-Gm-Message-State: AOJu0YyvtU3wPiSdxoFhrxW8PRtezZc+uW4WhxqIjFXeAmCf1be9UK8P E7YQxuASRE1JTut1x5RTc020aTBznfHHIbhJajCA0IZUVuM4d6EKOGjhx/8W6Rfgz7uKSv+xndP O X-Gm-Gg: ASbGncvnLCsZR4mj/vqG23qUFpZ4QVBoB4gV58iTeJc3FJZ2aAA5g4MbHVXoKiTsp+O 5vCnFuhxE3Tq6OoDNBid9QlOkeZZzBFw0IHWyiKj94teQjP41JXeVKdSWsirkTPnOsJbn6OmWhe jDezSHurJ/OeGSVb7hmtIKZ3xz6F0zTzWsJSw4Urqg3qka4h5v95gpB/HXhPlBsleeYZqcGLZV9 zC4BBt/GGLgzh631MwsFkLM3vSfHI/SLcLY4ppl5EkqUoLJRRokd/R+qbU= X-Google-Smtp-Source: AGHT+IEODiv8l1AgqaimR8WrrdJD0Fg4sY2O+Xorwib649Syv1InrpPoHazPaxe7xghmhfr2In7YJg== X-Received: by 2002:a05:6402:354d:b0:5cf:c1b2:c6ae with SMTP id 4fb4d7f45d1cf-5d007cb8018mr4193953a12.17.1732209312850; Thu, 21 Nov 2024 09:15:12 -0800 (PST) From: Roger Pau Monne To: xen-devel@lists.xenproject.org Cc: Roger Pau Monne , Jan Beulich , Andrew Cooper Subject: [PATCH] x86/pv: don't populate the GDT/LDT L3 slot at domain creation Date: Thu, 21 Nov 2024 18:15:04 +0100 Message-ID: <20241121171504.55383-1-roger.pau@citrix.com> X-Mailer: git-send-email 2.46.0 MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @citrix.com) X-ZM-MESSAGEID: 1732209335904116600 The current code in pv_domain_initialise() populates the L3 slot used for t= he GDT/LDT, however that's not needed, since the create_perdomain_mapping() in pv_create_gdt_ldt_l1tab() will already take care of allocating an L2 and populating the L3 entry if not present. No functional change intended. Signed-off-by: Roger Pau Monn=C3=A9 Reviewed-by: Jan Beulich --- xen/arch/x86/pv/domain.c | 6 ------ 1 file changed, 6 deletions(-) diff --git a/xen/arch/x86/pv/domain.c b/xen/arch/x86/pv/domain.c index d5a8564c1cbe..7aef628f55be 100644 --- a/xen/arch/x86/pv/domain.c +++ b/xen/arch/x86/pv/domain.c @@ -376,12 +376,6 @@ int pv_domain_initialise(struct domain *d) (d->arch.pv.cpuidmasks =3D xmemdup(&cpuidmask_defaults)) =3D=3D N= ULL ) goto fail; =20 - rc =3D create_perdomain_mapping(d, GDT_LDT_VIRT_START, - GDT_LDT_MBYTES << (20 - PAGE_SHIFT), - NULL, NULL); - if ( rc ) - goto fail; - d->arch.ctxt_switch =3D &pv_csw; =20 if ( !is_pv_32bit_domain(d) && use_invpcid && cpu_has_pcid ) --=20 2.46.0