summary refs log tree commit diff stats
path: root/rust/qemu-api/src/qdev.rs
diff options
context:
space:
mode:
authorPeter Maydell <peter.maydell@linaro.org>2025-07-14 17:55:23 +0100
committerJason Wang <jasowang@redhat.com>2025-07-21 10:21:51 +0800
commita6d6e37901551cbd61b0a61c6bab5745fb1833ff (patch)
treed6bdd1c88802105b544597754385732f864e0f59 /rust/qemu-api/src/qdev.rs
parente96a1aa6766f1b188dada3ad8d172c0fbe2f3a5f (diff)
downloadfocaccia-qemu-a6d6e37901551cbd61b0a61c6bab5745fb1833ff.tar.gz
focaccia-qemu-a6d6e37901551cbd61b0a61c6bab5745fb1833ff.zip
hw/net/npcm_gmac.c: Drop 'buf' local variable
We use the local variable 'buf' only when we call dma_memory_read(),
and it is always set to &tx_send_buffer[prev_buf_size] immediately
before both of those calls.  So remove the variable and pass
tx_send_buffer + prev_buf_size to dma_memory_read().

This fixes in passing a place where we set buf = tx_send_buffer
but never used that value because we always updated buf to
something else later before using it.

Coverity: CID 1534027
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Jason Wang <jasowang@redhat.com>
Diffstat (limited to 'rust/qemu-api/src/qdev.rs')
0 files changed, 0 insertions, 0 deletions