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: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CABGWkvpDY99-0FKi2VO+Pa4hSoEfFCAt7ZAgaVfeqqCqcOYWrA@mail.gmail.com>
Date: Wed, 23 Jul 2025 08:14:15 +0200
From: Dario Binacchi <dario.binacchi@...rulasolutions.com>
To: Bough Chen <haibo.chen@....com>
Cc: "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>, 
	"linux-amarula@...rulasolutions.com" <linux-amarula@...rulasolutions.com>, Conor Dooley <conor+dt@...nel.org>, 
	Dmitry Torokhov <dmitry.torokhov@...il.com>, Fabio Estevam <festevam@...il.com>, 
	Krzysztof Kozlowski <krzk+dt@...nel.org>, Pengutronix Kernel Team <kernel@...gutronix.de>, 
	Rob Herring <robh@...nel.org>, Sascha Hauer <s.hauer@...gutronix.de>, 
	Shawn Guo <shawnguo@...nel.org>, 
	"devicetree@...r.kernel.org" <devicetree@...r.kernel.org>, "imx@...ts.linux.dev" <imx@...ts.linux.dev>, 
	"linux-arm-kernel@...ts.infradead.org" <linux-arm-kernel@...ts.infradead.org>, 
	"linux-input@...r.kernel.org" <linux-input@...r.kernel.org>
Subject: Re: [PATCH 2/4] dt-bindings: input: touchscreen: fsl,imx6ul-tsc: add fsl,glitch-threshold

Hi Bough,

On Wed, Jul 23, 2025 at 4:45 AM Bough Chen <haibo.chen@....com> wrote:
>
> > -----Original Message-----
> > From: Dario Binacchi <dario.binacchi@...rulasolutions.com>
> > Sent: 2025年7月22日 18:36
> > To: linux-kernel@...r.kernel.org
> > Cc: linux-amarula@...rulasolutions.com; Dario Binacchi
> > <dario.binacchi@...rulasolutions.com>; Conor Dooley
> > <conor+dt@...nel.org>; Dmitry Torokhov <dmitry.torokhov@...il.com>;
> > Fabio Estevam <festevam@...il.com>; Bough Chen <haibo.chen@....com>;
> > Krzysztof Kozlowski <krzk+dt@...nel.org>; Pengutronix Kernel Team
> > <kernel@...gutronix.de>; Rob Herring <robh@...nel.org>; Sascha Hauer
> > <s.hauer@...gutronix.de>; Shawn Guo <shawnguo@...nel.org>;
> > devicetree@...r.kernel.org; imx@...ts.linux.dev;
> > linux-arm-kernel@...ts.infradead.org; linux-input@...r.kernel.org
> > Subject: [PATCH 2/4] dt-bindings: input: touchscreen: fsl,imx6ul-tsc: add
> > fsl,glitch-threshold
> >
> > Add support for glitch threshold configuration. A detected signal is valid only if it
> > lasts longer than the set threshold; otherwise, it is regarded as a glitch.
> >
> > Signed-off-by: Dario Binacchi <dario.binacchi@...rulasolutions.com>
> > ---
> >
> >  .../input/touchscreen/fsl,imx6ul-tsc.yaml      | 18 ++++++++++++++++++
> >  1 file changed, 18 insertions(+)
> >
> > diff --git
> > a/Documentation/devicetree/bindings/input/touchscreen/fsl,imx6ul-tsc.yaml
> > b/Documentation/devicetree/bindings/input/touchscreen/fsl,imx6ul-tsc.yaml
> > index 678756ad0f92..2fee2940213f 100644
> > --- a/Documentation/devicetree/bindings/input/touchscreen/fsl,imx6ul-tsc.yaml
> > +++ b/Documentation/devicetree/bindings/input/touchscreen/fsl,imx6ul-tsc
> > +++ .yaml
> > @@ -62,6 +62,23 @@ properties:
> >      description: Number of data samples which are averaged for each read.
> >      enum: [ 1, 4, 8, 16, 32 ]
> >
> > +  fsl,glitch-threshold:
> > +    $ref: /schemas/types.yaml#/definitions/uint32
> > +    default: 0
>
> Here the default should be 2 according to your third patch.

I considered the default value of the register, not the driver's.
If I'm not mistaken, the dt-bindings should be a description of the
hardware, not of the associated driver implementation.

>
> I'm okay for this patch set, let's waiting for comments about this yaml change.
>
> By the way, any real case which need to use other glitch threshod?

We recently submitted
https://lore.kernel.org/all/aGUDza5XRGDqfz5n@dragon/#t, and in this
initial contribution we removed all the custom parts that are not
supported upstream. This is
one such case. For our board, we need a de_glitch value of 1.

Thanks and regards,
Dario

>
> Regards
> Haibo Chen
>
> > +    enum: [ 0, 1, 2, 3 ]
> > +    description: |
> > +      Indicates the glitch threshold. The threshold is defined by number
> > +      of clock cycles. A detect signal is only valid if it is exist longer
> > +      than threshold; otherwise, it is regarded as a glitch.
> > +      0: Normal function: 8191 clock cycles
> > +         Low power mode: 9 clock cycles
> > +      1: Normal function: 4095 clock cycles
> > +         Low power mode: 7 clock cycles
> > +      2: Normal function: 2047 clock cycles
> > +         Low power mode: 5 clock cycles
> > +      3: Normal function: 1023 clock cycles
> > +         Low power mode: 3 clock cycles
> > +
> >  required:
> >    - compatible
> >    - reg
> > @@ -94,4 +111,5 @@ examples:
> >          measure-delay-time = <0xfff>;
> >          pre-charge-time = <0xffff>;
> >          touchscreen-average-samples = <32>;
> > +        fsl,glitch-threshold = <2>;
> >      };
> > --
> > 2.43.0
>


-- 

Dario Binacchi

Senior Embedded Linux Developer

dario.binacchi@...rulasolutions.com

__________________________________


Amarula Solutions SRL

Via Le Canevare 30, 31100 Treviso, Veneto, IT

T. +39 042 243 5310
info@...rulasolutions.com

www.amarulasolutions.com

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ