Skip to content

Commit 18970ad

Browse files
author
Appana Durga Kedareswara rao
committed
boards: amd: Use PDI path from runner arguments instead of environment
Modified the XSDB configuration to take the PDI path directly from the runner script's arguments rather than relying on an environment variable. This change improves usability and makes the runner more self-contained. Signed-off-by: Appana Durga Kedareswara rao <appana.durga.kedareswara.rao@amd.com>
1 parent 9c3ebc3 commit 18970ad

File tree

2 files changed

+4
-12
lines changed

2 files changed

+4
-12
lines changed

boards/amd/versal2_rpu/support/xsdb.cfg

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -33,19 +33,15 @@ proc rpu0_core0_rst { {mem "default"} } {
3333

3434
proc load_image args {
3535
set elf_file [lindex $args 0]
36+
set pdi_file [lindex $args 1]
3637

3738
if { [info exists ::env(HW_SERVER_URL)] } {
3839
connect -url $::env(HW_SERVER_URL)
3940
} else {
4041
connect
4142
}
4243

43-
if { [info exists ::env(PDI_FILE_PATH)] } {
44-
device program $::env(PDI_FILE_PATH)
45-
} else {
46-
puts "Error: env variable PDI_FILE_PATH is not set"
47-
exit
48-
}
44+
device program $pdi_file
4945

5046
if { [info exists ::env(HW_SERVER_URL)] } {
5147
set hw_server_url [split $::env(HW_SERVER_URL) ":"]

boards/amd/versalnet_rpu/support/xsdb.cfg

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44

55
proc load_image args {
66
set elf_file [lindex $args 0]
7+
set pdi_file [lindex $args 1]
78

89
if { [info exists ::env(HW_SERVER_URL)] } {
910
connect -url $::env(HW_SERVER_URL)
@@ -17,12 +18,7 @@ proc load_image args {
1718
rst -system
1819
after 100
1920

20-
if { [info exists ::env(PDI_FILE_PATH)] } {
21-
device program $::env(PDI_FILE_PATH)
22-
} else {
23-
puts "Error: env variable PDI_FILE_PATH is not set"
24-
exit
25-
}
21+
device program $pdi_file
2622

2723
after 100
2824
targets -set -nocase -filter {name =~ "DPC"}

0 commit comments

Comments
 (0)