From: Marek Belisko <marek@goldelico.com>
To: jic23@kernel.org, gregkh@linuxfoundation.org
Cc: linux-iio@vger.kernel.org, devel@driverdev.osuosl.org,
linux-kernel@vger.kernel.org, hns@goldelico.com,
Marek Belisko <marek@goldelico.com>
Subject: [PATCH] staging: iio: hmc5843: Set iio name property in sysfs
Date: Sat, 28 Feb 2015 21:54:42 +0100 [thread overview]
Message-ID: <1425156882-27691-1-git-send-email-marek@goldelico.com> (raw)
Without this change file name for hmc5843 is empty in
/sys/bus/iio/devices/iio\:device*/name
With this change name is reported correctly:
cat /sys/bus/iio/devices/iio\:device*/name
hmc5843
Signed-off-by: Marek Belisko <marek@goldelico.com>
---
drivers/staging/iio/magnetometer/hmc5843_core.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/staging/iio/magnetometer/hmc5843_core.c b/drivers/staging/iio/magnetometer/hmc5843_core.c
index fd171d8..90cc18b 100644
--- a/drivers/staging/iio/magnetometer/hmc5843_core.c
+++ b/drivers/staging/iio/magnetometer/hmc5843_core.c
@@ -592,6 +592,7 @@ int hmc5843_common_probe(struct device *dev, struct regmap *regmap,
mutex_init(&data->lock);
indio_dev->dev.parent = dev;
+ indio_dev->name = dev->driver->name;
indio_dev->info = &hmc5843_info;
indio_dev->modes = INDIO_DIRECT_MODE;
indio_dev->channels = data->variant->channels;
--
1.9.1
next reply other threads:[~2015-02-28 20:54 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-02-28 20:54 Marek Belisko [this message]
2015-03-08 11:28 ` Jonathan Cameron
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1425156882-27691-1-git-send-email-marek@goldelico.com \
--to=marek@goldelico.com \
--cc=devel@driverdev.osuosl.org \
--cc=gregkh@linuxfoundation.org \
--cc=hns@goldelico.com \
--cc=jic23@kernel.org \
--cc=linux-iio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®