mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-09-16 07:35:14 +00:00
soundwire: intel: Fix uninitialized adev deref
[ Upstream commit e1c815f4b2
]
In case of error, we can dereference uninitialized 'adev'
drivers/soundwire/intel_init.c:154 sdw_intel_acpi_cb()
error: uninitialized symbol 'adev'.
Fix that by not using adev for warn print and make it pr_err.
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Acked-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Vinod Koul <vkoul@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
parent
4b4153b7d6
commit
030f6397eb
1 changed files with 1 additions and 1 deletions
|
@ -151,7 +151,7 @@ static acpi_status sdw_intel_acpi_cb(acpi_handle handle, u32 level,
|
|||
struct acpi_device *adev;
|
||||
|
||||
if (acpi_bus_get_device(handle, &adev)) {
|
||||
dev_err(&adev->dev, "Couldn't find ACPI handle\n");
|
||||
pr_err("%s: Couldn't find ACPI handle\n", __func__);
|
||||
return AE_NOT_FOUND;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue