kernel_samsung_a53x/drivers/acpi
Jonathan Cameron bf6acb113e ACPI: processor: Fix memory leaks in error paths of processor_add()
[ Upstream commit 47ec9b417ed9b6b8ec2a941cd84d9de62adc358a ]

If acpi_processor_get_info() returned an error, pr and the associated
pr->throttling.shared_cpu_map were leaked.

The unwind code was in the wrong order wrt to setup, relying on
some unwind actions having no affect (clearing variables that were
never set etc).  That makes it harder to reason about so reorder
and add appropriate labels to only undo what was actually set up
in the first place.

Acked-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Reviewed-by: Gavin Shan <gshan@redhat.com>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Link: https://lore.kernel.org/r/20240529133446.28446-6-Jonathan.Cameron@huawei.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-11-23 23:21:08 +01:00
..
acpica ACPICA: Revert "ACPICA: avoid Info: mapping multiple BARs. Your kernel is fine." 2024-11-19 14:19:09 +01:00
apei ACPI: APEI: set memory failure flags as MF_ACTION_REQUIRED on synchronous events 2024-11-18 12:13:09 +01:00
arm64 Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
dptf Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
nfit Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
numa Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
pmic Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
x86 ACPI: x86: Force StorageD3Enable on more products 2024-11-19 14:19:30 +01:00
ac.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
acpi_adxl.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
acpi_amba.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
acpi_apd.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
acpi_cmos_rtc.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
acpi_configfs.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
acpi_dbg.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
acpi_extlog.c ACPI: extlog: fix NULL pointer dereference check 2024-11-18 12:13:09 +01:00
acpi_ipmi.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
acpi_lpat.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
acpi_lpit.c ACPI: LPIT: Avoid u32 multiplication overflow 2024-11-18 12:12:20 +01:00
acpi_lpss.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
acpi_memhotplug.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
acpi_pad.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
acpi_platform.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
acpi_pnp.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
acpi_processor.c ACPI: processor: Fix memory leaks in error paths of processor_add() 2024-11-23 23:21:08 +01:00
acpi_tad.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
acpi_video.c ACPI: video: Add quirk for the Colorful X15 AT 23 Laptop 2024-11-18 12:13:09 +01:00
acpi_watchdog.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
battery.c ACPI: battery: create alarm sysfs attribute atomically 2024-11-23 23:20:23 +01:00
bgrt.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
blacklist.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
bus.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
button.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
container.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
cppc_acpi.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
custom_method.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
debugfs.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
device_pm.c ACPI: Add quirks for AMD Renoir/Lucienne CPUs to force the D3 hint 2024-11-19 14:19:30 +01:00
device_sysfs.c ACPI: sysfs: Fix create_pnp_modalias() and create_of_modalias() 2024-11-18 11:42:50 +01:00
dock.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
ec.c ACPI: EC: Avoid returning AE_OK on errors in address space handler 2024-11-19 14:19:46 +01:00
ec_sys.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
event.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
evged.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
fan.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
fan.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
glue.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
hed.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
internal.h ACPI: Add quirks for AMD Renoir/Lucienne CPUs to force the D3 hint 2024-11-19 14:19:30 +01:00
ioapic.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
irq.c ACPI: irq: Fix incorrect return value in acpi_register_gsi() 2024-11-08 11:26:19 +01:00
Kconfig Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
Makefile Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
nvs.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
osi.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
osl.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
pci_irq.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
pci_link.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
pci_mcfg.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
pci_root.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
pci_slot.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
power.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
pptt.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
proc.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
processor_core.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
processor_driver.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
processor_idle.c ACPI: processor_idle: Fix invalid comparison with insertion sort for latency 2024-11-19 14:19:50 +01:00
processor_pdc.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
processor_perflib.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
processor_thermal.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
processor_throttling.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
property.c acpi: property: Let args be NULL in __acpi_node_get_property_reference 2024-11-18 12:12:49 +01:00
reboot.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
resource.c ACPI: resource: Do IRQ override on TongFang GXxHRXx and GMxHGxx 2024-11-19 12:27:13 +01:00
sbs.c ACPI: SBS: manage alarm sysfs attribute through psy core 2024-11-23 23:20:23 +01:00
sbshc.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
sbshc.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
scan.c ACPI: scan: Fix device check notification handling 2024-11-19 08:44:47 +01:00
sleep.c Revert "ACPI: PM: Block ASUS B1400CEAE from suspend to idle by default" 2024-11-19 09:23:14 +01:00
sleep.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
spcr.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
sysfs.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
tables.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
thermal.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
tiny-power-button.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
utils.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
video_detect.c ACPI: video: Add backlight=native quirk for Lenovo Slim 7 16ARH7 2024-11-19 14:19:06 +01:00
wakeup.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00