From: Andrea Merello Date: Mon, 9 Sep 2019 12:58:17 +0000 (+0200) Subject: iio: max31856: add missing of_node and parent references to iio_dev X-Git-Tag: v5.15~5053^2~250^2~28 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=505ea3ada665c466d0064b11b6e611b7f995517d;p=platform%2Fkernel%2Flinux-starfive.git iio: max31856: add missing of_node and parent references to iio_dev Adding missing indio_dev->dev.of_node references so that, in case multiple max31856 are present, users can get some clues to being able to distinguish each of them. While at it, add also the missing parent reference. Signed-off-by: Andrea Merello Signed-off-by: Jonathan Cameron --- diff --git a/drivers/iio/temperature/max31856.c b/drivers/iio/temperature/max31856.c index f184ba5..73ed550 100644 --- a/drivers/iio/temperature/max31856.c +++ b/drivers/iio/temperature/max31856.c @@ -284,6 +284,8 @@ static int max31856_probe(struct spi_device *spi) spi_set_drvdata(spi, indio_dev); indio_dev->info = &max31856_info; + indio_dev->dev.parent = &spi->dev; + indio_dev->dev.of_node = spi->dev.of_node; indio_dev->name = id->name; indio_dev->modes = INDIO_DIRECT_MODE; indio_dev->channels = max31856_channels;