AIESW-29257: Fix xrt-smi device ID reporting#9716
Open
sandilya-xilinx wants to merge 4 commits intoXilinx:masterfrom
Open
AIESW-29257: Fix xrt-smi device ID reporting#9716sandilya-xilinx wants to merge 4 commits intoXilinx:masterfrom
sandilya-xilinx wants to merge 4 commits intoXilinx:masterfrom
Conversation
[why] xrt-smi JSON report showed "id": "00000000-0000-0000-0000-000000000000" for all Ryzen/NPU devices (Phoenix, Strix, Strix2, StrixH, Krackan, Medusa, Soundwave). The root cause: rom_time_since_epoch returns a hardcoded 0 for Ryzen devices instead of throwing, so the existing Alveo 1RP path silently set id="0". No Ryzen-specific path existed, leaving every NPU device with an identical, non-unique identifier in the JSON output. [how] Extract device ID generation into a dedicated get_device_id() function in XBUtilities.cpp. For Ryzen/NPU devices, derive the UUID from PCIe BDF (domain, bus, device, function) using the same memcpy byte-packing as hip_device_get_uuid(), ensuring the xrt-smi id is consistent with the HIP UUID API. Alveo 2RP (xclbin logic UUID) and 1RP (ROM timestamp) paths are retained as fallbacks for non-Ryzen devices. AIESW-29257
|
@sandilya-xilinx is not a repository collaborator. To proceed:
|
Replace C-style byte array and magic number indices with xuid_t + std::apply fold, eliminating all cppcoreguidelines-avoid-magic-numbers and cppcoreguidelines-avoid-c-arrays warnings. AIESW-29257
|
@sandilya-xilinx is not a repository collaborator. To proceed:
|
|
@sandilya-xilinx is not a repository collaborator. To proceed:
|
Contributor
|
clang-tidy review says "All clean, LGTM! 👍" |
I, Sandilya Bhagi <sandilya.bhagi@amd.com>, hereby add my Signed-off-by to this commit: 498ab2f I, Sandilya Bhagi <sandilya.bhagi@amd.com>, hereby add my Signed-off-by to this commit: 8ecf10b I, Sandilya Bhagi <sandilya.bhagi@amd.com>, hereby add my Signed-off-by to this commit: fc560b2 Signed-off-by: Sandilya Bhagi <sandilya.bhagi@amd.com> Signed-off-by: Sandilya Bhagi <sandilya.bhagi@amd.com>
|
@sandilya-xilinx is not a repository collaborator. To proceed:
|
Contributor
|
clang-tidy review says "All clean, LGTM! 👍" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
[why]
xrt-smi JSON report showed "id": "00000000-0000-0000-0000-000000000000" for all Ryzen/NPU devices (Phoenix, Strix, Strix2, StrixH, Krackan, Medusa, Soundwave). The root cause: rom_time_since_epoch returns a hardcoded 0 for Ryzen devices instead of throwing, so the existing Alveo 1RP path silently set id="0". No Ryzen-specific path existed, leaving every NPU device with an identical, non-unique identifier in the JSON output.
[how]
Extract device ID generation into a dedicated get_device_id() function in XBUtilities.cpp. For Ryzen/NPU devices, derive the UUID from PCIe BDF (domain, bus, device, function) using the same memcpy byte-packing as hip_device_get_uuid(), ensuring the xrt-smi id is consistent with the HIP UUID API. Alveo 2RP (xclbin logic UUID) and 1RP (ROM timestamp) paths are retained as fallbacks for non-Ryzen devices.
AIESW-29257
Problem solved by the commit
Bug / issue (if any) fixed, which PR introduced the bug, how it was discovered
How problem was solved, alternative solutions (if any) and why they were rejected
Risks (if any) associated the changes in the commit
What has been tested and how, request additional testing if necessary
Documentation impact (if any)