Message ID | 20240222-x1e80100-display-refactor-connector-v2-1-bd4197dfceab@linaro.org (mailing list archive) |
---|---|
State | Superseded |
Headers | show |
Series | drm/msm/dp: Rework the eDP/DP modes and add support for X1E80100 | expand |
On Thu, 22 Feb 2024 at 17:55, Abel Vesa <abel.vesa@linaro.org> wrote: > > Add the X1E80100 to the list of compatibles and document the is-edp > flag. The controllers are expected to operate in DP mode by default, > and this flag can be used to select eDP mode. > > Signed-off-by: Abel Vesa <abel.vesa@linaro.org> Rob, Krzysztof, Connor, gracious ping for the review. It would be really nice to merge this patchset during the next cycle. It also unbreaks several other patches. > --- > Documentation/devicetree/bindings/display/msm/dp-controller.yaml | 6 ++++++ > 1 file changed, 6 insertions(+) > > diff --git a/Documentation/devicetree/bindings/display/msm/dp-controller.yaml b/Documentation/devicetree/bindings/display/msm/dp-controller.yaml > index ae53cbfb2193..ed11852e403d 100644 > --- a/Documentation/devicetree/bindings/display/msm/dp-controller.yaml > +++ b/Documentation/devicetree/bindings/display/msm/dp-controller.yaml > @@ -27,6 +27,7 @@ properties: > - qcom,sdm845-dp > - qcom,sm8350-dp > - qcom,sm8650-dp > + - qcom,x1e80100-dp > - items: > - enum: > - qcom,sm8150-dp > @@ -73,6 +74,11 @@ properties: > - description: phy 0 parent > - description: phy 1 parent > > + is-edp: > + $ref: /schemas/types.yaml#/definitions/flag > + description: > + Tells the controller to switch to eDP mode > + > phys: > maxItems: 1 > > > -- > 2.34.1 >
On 24/02/2024 23:34, Dmitry Baryshkov wrote: > On Thu, 22 Feb 2024 at 17:55, Abel Vesa <abel.vesa@linaro.org> wrote: >> >> Add the X1E80100 to the list of compatibles and document the is-edp >> flag. The controllers are expected to operate in DP mode by default, >> and this flag can be used to select eDP mode. >> >> Signed-off-by: Abel Vesa <abel.vesa@linaro.org> > > Rob, Krzysztof, Connor, gracious ping for the review. It would be > really nice to merge this patchset during the next cycle. It also > unbreaks several other patches. That's not a netdev... or do you have the same subsystem profile expecting reviews *from everyone* within two days? Best regards, Krzysztof
On 22/02/2024 16:55, Abel Vesa wrote: > Add the X1E80100 to the list of compatibles and document the is-edp > flag. The controllers are expected to operate in DP mode by default, > and this flag can be used to select eDP mode. > > Signed-off-by: Abel Vesa <abel.vesa@linaro.org> > --- > Documentation/devicetree/bindings/display/msm/dp-controller.yaml | 6 ++++++ > 1 file changed, 6 insertions(+) > > diff --git a/Documentation/devicetree/bindings/display/msm/dp-controller.yaml b/Documentation/devicetree/bindings/display/msm/dp-controller.yaml > index ae53cbfb2193..ed11852e403d 100644 > --- a/Documentation/devicetree/bindings/display/msm/dp-controller.yaml > +++ b/Documentation/devicetree/bindings/display/msm/dp-controller.yaml > @@ -27,6 +27,7 @@ properties: > - qcom,sdm845-dp > - qcom,sm8350-dp > - qcom,sm8650-dp > + - qcom,x1e80100-dp > - items: > - enum: > - qcom,sm8150-dp > @@ -73,6 +74,11 @@ properties: > - description: phy 0 parent > - description: phy 1 parent > > + is-edp: > + $ref: /schemas/types.yaml#/definitions/flag > + description: > + Tells the controller to switch to eDP mode DP controller cannot be edp, so property "is-edp" is confusing. Probably you want to choose some phy mode, so you should rather use "phy-mode" property. I am sure we've been here... Anyway, if you define completely new property without vendor prefix, that's a generic property, so you need to put it in some common schema for all Display Controllers, not only Qualcomm. Best regards, Krzysztof
On Sun, Feb 25, 2024 at 12:34:34AM +0200, Dmitry Baryshkov wrote: > On Thu, 22 Feb 2024 at 17:55, Abel Vesa <abel.vesa@linaro.org> wrote: > > > > Add the X1E80100 to the list of compatibles and document the is-edp > > flag. The controllers are expected to operate in DP mode by default, > > and this flag can be used to select eDP mode. > > > > Signed-off-by: Abel Vesa <abel.vesa@linaro.org> > > Rob, Krzysztof, Connor, gracious ping for the review. It would be > really nice to merge this patchset during the next cycle. It also > unbreaks several other patches. The only thing that speeds up my review is reviewing whatever is ahead of this patch in the queue[1]. Rob [1] https://patchwork.ozlabs.org/project/devicetree-bindings/list/
On Tue, Feb 27, 2024 at 04:45:25PM +0100, Krzysztof Kozlowski wrote: > On 22/02/2024 16:55, Abel Vesa wrote: > > Add the X1E80100 to the list of compatibles and document the is-edp > > flag. The controllers are expected to operate in DP mode by default, > > and this flag can be used to select eDP mode. > > > > Signed-off-by: Abel Vesa <abel.vesa@linaro.org> > > --- > > Documentation/devicetree/bindings/display/msm/dp-controller.yaml | 6 ++++++ > > 1 file changed, 6 insertions(+) > > > > diff --git a/Documentation/devicetree/bindings/display/msm/dp-controller.yaml b/Documentation/devicetree/bindings/display/msm/dp-controller.yaml > > index ae53cbfb2193..ed11852e403d 100644 > > --- a/Documentation/devicetree/bindings/display/msm/dp-controller.yaml > > +++ b/Documentation/devicetree/bindings/display/msm/dp-controller.yaml > > @@ -27,6 +27,7 @@ properties: > > - qcom,sdm845-dp > > - qcom,sm8350-dp > > - qcom,sm8650-dp > > + - qcom,x1e80100-dp > > - items: > > - enum: > > - qcom,sm8150-dp > > @@ -73,6 +74,11 @@ properties: > > - description: phy 0 parent > > - description: phy 1 parent > > > > + is-edp: > > + $ref: /schemas/types.yaml#/definitions/flag > > + description: > > + Tells the controller to switch to eDP mode > > > DP controller cannot be edp, so property "is-edp" is confusing. Probably > you want to choose some phy mode, so you should rather use "phy-mode" > property. I am sure we've been here... phy-mode belongs in the phy node though. Not that you couldn't look in the phy node and see, but everyone likes all the properties they need nicely packaged up in their driver's node. > Anyway, if you define completely new property without vendor prefix, > that's a generic property, so you need to put it in some common schema > for all Display Controllers, not only Qualcomm. I'm trying to unsee what the driver is doing... Hard-coding the connector type and some instance indices. Uhhhh! I'm sure I'm to blame for rejecting those in DT. I've suggested connector nodes in the past. More generally, whatever is attached at the other end (as it could be a bridge rather than a connector) knows what mode is needed. It's simple negotiation. Each end presents what they support. You take the union of the list(s) and get the mode. If there's more than one, then the kernel or user gets to choose. Qualcomm is not the only one with this problem. Solve it for everyone... Rob
On 24-02-27 16:45:25, Krzysztof Kozlowski wrote: > On 22/02/2024 16:55, Abel Vesa wrote: > > Add the X1E80100 to the list of compatibles and document the is-edp > > flag. The controllers are expected to operate in DP mode by default, > > and this flag can be used to select eDP mode. > > > > Signed-off-by: Abel Vesa <abel.vesa@linaro.org> > > --- > > Documentation/devicetree/bindings/display/msm/dp-controller.yaml | 6 ++++++ > > 1 file changed, 6 insertions(+) > > > > diff --git a/Documentation/devicetree/bindings/display/msm/dp-controller.yaml b/Documentation/devicetree/bindings/display/msm/dp-controller.yaml > > index ae53cbfb2193..ed11852e403d 100644 > > --- a/Documentation/devicetree/bindings/display/msm/dp-controller.yaml > > +++ b/Documentation/devicetree/bindings/display/msm/dp-controller.yaml > > @@ -27,6 +27,7 @@ properties: > > - qcom,sdm845-dp > > - qcom,sm8350-dp > > - qcom,sm8650-dp > > + - qcom,x1e80100-dp > > - items: > > - enum: > > - qcom,sm8150-dp > > @@ -73,6 +74,11 @@ properties: > > - description: phy 0 parent > > - description: phy 1 parent > > > > + is-edp: > > + $ref: /schemas/types.yaml#/definitions/flag > > + description: > > + Tells the controller to switch to eDP mode > > > DP controller cannot be edp, so property "is-edp" is confusing. Probably > you want to choose some phy mode, so you should rather use "phy-mode" > property. I am sure we've been here... phy-mode in controller node or in the phy node? > > Anyway, if you define completely new property without vendor prefix, > that's a generic property, so you need to put it in some common schema > for all Display Controllers, not only Qualcomm. I can re-spin with qcom,is-edp if that's better. > > > Best regards, > Krzysztof >
On Fri, 1 Mar 2024 at 19:52, Rob Herring <robh@kernel.org> wrote: > > On Tue, Feb 27, 2024 at 04:45:25PM +0100, Krzysztof Kozlowski wrote: > > On 22/02/2024 16:55, Abel Vesa wrote: > > > Add the X1E80100 to the list of compatibles and document the is-edp > > > flag. The controllers are expected to operate in DP mode by default, > > > and this flag can be used to select eDP mode. > > > > > > Signed-off-by: Abel Vesa <abel.vesa@linaro.org> > > > --- > > > Documentation/devicetree/bindings/display/msm/dp-controller.yaml | 6 ++++++ > > > 1 file changed, 6 insertions(+) > > > > > > diff --git a/Documentation/devicetree/bindings/display/msm/dp-controller.yaml b/Documentation/devicetree/bindings/display/msm/dp-controller.yaml > > > index ae53cbfb2193..ed11852e403d 100644 > > > --- a/Documentation/devicetree/bindings/display/msm/dp-controller.yaml > > > +++ b/Documentation/devicetree/bindings/display/msm/dp-controller.yaml > > > @@ -27,6 +27,7 @@ properties: > > > - qcom,sdm845-dp > > > - qcom,sm8350-dp > > > - qcom,sm8650-dp > > > + - qcom,x1e80100-dp > > > - items: > > > - enum: > > > - qcom,sm8150-dp > > > @@ -73,6 +74,11 @@ properties: > > > - description: phy 0 parent > > > - description: phy 1 parent > > > > > > + is-edp: > > > + $ref: /schemas/types.yaml#/definitions/flag > > > + description: > > > + Tells the controller to switch to eDP mode > > > > > > DP controller cannot be edp, so property "is-edp" is confusing. Probably > > you want to choose some phy mode, so you should rather use "phy-mode" > > property. I am sure we've been here... > > phy-mode belongs in the phy node though. Not that you couldn't look in > the phy node and see, but everyone likes all the properties they need > nicely packaged up in their driver's node. > > > Anyway, if you define completely new property without vendor prefix, > > that's a generic property, so you need to put it in some common schema > > for all Display Controllers, not only Qualcomm. Is there a generic schema for DisplayPort controllers? I think there is none at this point. We can probably add it, declaring is-edp property, link-frequencies, etc. However Mediatek already uses a different option to specify supported link frequencies. > > I'm trying to unsee what the driver is doing... Hard-coding the > connector type and some instance indices. Uhhhh! I'm sure I'm to blame > for rejecting those in DT. Once this patchset is accepted (in this or that or whatever else form), we will cleanup most of those hardcoded types. > > I've suggested connector nodes in the past. More generally, whatever is > attached at the other end (as it could be a bridge rather than a > connector) knows what mode is needed. It's simple negotiation. Each end > presents what they support. You take the union of the list(s) and get > the mode. If there's more than one, then the kernel or user gets to > choose. It's not that easy. First, probing of the bridge chain differs slightly depending on whether the controller is eDP or DP controller. eDP should use AUX BUS, while DP (currently) doesn't use it. More importantly, error conditions differ too. For example, in the DP case it is perfectly fine to have nothing attached to the controller. It just means that the display chain needs no additional handling and the HPD pin will be handled by the controller itself. In the eDP case if neither a panel nor a bridge are attached, it is considered to be an error and thus the driver will return probe error. > Qualcomm is not the only one with this problem. Solve it for everyone...
diff --git a/Documentation/devicetree/bindings/display/msm/dp-controller.yaml b/Documentation/devicetree/bindings/display/msm/dp-controller.yaml index ae53cbfb2193..ed11852e403d 100644 --- a/Documentation/devicetree/bindings/display/msm/dp-controller.yaml +++ b/Documentation/devicetree/bindings/display/msm/dp-controller.yaml @@ -27,6 +27,7 @@ properties: - qcom,sdm845-dp - qcom,sm8350-dp - qcom,sm8650-dp + - qcom,x1e80100-dp - items: - enum: - qcom,sm8150-dp @@ -73,6 +74,11 @@ properties: - description: phy 0 parent - description: phy 1 parent + is-edp: + $ref: /schemas/types.yaml#/definitions/flag + description: + Tells the controller to switch to eDP mode + phys: maxItems: 1
Add the X1E80100 to the list of compatibles and document the is-edp flag. The controllers are expected to operate in DP mode by default, and this flag can be used to select eDP mode. Signed-off-by: Abel Vesa <abel.vesa@linaro.org> --- Documentation/devicetree/bindings/display/msm/dp-controller.yaml | 6 ++++++ 1 file changed, 6 insertions(+)