summary refs log tree commit diff stats
path: root/hw/intc
diff options
context:
space:
mode:
authorShiva sagar Myana <Shivasagar.Myana@amd.com>2024-06-18 16:22:20 +0100
committerPeter Maydell <peter.maydell@linaro.org>2024-06-21 14:01:58 +0100
commit35e71ec53581fc8a90dfff1565e4ba344945cf80 (patch)
tree97473d21a6a23f48909aab0d90c4c2c13fb2ac50 /hw/intc
parent02d9c38236cf8c9826e5c5be61780c4444cb4ae0 (diff)
downloadfocaccia-qemu-35e71ec53581fc8a90dfff1565e4ba344945cf80.tar.gz
focaccia-qemu-35e71ec53581fc8a90dfff1565e4ba344945cf80.zip
hw/net/can/xlnx-versal-canfd: Fix sorting of the tx queue
Returning an uint32_t casted to a gint from g_cmp_ids causes the tx queue to
become wrongly sorted when executing g_slist_sort. Fix this by always
returning -1 or 1 from g_cmp_ids based on the ID comparison instead.
Also, if two message IDs are the same, sort them by using their index and
transmit the message at the lowest index first.

Signed-off-by: Shiva sagar Myana <Shivasagar.Myana@amd.com>
Reviewed-by: Francisco Iglesias <francisco.iglesias@amd.com>
Message-id: 20240603051732.3334571-1-Shivasagar.Myana@amd.com
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'hw/intc')
0 files changed, 0 insertions, 0 deletions