The eDP controller has an HPD GPIO. Describe it in the device tree
for the generic T14s model, as the HPD GPIO is used in both the
OLED and LCD models which inherit this device tree.
Signed-off-by: Christopher Obbard <christopher.obbard@linaro.org>
---
arch/arm64/boot/dts/qcom/x1e78100-lenovo-thinkpad-t14s.dtsi | 3 +++
arch/arm64/boot/dts/qcom/x1e80100.dtsi | 5 +++++
2 files changed, 8 insertions(+)
diff --git a/arch/arm64/boot/dts/qcom/x1e78100-lenovo-thinkpad-t14s.dtsi b/arch/arm64/boot/dts/qcom/x1e78100-lenovo-thinkpad-t14s.dtsi
index ac1dddf27da30e6a9f7e1d1ecbd5192bf2d0671e..c33dce6fec6746cc7fe2f7a1ab5e9f99feea5535 100644
--- a/arch/arm64/boot/dts/qcom/x1e78100-lenovo-thinkpad-t14s.dtsi
+++ b/arch/arm64/boot/dts/qcom/x1e78100-lenovo-thinkpad-t14s.dtsi
@@ -1008,6 +1008,9 @@ &mdss_dp1_out {
&mdss_dp3 {
/delete-property/ #sound-dai-cells;
+ pinctrl-names = "default";
+ pinctrl-0 = <&edp_hpd_active>;
+
status = "okay";
aux-bus {
diff --git a/arch/arm64/boot/dts/qcom/x1e80100.dtsi b/arch/arm64/boot/dts/qcom/x1e80100.dtsi
index 5e9a8fa3cf96468b12775f91192cbd779d5ce946..8efd045af778beb30831f3af5ad2b901a72d87d7 100644
--- a/arch/arm64/boot/dts/qcom/x1e80100.dtsi
+++ b/arch/arm64/boot/dts/qcom/x1e80100.dtsi
@@ -5779,6 +5779,11 @@ tlmm: pinctrl@f100000 {
gpio-ranges = <&tlmm 0 0 239>;
wakeup-parent = <&pdc>;
+ edp_hpd_active: edp-hpd-active-state {
+ pins = "gpio119";
+ function = "edp0_hot";
+ };
+
qup_i2c0_data_clk: qup-i2c0-data-clk-state {
/* SDA, SCL */
pins = "gpio0", "gpio1";
--
2.50.1
On Thu, Jul 31, 2025 at 09:51:26PM +0100, Christopher Obbard wrote: > The eDP controller has an HPD GPIO. Describe it in the device tree > for the generic T14s model, as the HPD GPIO is used in both the > OLED and LCD models which inherit this device tree. > @@ -5779,6 +5779,11 @@ tlmm: pinctrl@f100000 { > gpio-ranges = <&tlmm 0 0 239>; > wakeup-parent = <&pdc>; > > + edp_hpd_active: edp-hpd-active-state { The node name and label needs an index as this SoC has two edp hpd pins as I already pointed out. > + pins = "gpio119"; > + function = "edp0_hot"; And you also need to configure the bias somewhere as you should not rely on the firmware having configured things for you (as I also pointed out before). On my T14s the internal pull-up has been disabled. > + }; Johan
Hi Johan, On Mon, 4 Aug 2025 at 14:13, Johan Hovold <johan@kernel.org> wrote: > > On Thu, Jul 31, 2025 at 09:51:26PM +0100, Christopher Obbard wrote: > > The eDP controller has an HPD GPIO. Describe it in the device tree > > for the generic T14s model, as the HPD GPIO is used in both the > > OLED and LCD models which inherit this device tree. > > > @@ -5779,6 +5779,11 @@ tlmm: pinctrl@f100000 { > > gpio-ranges = <&tlmm 0 0 239>; > > wakeup-parent = <&pdc>; > > > > + edp_hpd_active: edp-hpd-active-state { > > The node name and label needs an index as this SoC has two edp hpd pins > as I already pointed out. Sure. After looking at the schematics this should be called edp0_hpd_active. I will fix this in the next revision. > > + pins = "gpio119"; > > + function = "edp0_hot"; > > And you also need to configure the bias somewhere as you should not rely > on the firmware having configured things for you (as I also pointed out > before). > > On my T14s the internal pull-up has been disabled. I am still unsure of what else needs to be set here. Can you help me with the correct settings? Thanks, Chris
On 09/08/2025 00:28, Christopher Obbard wrote: > Hi Johan, > > > On Mon, 4 Aug 2025 at 14:13, Johan Hovold <johan@kernel.org> wrote: >> >> On Thu, Jul 31, 2025 at 09:51:26PM +0100, Christopher Obbard wrote: >>> The eDP controller has an HPD GPIO. Describe it in the device tree >>> for the generic T14s model, as the HPD GPIO is used in both the >>> OLED and LCD models which inherit this device tree. >> >>> @@ -5779,6 +5779,11 @@ tlmm: pinctrl@f100000 { >>> gpio-ranges = <&tlmm 0 0 239>; >>> wakeup-parent = <&pdc>; >>> >>> + edp_hpd_active: edp-hpd-active-state { >> >> The node name and label needs an index as this SoC has two edp hpd pins >> as I already pointed out. > > Sure. After looking at the schematics this should be called > edp0_hpd_active. I will fix this in the next revision. > > >>> + pins = "gpio119"; >>> + function = "edp0_hot"; >> >> And you also need to configure the bias somewhere as you should not rely >> on the firmware having configured things for you (as I also pointed out >> before). >> >> On my T14s the internal pull-up has been disabled. > > I am still unsure of what else needs to be set here. Can you help me > with the correct settings? Just add bias-disable; Neil > > Thanks, > Chris
On Thu, Aug 14, 2025 at 04:21:09PM +0200, Neil Armstrong wrote: > On 09/08/2025 00:28, Christopher Obbard wrote: > > On Mon, 4 Aug 2025 at 14:13, Johan Hovold <johan@kernel.org> wrote: > > > > > > On Thu, Jul 31, 2025 at 09:51:26PM +0100, Christopher Obbard wrote: > > > > The eDP controller has an HPD GPIO. Describe it in the device tree > > > > for the generic T14s model, as the HPD GPIO is used in both the > > > > OLED and LCD models which inherit this device tree. > > > > > > > @@ -5779,6 +5779,11 @@ tlmm: pinctrl@f100000 { > > > > gpio-ranges = <&tlmm 0 0 239>; > > > > wakeup-parent = <&pdc>; > > > > > > > > + edp_hpd_active: edp-hpd-active-state { > > > > > > The node name and label needs an index as this SoC has two edp hpd pins > > > as I already pointed out. > > > > Sure. After looking at the schematics this should be called > > edp0_hpd_active. I will fix this in the next revision. > > > > > > > > + pins = "gpio119"; > > > > + function = "edp0_hot"; > > > > > > And you also need to configure the bias somewhere as you should not rely > > > on the firmware having configured things for you (as I also pointed out > > > before). > > > > > > On my T14s the internal pull-up has been disabled. > > > > I am still unsure of what else needs to be set here. Can you help me > > with the correct settings? > > Just add bias-disable; > I sent a patch fixing this for all the X1 devices upstream earlier [1], so you could also just send v7 with just the second patch of your series. The bias-disable is really somewhat device-specific (what if there is no pull down on the device side and someone disconnects the panel entirely?), so I put it into each board DT separately like Johan requested on v5. We have the same for the PCIe pinctrl. Thanks, Stephan [1]: https://lore.kernel.org/linux-arm-msm/20250814-x1e80100-add-edp-hpd-v1-0-a52804db53f6@linaro.org/T/
Hi Stephan, On Thu, 14 Aug 2025 at 15:47, Stephan Gerhold <stephan.gerhold@linaro.org> wrote: > > On Thu, Aug 14, 2025 at 04:21:09PM +0200, Neil Armstrong wrote: > > On 09/08/2025 00:28, Christopher Obbard wrote: > > > On Mon, 4 Aug 2025 at 14:13, Johan Hovold <johan@kernel.org> wrote: > > > > > > > > On Thu, Jul 31, 2025 at 09:51:26PM +0100, Christopher Obbard wrote: > > > > > The eDP controller has an HPD GPIO. Describe it in the device tree > > > > > for the generic T14s model, as the HPD GPIO is used in both the > > > > > OLED and LCD models which inherit this device tree. > > > > > > > > > @@ -5779,6 +5779,11 @@ tlmm: pinctrl@f100000 { > > > > > gpio-ranges = <&tlmm 0 0 239>; > > > > > wakeup-parent = <&pdc>; > > > > > > > > > > + edp_hpd_active: edp-hpd-active-state { > > > > > > > > The node name and label needs an index as this SoC has two edp hpd pins > > > > as I already pointed out. > > > > > > Sure. After looking at the schematics this should be called > > > edp0_hpd_active. I will fix this in the next revision. > > > > > > > > > > > + pins = "gpio119"; > > > > > + function = "edp0_hot"; > > > > > > > > And you also need to configure the bias somewhere as you should not rely > > > > on the firmware having configured things for you (as I also pointed out > > > > before). > > > > > > > > On my T14s the internal pull-up has been disabled. > > > > > > I am still unsure of what else needs to be set here. Can you help me > > > with the correct settings? > > > > Just add bias-disable; > > > > I sent a patch fixing this for all the X1 devices upstream earlier [1], > so you could also just send v7 with just the second patch of your > series. Sure. I will do so and base my next version on your patchset. > The bias-disable is really somewhat device-specific (what if there is no > pull down on the device side and someone disconnects the panel > entirely?), so I put it into each board DT separately like Johan > requested on v5. We have the same for the PCIe pinctrl. > > Thanks, > Stephan > > [1]: https://lore.kernel.org/linux-arm-msm/20250814-x1e80100-add-edp-hpd-v1-0-a52804db53f6@linaro.org/T/
© 2016 - 2025 Red Hat, Inc.