aboutsummaryrefslogtreecommitdiff
path: root/hw/core
diff options
context:
space:
mode:
authorIra Weiny <ira.weiny@intel.com>2024-05-31 11:22:05 -0500
committerMichael S. Tsirkin <mst@redhat.com>2024-07-01 17:16:05 -0400
commite6c9c9e7f46a9ecaf1d90a68595915d65cd9d72d (patch)
treed88084b94f3cf139a3cb35f0eaafe853abfdbdc1 /hw/core
parenta113d041e8d0b152d72a7c2bf47dd09aabf9ade2 (diff)
downloadqemu-e6c9c9e7f46a9ecaf1d90a68595915d65cd9d72d.zip
qemu-e6c9c9e7f46a9ecaf1d90a68595915d65cd9d72d.tar.gz
qemu-e6c9c9e7f46a9ecaf1d90a68595915d65cd9d72d.tar.bz2
hw/cxl: Fix read from bogus memory
Peter and coverity report: We've passed '&data' to address_space_write(), which means "read from the address on the stack where the function argument 'data' lives", so instead of writing 64 bytes of data to the guest , we'll write 64 bytes which start with a host pointer value and then continue with whatever happens to be on the host stack after that. Indeed the intention was to write 64 bytes of data at the address given. Fix the parameter to address_space_write(). Reported-by: Peter Maydell <peter.maydell@linaro.org> Link: https://lore.kernel.org/all/CAFEAcA-u4sytGwTKsb__Y+_+0O2-WwARntm3x8WNhvL1WfHOBg@mail.gmail.com/ Fixes: 6bda41a69bdc ("hw/cxl: Add clear poison mailbox command support.") Cc: Jonathan Cameron <Jonathan.Cameron@huawei.com> Signed-off-by: Ira Weiny <ira.weiny@intel.com> Message-Id: <20240531-fix-poison-set-cacheline-v1-1-e3bc7e8f1158@intel.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com> Reviewed-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Diffstat (limited to 'hw/core')
0 files changed, 0 insertions, 0 deletions