public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* [edk2-devel] [PATCH v1 1/1] DynamicTablesPkg: Fix assert in CmObject parser
@ 2023-11-01 10:28 Sami Mujawar
  2023-11-01 11:44 ` levi.yun
  0 siblings, 1 reply; 2+ messages in thread
From: Sami Mujawar @ 2023-11-01 10:28 UTC (permalink / raw)
  To: devel
  Cc: Sami Mujawar, pierre.gondois, YeoReum.Yun, quic_llindhol,
	Akanksha.Jain2, Sibel.Allinson, nd

The patch "f81ee47513e5 DynamicTablesPkg: Add an ET info
object parser" updates the Configuration Manager object
parser to add support for parsing CM_ARM_ET_INFO object.

However, the GicC info structure also has an ET Reference
token that points to the CM_ARM_ET_INFO object. Therefore,
update the GICC info object parser to add an entry to parse
the ET reference token. Without this change an assert
stating that the RemainingSize != 0 will be triggered.

Signed-off-by: Sami Mujawar <sami.mujawar@arm.com>
---
 DynamicTablesPkg/Library/Common/TableHelperLib/ConfigurationManagerObjectParser.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/DynamicTablesPkg/Library/Common/TableHelperLib/ConfigurationManagerObjectParser.c b/DynamicTablesPkg/Library/Common/TableHelperLib/ConfigurationManagerObjectParser.c
index 127675d4cec435e6a076c4466b86a31160bf9de1..ce494816ed884f14af56fb32e7bf6bbba8595521 100644
--- a/DynamicTablesPkg/Library/Common/TableHelperLib/ConfigurationManagerObjectParser.c
+++ b/DynamicTablesPkg/Library/Common/TableHelperLib/ConfigurationManagerObjectParser.c
@@ -84,7 +84,8 @@ STATIC CONST CM_OBJ_PARSER  CmArmGicCInfoParser[] = {
   { "ClockDomain",                   4,                        "0x%x",   NULL },
   { "AffinityFlags",                 4,                        "0x%x",   NULL },
   { "CpcToken",                      sizeof (CM_OBJECT_TOKEN), "0x%p",   NULL },
-  { "TRBEInterrupt",                 2,                        "0x%x",   NULL }
+  { "TRBEInterrupt",                 2,                        "0x%x",   NULL },
+  { "EtToken",                       sizeof (CM_OBJECT_TOKEN), "0x%p",   NULL }
 };
 
 /** A parser for EArmObjGicDInfo.
-- 
'Guid(CE165669-3EF3-493F-B85D-6190EE5B9759)'



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#110474): https://edk2.groups.io/g/devel/message/110474
Mute This Topic: https://groups.io/mt/102315705/7686176
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io]
-=-=-=-=-=-=-=-=-=-=-=-



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

* Re: [edk2-devel] [PATCH v1 1/1] DynamicTablesPkg: Fix assert in CmObject parser
  2023-11-01 10:28 [edk2-devel] [PATCH v1 1/1] DynamicTablesPkg: Fix assert in CmObject parser Sami Mujawar
@ 2023-11-01 11:44 ` levi.yun
  0 siblings, 0 replies; 2+ messages in thread
From: levi.yun @ 2023-11-01 11:44 UTC (permalink / raw)
  To: Sami Mujawar, devel@edk2.groups.io
  Cc: Pierre Gondois, quic_llindhol@quicinc.com, Akanksha Jain,
	Sibel Allinson, nd

Reviewed-by: levi.yun (yeoreum.yun@arm.com)

________________________________________
From: Sami Mujawar <sami.mujawar@arm.com>
Sent: 01 November 2023 10:28
To: devel@edk2.groups.io
Cc: Sami Mujawar; Pierre Gondois; Yeo Reum Yun; quic_llindhol@quicinc.com; Akanksha Jain; Sibel Allinson; nd
Subject: [PATCH v1 1/1] DynamicTablesPkg: Fix assert in CmObject parser

The patch "f81ee47513e5 DynamicTablesPkg: Add an ET info
object parser" updates the Configuration Manager object
parser to add support for parsing CM_ARM_ET_INFO object.

However, the GicC info structure also has an ET Reference
token that points to the CM_ARM_ET_INFO object. Therefore,
update the GICC info object parser to add an entry to parse
the ET reference token. Without this change an assert
stating that the RemainingSize != 0 will be triggered.

Signed-off-by: Sami Mujawar <sami.mujawar@arm.com>
---
 DynamicTablesPkg/Library/Common/TableHelperLib/ConfigurationManagerObjectParser.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/DynamicTablesPkg/Library/Common/TableHelperLib/ConfigurationManagerObjectParser.c b/DynamicTablesPkg/Library/Common/TableHelperLib/ConfigurationManagerObjectParser.c
index 127675d4cec435e6a076c4466b86a31160bf9de1..ce494816ed884f14af56fb32e7bf6bbba8595521 100644
--- a/DynamicTablesPkg/Library/Common/TableHelperLib/ConfigurationManagerObjectParser.c
+++ b/DynamicTablesPkg/Library/Common/TableHelperLib/ConfigurationManagerObjectParser.c
@@ -84,7 +84,8 @@ STATIC CONST CM_OBJ_PARSER  CmArmGicCInfoParser[] = {
   { "ClockDomain",                   4,                        "0x%x",   NULL },
   { "AffinityFlags",                 4,                        "0x%x",   NULL },
   { "CpcToken",                      sizeof (CM_OBJECT_TOKEN), "0x%p",   NULL },
-  { "TRBEInterrupt",                 2,                        "0x%x",   NULL }
+  { "TRBEInterrupt",                 2,                        "0x%x",   NULL },
+  { "EtToken",                       sizeof (CM_OBJECT_TOKEN), "0x%p",   NULL }
 };

 /** A parser for EArmObjGicDInfo.
--
'Guid(CE165669-3EF3-493F-B85D-6190EE5B9759)'

IMPORTANT NOTICE: The contents of this email and any attachments are confidential and may also be privileged. If you are not the intended recipient, please notify the sender immediately and do not disclose the contents to any other person, use it for any purpose, or store or copy the information in any medium. Thank you.


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#110476): https://edk2.groups.io/g/devel/message/110476
Mute This Topic: https://groups.io/mt/102315705/7686176
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io]
-=-=-=-=-=-=-=-=-=-=-=-



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

end of thread, other threads:[~2023-11-01 11:44 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-11-01 10:28 [edk2-devel] [PATCH v1 1/1] DynamicTablesPkg: Fix assert in CmObject parser Sami Mujawar
2023-11-01 11:44 ` levi.yun

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