All of lore.kernel.org
 help / color / mirror / Atom feed
From: sashiko-bot@kernel.org
To: "Bob Hui" <bg9oxa@163.com>
Cc: conor+dt@kernel.org, devicetree@vger.kernel.org, robh@kernel.org
Subject: Re: [PATCH v7 2/2] arm64: dts: rockchip: Add ALIENTEK QuarkPi-CA2
Date: Tue, 06 Oct 2026 17:20:47 +0000	[thread overview]
Message-ID: <sashiko-outbox-162297@kernel.org> (raw)
In-Reply-To: <20261007-quarkpi-ca2-v7-v7-2-a84c6d5d6ef6@163.com>

Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [High] dts: missing enable-active-high in vcc_3v3_sd_s0 inverts SD card power
--

commit 4624c6a23d34c30caad9b329d1a8fc7579634e41
Author: Bob Hui <bg9oxa@163.com>

arm64: dts: rockchip: Add ALIENTEK QuarkPi-CA2

This commit adds a device tree for the ALIENTEK QuarkPi-CA2, an RK3588S
based card computer. The board supports variants with different amounts
of LPDDR4X and eMMC. Various peripherals are configured including SDRAM,
eMMC, PMIC, Ethernet, HDMI, USB, and audio components.

> diff --git a/arch/arm64/boot/dts/rockchip/rk3588s-quarkpi-ca2.dts b/arch/arm64/boot/dts/rockchip/rk3588s-quarkpi-ca2.dts
> new file mode 100644
> index 0000000000000..d81b96d8daec0
> --- /dev/null
> +++ b/arch/arm64/boot/dts/rockchip/rk3588s-quarkpi-ca2.dts
[ ... ]
> +	vcc_3v3_sd_s0: regulator-vcc-3v3-sd-s0 {
> +		compatible = "regulator-fixed";
> +		gpios = <&gpio0 RK_PA0 GPIO_ACTIVE_HIGH>;
> +		pinctrl-names = "default";
> +		pinctrl-0 = <&sd_s0_pwr>;
> +		regulator-name = "vcc_3v3_sd_s0";
> +		regulator-min-microvolt = <3300000>;
> +		regulator-max-microvolt = <3300000>;
> +		vin-supply = <&vcc_3v3_s3>;
> +	};

[Severity: High]
Does this configuration invert the SD card power polarity?

The vcc_3v3_sd_s0 fixed regulator specifies gpios = <&gpio0 RK_PA0
GPIO_ACTIVE_HIGH> but omits the enable-active-high property. In
drivers/gpio/gpiolib-of.c, of_gpio_set_polarity_by_property() checks for
the presence of enable-active-high on regulator-fixed compatible nodes.

Because it is missing, of_gpio_quirk_polarity() evaluates active_high as
false and forcibly adds the OF_GPIO_ACTIVE_LOW flag to the internal GPIO
descriptor. This actively overrides the GPIO_ACTIVE_HIGH phandle flag
and emits an 'enforce active low on GPIO handle' message.

When the SDMMC driver subsequently calls regulator_enable(), the fixed
regulator driver sets a logical '1', which gpiolib translates to a physical
LOW signal due to the inverted polarity. Will this physically cut power to
the SD card when the driver attempts to enable it?

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20261007-quarkpi-ca2-v7-v7-0-a84c6d5d6ef6@163.com?part=2

      reply	other threads:[~2026-10-06 17:20 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-06 17:06 [PATCH v7 0/2] arm64: dts: rockchip: Add ALIENTEK QuarkPi-CA2 Bob Hui
2026-10-06 17:06 ` Bob Hui
2026-10-06 17:06 ` [PATCH v7 1/2] dt-bindings: arm: " Bob Hui
2026-10-06 17:06   ` Bob Hui
2026-10-07 10:14   ` Conor Dooley
2026-10-07 10:14     ` Conor Dooley
2026-10-06 17:06 ` [PATCH v7 2/2] arm64: dts: " Bob Hui
2026-10-06 17:06   ` Bob Hui
2026-10-06 17:20   ` sashiko-bot [this message]

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=sashiko-outbox-162297@kernel.org \
    --to=sashiko-bot@kernel.org \
    --cc=bg9oxa@163.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.