summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>2024-06-06 20:29:21 +0300
committerLee Jones <lee@kernel.org>2024-06-26 16:56:05 +0100
commit9ed388d1acb9b8d1136f429573d14ade963ba727 (patch)
treebadd2ee3f92517e252ae689cd50eee54ba5c1db7
parent67b66160bdb266f11ce65003a3e22d0986ad256c (diff)
downloadlwn-9ed388d1acb9b8d1136f429573d14ade963ba727.tar.gz
lwn-9ed388d1acb9b8d1136f429573d14ade963ba727.zip
leds: spi-byte: Utilise temporary variable for struct device
We have a temporary variable to keep a pointer to struct device. Utilise it where it makes sense. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://lore.kernel.org/r/20240606173037.3091598-5-andriy.shevchenko@linux.intel.com Signed-off-by: Lee Jones <lee@kernel.org>
-rw-r--r--drivers/leds/leds-spi-byte.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/leds/leds-spi-byte.c b/drivers/leds/leds-spi-byte.c
index 1fc0a8cc123e..e63958e584c2 100644
--- a/drivers/leds/leds-spi-byte.c
+++ b/drivers/leds/leds-spi-byte.c
@@ -116,7 +116,7 @@ static int spi_byte_probe(struct spi_device *spi)
init_data.devicename = "leds-spi-byte";
init_data.default_label = ":";
- ret = devm_led_classdev_register_ext(&spi->dev, &led->ldev, &init_data);
+ ret = devm_led_classdev_register_ext(dev, &led->ldev, &init_data);
if (ret) {
mutex_destroy(&led->mutex);
return ret;