linux/drivers/platform/x86/amd/pmf
Cong Liu a692a86efe platform/x86/amd/pmf: Fix memory leak in amd_pmf_get_pb_data()
amd_pmf_get_pb_data() will allocate memory for the policy buffer,
but does not free it if copy_from_user() fails. This leads to a memory
leak.

Fixes: 10817f28e5 ("platform/x86/amd/pmf: Add capability to sideload of policy binary")
Reviewed-by: Shyam Sundar S K <Shyam-sundar.S-k@amd.com>
Signed-off-by: Cong Liu <liucong2@kylinos.cn>
Link: https://lore.kernel.org/r/20240124012939.6550-1-liucong2@kylinos.cn
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2024-01-26 20:12:16 +01:00
..
acpi.c platform/x86/amd/pmf: Return a status code only as a constant in two functions 2024-01-02 13:32:22 +01:00
auto-mode.c platform/x86/amd/pmf: Add PMF debug facilities 2023-05-15 15:18:03 +02:00
cnqf.c platform/x86/amd/pmf: Use str_on_off() helper 2023-08-21 15:20:28 +02:00
core.c platform/x86/amd/pmf: change amd_pmf_init_features() call sequence 2023-12-18 12:47:46 +01:00
Kconfig platform/x86/amd/pmf: Get Human presence information from AMD SFH driver 2024-01-26 20:09:41 +01:00
Makefile platform/x86/amd/pmf: Add support to get inputs from other subsystems 2023-12-18 12:47:46 +01:00
pmf.h platform/x86/amd/pmf: Add capability to sideload of policy binary 2023-12-18 13:00:16 +01:00
spc.c platform/x86/amd/pmf: Get ambient light information from AMD SFH driver 2024-01-26 20:12:05 +01:00
sps.c platform/x86/amd/pmf: Make source_as_str() as non-static 2023-12-18 12:47:46 +01:00
tee-if.c platform/x86/amd/pmf: Fix memory leak in amd_pmf_get_pb_data() 2024-01-26 20:12:16 +01:00