summaryrefslogtreecommitdiff
path: root/drivers/accel
diff options
context:
space:
mode:
authorJeffrey Hugo <quic_jhugo@quicinc.com>2024-11-17 13:26:29 -0700
committerJeffrey Hugo <quic_jhugo@quicinc.com>2024-11-22 11:35:15 -0700
commit57250e0fa30194d4ac309ee87573bed71db68b46 (patch)
tree20cdfca7388ea3ce229a5db5acdc1236c8617f0f /drivers/accel
parent98efdd02e220fea84c1491012d7292749a71faeb (diff)
accel/qaic: Drop redundant vfree() null check in sahara
The documentation for vfree() says that passing in NULL is ok. Therefore we can drop the null check as redundant. Reported-by: kernel test robot <lkp@intel.com> Closes: https://lore.kernel.org/oe-kbuild-all/202410301732.abF5Md4e-lkp@intel.com/ Signed-off-by: Jeffrey Hugo <quic_jhugo@quicinc.com> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Reviewed-by: Youssef Samir <quic_yabdulra@quicinc.com> Reviewed-by: Carl Vanderlip <quic_carlv@quicinc.com> Link: https://patchwork.freedesktop.org/patch/msgid/20241117202629.1681358-1-quic_jhugo@quicinc.com
Diffstat (limited to 'drivers/accel')
-rw-r--r--drivers/accel/qaic/sahara.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/accel/qaic/sahara.c b/drivers/accel/qaic/sahara.c
index 6d772143d612..21d58aed0deb 100644
--- a/drivers/accel/qaic/sahara.c
+++ b/drivers/accel/qaic/sahara.c
@@ -772,8 +772,7 @@ static void sahara_mhi_remove(struct mhi_device *mhi_dev)
cancel_work_sync(&context->fw_work);
cancel_work_sync(&context->dump_work);
- if (context->mem_dump)
- vfree(context->mem_dump);
+ vfree(context->mem_dump);
sahara_release_image(context);
mhi_unprepare_from_transfer(mhi_dev);
}