From 5299568ce6737f0225c7cb5b7a6baef409994856 Mon Sep 17 00:00:00 2001 From: Rebecca Cran Date: Sun, 10 Apr 2022 19:16:58 -0600 Subject: ArmPlatformPkg: Fix target initialisation in cmd_load_symbols.py The debugger in Arm Development Studio 2021.2 doesn't work with "ec = debugger.getExecutionContext(0)" because it's subsequently unable to access memory. Fix it by switching to "ec = debugger.getCurrentExecutionContext()". The documentation for waitForStop() says: "It is not needed after a call to stop() because stop() is blocking." So, remove the call to waitForStop. Signed-off-by: Rebecca Cran Reviewed-by: Ard Biesheuvel --- ArmPlatformPkg/Scripts/Ds5/cmd_load_symbols.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/ArmPlatformPkg/Scripts/Ds5/cmd_load_symbols.py b/ArmPlatformPkg/Scripts/Ds5/cmd_load_symbols.py index 89d2f28ba2..cb4db148de 100644 --- a/ArmPlatformPkg/Scripts/Ds5/cmd_load_symbols.py +++ b/ArmPlatformPkg/Scripts/Ds5/cmd_load_symbols.py @@ -85,11 +85,10 @@ else: debugger = Debugger() # Initialisation commands -ec = debugger.getExecutionContext(0) +ec = debugger.getCurrentExecutionContext() ec.getExecutionService().stop() -ec.getExecutionService().waitForStop() # in case the execution context reference is out of date -ec = debugger.getExecutionContext(0) +ec = debugger.getCurrentExecutionContext() try: armplatform_debugger = edk2_debugger.ArmPlatformDebugger(ec, report_file, regions, verbose) -- cgit v1.2.3