Re: [PATCH v8 2/7] arm64: dts: imx8mm: imx8mp: Add LVDS DTOs for Data Modul i.MX8M Mini and Plus eDM SBC

[email protected] Thu, 30 Jul 2026 22:58:02 +0000
Newsgroups dev.linux.lists.imx,org.kernel.vger.linux-devicetree
Message-ID <[email protected]>
Thank you for your contribution! Sashiko AI review found 2 potential issue(s) to consider:
- [Medium] The G215HVN011 panel overlay hardcodes the adapter-specific backlight enable pin, breaking the backlight on the i.MX8MP native LVDS adapter.
- [Low] The documented MP2328 voltage divider formulas and resistor values mathematically contradict the claimed output voltages, risking hardware damage if copied.
--

--- Patch [2]: [PATCH v8 2/7] arm64: dts: imx8mm: imx8mp: Add LVDS DTOs for Data Modul i.MX8M Mini and Plus eDM SBC ---
commit 7f9fe59083c08b9930a9101dbccb23e4a6fbf244
Author: Marek Vasut <[email protected]>

arm64: dts: imx8mm: imx8mp: Add LVDS DTOs for Data Modul i.MX8M Mini and Plus eDM SBC

Add DT overlay for the DSI-to-LVDS adapter eDM-MOD-iMX8Mm-LVDS populated
with Lontium LT9211 bridge. This adapter can be optionally populated onto
the eDM SBC. This adapter can be extended with multiple panels.

> diff --git a/arch/arm64/boot/dts/freescale/imx8mm-data-modul-edm-sbc-overlay-lvds-g215hvn011.dtsi b/arch/arm64/boot/dts/freescale/imx8mm-data-modul-edm-sbc-overlay-lvds-g215hvn011.dtsi
> new file mode 100644
> index 0000000000000..3585170bd59dd
> --- /dev/null
> +++ b/arch/arm64/boot/dts/freescale/imx8mm-data-modul-edm-sbc-overlay-lvds-g215hvn011.dtsi
> @@ -0,0 +1,30 @@
[ ... ]
> +&backlight {
> +	pinctrl-names = "default";
> +	pinctrl-0 = <&pinctrl_panel_backlight>;
> +	enable-gpios = <&gpio3 0 GPIO_ACTIVE_HIGH>;
> +	/* 6.5 POWER ON/OFF SEQUENCE, T6 >= 10 ms */
[ ... ]
> diff --git a/arch/arm64/boot/dts/freescale/imx8mp-data-modul-edm-sbc-overlay-edm-sbc-imx8mp-lvds-g215hvn011.dtso b/arch/arm64/boot/dts/freescale/imx8mp-data-modul-edm-sbc-overlay-edm-sbc-imx8mp-lvds-g215hvn011.dtso
> new file mode 100644
> index 0000000000000..a6d13c3609796
> --- /dev/null
> +++ b/arch/arm64/boot/dts/freescale/imx8mp-data-modul-edm-sbc-overlay-edm-sbc-imx8mp-lvds-g215hvn011.dtso
> @@ -0,0 +1,36 @@
[ ... ]
> +#include "imx8mp-data-modul-edm-sbc-overlay-edm-sbc-imx8mp-lvds.dtsi"
> +#include "imx8mm-data-modul-edm-sbc-overlay-lvds-g215hvn011.dtsi"
> +
> +&backlight {
> +	power-supply = <&reg_panel_bl_supply>;
> +};

[Severity: Medium]
Will this hardcoded adapter-specific backlight enable pin break the backlight
on the i.MX8MP native LVDS adapter?

By setting enable-gpios = <&gpio3 0 GPIO_ACTIVE_HIGH>; in
imx8mm-data-modul-edm-sbc-overlay-lvds-g215hvn011.dtsi, the adapter-specific
gpio3 0 pin configuration leaks into the generic panel configuration.

Because the native adapter overlay
(imx8mp-data-modul-edm-sbc-overlay-edm-sbc-imx8mp-lvds-g215hvn011.dtso)
includes this generic panel file but fails to override enable-gpios
(to <&gpiowifi 0 GPIO_ACTIVE_HIGH>) and remove pinctrl-0, the native adapter
inherits the incorrect gpio3 0 pin, which may leave the backlight off.

> diff --git a/arch/arm64/boot/dts/freescale/imx8mp-data-modul-edm-sbc-overlay-edm-sbc-imx8mp-lvds.dtsi b/arch/arm64/boot/dts/freescale/imx8mp-data-modul-edm-sbc-overlay-edm-sbc-imx8mp-lvds.dtsi
> new file mode 100644
> index 0000000000000..b06af369a9245
> --- /dev/null
> +++ b/arch/arm64/boot/dts/freescale/imx8mp-data-modul-edm-sbc-overlay-edm-sbc-imx8mp-lvds.dtsi
> @@ -0,0 +1,79 @@
[ ... ]
> +	reg_panel_bl_supply: regulator-panel-bl-supply {
[ ... ]
> +		/*
> +		 * MP2328 voltage divider settings:
> +		 *   R1=51k1
> +		 *   R2=5k62 with optional series Rs=2k21 (12V)
> +		 *
> +		 * 1 / Rx = (1 / R2) [ + (1 / Rs)][ + (1 / Rt)]
> +		 * Vout = 0.5 + ((R1 / Rx) * 0.5)
> +		 */

[Severity: Low]
Is this mathematical formula for the MP2328 correct?

For the 12V backlight supply, calculating Rx in parallel (1/Rx = 1/R2 + 1/Rs)
using R1=51.1k, R2=5.62k, and Rs=2.21k yields Rx=1.586k.

Applying that to Vout = 0.5 + ((51.1k / 1.586k) * 0.5) gives approximately
16.6V, not 12V.

To achieve 12V, Rx needs to be exactly 2.21k, which means Rs would have to
replace R2 rather than run in parallel with it. Is it possible the formula
was copied from the AP63300 comment without updating the calculation method?

-- 
Sashiko AI review ยท https://sashiko.dev/#/patchset/[email protected]?part=2