public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* [PATCH v1 0/2] Fix for variable store corrupt issue
@ 2018-04-26  9:32 Sami Mujawar
  2018-04-26  9:32 ` [PATCH 1/2] Platform/ARM: Fix NOR Flash dependency for Juno Sami Mujawar
                   ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: Sami Mujawar @ 2018-04-26  9:32 UTC (permalink / raw)
  To: edk2-devel
  Cc: Arvind Chauhan, Daniil Egranov, Thomas Panakamattam Abraham,
	ard.biesheuvel, leif.lindholm, Matteo.Carlini,
	Stephanie.Hughes-Fitt, nd, evan.lloyd, alexei.fedorov,
	michael.d.kinney

These patches fix the "Firmware Volume for Variable Store is
corrupted" issue which is seen when the Flash is erased or
not formatted.

Sami Mujawar (2):
  Platform/ARM: Fix NOR Flash dependency for Juno
  Platform/ARM: Fix NOR Flash dependency for FVP

 Platform/ARM/JunoPkg/ArmJuno.dsc                     | 1 +
 Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.dsc | 1 +
 2 files changed, 2 insertions(+)

-- 
'Guid(CE165669-3EF3-493F-B85D-6190EE5B9759)'




^ permalink raw reply	[flat|nested] 7+ messages in thread

* [PATCH 1/2] Platform/ARM: Fix NOR Flash dependency for Juno
  2018-04-26  9:32 [PATCH v1 0/2] Fix for variable store corrupt issue Sami Mujawar
@ 2018-04-26  9:32 ` Sami Mujawar
  2018-04-26  9:32 ` [PATCH 2/2] Platform/ARM: Fix NOR Flash dependency for FVP Sami Mujawar
  2018-04-26  9:43 ` [PATCH v1 0/2] Fix for variable store corrupt issue Ard Biesheuvel
  2 siblings, 0 replies; 7+ messages in thread
From: Sami Mujawar @ 2018-04-26  9:32 UTC (permalink / raw)
  To: edk2-devel
  Cc: Arvind Chauhan, Daniil Egranov, Thomas Panakamattam Abraham,
	ard.biesheuvel, leif.lindholm, Matteo.Carlini,
	Stephanie.Hughes-Fitt, nd, evan.lloyd, alexei.fedorov,
	michael.d.kinney

The correct load order for the NOR Flash driver and Runtime Variables
to work is as below:
    1. Arm CPU Architecture Protocol Dxe
    2. NOR Flash Dxe
    3. Runtime Variable Dxe

NvVarStoreFormattedLib was recently introduced to resolve the dependency
order and more details can be seen at
https://github.com/tianocore/edk2/compare/master...lersek:depex_fixes

This patch propagates the necessary changes for ARM Juno platform and
also fixes the "Firmware Volume for Variable Store is corrupted" error
seen when the Flash is erased (or not formatted).

Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Sami Mujawar <sami.mujawar@arm.com>
Signed-off-by: Alexei Fedorov <alexei.fedorov@arm.com>
---
The changes can be seen at:
https://github.com/samimujawar/edk2-platforms/tree/255_firmware_volume_issue_v1

Notes:
    v1:
    - Fixed firmware volume variable store corrupt issue.           [SAMI]

 Platform/ARM/JunoPkg/ArmJuno.dsc | 1 +
 1 file changed, 1 insertion(+)

diff --git a/Platform/ARM/JunoPkg/ArmJuno.dsc b/Platform/ARM/JunoPkg/ArmJuno.dsc
index d5e87f1edfd5d60a543e51cb42dfbcc4489d3f7d..a10476fa135d0eccbed3d0eaf8cb02b26617c2eb 100644
--- a/Platform/ARM/JunoPkg/ArmJuno.dsc
+++ b/Platform/ARM/JunoPkg/ArmJuno.dsc
@@ -255,6 +255,7 @@ [Components.common]
   MdeModulePkg/Universal/Variable/RuntimeDxe/VariableRuntimeDxe.inf {
     <LibraryClasses>
       NULL|MdeModulePkg/Library/VarCheckUefiLib/VarCheckUefiLib.inf
+      NULL|EmbeddedPkg/Library/NvVarStoreFormattedLib/NvVarStoreFormattedLib.inf
       BaseMemoryLib|MdePkg/Library/BaseMemoryLib/BaseMemoryLib.inf
   }
   MdeModulePkg/Universal/FaultTolerantWriteDxe/FaultTolerantWriteDxe.inf
-- 
'Guid(CE165669-3EF3-493F-B85D-6190EE5B9759)'




^ permalink raw reply related	[flat|nested] 7+ messages in thread

* [PATCH 2/2] Platform/ARM: Fix NOR Flash dependency for FVP
  2018-04-26  9:32 [PATCH v1 0/2] Fix for variable store corrupt issue Sami Mujawar
  2018-04-26  9:32 ` [PATCH 1/2] Platform/ARM: Fix NOR Flash dependency for Juno Sami Mujawar
@ 2018-04-26  9:32 ` Sami Mujawar
  2018-04-26  9:43 ` [PATCH v1 0/2] Fix for variable store corrupt issue Ard Biesheuvel
  2 siblings, 0 replies; 7+ messages in thread
From: Sami Mujawar @ 2018-04-26  9:32 UTC (permalink / raw)
  To: edk2-devel
  Cc: Arvind Chauhan, Daniil Egranov, Thomas Panakamattam Abraham,
	ard.biesheuvel, leif.lindholm, Matteo.Carlini,
	Stephanie.Hughes-Fitt, nd, evan.lloyd, alexei.fedorov,
	michael.d.kinney

The correct load order for the NOR Flash driver and Runtime Variables
to work is as below:
    1. Arm CPU Architecture Protocol Dxe
    2. NOR Flash Dxe
    3. Runtime Variable Dxe

NvVarStoreFormattedLib was recently introduced to resolve the dependency
order and more details can be seen at
https://github.com/tianocore/edk2/compare/master...lersek:depex_fixes

This patch propagates the necessary changes for ARM FVP platform and
also fixes the "Firmware Volume for Variable Store is corrupted" error
seen when the Flash is erased (or not formatted).

Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Sami Mujawar <sami.mujawar@arm.com>
Signed-off-by: Alexei Fedorov <alexei.fedorov@arm.com>
---
The changes can be seen at:
https://github.com/samimujawar/edk2-platforms/tree/255_firmware_volume_issue_v1

Notes:
    v1:
    - Fixed firmware volume variable store corrupt issue.           [SAMI]

 Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.dsc | 1 +
 1 file changed, 1 insertion(+)

diff --git a/Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.dsc b/Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.dsc
index cdf9e2d49784d542701dc84eb511f592e77ec106..e0539d6a01363a3f2ae8e42d1a9e4125711b834f 100644
--- a/Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.dsc
+++ b/Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.dsc
@@ -229,6 +229,7 @@ [Components.common]
   MdeModulePkg/Universal/Variable/RuntimeDxe/VariableRuntimeDxe.inf {
     <LibraryClasses>
       NULL|MdeModulePkg/Library/VarCheckUefiLib/VarCheckUefiLib.inf
+      NULL|EmbeddedPkg/Library/NvVarStoreFormattedLib/NvVarStoreFormattedLib.inf
       BaseMemoryLib|MdePkg/Library/BaseMemoryLib/BaseMemoryLib.inf
   }
   MdeModulePkg/Universal/FaultTolerantWriteDxe/FaultTolerantWriteDxe.inf
-- 
'Guid(CE165669-3EF3-493F-B85D-6190EE5B9759)'




^ permalink raw reply related	[flat|nested] 7+ messages in thread

* Re: [PATCH v1 0/2] Fix for variable store corrupt issue
  2018-04-26  9:32 [PATCH v1 0/2] Fix for variable store corrupt issue Sami Mujawar
  2018-04-26  9:32 ` [PATCH 1/2] Platform/ARM: Fix NOR Flash dependency for Juno Sami Mujawar
  2018-04-26  9:32 ` [PATCH 2/2] Platform/ARM: Fix NOR Flash dependency for FVP Sami Mujawar
@ 2018-04-26  9:43 ` Ard Biesheuvel
  2018-04-26  9:47   ` Sami Mujawar
  2 siblings, 1 reply; 7+ messages in thread
From: Ard Biesheuvel @ 2018-04-26  9:43 UTC (permalink / raw)
  To: Sami Mujawar
  Cc: edk2-devel@lists.01.org, Arvind Chauhan, Daniil Egranov,
	Thomas Panakamattam Abraham, Leif Lindholm, Matteo Carlini,
	Stephanie Hughes-Fitt, nd, Evan Lloyd, Alexei Fedorov,
	Kinney, Michael D

On 26 April 2018 at 11:32, Sami Mujawar <sami.mujawar@arm.com> wrote:
> These patches fix the "Firmware Volume for Variable Store is
> corrupted" issue which is seen when the Flash is erased or
> not formatted.
>
> Sami Mujawar (2):
>   Platform/ARM: Fix NOR Flash dependency for Juno
>   Platform/ARM: Fix NOR Flash dependency for FVP
>
>  Platform/ARM/JunoPkg/ArmJuno.dsc                     | 1 +
>  Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.dsc | 1 +
>  2 files changed, 2 insertions(+)
>

Hello Sami,

Does ArmVExpress-CTA15-A7.dsc need this change as well?

-- 
Ard.


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH v1 0/2] Fix for variable store corrupt issue
  2018-04-26  9:43 ` [PATCH v1 0/2] Fix for variable store corrupt issue Ard Biesheuvel
@ 2018-04-26  9:47   ` Sami Mujawar
  2018-04-26 10:47     ` Leif Lindholm
  0 siblings, 1 reply; 7+ messages in thread
From: Sami Mujawar @ 2018-04-26  9:47 UTC (permalink / raw)
  To: Ard Biesheuvel
  Cc: edk2-devel@lists.01.org, Arvind Chauhan, Daniil Egranov,
	Thomas Abraham, Leif Lindholm, Matteo Carlini,
	Stephanie Hughes-Fitt, nd, Evan Lloyd, Alexei Fedorov,
	Kinney, Michael D

Hi Ard,

I do not have the setup currently to test ArmVExpress-CTA15-A7. However, I think it will need this change as well. 
Please ignore this patchset, I will send another one shortly. 

Regards,

Sami Mujawar
-----Original Message-----
From: Ard Biesheuvel <ard.biesheuvel@linaro.org> 
Sent: 26 April 2018 10:44 AM
To: Sami Mujawar <Sami.Mujawar@arm.com>
Cc: edk2-devel@lists.01.org; Arvind Chauhan <Arvind.Chauhan@arm.com>; Daniil Egranov <Daniil.Egranov@arm.com>; Thomas Abraham <thomas.abraham@arm.com>; Leif Lindholm <leif.lindholm@linaro.org>; Matteo Carlini <Matteo.Carlini@arm.com>; Stephanie Hughes-Fitt <Stephanie.Hughes-Fitt@arm.com>; nd <nd@arm.com>; Evan Lloyd <Evan.Lloyd@arm.com>; Alexei Fedorov <Alexei.Fedorov@arm.com>; Kinney, Michael D <michael.d.kinney@intel.com>
Subject: Re: [PATCH v1 0/2] Fix for variable store corrupt issue

On 26 April 2018 at 11:32, Sami Mujawar <sami.mujawar@arm.com> wrote:
> These patches fix the "Firmware Volume for Variable Store is 
> corrupted" issue which is seen when the Flash is erased or not 
> formatted.
>
> Sami Mujawar (2):
>   Platform/ARM: Fix NOR Flash dependency for Juno
>   Platform/ARM: Fix NOR Flash dependency for FVP
>
>  Platform/ARM/JunoPkg/ArmJuno.dsc                     | 1 +
>  Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.dsc | 1 +
>  2 files changed, 2 insertions(+)
>

Hello Sami,

Does ArmVExpress-CTA15-A7.dsc need this change as well?

--
Ard.

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH v1 0/2] Fix for variable store corrupt issue
  2018-04-26  9:47   ` Sami Mujawar
@ 2018-04-26 10:47     ` Leif Lindholm
  2018-04-26 17:01       ` Ard Biesheuvel
  0 siblings, 1 reply; 7+ messages in thread
From: Leif Lindholm @ 2018-04-26 10:47 UTC (permalink / raw)
  To: Sami Mujawar
  Cc: Ard Biesheuvel, edk2-devel@lists.01.org, Arvind Chauhan,
	Daniil Egranov, Thomas Abraham, Matteo Carlini,
	Stephanie Hughes-Fitt, nd, Evan Lloyd, Alexei Fedorov,
	Kinney, Michael D

On Thu, Apr 26, 2018 at 09:47:17AM +0000, Sami Mujawar wrote:
> Hi Ard,
> 
> I do not have the setup currently to test ArmVExpress-CTA15-A7. However, I think it will need this change as well. 
> Please ignore this patchset, I will send another one shortly. 

No need to resubmit the whole set - just send out a 3/3 to go on top
of this.

Regards,

Leif

> Regards,
> 
> Sami Mujawar
> -----Original Message-----
> From: Ard Biesheuvel <ard.biesheuvel@linaro.org> 
> Sent: 26 April 2018 10:44 AM
> To: Sami Mujawar <Sami.Mujawar@arm.com>
> Cc: edk2-devel@lists.01.org; Arvind Chauhan <Arvind.Chauhan@arm.com>; Daniil Egranov <Daniil.Egranov@arm.com>; Thomas Abraham <thomas.abraham@arm.com>; Leif Lindholm <leif.lindholm@linaro.org>; Matteo Carlini <Matteo.Carlini@arm.com>; Stephanie Hughes-Fitt <Stephanie.Hughes-Fitt@arm.com>; nd <nd@arm.com>; Evan Lloyd <Evan.Lloyd@arm.com>; Alexei Fedorov <Alexei.Fedorov@arm.com>; Kinney, Michael D <michael.d.kinney@intel.com>
> Subject: Re: [PATCH v1 0/2] Fix for variable store corrupt issue
> 
> On 26 April 2018 at 11:32, Sami Mujawar <sami.mujawar@arm.com> wrote:
> > These patches fix the "Firmware Volume for Variable Store is 
> > corrupted" issue which is seen when the Flash is erased or not 
> > formatted.
> >
> > Sami Mujawar (2):
> >   Platform/ARM: Fix NOR Flash dependency for Juno
> >   Platform/ARM: Fix NOR Flash dependency for FVP
> >
> >  Platform/ARM/JunoPkg/ArmJuno.dsc                     | 1 +
> >  Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.dsc | 1 +
> >  2 files changed, 2 insertions(+)
> >
> 
> Hello Sami,
> 
> Does ArmVExpress-CTA15-A7.dsc need this change as well?
> 
> --
> Ard.


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH v1 0/2] Fix for variable store corrupt issue
  2018-04-26 10:47     ` Leif Lindholm
@ 2018-04-26 17:01       ` Ard Biesheuvel
  0 siblings, 0 replies; 7+ messages in thread
From: Ard Biesheuvel @ 2018-04-26 17:01 UTC (permalink / raw)
  To: Leif Lindholm
  Cc: Sami Mujawar, edk2-devel@lists.01.org, Arvind Chauhan,
	Daniil Egranov, Thomas Abraham, Matteo Carlini,
	Stephanie Hughes-Fitt, nd, Evan Lloyd, Alexei Fedorov,
	Kinney, Michael D

On 26 April 2018 at 12:47, Leif Lindholm <leif.lindholm@linaro.org> wrote:
> On Thu, Apr 26, 2018 at 09:47:17AM +0000, Sami Mujawar wrote:
>> Hi Ard,
>>
>> I do not have the setup currently to test ArmVExpress-CTA15-A7. However, I think it will need this change as well.
>> Please ignore this patchset, I will send another one shortly.
>
> No need to resubmit the whole set - just send out a 3/3 to go on top
> of this.
>

Thanks Sami

Patches #1 .. #3 pushed as b581a4934d8f..3f20ed76ce78


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2018-04-26 17:01 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-04-26  9:32 [PATCH v1 0/2] Fix for variable store corrupt issue Sami Mujawar
2018-04-26  9:32 ` [PATCH 1/2] Platform/ARM: Fix NOR Flash dependency for Juno Sami Mujawar
2018-04-26  9:32 ` [PATCH 2/2] Platform/ARM: Fix NOR Flash dependency for FVP Sami Mujawar
2018-04-26  9:43 ` [PATCH v1 0/2] Fix for variable store corrupt issue Ard Biesheuvel
2018-04-26  9:47   ` Sami Mujawar
2018-04-26 10:47     ` Leif Lindholm
2018-04-26 17:01       ` Ard Biesheuvel

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox