linux-iio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Gwendal Grignou <gwendal@chromium.org>
To: Jonathan Cameron <jic23@kernel.org>
Cc: linux-iio <linux-iio@vger.kernel.org>,
	Jonathan Cameron <Jonathan.Cameron@huawei.com>
Subject: Re: [PATCH 06/11] iio: cros_ec_sensors: Fix alignment of buffer in iio_push_to_buffers_with_timestamp()
Date: Sat, 1 May 2021 16:58:21 -0700	[thread overview]
Message-ID: <CAPUE2uv7dX8kArmA76bLQ0DQmd=F_Obsv54KZGVcbFfC-aRC1g@mail.gmail.com> (raw)
In-Reply-To: <20210501171352.512953-7-jic23@kernel.org>

Fixes tag is correct up to kernel stable 4.18.
Before, the include file to fix is
drivers/iio/common/cros_ec_sensors/cros_ec_sensors_core.h:
commit 974e6f02e27 ("iio: cros_ec_sensors_core: Add common functions
for the ChromeOS EC Sensor Hub.") present since kernel stable 4.10.

Reviewed-by: Gwendal Grignou <gwendal@chromium.org

On Sat, May 1, 2021 at 10:15 AM Jonathan Cameron <jic23@kernel.org> wrote:
>
> From: Jonathan Cameron <Jonathan.Cameron@huawei.com>
>
> The samples buffer is passed to iio_push_to_buffers_with_timestamp()
> which requires a buffer aligned to 8 bytes as it is assumed that
> the timestamp will be naturally aligned if present.
>
> Fixes tag is inaccurate but prior to that likely manual backporting needed.
>
> Fixes: 5a0b8cb46624c ("iio: cros_ec: Move cros_ec_sensors_core.h in /include")
> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> Cc: Gwendal Grignou <gwendal@chromium.org>
> ---
>  include/linux/iio/common/cros_ec_sensors_core.h | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/include/linux/iio/common/cros_ec_sensors_core.h b/include/linux/iio/common/cros_ec_sensors_core.h
> index 7ce8a8adad58..c582e1a14232 100644
> --- a/include/linux/iio/common/cros_ec_sensors_core.h
> +++ b/include/linux/iio/common/cros_ec_sensors_core.h
> @@ -77,7 +77,7 @@ struct cros_ec_sensors_core_state {
>                 u16 scale;
>         } calib[CROS_EC_SENSOR_MAX_AXIS];
>         s8 sign[CROS_EC_SENSOR_MAX_AXIS];
> -       u8 samples[CROS_EC_SAMPLE_SIZE];
> +       u8 samples[CROS_EC_SAMPLE_SIZE] __aligned(8);
>
>         int (*read_ec_sensors_data)(struct iio_dev *indio_dev,
>                                     unsigned long scan_mask, s16 *data);
> --
> 2.31.1
>

  reply	other threads:[~2021-05-01 23:58 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-01 17:13 [PATCH 00/11] IIO: Alignment fixes part 3 - __aligned(8) used to ensure alignment Jonathan Cameron
2021-05-01 17:13 ` [PATCH 01/11] iio: adc: at91-sama5d2: Fix buffer alignment in iio_push_to_buffers_with_timestamp() Jonathan Cameron
2021-05-26 17:23   ` Eugen.Hristev
2021-05-27  8:48     ` Jonathan Cameron
2021-05-01 17:13 ` [PATCH 02/11] iio: adc: hx711: " Jonathan Cameron
2021-05-01 17:13 ` [PATCH 03/11] iio: adc: mxs-lradc: " Jonathan Cameron
2021-05-01 17:13 ` [PATCH 04/11] iio: adc: ti-ads8688: Fix alignment of buffer " Jonathan Cameron
2021-05-01 17:13 ` [PATCH 05/11] iio: chemical: atlas: Fix buffer alignment " Jonathan Cameron
2021-05-06  6:44   ` Matt Ranostay
2021-05-13 17:59     ` Jonathan Cameron
2021-05-01 17:13 ` [PATCH 06/11] iio: cros_ec_sensors: Fix alignment of buffer " Jonathan Cameron
2021-05-01 23:58   ` Gwendal Grignou [this message]
2021-05-13 18:03     ` Jonathan Cameron
2021-05-01 17:13 ` [PATCH 07/11] iio: potentiostat: lmp91000: " Jonathan Cameron
2021-05-06  6:44   ` Matt Ranostay
2021-05-13 18:04     ` Jonathan Cameron
2021-05-01 17:13 ` [PATCH 08/11] iio: magn: rm3100: " Jonathan Cameron
2021-05-01 17:13 ` [PATCH 09/11] iio: light: vcnl4000: Fix buffer alignment " Jonathan Cameron
2021-05-01 17:13 ` [PATCH 10/11] iio: light: vcnl4035: " Jonathan Cameron
2021-05-01 17:13 ` [PATCH 11/11] iio: prox: isl29501: " Jonathan Cameron
2021-05-13 17:58 ` [PATCH 00/11] IIO: Alignment fixes part 3 - __aligned(8) used to ensure alignment Jonathan Cameron
2021-05-26 17:09   ` Jonathan Cameron
2021-05-26 17:17     ` Andy Shevchenko

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='CAPUE2uv7dX8kArmA76bLQ0DQmd=F_Obsv54KZGVcbFfC-aRC1g@mail.gmail.com' \
    --to=gwendal@chromium.org \
    --cc=Jonathan.Cameron@huawei.com \
    --cc=jic23@kernel.org \
    --cc=linux-iio@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;
as well as URLs for NNTP newsgroup(s).