From: Jonathan Cameron <jic23@kernel.org>
To: Justin Weiss <justin@justinweiss.com>
Cc: "Alex Lanzano" <lanzano.alex@gmail.com>,
"Lars-Peter Clausen" <lars@metafoo.de>,
"Rob Herring" <robh@kernel.org>,
"Krzysztof Kozlowski" <krzk+dt@kernel.org>,
"Conor Dooley" <conor+dt@kernel.org>,
linux-iio@vger.kernel.org, devicetree@vger.kernel.org,
linux-kernel@vger.kernel.org,
"Derek J . Clark" <derekjohn.clark@gmail.com>,
"Philip Müller" <philm@manjaro.org>
Subject: Re: [PATCH v2 5/6] iio: imu: bmi270: Add triggered buffer for Bosch BMI270 IMU
Date: Sat, 19 Oct 2024 12:41:51 +0100 [thread overview]
Message-ID: <20241019124151.54ecaf2a@jic23-huawei> (raw)
In-Reply-To: <20241018233723.28757-6-justin@justinweiss.com>
On Fri, 18 Oct 2024 16:36:11 -0700
Justin Weiss <justin@justinweiss.com> wrote:
> Set up a triggered buffer for the accel and angl_vel values.
>
> Signed-off-by: Justin Weiss <justin@justinweiss.com>
Looks good. One trivial comment inline.
Thanks,
Jonathan
> ---
> drivers/iio/imu/bmi270/Kconfig | 1 +
> drivers/iio/imu/bmi270/bmi270.h | 9 +++++
> drivers/iio/imu/bmi270/bmi270_core.c | 56 ++++++++++++++++++++++++++++
> 3 files changed, 66 insertions(+)
>
> diff --git a/drivers/iio/imu/bmi270/Kconfig b/drivers/iio/imu/bmi270/Kconfig
> index 0ffd29794fda..6362acc706da 100644
> --- a/drivers/iio/imu/bmi270/Kconfig
> +++ b/drivers/iio/imu/bmi270/Kconfig
> @@ -6,6 +6,7 @@
> config BMI270
> tristate
> select IIO_BUFFER
> + select IIO_TRIGGERED_BUFFER
>
> config BMI270_I2C
> tristate "Bosch BMI270 I2C driver"
> diff --git a/drivers/iio/imu/bmi270/bmi270.h b/drivers/iio/imu/bmi270/bmi270.h
> index 51e374fd4290..844d70a7d32e 100644
> --- a/drivers/iio/imu/bmi270/bmi270.h
> +++ b/drivers/iio/imu/bmi270/bmi270.h
> @@ -11,6 +11,15 @@ struct bmi270_data {
> struct device *dev;
> struct regmap *regmap;
> const struct bmi270_chip_info *chip_info;
> +
> + /*
> + * Where IIO_DMA_MINALIGN is larger than 8 bytes, align to that
maybe larger than 8 bytes
on x86_64 I think it is 8 bytes exactly, though I could be remembering that wrong.
> + * to ensure a DMA safe buffer.
> + */
> + struct {
> + __le16 channels[6];
> + aligned_s64 timestamp;
> + } data __aligned(IIO_DMA_MINALIGN);
> };
>
next prev parent reply other threads:[~2024-10-19 11:41 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-10-18 23:36 [PATCH v2 0/6] Add i2c driver for Bosch BMI260 IMU Justin Weiss
2024-10-18 23:36 ` [PATCH v2 1/6] iio: imu: bmi270: Use INFO_SAMP_FREQ instead of INFO_FREQUENCY Justin Weiss
2024-10-19 11:30 ` Jonathan Cameron
2024-10-19 20:48 ` Justin Weiss
2024-10-18 23:36 ` [PATCH v2 2/6] iio: imu: bmi270: Provide chip info as configuration structure Justin Weiss
2024-10-19 11:33 ` Jonathan Cameron
2024-10-19 20:49 ` Justin Weiss
2024-10-18 23:36 ` [PATCH v2 3/6] dt-bindings: iio: imu: Add Bosch BMI260 Justin Weiss
2024-10-19 11:36 ` Jonathan Cameron
2024-10-19 20:49 ` Justin Weiss
2024-10-18 23:36 ` [PATCH v2 4/6] iio: imu: bmi270: Add support for BMI260 Justin Weiss
2024-10-19 11:40 ` Jonathan Cameron
2024-10-19 20:52 ` Justin Weiss
2024-10-20 11:00 ` Jonathan Cameron
2024-10-18 23:36 ` [PATCH v2 5/6] iio: imu: bmi270: Add triggered buffer for Bosch BMI270 IMU Justin Weiss
2024-10-19 11:41 ` Jonathan Cameron [this message]
2024-10-19 20:52 ` Justin Weiss
2024-10-18 23:36 ` [PATCH v2 6/6] iio: imu: bmi270: Add scale and sampling frequency to " Justin Weiss
2024-10-19 11:44 ` Jonathan Cameron
2024-10-19 20:52 ` Justin Weiss
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=20241019124151.54ecaf2a@jic23-huawei \
--to=jic23@kernel.org \
--cc=conor+dt@kernel.org \
--cc=derekjohn.clark@gmail.com \
--cc=devicetree@vger.kernel.org \
--cc=justin@justinweiss.com \
--cc=krzk+dt@kernel.org \
--cc=lanzano.alex@gmail.com \
--cc=lars@metafoo.de \
--cc=linux-iio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=philm@manjaro.org \
--cc=robh@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;
as well as URLs for NNTP newsgroup(s).