lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20250525104411.7108bfe3@jic23-huawei>
Date: Sun, 25 May 2025 10:44:11 +0100
From: Jonathan Cameron <jic23@...nel.org>
To: Jonathan Santos <jonath4nns@...il.com>
Cc: 4843ec52-57e2-418a-b640-8e05ba60959e@...libre.com, David Lechner
 <dlechner@...libre.com>,
 1aff0f813bb3fee55c5483be860b6885abdb81e5.1747175187.git.Jonathan.Santos@...log.com,
 Jonathan Santos <Jonathan.Santos@...log.com>, linux-iio@...r.kernel.org,
 devicetree@...r.kernel.org, linux-kernel@...r.kernel.org,
 linux-gpio@...r.kernel.org, andy@...nel.org, nuno.sa@...log.com,
 Michael.Hennerich@...log.com, marcelo.schmitt@...log.com, robh@...nel.org,
 krzk+dt@...nel.org, conor+dt@...nel.org, marcelo.schmitt1@...il.com,
 linus.walleij@...aro.org, brgl@...ev.pl, lgirdwood@...il.com,
 broonie@...nel.org, Pop Paul <paul.pop@...log.com>
Subject: Re: [PATCH v8 10/11] iio: adc: ad7768-1: add filter type and
 oversampling ratio attributes

On Mon, 19 May 2025 19:31:30 -0300
Jonathan Santos <jonath4nns@...il.com> wrote:

> On 05/19, David Lechner wrote:
> > On 5/19/25 12:13 PM, Jonathan Santos wrote:  
> > > On 05/15, Jonathan Santos wrote:  
> > 
> > ...  
> > >> +
> > >> +/* Decimation Rate range for each filter type */
> > >> +static const int ad7768_dec_rate_range[][3] = {
> > >> +	[AD7768_FILTER_SINC5] = { 8, 8, 1024 },
> > >> +	[AD7768_FILTER_SINC3] = { 32, 32, 163840 },
> > >> +	[AD7768_FILTER_WIDEBAND] = { 32, 32, 1024 },
> > >> +	[AD7768_FILTER_SINC3_REJ60] = { 32, 32, 163840 },
> > >> +};
> > >> +  
> > > 
> > > Since we're still discussing some points — is the `step` in 
> > > `[min step max]` for the IIO range additive or multiplicative? It is not 
> > > clear on documentation, maybe on purpose or I have missed something.
> > > 
> > > Here, decimation/OSR doubles from 8 or 32 for SINC5/WIDEBAND, and is a 
> > > multiple of 32 for SINC3. So I'm still unsure how to represent this to be
> > > clear to the user.  

Ah.  Indeed. It is intended to be additive. Good catch.

> > 
> > Sounds to me like sinc5/wideband should be lists instead of ranges.
> > It is only 6 values.  
> 
> So can we mix lists and ranges for the same attribute? I see that this
> is not usual.

Should be fine to mix. Userspace should never be assuming one or the other anyway.
I guess maybe some pretty tool might change how it presents the data depending
on what it sees in the first entry?  Do we know of any tool this would trip up?

Jonathan

> 
> > 
> >   


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ