summaryrefslogtreecommitdiff
path: root/drivers/spi/spi.c
diff options
context:
space:
mode:
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>2023-03-06 21:29:13 +0300
committerMark Brown <broonie@kernel.org>2023-03-06 21:39:16 +0300
commitc7cc588bf0054ce33a11b98d05859105c046c706 (patch)
tree018fa440aeec9a23d40514ee0131448108582dda /drivers/spi/spi.c
parentb36cecf247157c36aa8f41b5783122820b2c5456 (diff)
downloadlinux-c7cc588bf0054ce33a11b98d05859105c046c706.tar.xz
spi: Propagate firmware node
Propagate firmware node by using a specific API call, i.e. device_set_node(). Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://lore.kernel.org/r/20230306182913.87231-1-andriy.shevchenko@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'drivers/spi/spi.c')
-rw-r--r--drivers/spi/spi.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/spi/spi.c b/drivers/spi/spi.c
index 798030c0c5ce..295d02e7f0a8 100644
--- a/drivers/spi/spi.c
+++ b/drivers/spi/spi.c
@@ -2368,8 +2368,8 @@ of_register_spi_device(struct spi_controller *ctlr, struct device_node *nc)
/* Store a pointer to the node in the device structure */
of_node_get(nc);
- spi->dev.of_node = nc;
- spi->dev.fwnode = of_fwnode_handle(nc);
+
+ device_set_node(&spi->dev, of_fwnode_handle(nc));
/* Register the new device */
rc = spi_add_device(spi);