Commit fa7e9a15 authored by Ben Skeggs's avatar Ben Skeggs Committed by Greg Kroah-Hartman
Browse files

drm/nouveau/gsp: fix potential leak of memory used during acpi init



[ Upstream commit d133036a ]

If any of the ACPI calls fail, memory allocated for the input buffer
would be leaked.  Fix failure paths to free allocated memory.

Also add checks to ensure the allocations succeeded in the first place.

Reported-by: default avatarDanilo Krummrich <dakr@kernel.org>
Fixes: 176fdcbd ("drm/nouveau/gsp/r535: add support for booting GSP-RM")
Signed-off-by: default avatarBen Skeggs <bskeggs@nvidia.com>
Signed-off-by: default avatarDanilo Krummrich <dakr@kernel.org>
Link: https://lore.kernel.org/r/20250617040036.2932-1-bskeggs@nvidia.com


Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
parent 06c56637
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment