From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-dy1-f180.google.com (mail-dy1-f180.google.com [74.125.82.180]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 5934C2853E0 for ; Wed, 25 Mar 2026 14:56:36 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=74.125.82.180 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1774450597; cv=none; b=MUVeQTGFtIp1ICcOmUVpBKNNlZ0IcR1WsxGlsAHXtgYzbAZgf4pCzLcNJ4fC/CLSycKDcRNhGr2OAg8JJhUDGKIHQ6B4Kp6ENTR0DgCy0YzN8RxjZGa9VAmVCbO8C0B8HtZ0wJ30wul+scRHaJglErc9EGd4fvaMuHPk/xOmDaw= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1774450597; c=relaxed/simple; bh=p4Z+LkdfxNMxnSbynDgzXYzNKdDdBUjsPk5nyBozNS4=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=CoNZqkj3LP0XUyr1PN6TIhqzcgURLJMix146Yzppz2NxRgMlQm35mEeBEDMSXIZCELL3M8xRem+avo39uA2k24qD7PUYp223/sYUp+lrH9CWowEhg0ImRdSpuoL13+xG6k2HsuSD5/yTxpO59sFVSdOxzR7HNpt+XN8E34cRGEA= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=iv9lj16r; arc=none smtp.client-ip=74.125.82.180 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="iv9lj16r" Received: by mail-dy1-f180.google.com with SMTP id 5a478bee46e88-2b6b0500e06so8070343eec.1 for ; Wed, 25 Mar 2026 07:56:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1774450595; x=1775055395; darn=vger.kernel.org; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=4wLnGR0a4kOSYaA+zKfjvV1Pl1oVPkgUObtZwH/qq2M=; b=iv9lj16rcDDZ03mf9pM1tNkYiUd0ZkCcJaKoV5oZfimX2KcwiZSCLwrNS++KVI+xh+ CbBPtRAOtP9HDTcPWHjjkavclaWWzuArpczTXyIqGQJUUbJ2RkzlUg92oWK3fEotnkHF 0dafgzDsifZvVkZPbCNUiCr0sgPnPYw6q1VIpCkc/eeHYfYbVPV++EGMBHyaVG4spfDg kKn0SWrJV4uJs+FSTM4FLg0C9tydi/QGhYjil3ngQtixJloVoX5vZ3IEgXZqqRWDuXy6 42Dape+qVldnY35hXz8DAZ5JVlwGvX6Ke5DEAI9uXC5U1PG/14Sh0Gcs8K2xOf0Vq2Ep re4g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1774450595; x=1775055395; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-gg:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=4wLnGR0a4kOSYaA+zKfjvV1Pl1oVPkgUObtZwH/qq2M=; b=Anq9yhaXa6HjHQyKJlhvalehN0splWJEy8b0XcVmC6bGBBvlpkf/mBncEzABRNvgwQ I2/uxu6x5tQHwIm6WV1s7juOYhgfel9eMj2havI+z2n7RPbI+7QcIbtYkFy1vpoBGTtP bjwM/nJ5G7EeXJ72tZlOTpCnaIU++05gwNq2/F2QnV9D0SOFEHYx26Gqkki5cxGMco11 q6HLWoYc+SozfZcYgOk43zznMBhd110I+1Oostfp7nm3OHu7RhiZXfSfISECFSwC0z9P kgggKHIbMXykMHu7kWmPPtyMnJYNvv+b4vfIgGrlFnEv0NSrLjs44HtLv6wpQSAaSnmu CNrw== X-Forwarded-Encrypted: i=1; AJvYcCX6B3Tjt8EG+TUPSBZpecJrf/2TcfqTi487QGZv68J0Qo1etOb2eN7wcAQPz8J/UQ8ATjrPTJOe+54s4Hc=@vger.kernel.org X-Gm-Message-State: AOJu0YwQEZC1I5kJlssRs6YzT8CP/gX+l0u3BlLoz9DKai+MUrWAAC+z 6Ie1oaFrLvRubqUhsmG0UjQDKz1dJCKICdtimfqNAtsOCZrpGov58mDac8yN/A== X-Gm-Gg: ATEYQzz7unxb2oUykaGmXlmVhaZuDgRty0GzXnq5uq73Kv2V2Zw1YMZFuKriWinkFpJ 1N7jpOi+gN5laLwYItiMGKrCb8XrpwIjjZPKh+gic1nc0kYpwO0GKCdIw7jRoKB5piHHJFkIEm2 cZiAotxsFY8yg/BWGgRMwuj8jmlLyfErroJdtmOrbcFYC2+CmBKXr3BLg958p0d+d0ljsSNcm/P HhyLlWSrveDEuSs70VSpgkEWKjUZTICY9qkVeNyl5tYq5TuLOTPqWbv+MZkCd5bHdvCfyZ5LqUv jrbXgUjAVOd8xN4QX10c1YhKzK7Ybqd2fc2OZdgg748FLayoFtuHZ4wZ+81Lm0BijApe8yZc0KG APwETQNP+GZAzxr1ZJAVW/vcdtBJUgDOHnKpwb/234U3whRye+ce5Y3hFUYE0g9LT15NZUCMfpE 9U8/f2As86YAjNnHuUR2kEhd3fmbZoM/cDrgF+UH5OKcjo7wynCEI040iQUWbfQ58l X-Received: by 2002:a05:7300:b505:b0:2c0:d04c:a6a6 with SMTP id 5a478bee46e88-2c15d296064mr1960160eec.6.1774450595217; Wed, 25 Mar 2026 07:56:35 -0700 (PDT) Received: from google.com ([2a00:79e0:2ebe:8:a686:fd7f:70d3:9156]) by smtp.gmail.com with ESMTPSA id 5a478bee46e88-2c10b14c99bsm18578637eec.1.2026.03.25.07.56.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 25 Mar 2026 07:56:34 -0700 (PDT) Date: Wed, 25 Mar 2026 07:56:31 -0700 From: Dmitry Torokhov To: Jonathan Cameron Cc: David Lechner , Nuno =?utf-8?B?U8Oh?= , Andy Shevchenko , linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v2] iio: adc: ti-ads7950: use iio_push_to_buffers_with_ts_unaligned() Message-ID: References: <20260314-iio-adc-ti-ads7950-declare-dma-buffer-v2-1-2087fc18b077@baylibre.com> <20260321210539.2de04bc0@jic23-huawei> 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=us-ascii Content-Disposition: inline In-Reply-To: On Sun, Mar 22, 2026 at 03:30:21PM -0700, Dmitry Torokhov wrote: > On Sat, Mar 21, 2026 at 09:05:39PM +0000, Jonathan Cameron wrote: > > On Sat, 14 Mar 2026 16:12:24 -0500 > > David Lechner wrote: > > > > > Use iio_push_to_buffers_with_ts_unaligned() to avoid unaligned access > > > when writing the timestamp in the rx_buf. > > > > > > The previous implementation would have been fine on architectures that > > > support 4-byte alignment of 64-bit integers but could cause issues on > > > architectures that require 8-byte alignment. > > > > > > Fixes: 902c4b2446d4 ("iio: adc: New driver for TI ADS7950 chips") > > > Signed-off-by: David Lechner > > > --- > > > Since we were looking at this driver, I was going to convert this to use > > > IIO_DECLARE_DMA_BUFFER_WITH_TS() but then I noticed that we actually > > > have an unaligned access problem with the timestamp since we are > > > ignoring the first two elements in the rx_buf when pushing the data to > > > the buffer. > > > > > > Unfortunately, this will cause a merge conflict with the series Dmitry > > > is working on. I don't think there is any rush to get this backported > > > since no one has reported a crash from unaligned access. Since fixes > > > should go before improvements, we could apply this to iio/togreg then > > > Dmitry can rebase his series on top of it. > > I've done that. Applied to the togreg branch of iio.git pushed out as > > testing etc. I've also marked it for stable so it gets picked up in the long > > run. > > Cool, I'll rebase and send out my patches as soon as this hits > linux-next. Hm, I only see it in "testing", not in "togreg"... -- Dmitry