diff options
author | Rafael J. Wysocki | 2022-02-01 21:05:59 +0100 |
---|---|---|
committer | Mark Brown | 2022-02-02 16:09:28 +0000 |
commit | 7030c428fae100c339436f5cb6f9e7c0574097ad (patch) | |
tree | 720e123b94d085aef8a54b80a401f290c5766689 /drivers/spi | |
parent | 3e9cea48296e8150906fd40180ccec2e5de8275c (diff) |
spi: Replace acpi_bus_get_device()
Replace acpi_bus_get_device() that is going to be dropped with
acpi_fetch_acpi_dev().
No intentional functional impact.
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Link: https://lore.kernel.org/r/2231987.ElGaqSPkdT@kreacher
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'drivers/spi')
-rw-r--r-- | drivers/spi/spi.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/spi/spi.c b/drivers/spi/spi.c index ec9f2ed579e3..c98c55f44ee6 100644 --- a/drivers/spi/spi.c +++ b/drivers/spi/spi.c @@ -2585,10 +2585,10 @@ static acpi_status acpi_register_spi_device(struct spi_controller *ctlr, static acpi_status acpi_spi_add_device(acpi_handle handle, u32 level, void *data, void **return_value) { + struct acpi_device *adev = acpi_fetch_acpi_dev(handle); struct spi_controller *ctlr = data; - struct acpi_device *adev; - if (acpi_bus_get_device(handle, &adev)) + if (!adev) return AE_OK; return acpi_register_spi_device(ctlr, adev); |