From: Andy Shevchenko <andriy.shevchenko@intel.com>
To: jean-baptiste.maneyrol@tdk.com
Cc: "Jonathan Cameron" <jic23@kernel.org>,
"David Lechner" <dlechner@baylibre.com>,
"Nuno Sá" <nuno.sa@analog.com>,
"Andy Shevchenko" <andy@kernel.org>,
linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2] iio: imu: inv_icm42600: add buffer hwfifo watermark attributes
Date: Wed, 24 Jun 2026 14:47:53 +0300 [thread overview]
Message-ID: <ajvD6RtuDaRHoDiH@ashevche-desk.local> (raw)
In-Reply-To: <20260624-inv-icm42600-add-buffer-hwfifo_attributes-v2-1-12675259e688@tdk.com>
On Wed, Jun 24, 2026 at 10:25:46AM +0200, Jean-Baptiste Maneyrol via B4 Relay wrote:
> Add hwfifo_watermark/min/max/enabled buffer attributes.
> Hardware FIFO is always enabled and used.
...
> +++ b/drivers/iio/imu/inv_icm42600/inv_icm42600_buffer.c
> #include <linux/pm_runtime.h>
> #include <linux/regmap.h>
> #include <linux/delay.h>
> +#include <linux/stringify.h>
>
> #include <linux/iio/buffer.h>
> #include <linux/iio/common/inv_sensors_timestamp.h>
> #include <linux/iio/iio.h>
> +#include <linux/iio/sysfs.h>
Since I have another comment below, I would note that the list of inclusions
perhaps needs a preparatory patch to be sorted and regrouped a bit:
<linux/*.h>
...blank line...
<linux/iio/*.h>
...blank line...
<linux/iio/common/inv_*.h> // since it's quite custom but world visible header.
...blank line...
"*.h"
...
> +IIO_STATIC_CONST_DEVICE_ATTR(hwfifo_watermark_min, "1");
> +IIO_STATIC_CONST_DEVICE_ATTR(hwfifo_watermark_max,
> + __stringify(INV_ICM42600_FIFO_WATERMARK_MAX_SAMPLES));
> +static IIO_DEVICE_ATTR(hwfifo_watermark, 0444, inv_icm42600_buffer_get_watermark,
> + NULL, 0);
So, why not IIO_DEVICE_ATTR_RO()?
> +IIO_STATIC_CONST_DEVICE_ATTR(hwfifo_enabled, "1");
--
With Best Regards,
Andy Shevchenko
prev parent reply other threads:[~2026-06-24 11:47 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-06-24 8:25 Jean-Baptiste Maneyrol via B4 Relay
2026-06-24 11:47 ` Andy Shevchenko [this message]
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=ajvD6RtuDaRHoDiH@ashevche-desk.local \
--to=andriy.shevchenko@intel.com \
--cc=andy@kernel.org \
--cc=dlechner@baylibre.com \
--cc=jean-baptiste.maneyrol@tdk.com \
--cc=jic23@kernel.org \
--cc=linux-iio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=nuno.sa@analog.com \
/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®