summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/exported-sql-viewer.py
diff options
context:
space:
mode:
authorPurva Yeshi <purvayeshi550@gmail.com>2025-04-10 16:32:16 +0530
committerVinod Koul <vkoul@kernel.org>2025-04-17 12:51:55 +0530
commit97994333de2b8062d2df4e6ce0dc65c2dc0f40dc (patch)
tree61be0a2cc4ed49d71e9404e46abad19f45307c83 /tools/perf/scripts/python/exported-sql-viewer.py
parent0af2f6be1b4281385b618cb86ad946eded089ac8 (diff)
dmaengine: idxd: cdev: Fix uninitialized use of sva in idxd_cdev_open
Fix Smatch-detected issue: drivers/dma/idxd/cdev.c:321 idxd_cdev_open() error: uninitialized symbol 'sva'. 'sva' pointer may be used uninitialized in error handling paths. Specifically, if PASID support is enabled and iommu_sva_bind_device() returns an error, the code jumps to the cleanup label and attempts to call iommu_sva_unbind_device(sva) without ensuring that sva was successfully assigned. This triggers a Smatch warning about an uninitialized symbol. Initialize sva to NULL at declaration and add a check using IS_ERR_OR_NULL() before unbinding the device. This ensures the function does not use an invalid or uninitialized pointer during cleanup. Signed-off-by: Purva Yeshi <purvayeshi550@gmail.com> Reviewed-by: Dave Jiang <dave.jiang@intel.com> Acked-by: Vinicius Costa Gomes <vinicius.gomes@intel.com> Link: https://lore.kernel.org/r/20250410110216.21592-1-purvayeshi550@gmail.com Signed-off-by: Vinod Koul <vkoul@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python/exported-sql-viewer.py')
0 files changed, 0 insertions, 0 deletions