From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 4FCEC8F49; Fri, 18 Apr 2025 14:46:51 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1744987612; cv=none; b=RTQ4NrlY9Yl/GgBwoolfEtwUsXKPzZarRXwQmHisDoQwi+8CbBgxjbFYXo2qzLGk84loyWswlLrj9mXuVGpVijg7DjoZrkZKCLUhmT1e1WImk8q+TUDkKpAWHDK7sNwt1llM6yRDaWDschBBf2lBfEah38f7bfU+HNhAA9/sxUc= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1744987612; c=relaxed/simple; bh=5a8es+dGqoWzvZRG72BP+Tii3vAYyV3WD+yVJH2N8VY=; h=Date:From:To:Cc:Subject:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=F5EfmwuHE8eE6LLQnsg0SewoztCCCMnn++wdZOyGyWFJUP5KdZb80f2jEa4bWGbf3A6s4iqWU+EnoA0asu3fObYnSHK83QC9/GymJsZ/NL3SfovgOMzQ2iziw0SFtjRl7SWlO7eYw2gd0La/gkdVxb8OVjdzSEGQVEwjqKcXwr0= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=u0lo+pyc; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="u0lo+pyc" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 3BF95C4CEE2; Fri, 18 Apr 2025 14:46:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1744987611; bh=5a8es+dGqoWzvZRG72BP+Tii3vAYyV3WD+yVJH2N8VY=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=u0lo+pyc59zklEQ1VhjL78cRV7IzRREb/PqeQuX7c7lN1UI0U6opronFmJqw03IFH qhi8w8Su/KbAxKHSZSa0TpDLoOvOxJ+q+O903X156V/QOUV6EHHmknLm6gx9BdoxuS ji+0epLMGJXSShNJPDKLkl5C1xs8gaMvEzQ0T5XXmdtMu16L6id8bUerk/6I1F3FuE JiNdpRIth/fye2jEFhLedT419xj3EpRh6aLgzPLwemKjy4m0WNq9U8RPROR86x1hMu 8lAQbXPKqNGautan0WAWHrXvdxsYUwAXsiWLj+BOOS2Q50XhhrX7UBBT6dEjMsiqeH puBa/EeMfdF/Q== Date: Fri, 18 Apr 2025 15:46:42 +0100 From: Jonathan Cameron To: Nuno =?UTF-8?B?U8Oh?= Cc: David Lechner , Nuno =?UTF-8?B?U8Oh?= , Andy Shevchenko , Matthias Brugger , AngeloGioacchino Del Regno , Lars-Peter Clausen , Michael Hennerich , Cosmin Tanislav , Tomasz Duszynski , Jean-Baptiste Maneyrol , Andreas Klinger , Petre Rodan , linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org Subject: Re: [PATCH 3/8] iio: addac: ad74413r: use aligned_s64 for timestamp Message-ID: <20250418154642.41cb9d80@jic23-huawei> In-Reply-To: <057bec6375819c3a4cd227c20a60ec1dbb7405c3.camel@gmail.com> References: <20250417-iio-more-timestamp-alignment-v1-0-eafac1e22318@baylibre.com> <20250417-iio-more-timestamp-alignment-v1-3-eafac1e22318@baylibre.com> <057bec6375819c3a4cd227c20a60ec1dbb7405c3.camel@gmail.com> X-Mailer: Claws Mail 4.3.0 (GTK 3.24.48; x86_64-pc-linux-gnu) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On Fri, 18 Apr 2025 09:57:38 +0100 Nuno S=C3=A1 wrote: > On Thu, 2025-04-17 at 11:52 -0500, David Lechner wrote: > > Follow the pattern of other drivers and use aligned_s64 for the > > timestamp. Technically there was no issue here since > > AD74413R_FRAME_SIZE * AD74413R_CHANNEL_MAX =3D=3D 16 and IIO_DMA_MINALI= GN > > is always a multiple of 8. But best to conform in case someone copies > > this to new code and then tweaks something. > >=20 > > Also move the unaligned.h header while touching this since it was the > > only one not in alphabetical order. > >=20 > > Signed-off-by: David Lechner > > --- =20 >=20 > Reviewed-by: Nuno S=C3=A1 Applied. >=20 > > =C2=A0drivers/iio/addac/ad74413r.c | 5 +++-- > > =C2=A01 file changed, 3 insertions(+), 2 deletions(-) > >=20 > > diff --git a/drivers/iio/addac/ad74413r.c b/drivers/iio/addac/ad74413r.c > > index > > f0929616ab899cb374f00869787321eed4ccde16..a0bb1dbcb7ad9d02337d0990e5a3f= 90be7eaa4ac > > 100644 > > --- a/drivers/iio/addac/ad74413r.c > > +++ b/drivers/iio/addac/ad74413r.c > > @@ -4,7 +4,6 @@ > > =C2=A0 * Author: Cosmin Tanislav > > =C2=A0 */ > > =C2=A0 > > -#include > > =C2=A0#include > > =C2=A0#include > > =C2=A0#include > > @@ -24,6 +23,8 @@ > > =C2=A0#include > > =C2=A0#include > > =C2=A0#include > > +#include > > +#include > > =C2=A0 > > =C2=A0#include > > =C2=A0 > > @@ -84,7 +85,7 @@ struct ad74413r_state { > > =C2=A0 */ > > =C2=A0 struct { > > =C2=A0 u8 rx_buf[AD74413R_FRAME_SIZE * AD74413R_CHANNEL_MAX]; > > - s64 timestamp; > > + aligned_s64 timestamp; > > =C2=A0 } adc_samples_buf __aligned(IIO_DMA_MINALIGN); > > =C2=A0 > > =C2=A0 u8 adc_samples_tx_buf[AD74413R_FRAME_SIZE * AD74413R_CHANNEL_MAX= ]; > > =20 >=20