linux/drivers/base/firmware_loader
Russ Weight 789bba82f6 firmware_loader: Fix memory leak in firmware upload
In the case of firmware-upload, an instance of struct fw_upload is
allocated in firmware_upload_register(). This data needs to be freed
in fw_dev_release(). Create a new fw_upload_free() function in
sysfs_upload.c to handle the firmware-upload specific memory frees
and incorporate the missing kfree call for the fw_upload structure.

Fixes: 97730bbb24 ("firmware_loader: Add firmware-upload support")
Cc: stable <stable@kernel.org>
Signed-off-by: Russ Weight <russell.h.weight@intel.com>
Link: https://lore.kernel.org/r/20220831002518.465274-1-russell.h.weight@intel.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2022-09-01 17:47:27 +02:00
..
builtin kbuild: do not quote string values in include/config/auto.conf 2022-01-08 18:03:57 +09:00
fallback_platform.c firmware: Store opt_flags in fw_priv 2020-10-05 13:37:04 +02:00
fallback_table.c firmware_loader: move firmware sysctl to its own files 2022-01-22 08:33:35 +02:00
fallback.c firmware_loader: Split sysfs support from fallback 2022-04-26 12:34:09 +02:00
fallback.h firmware_loader: Split sysfs support from fallback 2022-04-26 12:34:09 +02:00
firmware.h firmware_loader: Add firmware-upload support 2022-04-26 12:34:28 +02:00
Kconfig firmware_loader: enable XZ by default if compressed support is enabled 2022-06-03 15:46:03 -07:00
main.c firmware_loader: Replace kmap() with kmap_local_page() 2022-07-28 16:32:56 +02:00
Makefile firmware_loader: Add firmware-upload support 2022-04-26 12:34:28 +02:00
sysfs_upload.c firmware_loader: Fix memory leak in firmware upload 2022-09-01 17:47:27 +02:00
sysfs_upload.h firmware_loader: Move definitions from sysfs_upload.h to sysfs.h 2022-04-29 16:49:44 +02:00
sysfs.c firmware_loader: Fix memory leak in firmware upload 2022-09-01 17:47:27 +02:00
sysfs.h firmware_loader: Fix memory leak in firmware upload 2022-09-01 17:47:27 +02:00