tmp_suning_uos_patched/drivers/firmware/xilinx
Tejas Patel ef7809681b firmware: xilinx: Fix dereferencing freed memory
[ Upstream commit f1f21bece82c76a56a96988ec7d51ccc033d8949 ]

Fix smatch warning:
drivers/firmware/xilinx/zynqmp.c:1288 zynqmp_firmware_remove()
error: dereferencing freed memory 'feature_data'

Use hash_for_each_safe for safe removal of hash entry.

Fixes: acfdd18591 ("firmware: xilinx: Use hash-table for api feature check")
Reported-by: kernel test robot <lkp@intel.com>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Tejas Patel <tejas.patel@xilinx.com>
Signed-off-by: Rajan Vaja <rajan.vaja@xilinx.com>
Link: https://lore.kernel.org/r/1612765883-22018-1-git-send-email-rajan.vaja@xilinx.com
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2021-05-14 09:50:05 +02:00
..
Kconfig arm64: zynqmp: Make zynqmp_firmware driver optional 2020-03-09 14:58:24 +01:00
Makefile firmware: xilinx: Add debugfs interface 2018-09-26 08:47:35 +02:00
zynqmp-debug.c firmware: xilinx: Remove eemi ops for query_data 2020-04-28 15:45:06 +02:00
zynqmp-debug.h firmware: xilinx: Add debugfs interface 2018-09-26 08:47:35 +02:00
zynqmp.c firmware: xilinx: Fix dereferencing freed memory 2021-05-14 09:50:05 +02:00