gma: Avoid dynamic stack usage in status dumping procedures
`Dump_Configs ()` is not only used for debugging, we can avoid the
dynamic stack usage by getting rid of the concatenation operation.
While we are at it, also take care of `Dump_Link_Status ()`.
Change-Id: Icc07566977fac43d7403784ea6454c3cd668b683
Signed-off-by: Nico Huber <nico.huber@secunet.com>
Reviewed-on: https://review.sourcearcade.org/c/libgfxinit/+/534
Reviewed-by: Thomas Heijligen <src@posteo.de>
Tested-by: Nico Huber <nico.h@gmx.de>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
diff --git a/common/hw-gfx-dp_training.adb b/common/hw-gfx-dp_training.adb
index 7b06679..7a7bd78 100644
--- a/common/hw-gfx-dp_training.adb
+++ b/common/hw-gfx-dp_training.adb
@@ -202,16 +202,32 @@
Debug.Put_Int8 (Int8 (Lane));
Debug.Put_Line (":");
- Debug.Put_Line (" CR_Done : " &
- (if Status.Lanes (Lane).CR_Done then "1" else "0"));
- Debug.Put_Line (" Channel_EQ_Done: " &
- (if Status.Lanes (Lane).Channel_EQ_Done then "1" else "0"));
- Debug.Put_Line (" Symbol_Locked : " &
- (if Status.Lanes (Lane).Symbol_Locked then "1" else "0"));
+ Debug.Put (" CR_Done : ");
+ if Status.Lanes (Lane).CR_Done then
+ Debug.Put_Line ("1");
+ else
+ Debug.Put_Line ("0");
+ end if;
+ Debug.Put (" Channel_EQ_Done: ");
+ if Status.Lanes (Lane).Channel_EQ_Done then
+ Debug.Put_Line ("1");
+ else
+ Debug.Put_Line ("0");
+ end if;
+ Debug.Put (" Symbol_Locked : ");
+ if Status.Lanes (Lane).Symbol_Locked then
+ Debug.Put_Line ("1");
+ else
+ Debug.Put_Line ("0");
+ end if;
end loop;
- Debug.Put_Line (" Interlane_Align_Done: " &
- (if Status.Interlane_Align_Done then "1" else "0"));
+ Debug.Put (" Interlane_Align_Done: ");
+ if Status.Interlane_Align_Done then
+ Debug.Put_Line ("1");
+ else
+ Debug.Put_Line ("0");
+ end if;
for Lane in DP_Info.Lane_Index range 0
.. DP_Info.Lane_Index (Lane_Count_As_Integer (Link.Lane_Count) - 1)