From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mga04.intel.com (mga04.intel.com [192.55.52.120]) by mx.groups.io with SMTP id smtpd.web10.41316.1636351702396824859 for ; Sun, 07 Nov 2021 22:08:22 -0800 Authentication-Results: mx.groups.io; dkim=missing; spf=pass (domain: intel.com, ip: 192.55.52.120, mailfrom: min.m.xu@intel.com) X-IronPort-AV: E=McAfee;i="6200,9189,10161"; a="230886911" X-IronPort-AV: E=Sophos;i="5.87,217,1631602800"; d="scan'208";a="230886911" Received: from orsmga007.jf.intel.com ([10.7.209.58]) by fmsmga104.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 07 Nov 2021 22:08:21 -0800 X-IronPort-AV: E=Sophos;i="5.87,217,1631602800"; d="scan'208";a="491089684" Received: from mxu9-mobl1.ccr.corp.intel.com ([10.238.4.37]) by orsmga007-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 07 Nov 2021 22:08:17 -0800 From: "Min Xu" To: devel@edk2.groups.io Cc: Min Xu , Ard Biesheuvel , Jordan Justen , Brijesh Singh , Erdem Aktas , James Bottomley , Jiewen Yao , Tom Lendacky , Gerd Hoffmann , Eric Dong , Ray Ni Subject: [PATCH V3 0/3] Rename XenTimerDxe to LocalApicTimerDxe Date: Mon, 8 Nov 2021 14:07:57 +0800 Message-Id: X-Mailer: git-send-email 2.29.2.windows.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=3711 XenTimerDxe is a local Apic timer driver and it has nothing to do with Xen. So rename it to LocalApicTimerDxe. After renaming, LocalApicTimerDxe is used in OvmfPkg if CSM_ENABLE=FALSE. Otherwise 8254 timer is used. Since LocalApicTimerDxe doesn't depend on OvmfPkg, so it is moved to UefiCpuPkg. Patch #1: Rename XenTimerDxe to LocalApicTimerDxe Patch #2: Switch timer in build time for OvmfPkg. If CSM_ENABLE=TRUE, 8254 timer is used, otherwise the timer is LocalApicTimerDxe. Patch #3: Move LocalApicTimerDxe from OvmfPkg to UefiCpuPkg. Code at: https://github.com/mxu9/edk2/tree/ovmf_lapic_timer.v3 v3 changes: - Move LocalApicTimerDxe to UefiCpuPkg - Fix the errors in v2 patch-1 that OvmfXen.dsc / .fdf and MicrovmX64.dsc / .fdf are not updated for new name. - Add XenTimerDxe reviewers. v2 changes: - Add gEfiMdePkgTokenSpaceGuid.PcdFSBClock in *.dsc Cc: Ard Biesheuvel Cc: Jordan Justen Cc: Brijesh Singh Cc: Erdem Aktas Cc: James Bottomley Cc: Jiewen Yao Cc: Tom Lendacky Cc: Gerd Hoffmann Cc: Eric Dong Cc: Ray Ni Signed-off-by: Min Xu Min Xu (3): OvmfPkg: Rename XenTimerDxe to LocalApicTimerDxe OvmfPkg: Switch timer in build time for OvmfPkg OvmfPkg: Move LocalApicTimerDxe to UefiCpuPkg OvmfPkg/AmdSev/AmdSevX64.dsc | 5 +++-- OvmfPkg/AmdSev/AmdSevX64.fdf | 3 +-- OvmfPkg/Microvm/MicrovmX64.dsc | 2 +- OvmfPkg/Microvm/MicrovmX64.fdf | 2 +- OvmfPkg/OvmfPkgIa32.dsc | 10 +++++++++- OvmfPkg/OvmfPkgIa32.fdf | 8 ++++++-- OvmfPkg/OvmfPkgIa32X64.dsc | 10 +++++++++- OvmfPkg/OvmfPkgIa32X64.fdf | 8 ++++++-- OvmfPkg/OvmfPkgX64.dsc | 10 +++++++++- OvmfPkg/OvmfPkgX64.fdf | 8 ++++++-- OvmfPkg/OvmfXen.dsc | 2 +- OvmfPkg/OvmfXen.fdf | 2 +- .../LocalApicTimerDxe/LocalApicTimerDxe.c | 7 +++---- .../LocalApicTimerDxe/LocalApicTimerDxe.h | 4 ++-- .../LocalApicTimerDxe/LocalApicTimerDxe.inf | 11 +++++++---- 15 files changed, 65 insertions(+), 27 deletions(-) rename OvmfPkg/XenTimerDxe/XenTimerDxe.c => UefiCpuPkg/LocalApicTimerDxe/LocalApicTimerDxe.c (95%) rename OvmfPkg/XenTimerDxe/XenTimerDxe.h => UefiCpuPkg/LocalApicTimerDxe/LocalApicTimerDxe.h (96%) rename OvmfPkg/XenTimerDxe/XenTimerDxe.inf => UefiCpuPkg/LocalApicTimerDxe/LocalApicTimerDxe.inf (72%) -- 2.29.2.windows.2