The Linux Kernel Mailing List
 help / color / mirror / Atom feed
* [PATCH] iio: accel: bmc150: use IIO_DECLARE_BUFFER_WITH_TS
@ 2026-08-08 22:02 Yash Suthar
  2026-08-08 22:35 ` David Lechner
  2026-08-09  5:54 ` [PATCH v2] " Yash Suthar
  0 siblings, 2 replies; 7+ messages in thread
From: Yash Suthar @ 2026-08-08 22:02 UTC (permalink / raw)
  To: Jonathan Cameron
  Cc: David Lechner, Nuno Sá, Andy Shevchenko, linux-iio,
	linux-kernel, Yash Suthar

Replace bmc150_accel_data plain buffer with
IIO_DECLARE_BUFFER_WITH_TS() that also keep
timestamp aligned.

Signed-off-by: Yash Suthar <yashsuthar983@gmail.com>
---
 drivers/iio/accel/bmc150-accel.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/iio/accel/bmc150-accel.h b/drivers/iio/accel/bmc150-accel.h
index e8f26198359f..e0773533efeb 100644
--- a/drivers/iio/accel/bmc150-accel.h
+++ b/drivers/iio/accel/bmc150-accel.h
@@ -64,7 +64,7 @@ struct bmc150_accel_data {
 	struct bmc150_accel_trigger triggers[BMC150_ACCEL_TRIGGERS];
 	struct mutex mutex;
 	u8 fifo_mode, watermark;
-	s16 buffer[8];
+	IIO_DECLARE_BUFFER_WITH_TS(s16, buffer, 3);
 	/*
 	 * Ensure there is sufficient space and correct alignment for
 	 * the timestamp if enabled
-- 
2.43.0


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

end of thread, other threads:[~2026-08-10 21:58 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-08-08 22:02 [PATCH] iio: accel: bmc150: use IIO_DECLARE_BUFFER_WITH_TS Yash Suthar
2026-08-08 22:35 ` David Lechner
2026-08-09  5:54 ` [PATCH v2] " Yash Suthar
2026-08-09 22:59   ` Jonathan Cameron
2026-08-09 23:18     ` Jonathan Cameron
2026-08-10  9:00       ` Andy Shevchenko
2026-08-10 21:58       ` Yash Suthar

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox