All of lore.kernel.org
 help / color / mirror / Atom feed
* [QUESTION] Enable PINEBOOK Pro's display
@ 2020-09-17  8:34 Jian-Hong Pan
  2020-09-23  6:59   ` Jian-Hong Pan
  0 siblings, 1 reply; 21+ messages in thread
From: Jian-Hong Pan @ 2020-09-17  8:34 UTC (permalink / raw)
  To: linux-rockchip, t.schramm; +Cc: Linux Upstreaming Team

Hi,

We have a PINEBOOK Pro [1] equipped with Rockchip RK3399.
I tried linux-next kernel at tag 5.9.0-rc5-next-20200915 with the
build config [2].  However, the drm seems failed and also leads Xorg
failed.

Here is the log [3]:

kernel: rockchip-dp ff970000.edp: no DP phy configured
kernel: cdn-dp fec00000.dp: [drm:cdn_dp_probe [rockchipdrm]] *ERROR*
missing extcon or phy
kernel: cdn-dp: probe of fec00000.dp failed with error -22
...
gdm-Xorg-:0[660]: (EE) open /dev/fb0: No such file or directory
gdm-Xorg-:0[660]: (EE) No devices detected.
gdm-Xorg-:0[660]: (EE)
gdm-Xorg-:0[660]: Fatal server error:
gdm-Xorg-:0[660]: (EE) no screens found(EE)

Do I miss something?  Any guidance will be appreciated.

[1] https://www.pine64.org/pinebook-pro/
[2] https://gist.github.com/starnight/66d27f7888d599247371adb1575d1092#file-config
[3] https://gist.github.com/starnight/66d27f7888d599247371adb1575d1092#file-journal-log

Jian-Hong Pan

_______________________________________________
Linux-rockchip mailing list
Linux-rockchip@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-rockchip

^ permalink raw reply	[flat|nested] 21+ messages in thread

* [PATCH] drm/rockchip: skip probed failed device
  2020-09-17  8:34 [QUESTION] Enable PINEBOOK Pro's display Jian-Hong Pan
  2020-09-23  6:59   ` Jian-Hong Pan
  (?)
@ 2020-09-23  6:59   ` Jian-Hong Pan
  0 siblings, 0 replies; 21+ messages in thread
From: Jian-Hong Pan @ 2020-09-23  6:59 UTC (permalink / raw)
  To: Heiko Stübner, David Airlie, Daniel Vetter
  Cc: dri-devel, linux-arm-kernel, linux-rockchip, linux-kernel, linux,
	Jian-Hong Pan

The cdn-dp sub driver probes the device failed on PINEBOOK Pro.

kernel: cdn-dp fec00000.dp: [drm:cdn_dp_probe [rockchipdrm]] *ERROR* missing extcon or phy
kernel: cdn-dp: probe of fec00000.dp failed with error -22

Then, the device halts all of the DRM related device jobs. For example,
the operations: vop_component_ops, vop_component_ops and
rockchip_dp_component_ops cannot be bound to corresponding devices. So,
Xorg cannot find the correct DRM device.

This patch skips the probing failed devices to fix this issue.

Link: http://lists.infradead.org/pipermail/linux-rockchip/2020-September/022352.html
Signed-off-by: Jian-Hong Pan <jhp@endlessos.org>
---
 drivers/gpu/drm/rockchip/rockchip_drm_drv.c | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
index 0f3eb392fe39..de13588602b4 100644
--- a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
+++ b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
@@ -331,6 +331,12 @@ static struct component_match *rockchip_drm_match_add(struct device *dev)
 
 			if (!d)
 				break;
+			if (!d->driver) {
+				DRM_DEV_ERROR(d,
+					      "%s did not probe successfully",
+					      drv->driver.name);
+				continue;
+			}
 
 			device_link_add(dev, d, DL_FLAG_STATELESS);
 			component_match_add(dev, &match, compare_dev, d);
-- 
2.28.0


^ permalink raw reply related	[flat|nested] 21+ messages in thread

* [PATCH] drm/rockchip: skip probed failed device
@ 2020-09-23  6:59   ` Jian-Hong Pan
  0 siblings, 0 replies; 21+ messages in thread
From: Jian-Hong Pan @ 2020-09-23  6:59 UTC (permalink / raw)
  To: Heiko Stübner, David Airlie, Daniel Vetter
  Cc: Jian-Hong Pan, dri-devel, linux-kernel, linux-rockchip, linux,
	linux-arm-kernel

The cdn-dp sub driver probes the device failed on PINEBOOK Pro.

kernel: cdn-dp fec00000.dp: [drm:cdn_dp_probe [rockchipdrm]] *ERROR* missing extcon or phy
kernel: cdn-dp: probe of fec00000.dp failed with error -22

Then, the device halts all of the DRM related device jobs. For example,
the operations: vop_component_ops, vop_component_ops and
rockchip_dp_component_ops cannot be bound to corresponding devices. So,
Xorg cannot find the correct DRM device.

This patch skips the probing failed devices to fix this issue.

Link: http://lists.infradead.org/pipermail/linux-rockchip/2020-September/022352.html
Signed-off-by: Jian-Hong Pan <jhp@endlessos.org>
---
 drivers/gpu/drm/rockchip/rockchip_drm_drv.c | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
index 0f3eb392fe39..de13588602b4 100644
--- a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
+++ b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
@@ -331,6 +331,12 @@ static struct component_match *rockchip_drm_match_add(struct device *dev)
 
 			if (!d)
 				break;
+			if (!d->driver) {
+				DRM_DEV_ERROR(d,
+					      "%s did not probe successfully",
+					      drv->driver.name);
+				continue;
+			}
 
 			device_link_add(dev, d, DL_FLAG_STATELESS);
 			component_match_add(dev, &match, compare_dev, d);
-- 
2.28.0


_______________________________________________
Linux-rockchip mailing list
Linux-rockchip@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-rockchip

^ permalink raw reply related	[flat|nested] 21+ messages in thread

* [PATCH] drm/rockchip: skip probed failed device
@ 2020-09-23  6:59   ` Jian-Hong Pan
  0 siblings, 0 replies; 21+ messages in thread
From: Jian-Hong Pan @ 2020-09-23  6:59 UTC (permalink / raw)
  To: Heiko Stübner, David Airlie, Daniel Vetter
  Cc: Jian-Hong Pan, dri-devel, linux-kernel, linux-rockchip, linux,
	linux-arm-kernel

The cdn-dp sub driver probes the device failed on PINEBOOK Pro.

kernel: cdn-dp fec00000.dp: [drm:cdn_dp_probe [rockchipdrm]] *ERROR* missing extcon or phy
kernel: cdn-dp: probe of fec00000.dp failed with error -22

Then, the device halts all of the DRM related device jobs. For example,
the operations: vop_component_ops, vop_component_ops and
rockchip_dp_component_ops cannot be bound to corresponding devices. So,
Xorg cannot find the correct DRM device.

This patch skips the probing failed devices to fix this issue.

Link: http://lists.infradead.org/pipermail/linux-rockchip/2020-September/022352.html
Signed-off-by: Jian-Hong Pan <jhp@endlessos.org>
---
 drivers/gpu/drm/rockchip/rockchip_drm_drv.c | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
index 0f3eb392fe39..de13588602b4 100644
--- a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
+++ b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
@@ -331,6 +331,12 @@ static struct component_match *rockchip_drm_match_add(struct device *dev)
 
 			if (!d)
 				break;
+			if (!d->driver) {
+				DRM_DEV_ERROR(d,
+					      "%s did not probe successfully",
+					      drv->driver.name);
+				continue;
+			}
 
 			device_link_add(dev, d, DL_FLAG_STATELESS);
 			component_match_add(dev, &match, compare_dev, d);
-- 
2.28.0


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply related	[flat|nested] 21+ messages in thread

* [PATCH] drm/rockchip: skip probed failed device
@ 2020-09-23  6:59   ` Jian-Hong Pan
  0 siblings, 0 replies; 21+ messages in thread
From: Jian-Hong Pan @ 2020-09-23  6:59 UTC (permalink / raw)
  To: Heiko Stübner, David Airlie, Daniel Vetter
  Cc: Jian-Hong Pan, dri-devel, linux-kernel, linux-rockchip, linux,
	linux-arm-kernel

The cdn-dp sub driver probes the device failed on PINEBOOK Pro.

kernel: cdn-dp fec00000.dp: [drm:cdn_dp_probe [rockchipdrm]] *ERROR* missing extcon or phy
kernel: cdn-dp: probe of fec00000.dp failed with error -22

Then, the device halts all of the DRM related device jobs. For example,
the operations: vop_component_ops, vop_component_ops and
rockchip_dp_component_ops cannot be bound to corresponding devices. So,
Xorg cannot find the correct DRM device.

This patch skips the probing failed devices to fix this issue.

Link: http://lists.infradead.org/pipermail/linux-rockchip/2020-September/022352.html
Signed-off-by: Jian-Hong Pan <jhp@endlessos.org>
---
 drivers/gpu/drm/rockchip/rockchip_drm_drv.c | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
index 0f3eb392fe39..de13588602b4 100644
--- a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
+++ b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
@@ -331,6 +331,12 @@ static struct component_match *rockchip_drm_match_add(struct device *dev)
 
 			if (!d)
 				break;
+			if (!d->driver) {
+				DRM_DEV_ERROR(d,
+					      "%s did not probe successfully",
+					      drv->driver.name);
+				continue;
+			}
 
 			device_link_add(dev, d, DL_FLAG_STATELESS);
 			component_match_add(dev, &match, compare_dev, d);
-- 
2.28.0

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply related	[flat|nested] 21+ messages in thread

* Re: [PATCH] drm/rockchip: skip probed failed device
  2020-09-23  6:59   ` Jian-Hong Pan
  (?)
  (?)
@ 2020-09-23  7:38     ` Heiko Stübner
  -1 siblings, 0 replies; 21+ messages in thread
From: Heiko Stübner @ 2020-09-23  7:38 UTC (permalink / raw)
  To: David Airlie, Daniel Vetter, Jian-Hong Pan
  Cc: dri-devel, linux-arm-kernel, linux-rockchip, linux-kernel, linux,
	Jian-Hong Pan

Hi,

Am Mittwoch, 23. September 2020, 08:59:00 CEST schrieb Jian-Hong Pan:
> The cdn-dp sub driver probes the device failed on PINEBOOK Pro.
> 
> kernel: cdn-dp fec00000.dp: [drm:cdn_dp_probe [rockchipdrm]] *ERROR* missing extcon or phy
> kernel: cdn-dp: probe of fec00000.dp failed with error -22
> 
> Then, the device halts all of the DRM related device jobs. For example,
> the operations: vop_component_ops, vop_component_ops and
> rockchip_dp_component_ops cannot be bound to corresponding devices. So,
> Xorg cannot find the correct DRM device.
> 
> This patch skips the probing failed devices to fix this issue.
> 
> Link: http://lists.infradead.org/pipermail/linux-rockchip/2020-September/022352.html
> Signed-off-by: Jian-Hong Pan <jhp@endlessos.org>
> ---
>  drivers/gpu/drm/rockchip/rockchip_drm_drv.c | 6 ++++++
>  1 file changed, 6 insertions(+)
> 
> diff --git a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> index 0f3eb392fe39..de13588602b4 100644
> --- a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> +++ b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> @@ -331,6 +331,12 @@ static struct component_match *rockchip_drm_match_add(struct device *dev)
>  
>  			if (!d)
>  				break;
> +			if (!d->driver) {
> +				DRM_DEV_ERROR(d,
> +					      "%s did not probe successfully",
> +					      drv->driver.name);
> +				continue;
> +			}

How does this relate to drivers doing EPROBE_DEFER?

Very often you have sub-drivers defering probe as they still need another
resource, so excluding them in that case would not work?

Heiko


>  
>  			device_link_add(dev, d, DL_FLAG_STATELESS);
>  			component_match_add(dev, &match, compare_dev, d);
> 





^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH] drm/rockchip: skip probed failed device
@ 2020-09-23  7:38     ` Heiko Stübner
  0 siblings, 0 replies; 21+ messages in thread
From: Heiko Stübner @ 2020-09-23  7:38 UTC (permalink / raw)
  To: David Airlie, Daniel Vetter, Jian-Hong Pan
  Cc: Jian-Hong Pan, dri-devel, linux-kernel, linux-rockchip, linux,
	linux-arm-kernel

Hi,

Am Mittwoch, 23. September 2020, 08:59:00 CEST schrieb Jian-Hong Pan:
> The cdn-dp sub driver probes the device failed on PINEBOOK Pro.
> 
> kernel: cdn-dp fec00000.dp: [drm:cdn_dp_probe [rockchipdrm]] *ERROR* missing extcon or phy
> kernel: cdn-dp: probe of fec00000.dp failed with error -22
> 
> Then, the device halts all of the DRM related device jobs. For example,
> the operations: vop_component_ops, vop_component_ops and
> rockchip_dp_component_ops cannot be bound to corresponding devices. So,
> Xorg cannot find the correct DRM device.
> 
> This patch skips the probing failed devices to fix this issue.
> 
> Link: http://lists.infradead.org/pipermail/linux-rockchip/2020-September/022352.html
> Signed-off-by: Jian-Hong Pan <jhp@endlessos.org>
> ---
>  drivers/gpu/drm/rockchip/rockchip_drm_drv.c | 6 ++++++
>  1 file changed, 6 insertions(+)
> 
> diff --git a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> index 0f3eb392fe39..de13588602b4 100644
> --- a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> +++ b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> @@ -331,6 +331,12 @@ static struct component_match *rockchip_drm_match_add(struct device *dev)
>  
>  			if (!d)
>  				break;
> +			if (!d->driver) {
> +				DRM_DEV_ERROR(d,
> +					      "%s did not probe successfully",
> +					      drv->driver.name);
> +				continue;
> +			}

How does this relate to drivers doing EPROBE_DEFER?

Very often you have sub-drivers defering probe as they still need another
resource, so excluding them in that case would not work?

Heiko


>  
>  			device_link_add(dev, d, DL_FLAG_STATELESS);
>  			component_match_add(dev, &match, compare_dev, d);
> 





_______________________________________________
Linux-rockchip mailing list
Linux-rockchip@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-rockchip

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH] drm/rockchip: skip probed failed device
@ 2020-09-23  7:38     ` Heiko Stübner
  0 siblings, 0 replies; 21+ messages in thread
From: Heiko Stübner @ 2020-09-23  7:38 UTC (permalink / raw)
  To: David Airlie, Daniel Vetter, Jian-Hong Pan
  Cc: Jian-Hong Pan, dri-devel, linux-kernel, linux-rockchip, linux,
	linux-arm-kernel

Hi,

Am Mittwoch, 23. September 2020, 08:59:00 CEST schrieb Jian-Hong Pan:
> The cdn-dp sub driver probes the device failed on PINEBOOK Pro.
> 
> kernel: cdn-dp fec00000.dp: [drm:cdn_dp_probe [rockchipdrm]] *ERROR* missing extcon or phy
> kernel: cdn-dp: probe of fec00000.dp failed with error -22
> 
> Then, the device halts all of the DRM related device jobs. For example,
> the operations: vop_component_ops, vop_component_ops and
> rockchip_dp_component_ops cannot be bound to corresponding devices. So,
> Xorg cannot find the correct DRM device.
> 
> This patch skips the probing failed devices to fix this issue.
> 
> Link: http://lists.infradead.org/pipermail/linux-rockchip/2020-September/022352.html
> Signed-off-by: Jian-Hong Pan <jhp@endlessos.org>
> ---
>  drivers/gpu/drm/rockchip/rockchip_drm_drv.c | 6 ++++++
>  1 file changed, 6 insertions(+)
> 
> diff --git a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> index 0f3eb392fe39..de13588602b4 100644
> --- a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> +++ b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> @@ -331,6 +331,12 @@ static struct component_match *rockchip_drm_match_add(struct device *dev)
>  
>  			if (!d)
>  				break;
> +			if (!d->driver) {
> +				DRM_DEV_ERROR(d,
> +					      "%s did not probe successfully",
> +					      drv->driver.name);
> +				continue;
> +			}

How does this relate to drivers doing EPROBE_DEFER?

Very often you have sub-drivers defering probe as they still need another
resource, so excluding them in that case would not work?

Heiko


>  
>  			device_link_add(dev, d, DL_FLAG_STATELESS);
>  			component_match_add(dev, &match, compare_dev, d);
> 





_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH] drm/rockchip: skip probed failed device
@ 2020-09-23  7:38     ` Heiko Stübner
  0 siblings, 0 replies; 21+ messages in thread
From: Heiko Stübner @ 2020-09-23  7:38 UTC (permalink / raw)
  To: David Airlie, Daniel Vetter, Jian-Hong Pan
  Cc: Jian-Hong Pan, dri-devel, linux-kernel, linux-rockchip, linux,
	linux-arm-kernel

Hi,

Am Mittwoch, 23. September 2020, 08:59:00 CEST schrieb Jian-Hong Pan:
> The cdn-dp sub driver probes the device failed on PINEBOOK Pro.
> 
> kernel: cdn-dp fec00000.dp: [drm:cdn_dp_probe [rockchipdrm]] *ERROR* missing extcon or phy
> kernel: cdn-dp: probe of fec00000.dp failed with error -22
> 
> Then, the device halts all of the DRM related device jobs. For example,
> the operations: vop_component_ops, vop_component_ops and
> rockchip_dp_component_ops cannot be bound to corresponding devices. So,
> Xorg cannot find the correct DRM device.
> 
> This patch skips the probing failed devices to fix this issue.
> 
> Link: http://lists.infradead.org/pipermail/linux-rockchip/2020-September/022352.html
> Signed-off-by: Jian-Hong Pan <jhp@endlessos.org>
> ---
>  drivers/gpu/drm/rockchip/rockchip_drm_drv.c | 6 ++++++
>  1 file changed, 6 insertions(+)
> 
> diff --git a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> index 0f3eb392fe39..de13588602b4 100644
> --- a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> +++ b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> @@ -331,6 +331,12 @@ static struct component_match *rockchip_drm_match_add(struct device *dev)
>  
>  			if (!d)
>  				break;
> +			if (!d->driver) {
> +				DRM_DEV_ERROR(d,
> +					      "%s did not probe successfully",
> +					      drv->driver.name);
> +				continue;
> +			}

How does this relate to drivers doing EPROBE_DEFER?

Very often you have sub-drivers defering probe as they still need another
resource, so excluding them in that case would not work?

Heiko


>  
>  			device_link_add(dev, d, DL_FLAG_STATELESS);
>  			component_match_add(dev, &match, compare_dev, d);
> 




_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH] drm/rockchip: skip probed failed device
  2020-09-23  6:59   ` Jian-Hong Pan
  (?)
  (?)
@ 2020-09-23 11:05     ` Robin Murphy
  -1 siblings, 0 replies; 21+ messages in thread
From: Robin Murphy @ 2020-09-23 11:05 UTC (permalink / raw)
  To: Jian-Hong Pan, Heiko Stübner, David Airlie, Daniel Vetter
  Cc: dri-devel, linux-kernel, linux-rockchip, linux, linux-arm-kernel

On 2020-09-23 07:59, Jian-Hong Pan wrote:
> The cdn-dp sub driver probes the device failed on PINEBOOK Pro.
> 
> kernel: cdn-dp fec00000.dp: [drm:cdn_dp_probe [rockchipdrm]] *ERROR* missing extcon or phy
> kernel: cdn-dp: probe of fec00000.dp failed with error -22

Wouldn't it make more sense to simply not enable the DisplayPort node in 
the upstream DT, until the type-C phy work has been done to make it 
usable at all? AIUI the "official" Manjaro kernel is carrying a bunch of 
hacks to make type-C work via extcon, but they know that isn't an 
upstreamable solution.

Robin.

> Then, the device halts all of the DRM related device jobs. For example,
> the operations: vop_component_ops, vop_component_ops and
> rockchip_dp_component_ops cannot be bound to corresponding devices. So,
> Xorg cannot find the correct DRM device.
> 
> This patch skips the probing failed devices to fix this issue.
> 
> Link: http://lists.infradead.org/pipermail/linux-rockchip/2020-September/022352.html
> Signed-off-by: Jian-Hong Pan <jhp@endlessos.org>
> ---
>   drivers/gpu/drm/rockchip/rockchip_drm_drv.c | 6 ++++++
>   1 file changed, 6 insertions(+)
> 
> diff --git a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> index 0f3eb392fe39..de13588602b4 100644
> --- a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> +++ b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> @@ -331,6 +331,12 @@ static struct component_match *rockchip_drm_match_add(struct device *dev)
>   
>   			if (!d)
>   				break;
> +			if (!d->driver) {
> +				DRM_DEV_ERROR(d,
> +					      "%s did not probe successfully",
> +					      drv->driver.name);
> +				continue;
> +			}
>   
>   			device_link_add(dev, d, DL_FLAG_STATELESS);
>   			component_match_add(dev, &match, compare_dev, d);
> 

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH] drm/rockchip: skip probed failed device
@ 2020-09-23 11:05     ` Robin Murphy
  0 siblings, 0 replies; 21+ messages in thread
From: Robin Murphy @ 2020-09-23 11:05 UTC (permalink / raw)
  To: Jian-Hong Pan, Heiko Stübner, David Airlie, Daniel Vetter
  Cc: linux-arm-kernel, linux-rockchip, linux, linux-kernel, dri-devel

On 2020-09-23 07:59, Jian-Hong Pan wrote:
> The cdn-dp sub driver probes the device failed on PINEBOOK Pro.
> 
> kernel: cdn-dp fec00000.dp: [drm:cdn_dp_probe [rockchipdrm]] *ERROR* missing extcon or phy
> kernel: cdn-dp: probe of fec00000.dp failed with error -22

Wouldn't it make more sense to simply not enable the DisplayPort node in 
the upstream DT, until the type-C phy work has been done to make it 
usable at all? AIUI the "official" Manjaro kernel is carrying a bunch of 
hacks to make type-C work via extcon, but they know that isn't an 
upstreamable solution.

Robin.

> Then, the device halts all of the DRM related device jobs. For example,
> the operations: vop_component_ops, vop_component_ops and
> rockchip_dp_component_ops cannot be bound to corresponding devices. So,
> Xorg cannot find the correct DRM device.
> 
> This patch skips the probing failed devices to fix this issue.
> 
> Link: http://lists.infradead.org/pipermail/linux-rockchip/2020-September/022352.html
> Signed-off-by: Jian-Hong Pan <jhp@endlessos.org>
> ---
>   drivers/gpu/drm/rockchip/rockchip_drm_drv.c | 6 ++++++
>   1 file changed, 6 insertions(+)
> 
> diff --git a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> index 0f3eb392fe39..de13588602b4 100644
> --- a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> +++ b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> @@ -331,6 +331,12 @@ static struct component_match *rockchip_drm_match_add(struct device *dev)
>   
>   			if (!d)
>   				break;
> +			if (!d->driver) {
> +				DRM_DEV_ERROR(d,
> +					      "%s did not probe successfully",
> +					      drv->driver.name);
> +				continue;
> +			}
>   
>   			device_link_add(dev, d, DL_FLAG_STATELESS);
>   			component_match_add(dev, &match, compare_dev, d);
> 

_______________________________________________
Linux-rockchip mailing list
Linux-rockchip@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-rockchip

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH] drm/rockchip: skip probed failed device
@ 2020-09-23 11:05     ` Robin Murphy
  0 siblings, 0 replies; 21+ messages in thread
From: Robin Murphy @ 2020-09-23 11:05 UTC (permalink / raw)
  To: Jian-Hong Pan, Heiko Stübner, David Airlie, Daniel Vetter
  Cc: linux-arm-kernel, linux-rockchip, linux, linux-kernel, dri-devel

On 2020-09-23 07:59, Jian-Hong Pan wrote:
> The cdn-dp sub driver probes the device failed on PINEBOOK Pro.
> 
> kernel: cdn-dp fec00000.dp: [drm:cdn_dp_probe [rockchipdrm]] *ERROR* missing extcon or phy
> kernel: cdn-dp: probe of fec00000.dp failed with error -22

Wouldn't it make more sense to simply not enable the DisplayPort node in 
the upstream DT, until the type-C phy work has been done to make it 
usable at all? AIUI the "official" Manjaro kernel is carrying a bunch of 
hacks to make type-C work via extcon, but they know that isn't an 
upstreamable solution.

Robin.

> Then, the device halts all of the DRM related device jobs. For example,
> the operations: vop_component_ops, vop_component_ops and
> rockchip_dp_component_ops cannot be bound to corresponding devices. So,
> Xorg cannot find the correct DRM device.
> 
> This patch skips the probing failed devices to fix this issue.
> 
> Link: http://lists.infradead.org/pipermail/linux-rockchip/2020-September/022352.html
> Signed-off-by: Jian-Hong Pan <jhp@endlessos.org>
> ---
>   drivers/gpu/drm/rockchip/rockchip_drm_drv.c | 6 ++++++
>   1 file changed, 6 insertions(+)
> 
> diff --git a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> index 0f3eb392fe39..de13588602b4 100644
> --- a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> +++ b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> @@ -331,6 +331,12 @@ static struct component_match *rockchip_drm_match_add(struct device *dev)
>   
>   			if (!d)
>   				break;
> +			if (!d->driver) {
> +				DRM_DEV_ERROR(d,
> +					      "%s did not probe successfully",
> +					      drv->driver.name);
> +				continue;
> +			}
>   
>   			device_link_add(dev, d, DL_FLAG_STATELESS);
>   			component_match_add(dev, &match, compare_dev, d);
> 

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH] drm/rockchip: skip probed failed device
@ 2020-09-23 11:05     ` Robin Murphy
  0 siblings, 0 replies; 21+ messages in thread
From: Robin Murphy @ 2020-09-23 11:05 UTC (permalink / raw)
  To: Jian-Hong Pan, Heiko Stübner, David Airlie, Daniel Vetter
  Cc: linux-arm-kernel, linux-rockchip, linux, linux-kernel, dri-devel

On 2020-09-23 07:59, Jian-Hong Pan wrote:
> The cdn-dp sub driver probes the device failed on PINEBOOK Pro.
> 
> kernel: cdn-dp fec00000.dp: [drm:cdn_dp_probe [rockchipdrm]] *ERROR* missing extcon or phy
> kernel: cdn-dp: probe of fec00000.dp failed with error -22

Wouldn't it make more sense to simply not enable the DisplayPort node in 
the upstream DT, until the type-C phy work has been done to make it 
usable at all? AIUI the "official" Manjaro kernel is carrying a bunch of 
hacks to make type-C work via extcon, but they know that isn't an 
upstreamable solution.

Robin.

> Then, the device halts all of the DRM related device jobs. For example,
> the operations: vop_component_ops, vop_component_ops and
> rockchip_dp_component_ops cannot be bound to corresponding devices. So,
> Xorg cannot find the correct DRM device.
> 
> This patch skips the probing failed devices to fix this issue.
> 
> Link: http://lists.infradead.org/pipermail/linux-rockchip/2020-September/022352.html
> Signed-off-by: Jian-Hong Pan <jhp@endlessos.org>
> ---
>   drivers/gpu/drm/rockchip/rockchip_drm_drv.c | 6 ++++++
>   1 file changed, 6 insertions(+)
> 
> diff --git a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> index 0f3eb392fe39..de13588602b4 100644
> --- a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> +++ b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> @@ -331,6 +331,12 @@ static struct component_match *rockchip_drm_match_add(struct device *dev)
>   
>   			if (!d)
>   				break;
> +			if (!d->driver) {
> +				DRM_DEV_ERROR(d,
> +					      "%s did not probe successfully",
> +					      drv->driver.name);
> +				continue;
> +			}
>   
>   			device_link_add(dev, d, DL_FLAG_STATELESS);
>   			component_match_add(dev, &match, compare_dev, d);
> 
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH] drm/rockchip: skip probed failed device
  2020-09-23 11:05     ` Robin Murphy
  (?)
  (?)
@ 2020-09-23 11:16       ` Heiko Stübner
  -1 siblings, 0 replies; 21+ messages in thread
From: Heiko Stübner @ 2020-09-23 11:16 UTC (permalink / raw)
  To: Jian-Hong Pan, David Airlie, Daniel Vetter, Robin Murphy
  Cc: dri-devel, linux-kernel, linux-rockchip, linux, linux-arm-kernel

Am Mittwoch, 23. September 2020, 13:05:26 CEST schrieb Robin Murphy:
> On 2020-09-23 07:59, Jian-Hong Pan wrote:
> > The cdn-dp sub driver probes the device failed on PINEBOOK Pro.
> > 
> > kernel: cdn-dp fec00000.dp: [drm:cdn_dp_probe [rockchipdrm]] *ERROR* missing extcon or phy
> > kernel: cdn-dp: probe of fec00000.dp failed with error -22
> 
> Wouldn't it make more sense to simply not enable the DisplayPort node in 
> the upstream DT, until the type-C phy work has been done to make it 
> usable at all?

Or alternatively just disable the cdn-dp Rockchip driver in the kernel config,
which results in it also not getting probed.


> AIUI the "official" Manjaro kernel is carrying a bunch of 
> hacks to make type-C work via extcon, but they know that isn't an 
> upstreamable solution.
> 
> Robin.
> 
> > Then, the device halts all of the DRM related device jobs. For example,
> > the operations: vop_component_ops, vop_component_ops and
> > rockchip_dp_component_ops cannot be bound to corresponding devices. So,
> > Xorg cannot find the correct DRM device.
> > 
> > This patch skips the probing failed devices to fix this issue.
> > 
> > Link: http://lists.infradead.org/pipermail/linux-rockchip/2020-September/022352.html
> > Signed-off-by: Jian-Hong Pan <jhp@endlessos.org>
> > ---
> >   drivers/gpu/drm/rockchip/rockchip_drm_drv.c | 6 ++++++
> >   1 file changed, 6 insertions(+)
> > 
> > diff --git a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> > index 0f3eb392fe39..de13588602b4 100644
> > --- a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> > +++ b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> > @@ -331,6 +331,12 @@ static struct component_match *rockchip_drm_match_add(struct device *dev)
> >   
> >   			if (!d)
> >   				break;
> > +			if (!d->driver) {
> > +				DRM_DEV_ERROR(d,
> > +					      "%s did not probe successfully",
> > +					      drv->driver.name);
> > +				continue;
> > +			}
> >   
> >   			device_link_add(dev, d, DL_FLAG_STATELESS);
> >   			component_match_add(dev, &match, compare_dev, d);
> > 
> 





^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH] drm/rockchip: skip probed failed device
@ 2020-09-23 11:16       ` Heiko Stübner
  0 siblings, 0 replies; 21+ messages in thread
From: Heiko Stübner @ 2020-09-23 11:16 UTC (permalink / raw)
  To: Jian-Hong Pan, David Airlie, Daniel Vetter, Robin Murphy
  Cc: linux-arm-kernel, linux-rockchip, linux, linux-kernel, dri-devel

Am Mittwoch, 23. September 2020, 13:05:26 CEST schrieb Robin Murphy:
> On 2020-09-23 07:59, Jian-Hong Pan wrote:
> > The cdn-dp sub driver probes the device failed on PINEBOOK Pro.
> > 
> > kernel: cdn-dp fec00000.dp: [drm:cdn_dp_probe [rockchipdrm]] *ERROR* missing extcon or phy
> > kernel: cdn-dp: probe of fec00000.dp failed with error -22
> 
> Wouldn't it make more sense to simply not enable the DisplayPort node in 
> the upstream DT, until the type-C phy work has been done to make it 
> usable at all?

Or alternatively just disable the cdn-dp Rockchip driver in the kernel config,
which results in it also not getting probed.


> AIUI the "official" Manjaro kernel is carrying a bunch of 
> hacks to make type-C work via extcon, but they know that isn't an 
> upstreamable solution.
> 
> Robin.
> 
> > Then, the device halts all of the DRM related device jobs. For example,
> > the operations: vop_component_ops, vop_component_ops and
> > rockchip_dp_component_ops cannot be bound to corresponding devices. So,
> > Xorg cannot find the correct DRM device.
> > 
> > This patch skips the probing failed devices to fix this issue.
> > 
> > Link: http://lists.infradead.org/pipermail/linux-rockchip/2020-September/022352.html
> > Signed-off-by: Jian-Hong Pan <jhp@endlessos.org>
> > ---
> >   drivers/gpu/drm/rockchip/rockchip_drm_drv.c | 6 ++++++
> >   1 file changed, 6 insertions(+)
> > 
> > diff --git a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> > index 0f3eb392fe39..de13588602b4 100644
> > --- a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> > +++ b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> > @@ -331,6 +331,12 @@ static struct component_match *rockchip_drm_match_add(struct device *dev)
> >   
> >   			if (!d)
> >   				break;
> > +			if (!d->driver) {
> > +				DRM_DEV_ERROR(d,
> > +					      "%s did not probe successfully",
> > +					      drv->driver.name);
> > +				continue;
> > +			}
> >   
> >   			device_link_add(dev, d, DL_FLAG_STATELESS);
> >   			component_match_add(dev, &match, compare_dev, d);
> > 
> 





_______________________________________________
Linux-rockchip mailing list
Linux-rockchip@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-rockchip

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH] drm/rockchip: skip probed failed device
@ 2020-09-23 11:16       ` Heiko Stübner
  0 siblings, 0 replies; 21+ messages in thread
From: Heiko Stübner @ 2020-09-23 11:16 UTC (permalink / raw)
  To: Jian-Hong Pan, David Airlie, Daniel Vetter, Robin Murphy
  Cc: linux-arm-kernel, linux-rockchip, linux, linux-kernel, dri-devel

Am Mittwoch, 23. September 2020, 13:05:26 CEST schrieb Robin Murphy:
> On 2020-09-23 07:59, Jian-Hong Pan wrote:
> > The cdn-dp sub driver probes the device failed on PINEBOOK Pro.
> > 
> > kernel: cdn-dp fec00000.dp: [drm:cdn_dp_probe [rockchipdrm]] *ERROR* missing extcon or phy
> > kernel: cdn-dp: probe of fec00000.dp failed with error -22
> 
> Wouldn't it make more sense to simply not enable the DisplayPort node in 
> the upstream DT, until the type-C phy work has been done to make it 
> usable at all?

Or alternatively just disable the cdn-dp Rockchip driver in the kernel config,
which results in it also not getting probed.


> AIUI the "official" Manjaro kernel is carrying a bunch of 
> hacks to make type-C work via extcon, but they know that isn't an 
> upstreamable solution.
> 
> Robin.
> 
> > Then, the device halts all of the DRM related device jobs. For example,
> > the operations: vop_component_ops, vop_component_ops and
> > rockchip_dp_component_ops cannot be bound to corresponding devices. So,
> > Xorg cannot find the correct DRM device.
> > 
> > This patch skips the probing failed devices to fix this issue.
> > 
> > Link: http://lists.infradead.org/pipermail/linux-rockchip/2020-September/022352.html
> > Signed-off-by: Jian-Hong Pan <jhp@endlessos.org>
> > ---
> >   drivers/gpu/drm/rockchip/rockchip_drm_drv.c | 6 ++++++
> >   1 file changed, 6 insertions(+)
> > 
> > diff --git a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> > index 0f3eb392fe39..de13588602b4 100644
> > --- a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> > +++ b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> > @@ -331,6 +331,12 @@ static struct component_match *rockchip_drm_match_add(struct device *dev)
> >   
> >   			if (!d)
> >   				break;
> > +			if (!d->driver) {
> > +				DRM_DEV_ERROR(d,
> > +					      "%s did not probe successfully",
> > +					      drv->driver.name);
> > +				continue;
> > +			}
> >   
> >   			device_link_add(dev, d, DL_FLAG_STATELESS);
> >   			component_match_add(dev, &match, compare_dev, d);
> > 
> 





_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH] drm/rockchip: skip probed failed device
@ 2020-09-23 11:16       ` Heiko Stübner
  0 siblings, 0 replies; 21+ messages in thread
From: Heiko Stübner @ 2020-09-23 11:16 UTC (permalink / raw)
  To: Jian-Hong Pan, David Airlie, Daniel Vetter, Robin Murphy
  Cc: linux-arm-kernel, linux-rockchip, linux, linux-kernel, dri-devel

Am Mittwoch, 23. September 2020, 13:05:26 CEST schrieb Robin Murphy:
> On 2020-09-23 07:59, Jian-Hong Pan wrote:
> > The cdn-dp sub driver probes the device failed on PINEBOOK Pro.
> > 
> > kernel: cdn-dp fec00000.dp: [drm:cdn_dp_probe [rockchipdrm]] *ERROR* missing extcon or phy
> > kernel: cdn-dp: probe of fec00000.dp failed with error -22
> 
> Wouldn't it make more sense to simply not enable the DisplayPort node in 
> the upstream DT, until the type-C phy work has been done to make it 
> usable at all?

Or alternatively just disable the cdn-dp Rockchip driver in the kernel config,
which results in it also not getting probed.


> AIUI the "official" Manjaro kernel is carrying a bunch of 
> hacks to make type-C work via extcon, but they know that isn't an 
> upstreamable solution.
> 
> Robin.
> 
> > Then, the device halts all of the DRM related device jobs. For example,
> > the operations: vop_component_ops, vop_component_ops and
> > rockchip_dp_component_ops cannot be bound to corresponding devices. So,
> > Xorg cannot find the correct DRM device.
> > 
> > This patch skips the probing failed devices to fix this issue.
> > 
> > Link: http://lists.infradead.org/pipermail/linux-rockchip/2020-September/022352.html
> > Signed-off-by: Jian-Hong Pan <jhp@endlessos.org>
> > ---
> >   drivers/gpu/drm/rockchip/rockchip_drm_drv.c | 6 ++++++
> >   1 file changed, 6 insertions(+)
> > 
> > diff --git a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> > index 0f3eb392fe39..de13588602b4 100644
> > --- a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> > +++ b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> > @@ -331,6 +331,12 @@ static struct component_match *rockchip_drm_match_add(struct device *dev)
> >   
> >   			if (!d)
> >   				break;
> > +			if (!d->driver) {
> > +				DRM_DEV_ERROR(d,
> > +					      "%s did not probe successfully",
> > +					      drv->driver.name);
> > +				continue;
> > +			}
> >   
> >   			device_link_add(dev, d, DL_FLAG_STATELESS);
> >   			component_match_add(dev, &match, compare_dev, d);
> > 
> 




_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH] drm/rockchip: skip probed failed device
  2020-09-23 11:16       ` Heiko Stübner
  (?)
  (?)
@ 2020-09-24  6:07         ` Jian-Hong Pan
  -1 siblings, 0 replies; 21+ messages in thread
From: Jian-Hong Pan @ 2020-09-24  6:07 UTC (permalink / raw)
  To: Heiko Stübner
  Cc: David Airlie, Daniel Vetter, Robin Murphy, dri-devel,
	Linux Kernel, linux-rockchip, Linux Upstreaming Team,
	linux-arm-kernel

Heiko Stübner <heiko@sntech.de> 於 2020年9月23日 週三 下午7:16寫道:
>
> Am Mittwoch, 23. September 2020, 13:05:26 CEST schrieb Robin Murphy:
> > On 2020-09-23 07:59, Jian-Hong Pan wrote:
> > > The cdn-dp sub driver probes the device failed on PINEBOOK Pro.
> > >
> > > kernel: cdn-dp fec00000.dp: [drm:cdn_dp_probe [rockchipdrm]] *ERROR* missing extcon or phy
> > > kernel: cdn-dp: probe of fec00000.dp failed with error -22
> >
> > Wouldn't it make more sense to simply not enable the DisplayPort node in
> > the upstream DT, until the type-C phy work has been done to make it
> > usable at all?
>
> Or alternatively just disable the cdn-dp Rockchip driver in the kernel config,
> which results in it also not getting probed.

This may be the simplest way.
However, considering generic distro kernels have a policy to enable
all drivers, disabling the DisplayPort node in the upstream DT, until
the type-C phy work has been done may be a better solution for now.
I can prepare a patch for this.

Jian-Hong Pan

> > AIUI the "official" Manjaro kernel is carrying a bunch of
> > hacks to make type-C work via extcon, but they know that isn't an
> > upstreamable solution.
> >
> > Robin.
> >
> > > Then, the device halts all of the DRM related device jobs. For example,
> > > the operations: vop_component_ops, vop_component_ops and
> > > rockchip_dp_component_ops cannot be bound to corresponding devices. So,
> > > Xorg cannot find the correct DRM device.
> > >
> > > This patch skips the probing failed devices to fix this issue.
> > >
> > > Link: http://lists.infradead.org/pipermail/linux-rockchip/2020-September/022352.html
> > > Signed-off-by: Jian-Hong Pan <jhp@endlessos.org>
> > > ---
> > >   drivers/gpu/drm/rockchip/rockchip_drm_drv.c | 6 ++++++
> > >   1 file changed, 6 insertions(+)
> > >
> > > diff --git a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> > > index 0f3eb392fe39..de13588602b4 100644
> > > --- a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> > > +++ b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> > > @@ -331,6 +331,12 @@ static struct component_match *rockchip_drm_match_add(struct device *dev)
> > >
> > >                     if (!d)
> > >                             break;
> > > +                   if (!d->driver) {
> > > +                           DRM_DEV_ERROR(d,
> > > +                                         "%s did not probe successfully",
> > > +                                         drv->driver.name);
> > > +                           continue;
> > > +                   }
> > >
> > >                     device_link_add(dev, d, DL_FLAG_STATELESS);
> > >                     component_match_add(dev, &match, compare_dev, d);

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH] drm/rockchip: skip probed failed device
@ 2020-09-24  6:07         ` Jian-Hong Pan
  0 siblings, 0 replies; 21+ messages in thread
From: Jian-Hong Pan @ 2020-09-24  6:07 UTC (permalink / raw)
  To: Heiko Stübner
  Cc: David Airlie, Linux Upstreaming Team, Linux Kernel, dri-devel,
	linux-rockchip, Daniel Vetter, Robin Murphy, linux-arm-kernel

Heiko Stübner <heiko@sntech.de> 於 2020年9月23日 週三 下午7:16寫道:
>
> Am Mittwoch, 23. September 2020, 13:05:26 CEST schrieb Robin Murphy:
> > On 2020-09-23 07:59, Jian-Hong Pan wrote:
> > > The cdn-dp sub driver probes the device failed on PINEBOOK Pro.
> > >
> > > kernel: cdn-dp fec00000.dp: [drm:cdn_dp_probe [rockchipdrm]] *ERROR* missing extcon or phy
> > > kernel: cdn-dp: probe of fec00000.dp failed with error -22
> >
> > Wouldn't it make more sense to simply not enable the DisplayPort node in
> > the upstream DT, until the type-C phy work has been done to make it
> > usable at all?
>
> Or alternatively just disable the cdn-dp Rockchip driver in the kernel config,
> which results in it also not getting probed.

This may be the simplest way.
However, considering generic distro kernels have a policy to enable
all drivers, disabling the DisplayPort node in the upstream DT, until
the type-C phy work has been done may be a better solution for now.
I can prepare a patch for this.

Jian-Hong Pan

> > AIUI the "official" Manjaro kernel is carrying a bunch of
> > hacks to make type-C work via extcon, but they know that isn't an
> > upstreamable solution.
> >
> > Robin.
> >
> > > Then, the device halts all of the DRM related device jobs. For example,
> > > the operations: vop_component_ops, vop_component_ops and
> > > rockchip_dp_component_ops cannot be bound to corresponding devices. So,
> > > Xorg cannot find the correct DRM device.
> > >
> > > This patch skips the probing failed devices to fix this issue.
> > >
> > > Link: http://lists.infradead.org/pipermail/linux-rockchip/2020-September/022352.html
> > > Signed-off-by: Jian-Hong Pan <jhp@endlessos.org>
> > > ---
> > >   drivers/gpu/drm/rockchip/rockchip_drm_drv.c | 6 ++++++
> > >   1 file changed, 6 insertions(+)
> > >
> > > diff --git a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> > > index 0f3eb392fe39..de13588602b4 100644
> > > --- a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> > > +++ b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> > > @@ -331,6 +331,12 @@ static struct component_match *rockchip_drm_match_add(struct device *dev)
> > >
> > >                     if (!d)
> > >                             break;
> > > +                   if (!d->driver) {
> > > +                           DRM_DEV_ERROR(d,
> > > +                                         "%s did not probe successfully",
> > > +                                         drv->driver.name);
> > > +                           continue;
> > > +                   }
> > >
> > >                     device_link_add(dev, d, DL_FLAG_STATELESS);
> > >                     component_match_add(dev, &match, compare_dev, d);

_______________________________________________
Linux-rockchip mailing list
Linux-rockchip@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-rockchip

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH] drm/rockchip: skip probed failed device
@ 2020-09-24  6:07         ` Jian-Hong Pan
  0 siblings, 0 replies; 21+ messages in thread
From: Jian-Hong Pan @ 2020-09-24  6:07 UTC (permalink / raw)
  To: Heiko Stübner
  Cc: David Airlie, Linux Upstreaming Team, Linux Kernel, dri-devel,
	linux-rockchip, Daniel Vetter, Robin Murphy, linux-arm-kernel

Heiko Stübner <heiko@sntech.de> 於 2020年9月23日 週三 下午7:16寫道:
>
> Am Mittwoch, 23. September 2020, 13:05:26 CEST schrieb Robin Murphy:
> > On 2020-09-23 07:59, Jian-Hong Pan wrote:
> > > The cdn-dp sub driver probes the device failed on PINEBOOK Pro.
> > >
> > > kernel: cdn-dp fec00000.dp: [drm:cdn_dp_probe [rockchipdrm]] *ERROR* missing extcon or phy
> > > kernel: cdn-dp: probe of fec00000.dp failed with error -22
> >
> > Wouldn't it make more sense to simply not enable the DisplayPort node in
> > the upstream DT, until the type-C phy work has been done to make it
> > usable at all?
>
> Or alternatively just disable the cdn-dp Rockchip driver in the kernel config,
> which results in it also not getting probed.

This may be the simplest way.
However, considering generic distro kernels have a policy to enable
all drivers, disabling the DisplayPort node in the upstream DT, until
the type-C phy work has been done may be a better solution for now.
I can prepare a patch for this.

Jian-Hong Pan

> > AIUI the "official" Manjaro kernel is carrying a bunch of
> > hacks to make type-C work via extcon, but they know that isn't an
> > upstreamable solution.
> >
> > Robin.
> >
> > > Then, the device halts all of the DRM related device jobs. For example,
> > > the operations: vop_component_ops, vop_component_ops and
> > > rockchip_dp_component_ops cannot be bound to corresponding devices. So,
> > > Xorg cannot find the correct DRM device.
> > >
> > > This patch skips the probing failed devices to fix this issue.
> > >
> > > Link: http://lists.infradead.org/pipermail/linux-rockchip/2020-September/022352.html
> > > Signed-off-by: Jian-Hong Pan <jhp@endlessos.org>
> > > ---
> > >   drivers/gpu/drm/rockchip/rockchip_drm_drv.c | 6 ++++++
> > >   1 file changed, 6 insertions(+)
> > >
> > > diff --git a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> > > index 0f3eb392fe39..de13588602b4 100644
> > > --- a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> > > +++ b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> > > @@ -331,6 +331,12 @@ static struct component_match *rockchip_drm_match_add(struct device *dev)
> > >
> > >                     if (!d)
> > >                             break;
> > > +                   if (!d->driver) {
> > > +                           DRM_DEV_ERROR(d,
> > > +                                         "%s did not probe successfully",
> > > +                                         drv->driver.name);
> > > +                           continue;
> > > +                   }
> > >
> > >                     device_link_add(dev, d, DL_FLAG_STATELESS);
> > >                     component_match_add(dev, &match, compare_dev, d);

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH] drm/rockchip: skip probed failed device
@ 2020-09-24  6:07         ` Jian-Hong Pan
  0 siblings, 0 replies; 21+ messages in thread
From: Jian-Hong Pan @ 2020-09-24  6:07 UTC (permalink / raw)
  To: Heiko Stübner
  Cc: David Airlie, Linux Upstreaming Team, Linux Kernel, dri-devel,
	linux-rockchip, Robin Murphy, linux-arm-kernel

Heiko Stübner <heiko@sntech.de> 於 2020年9月23日 週三 下午7:16寫道:
>
> Am Mittwoch, 23. September 2020, 13:05:26 CEST schrieb Robin Murphy:
> > On 2020-09-23 07:59, Jian-Hong Pan wrote:
> > > The cdn-dp sub driver probes the device failed on PINEBOOK Pro.
> > >
> > > kernel: cdn-dp fec00000.dp: [drm:cdn_dp_probe [rockchipdrm]] *ERROR* missing extcon or phy
> > > kernel: cdn-dp: probe of fec00000.dp failed with error -22
> >
> > Wouldn't it make more sense to simply not enable the DisplayPort node in
> > the upstream DT, until the type-C phy work has been done to make it
> > usable at all?
>
> Or alternatively just disable the cdn-dp Rockchip driver in the kernel config,
> which results in it also not getting probed.

This may be the simplest way.
However, considering generic distro kernels have a policy to enable
all drivers, disabling the DisplayPort node in the upstream DT, until
the type-C phy work has been done may be a better solution for now.
I can prepare a patch for this.

Jian-Hong Pan

> > AIUI the "official" Manjaro kernel is carrying a bunch of
> > hacks to make type-C work via extcon, but they know that isn't an
> > upstreamable solution.
> >
> > Robin.
> >
> > > Then, the device halts all of the DRM related device jobs. For example,
> > > the operations: vop_component_ops, vop_component_ops and
> > > rockchip_dp_component_ops cannot be bound to corresponding devices. So,
> > > Xorg cannot find the correct DRM device.
> > >
> > > This patch skips the probing failed devices to fix this issue.
> > >
> > > Link: http://lists.infradead.org/pipermail/linux-rockchip/2020-September/022352.html
> > > Signed-off-by: Jian-Hong Pan <jhp@endlessos.org>
> > > ---
> > >   drivers/gpu/drm/rockchip/rockchip_drm_drv.c | 6 ++++++
> > >   1 file changed, 6 insertions(+)
> > >
> > > diff --git a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> > > index 0f3eb392fe39..de13588602b4 100644
> > > --- a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> > > +++ b/drivers/gpu/drm/rockchip/rockchip_drm_drv.c
> > > @@ -331,6 +331,12 @@ static struct component_match *rockchip_drm_match_add(struct device *dev)
> > >
> > >                     if (!d)
> > >                             break;
> > > +                   if (!d->driver) {
> > > +                           DRM_DEV_ERROR(d,
> > > +                                         "%s did not probe successfully",
> > > +                                         drv->driver.name);
> > > +                           continue;
> > > +                   }
> > >
> > >                     device_link_add(dev, d, DL_FLAG_STATELESS);
> > >                     component_match_add(dev, &match, compare_dev, d);
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 21+ messages in thread

end of thread, other threads:[~2020-09-24  7:19 UTC | newest]

Thread overview: 21+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-17  8:34 [QUESTION] Enable PINEBOOK Pro's display Jian-Hong Pan
2020-09-23  6:59 ` [PATCH] drm/rockchip: skip probed failed device Jian-Hong Pan
2020-09-23  6:59   ` Jian-Hong Pan
2020-09-23  6:59   ` Jian-Hong Pan
2020-09-23  6:59   ` Jian-Hong Pan
2020-09-23  7:38   ` Heiko Stübner
2020-09-23  7:38     ` Heiko Stübner
2020-09-23  7:38     ` Heiko Stübner
2020-09-23  7:38     ` Heiko Stübner
2020-09-23 11:05   ` Robin Murphy
2020-09-23 11:05     ` Robin Murphy
2020-09-23 11:05     ` Robin Murphy
2020-09-23 11:05     ` Robin Murphy
2020-09-23 11:16     ` Heiko Stübner
2020-09-23 11:16       ` Heiko Stübner
2020-09-23 11:16       ` Heiko Stübner
2020-09-23 11:16       ` Heiko Stübner
2020-09-24  6:07       ` Jian-Hong Pan
2020-09-24  6:07         ` Jian-Hong Pan
2020-09-24  6:07         ` Jian-Hong Pan
2020-09-24  6:07         ` Jian-Hong Pan

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.