linux-iio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH -next] iio: st_accel: Fix unused variable warning
@ 2019-11-01 13:47 YueHaibing
  2019-11-02 10:41 ` Ladislav Michl
  2019-11-11  3:21 ` [PATCH v2 " YueHaibing
  0 siblings, 2 replies; 10+ messages in thread
From: YueHaibing @ 2019-11-01 13:47 UTC (permalink / raw)
  To: jic23, knaack.h, lars, pmeerw, denis.ciocca, yuehaibing,
	rfontana, tglx, heiko.stuebner, rjones, drake, colin.king
  Cc: linux-iio, linux-kernel

drivers/iio/accel/st_accel_core.c:1005:44: warning:
 mount_matrix_ext_info defined but not used [-Wunused-const-variable=]

Move it to ifdef to mute this warning.

Signed-off-by: YueHaibing <yuehaibing@huawei.com>
---
 drivers/iio/accel/st_accel_core.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/iio/accel/st_accel_core.c b/drivers/iio/accel/st_accel_core.c
index 2e37f8a..bba0717 100644
--- a/drivers/iio/accel/st_accel_core.c
+++ b/drivers/iio/accel/st_accel_core.c
@@ -1002,10 +1002,12 @@ get_mount_matrix(const struct iio_dev *indio_dev,
 	return adata->mount_matrix;
 }
 
+#ifdef CONFIG_ACPI
 static const struct iio_chan_spec_ext_info mount_matrix_ext_info[] = {
 	IIO_MOUNT_MATRIX(IIO_SHARED_BY_ALL, get_mount_matrix),
 	{ },
 };
+#endif
 
 /* Read ST-specific _ONT orientation data from ACPI and generate an
  * appropriate mount matrix.
-- 
2.7.4



^ permalink raw reply related	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2019-11-18  1:41 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-11-01 13:47 [PATCH -next] iio: st_accel: Fix unused variable warning YueHaibing
2019-11-02 10:41 ` Ladislav Michl
2019-11-02 14:08   ` Jonathan Cameron
2019-11-02 20:15     ` Ladislav Michl
2019-11-03 11:01       ` Jonathan Cameron
2019-11-04  1:29       ` Yuehaibing
2019-11-09 11:50         ` Jonathan Cameron
2019-11-11  3:21 ` [PATCH v2 " YueHaibing
2019-11-16 14:58   ` Jonathan Cameron
2019-11-18  1:41     ` Yuehaibing

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).