From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by mx.groups.io with SMTP id smtpd.web12.200.1666890927002314338 for ; Thu, 27 Oct 2022 10:15:27 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=FxksFquQ; spf=pass (domain: kernel.org, ip: 145.40.68.75, mailfrom: ardb@kernel.org) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 89284B826D7 for ; Thu, 27 Oct 2022 17:15:24 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 450C8C433D6 for ; Thu, 27 Oct 2022 17:15:23 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1666890923; bh=w+LXh8hPeOS1JaTVx51rDzWbLP+Vo+bU3Spv4+qe3sY=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=FxksFquQRRjAqARBVkL6MkOtdRfapjggFylEBxQQmE0ySt7DxwPhA+9J4HVsteM5P 6gig2PI/EVH2hto3cTArIqs9eBL5865yuf3DYObatLflKyJWdCTuLM+gvYDprjprRN trNbIUP7AJ7P/zeKVVoMctoJPbUaYrd8B/EyLLx64kvJ8WxIKUlyHeP6PHyPBzy36E ed49bCJ4l06Ypo1H3Zkdis3yByJTMp4Fov3gZp2xymZuGhMVTAwvBmsXEwE2t6rD/e BsJJRIGjMPBvyEoNrYDWAxUcxki0W91ER4VxCIPBpkrAGuR/FbK1rRflAzdUdWEaoS //oVTm6RzI21A== Received: by mail-lj1-f170.google.com with SMTP id o4so4070386ljp.8 for ; Thu, 27 Oct 2022 10:15:23 -0700 (PDT) X-Gm-Message-State: ACrzQf1dN3PvHGW5ZfnctGiefedy2ln7wypFlDk+KZ5qDWbP340KdxR+ pT/JHQBOUUGX4tP2z3duSojq/Iurqxcedz/C8SA= X-Google-Smtp-Source: AMsMyM5YRxzgAt2AMmPJfHqMSrLytcQ2Q0X3XLGFtzF+lAdm83xiuKF4e3j09ycWpF/Zec6qmjR4AbsffIinPF/Q8uI= X-Received: by 2002:a19:c20b:0:b0:4a2:40e5:78b1 with SMTP id l11-20020a19c20b000000b004a240e578b1mr18149251lfc.228.1666890921246; Thu, 27 Oct 2022 10:15:21 -0700 (PDT) MIME-Version: 1.0 References: <20221026174210.1255165-1-ardb@kernel.org> In-Reply-To: From: "Ard Biesheuvel" Date: Thu, 27 Oct 2022 19:15:09 +0200 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH edk2-platforms] Platform/SbsaQemu: Switch to VirtNorFlashDxe To: Leif Lindholm Cc: devel@edk2.groups.io, Graeme Gregory Content-Type: text/plain; charset="UTF-8" On Thu, 27 Oct 2022 at 12:48, Leif Lindholm wrote: > > On Wed, Oct 26, 2022 at 19:42:10 +0200, Ard Biesheuvel wrote: > > Switch to the OVMF version of the NOR flash DXE driver, which supports > > QEMU's NOR flash emulation specifically, and carries some optimizations > > that are therefore permitted. > > > > Cc: Leif Lindholm > > Cc: Graeme Gregory > > Graeme Gregory is probably more likely to > be seen these days. Patch to Maintainers.txt coming up (although > Graeme is out this week). > > > Signed-off-by: Ard Biesheuvel > > Reviewed-by: Leif Lindholm > > Thanks Merged as 8ea6ec38da88..2ce82b713db8 > > --- > > Platform/Qemu/SbsaQemu/SbsaQemu.dsc | 4 ++-- > > Platform/Qemu/SbsaQemu/SbsaQemu.fdf | 2 +- > > Silicon/Qemu/SbsaQemu/Library/SbsaQemuNorFlashLib/SbsaQemuNorFlashLib.inf | 4 ++-- > > Silicon/Qemu/SbsaQemu/Library/SbsaQemuNorFlashLib/SbsaQemuNorFlashLib.c | 12 ++++++------ > > 4 files changed, 11 insertions(+), 11 deletions(-) > > > > diff --git a/Platform/Qemu/SbsaQemu/SbsaQemu.dsc b/Platform/Qemu/SbsaQemu/SbsaQemu.dsc > > index ff280709a509..79dd200ca7fc 100644 > > --- a/Platform/Qemu/SbsaQemu/SbsaQemu.dsc > > +++ b/Platform/Qemu/SbsaQemu/SbsaQemu.dsc > > @@ -178,7 +178,7 @@ [LibraryClasses.common] > > ArmPlatformLib|ArmPlatformPkg/Library/ArmPlatformLibNull/ArmPlatformLibNull.inf > > > > TimerLib|ArmPkg/Library/ArmArchTimerLib/ArmArchTimerLib.inf > > - NorFlashPlatformLib|Silicon/Qemu/SbsaQemu/Library/SbsaQemuNorFlashLib/SbsaQemuNorFlashLib.inf > > + VirtNorFlashPlatformLib|Silicon/Qemu/SbsaQemu/Library/SbsaQemuNorFlashLib/SbsaQemuNorFlashLib.inf > > > > CapsuleLib|MdeModulePkg/Library/DxeCapsuleLibNull/DxeCapsuleLibNull.inf > > BootLogoLib|MdeModulePkg/Library/BootLogoLib/BootLogoLib.inf > > @@ -663,7 +663,7 @@ [Components.common] > > > > ArmPkg/Drivers/ArmGic/ArmGicDxe.inf > > ArmPkg/Drivers/TimerDxe/TimerDxe.inf > > - ArmPlatformPkg/Drivers/NorFlashDxe/NorFlashDxe.inf > > + OvmfPkg/VirtNorFlashDxe/VirtNorFlashDxe.inf > > MdeModulePkg/Universal/WatchdogTimerDxe/WatchdogTimer.inf > > > > # > > diff --git a/Platform/Qemu/SbsaQemu/SbsaQemu.fdf b/Platform/Qemu/SbsaQemu/SbsaQemu.fdf > > index 9f031c3e6649..781215707c3d 100644 > > --- a/Platform/Qemu/SbsaQemu/SbsaQemu.fdf > > +++ b/Platform/Qemu/SbsaQemu/SbsaQemu.fdf > > @@ -189,7 +189,7 @@ [FV.FvMain] > > > > INF ArmPkg/Drivers/ArmGic/ArmGicDxe.inf > > INF ArmPkg/Drivers/TimerDxe/TimerDxe.inf > > - INF ArmPlatformPkg/Drivers/NorFlashDxe/NorFlashDxe.inf > > + INF OvmfPkg/VirtNorFlashDxe/VirtNorFlashDxe.inf > > INF MdeModulePkg/Universal/WatchdogTimerDxe/WatchdogTimer.inf > > > > # > > diff --git a/Silicon/Qemu/SbsaQemu/Library/SbsaQemuNorFlashLib/SbsaQemuNorFlashLib.inf b/Silicon/Qemu/SbsaQemu/Library/SbsaQemuNorFlashLib/SbsaQemuNorFlashLib.inf > > index f2ba41e1df99..f7e3f8e05eec 100644 > > --- a/Silicon/Qemu/SbsaQemu/Library/SbsaQemuNorFlashLib/SbsaQemuNorFlashLib.inf > > +++ b/Silicon/Qemu/SbsaQemu/Library/SbsaQemuNorFlashLib/SbsaQemuNorFlashLib.inf > > @@ -14,16 +14,16 @@ [Defines] > > FILE_GUID = c53d904d-de50-40f1-a148-a2ece48303d8 > > MODULE_TYPE = BASE > > VERSION_STRING = 1.0 > > - LIBRARY_CLASS = NorFlashPlatformLib > > + LIBRARY_CLASS = VirtNorFlashPlatformLib > > > > [Sources.common] > > SbsaQemuNorFlashLib.c > > > > [Packages] > > - ArmPlatformPkg/ArmPlatformPkg.dec > > ArmPkg/ArmPkg.dec > > MdePkg/MdePkg.dec > > MdeModulePkg/MdeModulePkg.dec > > + OvmfPkg/OvmfPkg.dec > > > > [FixedPcd] > > gArmTokenSpaceGuid.PcdFdBaseAddress > > diff --git a/Silicon/Qemu/SbsaQemu/Library/SbsaQemuNorFlashLib/SbsaQemuNorFlashLib.c b/Silicon/Qemu/SbsaQemu/Library/SbsaQemuNorFlashLib/SbsaQemuNorFlashLib.c > > index 0946327cb529..56c26019a140 100644 > > --- a/Silicon/Qemu/SbsaQemu/Library/SbsaQemuNorFlashLib/SbsaQemuNorFlashLib.c > > +++ b/Silicon/Qemu/SbsaQemu/Library/SbsaQemuNorFlashLib/SbsaQemuNorFlashLib.c > > @@ -8,19 +8,19 @@ > > > > #include > > #include > > -#include > > +#include > > > > #define QEMU_NOR_BLOCK_SIZE SIZE_256KB > > > > EFI_STATUS > > -NorFlashPlatformInitialization ( > > +VirtNorFlashPlatformInitialization ( > > VOID > > ) > > { > > return EFI_SUCCESS; > > } > > > > -NOR_FLASH_DESCRIPTION mNorFlashDevice = > > +STATIC VIRT_NOR_FLASH_DESCRIPTION mNorFlashDevice = > > { > > FixedPcdGet64(PcdFdBaseAddress), > > FixedPcdGet64(PcdFlashNvStorageVariableBase), > > @@ -29,9 +29,9 @@ NOR_FLASH_DESCRIPTION mNorFlashDevice = > > }; > > > > EFI_STATUS > > -NorFlashPlatformGetDevices ( > > - OUT NOR_FLASH_DESCRIPTION **NorFlashDescriptions, > > - OUT UINT32 *Count > > +VirtNorFlashPlatformGetDevices ( > > + OUT VIRT_NOR_FLASH_DESCRIPTION **NorFlashDescriptions, > > + OUT UINT32 *Count > > ) > > { > > *NorFlashDescriptions = &mNorFlashDevice; > > -- > > 2.35.1 > >