public inbox for devicetree@vger.kernel.org
 help / color / mirror / Atom feed
From: Jonathan Cameron <jic23@kernel.org>
To: Gwendal Grignou <gwendal@chromium.org>
Cc: robh+dt@kernel.org, swboyd@chromium.org,
	linux-iio@vger.kernel.org, devicetree@vger.kernel.org
Subject: Re: [PATCH v5 07/10] dt-bindings: iio: sx9324: Add input analog gain
Date: Sat, 4 Jun 2022 17:23:57 +0100	[thread overview]
Message-ID: <20220604172357.6621e674@jic23-huawei> (raw)
In-Reply-To: <CAPUE2utjhjLiXyASp5kuM9E67xeKztjtH6JJxNzGqtv3anaafQ@mail.gmail.com>

On Mon, 9 May 2022 22:48:26 -0700
Gwendal Grignou <gwendal@chromium.org> wrote:

> On Sun, May 1, 2022 at 10:09 AM Jonathan Cameron <jic23@kernel.org> wrote:
> >
> > On Fri, 29 Apr 2022 15:01:41 -0700
> > Gwendal Grignou <gwendal@chromium.org> wrote:
> >  
> > > Allow setting the configure the input analog gain.
> > >
> > > Signed-off-by: Gwendal Grignou <gwendal@chromium.org>  
> >
> > Hi Gwendal.
> >
> > So, my immediate thought on this is whether it make sense as a
> > dt controlled thing or not. It's the sort of thing hardwaregain
> > is for in the userspace ABI. However, I see that's already
> > in use for the digital gain. This one also unhelpfully applies
> > to all changes whereas the digital gain is pair wise. Hence
> > there is basically no way we can map the two controls to a
> > single ABI element.
> >
> > So, how would we expect a board designer to set this value?
> >
> > If the answer is we basically have no idea but some boards do
> > want it set then I'm fine with this basically being a somewhat magic
> > value that is in some vague way associated with the antenna setup...  
> More or less :-). All these parameters are set with the help of
> Semtech application engineers. The input analog gain is directly
> linked to the antenna design, as it is used by the AFE (Analog Front
> End). The hardwaregain (aka digital gain) comes second during the
> digital processing. We could have put all the settings in the device
> tree, as we don't expect changes once the values are satisfactory to
> pass regulatory testings, but the hybrid approach still allows some
> tinkering: I've use to get a sense of the data amplitude when
> collecting data with /dev/iio:devoceX.

Fair enough. Applied,

Thanks,

Jonathan

> >
> > Jonathan
> >  
> > > ---
> > > New in v5.
> > >
> > >  .../bindings/iio/proximity/semtech,sx9324.yaml        | 11 +++++++++++
> > >  1 file changed, 11 insertions(+)
> > >
> > > diff --git a/Documentation/devicetree/bindings/iio/proximity/semtech,sx9324.yaml b/Documentation/devicetree/bindings/iio/proximity/semtech,sx9324.yaml
> > > index 0be87ac05b97a..d265eb5258c84 100644
> > > --- a/Documentation/devicetree/bindings/iio/proximity/semtech,sx9324.yaml
> > > +++ b/Documentation/devicetree/bindings/iio/proximity/semtech,sx9324.yaml
> > > @@ -143,6 +143,17 @@ properties:
> > >      description:
> > >        Pre-charge input resistance in Ohm.
> > >
> > > +  semtech,input-analog-gain:
> > > +    $ref: /schemas/types.yaml#/definitions/uint32
> > > +    minimum: 0
> > > +    maximum: 3
> > > +    description: |
> > > +      Defines the input antenna analog gain
> > > +      0: x1.247
> > > +      1: x1 (default)
> > > +      2: x0.768
> > > +      3: x0.552
> > > +
> > >  required:
> > >    - compatible
> > >    - reg  
> >  


  reply	other threads:[~2022-06-04 16:15 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-04-29 22:01 [PATCH v4 00/10] iio: sx9324/9360: Add settings for precharge, gain and internal resistor Gwendal Grignou
2022-04-29 22:01 ` [PATCH v5 01/10] iio: sx9324: Fix default precharge internal resistance register Gwendal Grignou
2022-04-29 22:01 ` [PATCH v5 02/10] iio: sx9324: Fix register field spelling Gwendal Grignou
2022-06-04 16:19   ` Jonathan Cameron
2022-04-29 22:01 ` [PATCH v5 03/10] dt-bindings: iio: sx9324: Add precharge resistor setting Gwendal Grignou
2022-06-04 16:20   ` Jonathan Cameron
2022-04-29 22:01 ` [PATCH v5 04/10] iio: sx9324: Add precharge internal resistance setting Gwendal Grignou
2022-06-04 16:21   ` Jonathan Cameron
2022-04-29 22:01 ` [PATCH v5 05/10] dt-bindings: iio: sx9324: Add internal compensation resistor setting Gwendal Grignou
2022-06-04 16:22   ` Jonathan Cameron
2022-04-29 22:01 ` [PATCH v5 06/10] iio: sx9324: Add Setting for internal compensation resistor Gwendal Grignou
2022-04-29 22:01 ` [PATCH v5 07/10] dt-bindings: iio: sx9324: Add input analog gain Gwendal Grignou
2022-05-01 17:17   ` Jonathan Cameron
2022-05-10  5:48     ` Gwendal Grignou
2022-06-04 16:23       ` Jonathan Cameron [this message]
2022-05-03 18:02   ` Rob Herring
2022-05-03 19:10   ` Stephen Boyd
2022-04-29 22:01 ` [PATCH v5 08/10] iio: sx9324: Add Setting for internal " Gwendal Grignou
2022-05-03 19:12   ` Stephen Boyd
2022-06-04 16:25     ` Jonathan Cameron
2022-04-29 22:01 ` [PATCH v5 09/10] dt-bindings: iio: sx9360: Add precharge resistor setting Gwendal Grignou
2022-05-03 18:03   ` Rob Herring
2022-06-04 16:25     ` Jonathan Cameron
2022-04-29 22:01 ` [PATCH v5 10/10] iio: sx9360: Add pre-charge " Gwendal Grignou
2022-06-04 16:26   ` Jonathan Cameron
2022-05-01 17:20 ` [PATCH v4 00/10] iio: sx9324/9360: Add settings for precharge, gain and internal resistor Jonathan Cameron

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=20220604172357.6621e674@jic23-huawei \
    --to=jic23@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=gwendal@chromium.org \
    --cc=linux-iio@vger.kernel.org \
    --cc=robh+dt@kernel.org \
    --cc=swboyd@chromium.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