Re: [PATCH v6 4/4] arm64: dts: qcom: Add Lenovo ThinkBook 16 G7 QOY device tree
From: Konrad Dybcio
Date: Sat Jun 14 2025 - 15:39:47 EST
On 6/7/25 9:19 PM, Jens Glathe via B4 Relay wrote:
> From: Jens Glathe <jens.glathe@xxxxxxxxxxxxxxxxxxxxxx>
>
> Device tree for the Lenovo Thinkbook 16 G7 QOY
>
> The Laptop is a Snapdragon X1 / X1 Plus (Purwa) based device [1].
>
> Supported features:
>
> - USB type-c and type-a ports
> - Keyboard
> - Touchpad (all that are described in the dsdt)
> - Touchscreen (described in the dsdt, no known SKUss)
> - Display including PWM backlight control
> - PCIe devices
> - nvme
> - SDHC card reader
> - ath12k WCN7850 Wifi and Bluetooth
> - ADSP and CDSP
> - GPIO keys (Lid switch)
> - Sound via internal speakers / DMIC / USB / headphone jack
> - DP Altmode with 2 lanes (as all of these still do)
> - Integrated fingerprint reader (FPC)
> - Integrated UVC camera
>
> Not supported yet:
>
> - HDMI port.
> - EC and some fn hotkeys.
>
> Limited support yet:
>
> - SDHC card reader is based on the on-chip sdhc_2 controller, but the driver from
> the Snapdragon Dev Kit is only a partial match. It can do normal slow sd cards,
> but not UHS-I (SD104) and UHS-II.
>
> - The GPU is not yet supported. Graphics is only software rendered.
>
> This work was done without any schematics or non-public knowledge of the device.
> So, it is based on the existing x1e device trees, dsdt analysis, using HWInfo
> ARM64, and pure guesswork. It has been confirmed, however, that the device really
> has 4 NXP PTN3222 eUSB2 repeaters, one of which doesn't have a reset GPIO (eusb5
> @43).
>
> Signed-off-by: Jens Glathe <jens.glathe@xxxxxxxxxxxxxxxxxxxxxx>
> Co-developed by: Aleksandrs Vinarskis <alex.vinarskis@xxxxxxxxx>
> ---
[...]
> +
> + pinctrl-names = "default";
> + pinctrl-0 = <&wcd_default>;
property-n
property-names
please
[...]
> + /*
> + * This is an odd one. The camera is physically behind the eusb9 repeater (confirmed) but
> + * if it is placed below the usb_2_dwc3 node, it will be switched of after ~30 seconds.
> + * The whole reason it is described in the dt (as an USB device) is its requirement for
> + * that additional regulator, and to get power management to switch it off when suspended.
> + * Defining it stand-alone does work.
> + */
Looks like DWC3 only does of_platform_populate() ("probe drivers for
child nodes") in drd.c, and your dt sets everything to host-only..
[...]
> +&tlmm {
> + gpio-reserved-ranges = <34 2>, /* Unused */
> + <72 2>, /* Secure EC I2C connection (?) */
> + <238 1>; /* UFS Reset */
Please align the '<'s
Konrad