-
Notifications
You must be signed in to change notification settings - Fork 6.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add support for xsdb runner #80046
base: main
Are you sure you want to change the base?
add support for xsdb runner #80046
Conversation
Hello @kedareswararao, and thank you very much for your first pull request to the Zephyr project! |
c5dc99e
to
9c9a16f
Compare
if 'mbv32' in board_name and bitstream is None: | ||
raise ValueError('Valid bitstream is required for mbv32 platform') | ||
if 'kv260_r5' in board_name and fsbl is None: | ||
raise ValueError('Valid fsbl elf is required for kv260_r5 platform') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We shouldn't have board logic in runner scripts. Try to pass the necessary arguments in the board.cmake files using board_runner_args(xsdb "--some-option=value")
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure will fix
boards/amd/kv260_r5/board.cmake
Outdated
board_set_runner(FLASH xsdb) | ||
board_set_debugger_ifnset(xsdb) | ||
board_set_flasher_ifnset(xsdb) | ||
board_finalize_runner_args(xsdb) | ||
set(FLASH_RUNNER xsdb) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If this is going to be used by more boards, add boards/common/xsdb.board.cmake
and include it here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure will move it to xsdb.board.cmake and will include it in the board.cmake
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would suggest creating a boards/common/xsdb.board.cmake
for setting the defaults and include this in the board.cmake
. Please see the in-tree examples of how this is done (e.g. `boards/common/jlink.board.cmake).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sure
boards/amd/kv260_r5/support/xsdb.cfg
Outdated
# Copyright (c) 2024 Advanced Micro Devices, Inc. | ||
# | ||
# SPDX-License-Identifier: Apache-2.0 | ||
# Author: Appana Durga Kedareswara rao |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We usually don't list authors.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Okay will remove the Author tag
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add a test suite under scripts/west_commands/tests/
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sure will add
9c9a16f
to
cbed5e7
Compare
Add support for xsdb(Xilinx System Debugger) used with AMD's FPGA and SOC platforms, it is a user-friendly, interactive, and scriptable command line interface, by design choice it's expected that platforms to have xsdb scripts present inside their platform code. xsdb runner has bitstream and fsbl optional arguments, bitstream is needed for fpga targets and fsbl is needed for SOC targets, added support for both options. Signed-off-by: Appana Durga Kedareswara rao <[email protected]>
Add pytest case for xsdb runner. Signed-off-by: Appana Durga Kedareswara rao <[email protected]>
Update the board cmake to use xsdb runner, If users would like to use default xsdb.cfg then need to pass the fsbl.elf binary via --fsbl option when using west flash or twister commands. Usage: 1) west flash --runner xsdb --elf-file kv260_r5/zephyr/zephyr.elf --fsbl <path>/fsbl.elf 2) ./scripts/twister -p kv260_r5 --west-runner xsdb --device-testing --device-serial /dev/ttyUSB0 --west-flash="--fsbl=<path>/fsbl.elf" Signed-off-by: Appana Durga Kedareswara rao <[email protected]>
cbed5e7
to
5e92583
Compare
This pull request adds support for xsdb runner