* [PATCH] MdeModulePkg/PCD: Pcd initialize DXE have assert
@ 2022-05-05 21:29 guo.guo
2022-05-08 14:43 ` 回复: [edk2-devel] " gaoliming
0 siblings, 1 reply; 4+ messages in thread
From: guo.guo @ 2022-05-05 21:29 UTC (permalink / raw)
To: devel; +Cc: Gua Guo
From: Gua Guo <gua.guo@intel.com>
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3917
When PlatformPkg.dsc has multiple SKU IDs but didn't exist delta PCD,
System will hang on BuildPcdDxeDataBase.
Ideally, if didn't exist delta PCD by different SKU ID,
UpdatePcdDatabase () shouldn't return EFI_NOT_FOUND.
Signed-off-by: Gua Guo <gua.guo@intel.com>
---
MdeModulePkg/Universal/PCD/Dxe/Service.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/MdeModulePkg/Universal/PCD/Dxe/Service.c b/MdeModulePkg/Universal/PCD/Dxe/Service.c
index 3965846b93..5ade8d988b 100644
--- a/MdeModulePkg/Universal/PCD/Dxe/Service.c
+++ b/MdeModulePkg/Universal/PCD/Dxe/Service.c
@@ -817,6 +817,11 @@ UpdatePcdDatabase (
//
Index = (mPcdDatabase.DxeDb->Length + 7) & (~7);
SkuDelta = NULL;
+
+ if (Index == mDxePcdDbSize) {
+ return EFI_SUCCESS;
+ }
+
while (Index < mDxePcdDbSize) {
SkuDelta = (PCD_DATABASE_SKU_DELTA *)((UINT8 *)mDxePcdDbBinary + Index);
if ((SkuDelta->SkuId == SkuId) && (SkuDelta->SkuIdCompared == 0)) {
--
2.31.1.windows.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* 回复: [edk2-devel] [PATCH] MdeModulePkg/PCD: Pcd initialize DXE have assert
2022-05-05 21:29 [PATCH] MdeModulePkg/PCD: Pcd initialize DXE have assert guo.guo
@ 2022-05-08 14:43 ` gaoliming
2022-05-09 1:31 ` Guo, Gua
0 siblings, 1 reply; 4+ messages in thread
From: gaoliming @ 2022-05-08 14:43 UTC (permalink / raw)
To: devel, guo.guo; +Cc: 'Gua Guo'
Guo:
This change is good to me. Reviewed-by: Liming Gao <gaoliming@byosoft.com.
cn>
Thanks
Liming
> -----邮件原件-----
> 发件人: devel@edk2.groups.io <devel@edk2.groups.io> 代表
> guo.guo@intel.com
> 发送时间: 2022年5月6日 5:30
> 收件人: devel@edk2.groups.io
> 抄送: Gua Guo <gua.guo@intel.com>
> 主题: [edk2-devel] [PATCH] MdeModulePkg/PCD: Pcd initialize DXE have
> assert
>
> From: Gua Guo <gua.guo@intel.com>
>
> REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3917
>
> When PlatformPkg.dsc has multiple SKU IDs but didn't exist delta PCD,
> System will hang on BuildPcdDxeDataBase.
>
> Ideally, if didn't exist delta PCD by different SKU ID,
> UpdatePcdDatabase () shouldn't return EFI_NOT_FOUND.
>
> Signed-off-by: Gua Guo <gua.guo@intel.com>
> ---
> MdeModulePkg/Universal/PCD/Dxe/Service.c | 5 +++++
> 1 file changed, 5 insertions(+)
>
> diff --git a/MdeModulePkg/Universal/PCD/Dxe/Service.c
> b/MdeModulePkg/Universal/PCD/Dxe/Service.c
> index 3965846b93..5ade8d988b 100644
> --- a/MdeModulePkg/Universal/PCD/Dxe/Service.c
> +++ b/MdeModulePkg/Universal/PCD/Dxe/Service.c
> @@ -817,6 +817,11 @@ UpdatePcdDatabase (
> //
>
> Index = (mPcdDatabase.DxeDb->Length + 7) & (~7);
>
> SkuDelta = NULL;
>
> +
>
> + if (Index == mDxePcdDbSize) {
>
> + return EFI_SUCCESS;
>
> + }
>
> +
>
> while (Index < mDxePcdDbSize) {
>
> SkuDelta = (PCD_DATABASE_SKU_DELTA *)((UINT8 *)mDxePcdDbBinary
> + Index);
>
> if ((SkuDelta->SkuId == SkuId) && (SkuDelta->SkuIdCompared == 0)) {
>
> --
> 2.31.1.windows.1
>
>
>
> -=-=-=-=-=-=
> Groups.io Links: You receive all messages sent to this group.
> View/Reply Online (#89557): https://edk2.groups.io/g/devel/message/89557
> Mute This Topic: https://groups.io/mt/90934230/4905953
> Group Owner: devel+owner@edk2.groups.io
> Unsubscribe: https://edk2.groups.io/g/devel/unsub
> [gaoliming@byosoft.com.cn]
> -=-=-=-=-=-=
>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [edk2-devel] [PATCH] MdeModulePkg/PCD: Pcd initialize DXE have assert
2022-05-08 14:43 ` 回复: [edk2-devel] " gaoliming
@ 2022-05-09 1:31 ` Guo, Gua
2022-05-09 14:32 ` 回复: " gaoliming
0 siblings, 1 reply; 4+ messages in thread
From: Guo, Gua @ 2022-05-09 1:31 UTC (permalink / raw)
To: Gao, Liming, devel@edk2.groups.io; +Cc: Guo, Gua
[-- Attachment #1: Type: text/plain, Size: 2950 bytes --]
@gaoliming<mailto:gaoliming@byosoft.com.cn>
May I get your help to add push Label on the PR ?
https://github.com/tianocore/edk2/pull/2844
It seems I don't have access right to add push Label by myself.
If have any concern please also share me.
Thanks,
Gua
-----Original Message-----
From: gaoliming <gaoliming@byosoft.com.cn>
Sent: Sunday, May 8, 2022 10:44 PM
To: devel@edk2.groups.io; guo.guo@intel.com
Cc: Guo, Gua <gua.guo@intel.com>
Subject: 回复: [edk2-devel] [PATCH] MdeModulePkg/PCD: Pcd initialize DXE have assert
Guo:
This change is good to me. Reviewed-by: Liming Gao <gaoliming@byosoft.com.
cn>
Thanks
Liming
> -----邮件原件-----
> 发件人: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> 代表
> guo.guo@intel.com<mailto:guo.guo@intel.com>
> 发送时间: 2022年5月6日 5:30
> 收件人: devel@edk2.groups.io<mailto:devel@edk2.groups.io>
> 抄送: Gua Guo <gua.guo@intel.com<mailto:gua.guo@intel.com>>
> 主题: [edk2-devel] [PATCH] MdeModulePkg/PCD: Pcd initialize DXE have
> assert
>
> From: Gua Guo <gua.guo@intel.com<mailto:gua.guo@intel.com>>
>
> REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3917
>
> When PlatformPkg.dsc has multiple SKU IDs but didn't exist delta PCD,
> System will hang on BuildPcdDxeDataBase.
>
> Ideally, if didn't exist delta PCD by different SKU ID,
> UpdatePcdDatabase () shouldn't return EFI_NOT_FOUND.
>
> Signed-off-by: Gua Guo <gua.guo@intel.com<mailto:gua.guo@intel.com>>
> ---
> MdeModulePkg/Universal/PCD/Dxe/Service.c | 5 +++++
> 1 file changed, 5 insertions(+)
>
> diff --git a/MdeModulePkg/Universal/PCD/Dxe/Service.c
> b/MdeModulePkg/Universal/PCD/Dxe/Service.c
> index 3965846b93..5ade8d988b 100644
> --- a/MdeModulePkg/Universal/PCD/Dxe/Service.c
> +++ b/MdeModulePkg/Universal/PCD/Dxe/Service.c
> @@ -817,6 +817,11 @@ UpdatePcdDatabase (
> //
>
> Index = (mPcdDatabase.DxeDb->Length + 7) & (~7);
>
> SkuDelta = NULL;
>
> +
>
> + if (Index == mDxePcdDbSize) {
>
> + return EFI_SUCCESS;
>
> + }
>
> +
>
> while (Index < mDxePcdDbSize) {
>
> SkuDelta = (PCD_DATABASE_SKU_DELTA *)((UINT8 *)mDxePcdDbBinary
> + Index);
>
> if ((SkuDelta->SkuId == SkuId) && (SkuDelta->SkuIdCompared == 0))
> {
>
> --
> 2.31.1.windows.1
>
>
>
> -=-=-=-=-=-=
> Groups.io Links: You receive all messages sent to this group.
> View/Reply Online (#89557):
> https://edk2.groups.io/g/devel/message/89557
> Mute This Topic: https://groups.io/mt/90934230/4905953
> Group Owner: devel+owner@edk2.groups.io<mailto:devel+owner@edk2.groups.io>
> Unsubscribe: https://edk2.groups.io/g/devel/unsub
> [gaoliming@byosoft.com.cn]
> -=-=-=-=-=-=
>
[-- Attachment #2: Type: text/html, Size: 10699 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
* 回复: [edk2-devel] [PATCH] MdeModulePkg/PCD: Pcd initialize DXE have assert
2022-05-09 1:31 ` Guo, Gua
@ 2022-05-09 14:32 ` gaoliming
0 siblings, 0 replies; 4+ messages in thread
From: gaoliming @ 2022-05-09 14:32 UTC (permalink / raw)
To: 'Guo, Gua', devel
[-- Attachment #1: Type: text/plain, Size: 3682 bytes --]
I have merged it by https://github.com/tianocore/edk2/pull/2865
Thanks
Liming
发件人: Guo, Gua <gua.guo@intel.com>
发送时间: 2022年5月9日 9:31
收件人: Gao, Liming <gaoliming@byosoft.com.cn>; devel@edk2.groups.io
抄送: Guo, Gua <gua.guo@intel.com>
主题: RE: [edk2-devel] [PATCH] MdeModulePkg/PCD: Pcd initialize DXE have assert
<mailto:gaoliming@byosoft.com.cn> @gaoliming
May I get your help to add push Label on the PR ?
https://github.com/tianocore/edk2/pull/2844
It seems I don't have access right to add push Label by myself.
If have any concern please also share me.
Thanks,
Gua
-----Original Message-----
From: gaoliming <gaoliming@byosoft.com.cn <mailto:gaoliming@byosoft.com.cn> >
Sent: Sunday, May 8, 2022 10:44 PM
To: devel@edk2.groups.io <mailto:devel@edk2.groups.io> ; guo.guo@intel.com <mailto:guo.guo@intel.com>
Cc: Guo, Gua <gua.guo@intel.com <mailto:gua.guo@intel.com> >
Subject: 回复: [edk2-devel] [PATCH] MdeModulePkg/PCD: Pcd initialize DXE have assert
Guo:
This change is good to me. Reviewed-by: Liming Gao <gaoliming@byosoft.com.
cn>
Thanks
Liming
> -----邮件原件-----
> 发件人: <mailto:devel@edk2.groups.io> devel@edk2.groups.io < <mailto:devel@edk2.groups.io> devel@edk2.groups.io> 代表
> <mailto:guo.guo@intel.com> guo.guo@intel.com
> 发送时间: 2022年5月6日 5:30
> 收件人: <mailto:devel@edk2.groups.io> devel@edk2.groups.io
> 抄送: Gua Guo < <mailto:gua.guo@intel.com> gua.guo@intel.com>
> 主题: [edk2-devel] [PATCH] MdeModulePkg/PCD: Pcd initialize DXE have
> assert
>
> From: Gua Guo < <mailto:gua.guo@intel.com> gua.guo@intel.com>
>
> REF: <https://bugzilla.tianocore.org/show_bug.cgi?id=3917> https://bugzilla.tianocore.org/show_bug.cgi?id=3917
>
> When PlatformPkg.dsc has multiple SKU IDs but didn't exist delta PCD,
> System will hang on BuildPcdDxeDataBase.
>
> Ideally, if didn't exist delta PCD by different SKU ID,
> UpdatePcdDatabase () shouldn't return EFI_NOT_FOUND.
>
> Signed-off-by: Gua Guo < <mailto:gua.guo@intel.com> gua.guo@intel.com>
> ---
> MdeModulePkg/Universal/PCD/Dxe/Service.c | 5 +++++
> 1 file changed, 5 insertions(+)
>
> diff --git a/MdeModulePkg/Universal/PCD/Dxe/Service.c
> b/MdeModulePkg/Universal/PCD/Dxe/Service.c
> index 3965846b93..5ade8d988b 100644
> --- a/MdeModulePkg/Universal/PCD/Dxe/Service.c
> +++ b/MdeModulePkg/Universal/PCD/Dxe/Service.c
> @@ -817,6 +817,11 @@ UpdatePcdDatabase (
> //
>
> Index = (mPcdDatabase.DxeDb->Length + 7) & (~7);
>
> SkuDelta = NULL;
>
> +
>
> + if (Index == mDxePcdDbSize) {
>
> + return EFI_SUCCESS;
>
> + }
>
> +
>
> while (Index < mDxePcdDbSize) {
>
> SkuDelta = (PCD_DATABASE_SKU_DELTA *)((UINT8 *)mDxePcdDbBinary
> + Index);
>
> if ((SkuDelta->SkuId == SkuId) && (SkuDelta->SkuIdCompared == 0))
> {
>
> --
> 2.31.1.windows.1
>
>
>
> -=-=-=-=-=-=
> Groups.io Links: You receive all messages sent to this group.
> View/Reply Online (#89557):
> <https://edk2.groups.io/g/devel/message/89557> https://edk2.groups.io/g/devel/message/89557
> Mute This Topic: <https://groups.io/mt/90934230/4905953> https://groups.io/mt/90934230/4905953
> Group Owner: <mailto:devel+owner@edk2.groups.io> devel+owner@edk2.groups.io
> Unsubscribe: <https://edk2.groups.io/g/devel/unsub> https://edk2.groups.io/g/devel/unsub
> [gaoliming@byosoft.com.cn]
> -=-=-=-=-=-=
>
[-- Attachment #2: Type: text/html, Size: 15013 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2022-05-09 14:33 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-05-05 21:29 [PATCH] MdeModulePkg/PCD: Pcd initialize DXE have assert guo.guo
2022-05-08 14:43 ` 回复: [edk2-devel] " gaoliming
2022-05-09 1:31 ` Guo, Gua
2022-05-09 14:32 ` 回复: " gaoliming
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox