From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-wm1-f47.google.com (mail-wm1-f47.google.com [209.85.128.47]) (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 8D7503EAC75 for ; Thu, 18 Jun 2026 10:37:37 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.47 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1781779060; cv=none; b=ebe3cQ3Hgbkxdz5HiaoQnm1Dza/y8+uyqiItfcm04+ue3DXY+AE18OTIcDdQov6h98Nj1tEkTRSrkfAEAqKza9lGZv/mA0u8siZ3KxR+BPgfDBYYefm4KP84JFhxdGBRT95so3pLO1SSdQt7jlxrJqCWatrE225bhgLOQ61hNwQ= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1781779060; c=relaxed/simple; bh=WaatnYQzAn1y5alEj6OiK/0aXjq78txcoSV151CVOB8=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=mExPGfFl6LiBilsKjfqZ4558E5ZzgbvtpnqjoRO5qTQtCjg1V5fza1X7LIVsaWLKqjKzsKy9bvxa2ZsU5AfVwTuH5usCvnKl3YAXuDFleNtaqEcKfyDTa3qG3saeRH8fy7w0XhJPHXUzYBwrkfoBpVE3yX1bTtQqzKDp63hu32A= 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=o4Ard0Q8; arc=none smtp.client-ip=209.85.128.47 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="o4Ard0Q8" Received: by mail-wm1-f47.google.com with SMTP id 5b1f17b1804b1-490b1bbcf3aso4461485e9.1 for ; Thu, 18 Jun 2026 03:37:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1781779056; x=1782383856; darn=vger.kernel.org; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:message-id:subject:cc:to:from:date:from:to :cc:subject:date:message-id:reply-to; bh=xwEhTrq+qTzF8O+m1hCZfz1bJ+2UVVplvdeiwcSgpIs=; b=o4Ard0Q8G9T7KU+xO8QykTPVkQazez8iME+f9zZs9sn0uPq4XE8pQ4famyIRHt/0Lz SfJsZzbnLEn3+GJEvHcLLyyWTqF330Eu1jPKnL3HQYJB83SYTeSqQnKDWVPFtjjyBfhw 37rhBHzRGs6TBfvPvK7yv7X9e1rFsN8aiyW0QeqjcTlWergFMGBqTIjN3OnFuxqnRc// +cXioGmT3oEyblCMUIaB3h5LWNY3AT0Taqz6uU6GrTiVrgm1xk4p5kEitf6Fa8Oqn2jW em4gRVJcw3YFuIXCO8wUPfGQwf0CckGJkNJON0TkYOApe/ItBqaa+8w7SgsMtM9qZ0sn EOwA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1781779056; x=1782383856; h=in-reply-to:content-transfer-encoding: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=xwEhTrq+qTzF8O+m1hCZfz1bJ+2UVVplvdeiwcSgpIs=; b=MrsTPLXmL+SmGz5YasykHzfKBGnn9oGb2pL3Uw3dqSbwAEegRBRTp1l2/aprXO48YB I9lFNQJBnXfTfwkLMwKnKXbGBSoCC664STUBKWt0z3jkX81YUN8R89SG2Xx+DzXWbDZK HarXUOIsaiRgrXQeqd/yPTPCjTAkjdtcWlFq3HLi/39Fa1rIRJYtKHx6X7KuL+YB4/qC 3ZjKOuI6aAjMSrYcCBzeydeZtteBhYv6QOu1wt6/rQs1epkC05J3q9RoWqd1SRP0j2Qf JTTrvPqtWKq6pALDE6YVQ60Jqeh7OHmjJh0/pK75O4oDfYVUL96ts+/2gl+U2g3MyOXm HHJA== X-Forwarded-Encrypted: i=1; AFNElJ+YLYqm+Mm77aDWfy4p4Pg3Jmrl9m5fSjCPoS1E38NsukZPZyVmUfHSinwZ19OH+N3aHoybcisha5BOTzY=@vger.kernel.org X-Gm-Message-State: AOJu0YznIMz7N1cc/M0UodAo11dmPoWvdewpaLnDvsB6nW9jJwrW3OWF 1aaiDBEyr3WHfQFp36WdEQLxwS/hKk6GgnkeI+H2/AREzm8Rm3Pd9Kya X-Gm-Gg: AfdE7clBDZG4jlCnE+rjHGR/loLCYQ0ZTtehZ1Fi0UulJAEzolzGMZeeSzGFTbTDElE V3vQxxWlHniB5JiY3GFB8X4az9TLL+ywnqStGGPnmgwH5nZ2pp1eh6YWuz0rG/dZRlWL3LadrGw Z/8WPGMiPaNZ/13arjBEv/LHx0716oSc4DSs2wMLJga7GP9Z3svPe37b3HDV+9HQCNbvX7tRn71 SkxeTtg0Sa1vU7HrBqX6kkMgSLeGQoJIrKcz5B6+sdilPW42SulV3NffbN/XeAWJG6EAHcd2PWI LPTuot+khZj0Z9S4x1swnG8Rer73Oc2MnnZEpIyO48xtzcV66y0H9YaPoDjcznwlFObF9HbP2Ie xnK48XNjn+D0Z4zMWHQoB5p80EBAhyjod60Fe2bY8mPSqD0ij0GBF+YW20vE73Whyn5/jts46nr EhLrUC X-Received: by 2002:a05:600c:a010:b0:492:329e:528 with SMTP id 5b1f17b1804b1-4923a9d5c61mr21645925e9.23.1781779055452; Thu, 18 Jun 2026 03:37:35 -0700 (PDT) Received: from nsa ([148.63.225.166]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-4923a154446sm26041375e9.0.2026.06.18.03.37.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 18 Jun 2026 03:37:35 -0700 (PDT) Date: Thu, 18 Jun 2026 11:38:37 +0100 From: Nuno =?utf-8?B?U8Oh?= To: David Lechner Cc: Marcelo Schmitt , linux-iio@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, jic23@kernel.org, nuno.sa@analog.com, Michael.Hennerich@analog.com, andy@kernel.org, robh@kernel.org, krzk+dt@kernel.org, conor+dt@kernel.org, pop.ioan-daniel@analog.com, marcelo.schmitt1@gmail.com Subject: Re: [RFC PATCH v3 3/5] iio: buffer: Extend DMAengine buffer interfaces to take extra sysfs attributes Message-ID: References: <3b96ec10-b022-4135-9ade-6fd9eb6e78a6@baylibre.com> 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-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <3b96ec10-b022-4135-9ade-6fd9eb6e78a6@baylibre.com> On Wed, Jun 17, 2026 at 04:43:18PM -0500, David Lechner wrote: > On 6/16/26 9:03 PM, Marcelo Schmitt wrote: > > Some devices using DMAengine buffers are connected to extra hardware that > > allows setting how fast data is transferred to/from the buffer. However, > > those extra pieces of harwdware are external to the sensor chip such that > > supporting the transfer speed as a sensor property is a bit of an > > inaccuracy. Expand IIO DMAengine buffer interfaces to take arguments for > > extra sysfs attributes, enabling the transfer speed to be configured > > through the buffer interface. > > This message is a bit confusing. It sounds like it is attempting to > control something about the DMA controller itself. But based on the > later patches, it looks like this is just so we can add arbitrary > sysfs attributes to the bufferX directory. And in this specific case, > a sampling_frequency attribute. Agreed. Seems like rate control comes from the buffer. > > > > > Signed-off-by: Marcelo Schmitt > > --- > > New patch. > > > > Now that I've come to this buffer "solution", I have pretty much convinced > > myself it would be better to instead have some sort of IIO trigger to control > > the signal source connected to SPI offloading trigger module. > > > In the other chips with SPI offload we've done already, we just used > IIO_CHAN_INFO_SAMP_FREQ to control the SPI offload trigger rate. > Any reason why we can't do that here? In the original SPI offload > discussions, IIRC the general consensus was that adding a trigger > just to control that was overkill when I suggested the same. > I tend to agree with David. Even if we come to a conclusion that we can't use IIO_CHAN_INFO_SAMP_FREQ to control the trigger rate, I'm not really convinced sysfs interfaces on the buffer itself are the place for this. - Nuno Sá