Devicetree
 help / color / mirror / Atom feed
From: sashiko-bot@kernel.org
To: "Coia Prant" <coiaprant@gmail.com>
Cc: robh@kernel.org, conor+dt@kernel.org, devicetree@vger.kernel.org
Subject: Re: [PATCH v5 3/3] arm64: dts: rockchip: Add devicetree for the Graperain G3568 v2
Date: Thu, 02 Jul 2026 20:57:03 +0000	[thread overview]
Message-ID: <20260702205704.059411F000E9@smtp.kernel.org> (raw)
In-Reply-To: <20260702204628.2407308-5-coiaprant@gmail.com>

Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Medium] Incorrect ADC key threshold definitions lead to mapping collisions, causing the MENU button to be registered as ESC.
--

commit fe49d935384ac01dd829b914e2d8c0b5c9cffcdb
Author: Coia Prant <coiaprant@gmail.com>

arm64: dts: rockchip: Add devicetree for the Graperain G3568 v2

This commit introduces devicetree support for the Graperain G3568 v2
development board. It defines the hardware configuration including networking,
storage, multimedia, and ADC buttons.

Link: https://image.chukouplus.com/upload/C_153/product_file/20211022/6daddec9e400458816dd4c57ba807fc3.pdf
Link: https://blog.gov.cooking/archives/research-graperain-g3568-v2-and-flash.html

> diff --git a/arch/arm64/boot/dts/rockchip/rk3568-graperain-g3568-v2.dts b/arch/arm64/boot/dts/rockchip/rk3568-graperain-g3568-v2.dts
> new file mode 100644
> index 0000000000000..9705e1c5a98a9
> --- /dev/null
> +++ b/arch/arm64/boot/dts/rockchip/rk3568-graperain-g3568-v2.dts

[ ... ]

> +	adc-keys {
> +		compatible = "adc-keys";
> +		io-channels = <&saradc 0>;
> +		io-channel-names = "buttons";
> +		keyup-threshold-microvolt = <1800000>;
> +		poll-interval = <100>;
> +
> +		button-esc {
> +			label = "esc";
> +			linux,code = <KEY_ESC>;
> +			press-threshold-microvolt = <1250000>;
> +		};
> +
> +		button-menu {
> +			label = "menu";
> +			linux,code = <KEY_MENU>;
> +			press-threshold-microvolt = <1600000>;
> +		};

[Severity: Medium]
Will this configuration cause the MENU button to be incorrectly registered as
an ESC button press?

The commit message states the MENU button generates 1400k µV and the ESC
button generates 1100k µV. Since the adc-keys driver computes the distance to
all thresholds and selects the closest one, a 1400mV physical signal is
closer to the ESC threshold (1250mV, a 150mV difference) than the MENU
threshold (1600mV, a 200mV difference).

Could these press-threshold-microvolt definitions be adjusted to ensure the
generated hardware voltage aligns accurately with its intended target?

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20260702204628.2407308-2-coiaprant@gmail.com?part=3

  reply	other threads:[~2026-07-02 20:57 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-02 20:46 [PATCH v5 0/3] Add devicetree for the Graperain G3568 v2 Coia Prant
2026-07-02 20:46 ` [PATCH v5 1/3] dt-bindings: vendor-prefixes: Add graperain Coia Prant
2026-07-02 20:46 ` [PATCH v5 2/3] dt-bindings: arm: rockchip: Add Graperain G3568 series Coia Prant
2026-07-02 20:46 ` [PATCH v5 3/3] arm64: dts: rockchip: Add devicetree for the Graperain G3568 v2 Coia Prant
2026-07-02 20:57   ` sashiko-bot [this message]
2026-07-02 21:08   ` Andrew Lunn

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=20260702205704.059411F000E9@smtp.kernel.org \
    --to=sashiko-bot@kernel.org \
    --cc=coiaprant@gmail.com \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=robh@kernel.org \
    --cc=sashiko-reviews@lists.linux.dev \
    /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