drm/mxsfb: Add an entry for "fsl,imx8mq-lcdif"
Subsystems (5)
Fabio Estevam
reviewerPATCH 1/3 drm/mxsfb: Add an entry for "fsl,imx8mq-lcdif"
From: Fabio Estevam <[email protected]>
On i.MX6SX, the LCDIF has an associated power domain.
However, i.MX8MQ does not have an LCDIF power domain.
imx8mq.dtsi has the following compatible string:
compatible = "fsl,imx8mq-lcdif", "fsl,imx6sx-lcdif";
which causes the following dt-schema warning:
imx8mq-evk.dtb: lcd-controller@30320000: 'power-domains' is a required property
from schema $id: http://devicetree.org/schemas/display/fsl,lcdif.yaml#
To prevent this problem, add a specific fsl,imx8mq-lcdif entry in the driver to properly handle such a power-domain requirement difference.
--- drivers/gpu/drm/mxsfb/mxsfb_drv.c | 1 + 1 file changed, 1 insertion(+)
drivers/gpu/drm/mxsfb/mxsfb_drv.c +1 -0
@@ -340,6 +340,7 @@ static const struct of_device_id mxsfb_dt_ids[] = { { .compatible = "fsl,imx23-lcdif", .data = &mxsfb_devdata[MXSFB_V3], }, { .compatible = "fsl,imx28-lcdif", .data = &mxsfb_devdata[MXSFB_V4], }, { .compatible = "fsl,imx6sx-lcdif", .data = &mxsfb_devdata[MXSFB_V6], }, + { .compatible = "fsl,imx8mq-lcdif", .data = &mxsfb_devdata[MXSFB_V6], }, { /* sentinel */ } }; MODULE_DEVICE_TABLE(of, mxsfb_dt_ids);
Signature · 1 line
2.34.1
Fabio Estevam
reviewerPATCH 2/3 dt-bindings: lcdif: Decouple imx8mq from imx6sx
From: Fabio Estevam <[email protected]>
On i.MX6SX, the LCDIF has an associated power domain.
i.MX8MQ does not have an LCDIF power domain, so allow passing only "fsl,imx8mq-lcdif" as compatible string to fix the following dt-schema warning:
imx8mq-evk.dtb: lcd-controller@30320000: 'power-domains' is a required property
from schema $id: http://devicetree.org/schemas/display/fsl,lcdif.yaml#
--- Documentation/devicetree/bindings/display/fsl,lcdif.yaml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-)
Documentation/devicetree/bindings/display/fsl,lcdif.yaml +5 -1
@@ -20,6 +20,7 @@ properties: - fsl,imx23-lcdif - fsl,imx28-lcdif - fsl,imx6sx-lcdif + - fsl,imx8mq-lcdif - fsl,imx8mp-lcdif - fsl,imx93-lcdif - items:
@@ -77,7 +78,9 @@ allOf: properties: compatible: contains: - const: fsl,imx6sx-lcdif + enum: + - fsl,imx6sx-lcdif + - fsl,imx8mq-lcdif then: properties: clocks:
@@ -113,6 +116,7 @@ allOf: enum: - fsl,imx6sx-lcdif - fsl,imx8mp-lcdif + - fsl,imx8mq-lcdif - fsl,imx93-lcdif then: properties:
Signature · 1 line
2.34.1
Re: [PATCH 2/3] dt-bindings: lcdif: Decouple imx8mq from imx6sx
Quoted 4 lines · Fabio Estevam
From: Fabio Estevam <[email protected]>
On i.MX6SX, the LCDIF has an associated power domain.
Quoted 8 lines
i.MX8MQ does not have an LCDIF power domain, so allow passing only "fsl,imx8mq-lcdif" as compatible string to fix the following dt-schema warning:
imx8mq-evk.dtb: lcd-controller@30320000: 'power-domains' is a required property
from schema $id: http://devicetree.org/schemas/display/fsl,lcdif.yaml#Signed-off-by Fabio Estevam <[email protected]>
Cheers,
Conor.
Fabio Estevam
reviewerPATCH 3/3 arm64: dts: imx8mq: Exclude "fsl,imx6sx-lcdif"
In reply to Fabio EstevamFrom: Fabio Estevam <[email protected]>
On i.MX6SX, the LCDIF has an associated power domain.
i.MX8MQ does not have an LCDIF power domain, so pass only "fsl,imx8mq-lcdif" as compatible string to fix the following dt-schema warning:
imx8mq-evk.dtb: lcd-controller@30320000: 'power-domains' is a required property
from schema $id: http://devicetree.org/schemas/display/fsl,lcdif.yaml#
--- arch/arm64/boot/dts/freescale/imx8mq.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm64/boot/dts/freescale/imx8mq.dtsi +1 -1
@@ -739,7 +739,7 @@ sdma2: dma-controller@302c0000 { }; lcdif: lcd-controller@30320000 { - compatible = "fsl,imx8mq-lcdif", "fsl,imx6sx-lcdif"; + compatible = "fsl,imx8mq-lcdif"; reg = <0x30320000 0x10000>; interrupts = <GIC_SPI 5 IRQ_TYPE_LEVEL_HIGH>; clocks = <&clk IMX8MQ_CLK_LCDIF_PIXEL>,
Signature · 1 line
2.34.1
Hi Fabio,
Am Montag, dem 11.12.2023 um 17:41 -0300 schrieb Fabio Estevam:
Quoted 10 lines
From: Fabio Estevam <[email protected]>
On i.MX6SX, the LCDIF has an associated power domain.
However, i.MX8MQ does not have an LCDIF power domain.
imx8mq.dtsihas the following compatible string:compatible = "fsl,imx8mq-lcdif", "fsl,imx6sx-lcdif";
Quoted 8 lines
which causes the following dt-schema warning:
imx8mq-evk.dtb: lcd-controller@30320000: 'power-domains' is a required property
from schema $id: http://devicetree.org/schemas/display/fsl,lcdif.yaml#To prevent this problem, add a specific fsl,imx8mq-lcdif entry in the driver to properly handle such a power-domain requirement difference.
I don't really like this series. While we don't make any strong guarantees in this way, it breaks booting older kernels with a new DT.
As this driver patch shows, there are no actual differences in the IP block between i.MX6SX and i.MX8MQ, it's just the SoC integration that's different, where in one SoC the controller is located in a power domain, while it isn't in another.
To me this smells like making changes to parts that don't really care about those differences. The thing that cares about the difference is the DT schema validation and I feel like there must be a better way to describe this in the schema than to patch both driver and DT just to accommodate a SoC integration difference. Is there a way to make the power-domain property not dependent on the IP block, but the machine compatible?
Regards,
Lucas
Quoted 17 lines
Signed-off-by Fabio Estevam <[email protected]>--- drivers/gpu/drm/mxsfb/mxsfb_drv.c | 1 + 1 file changed, 1 insertion(+)drivers/gpu/drm/mxsfb/mxsfb_drv.c +1
-0@@ -340,6 +340,7 @@ static const struct of_device_id mxsfb_dt_ids[] = { { .compatible = "fsl,imx23-lcdif", .data = &mxsfb_devdata[MXSFB_V3], }, { .compatible = "fsl,imx28-lcdif", .data = &mxsfb_devdata[MXSFB_V4], }, { .compatible = "fsl,imx6sx-lcdif", .data = &mxsfb_devdata[MXSFB_V6], }, + { .compatible = "fsl,imx8mq-lcdif", .data = &mxsfb_devdata[MXSFB_V6], }, { /* sentinel */ } }; MODULE_DEVICE_TABLE(of, mxsfb_dt_ids);
Fabio Estevam
reviewerHi Lucas,
Quoted 2 lines · Lucas Stach
I don't really like this series. While we don't make any strong guarantees in this way, it breaks booting older kernels with a new DT.
I thought we needed only to guarantee that old DTs still run with newer kernels, not the other way around.
Quoted 5 lines
As this driver patch shows, there are no actual differences in the IP block between i.MX6SX and i.MX8MQ, it's just the SoC integration that's different, where in one SoC the controller is located in a power domain, while it isn't in another.
Quoted 7 lines
To me this smells like making changes to parts that don't really care about those differences. The thing that cares about the difference is the DT schema validation and I feel like there must be a better way to describe this in the schema than to patch both driver and DT just to accommodate a SoC integration difference. Is there a way to make the power-domain property not dependent on the IP block, but the machine compatible?
Yes, this series is all about making dt-schema validation happy.
If there is a better alternative, I am all ears.
Rob, Krzysztof, Conor
Any suggestions?
Thanks
Hi Fabio,
Am Dienstag, dem 12.12.2023 um 15:28 -0300 schrieb Fabio Estevam:
Quoted 10 lines
Hi Lucas,
Quoted 2 lines · Lucas Stach
I don't really like this series. While we don't make any strong guarantees in this way, it breaks booting older kernels with a new DT.
I thought we needed only to guarantee that old DTs still run with newer kernels, not the other way around.
That's right. At least in the i.MX world we never made a strong guarantee in that way.
Still we should not break it deliberately if there isn't a good reason to do so. And I _feel_ that "DT schema isn't able to express the SoC integration" isn't a good enough reason to break things.
But maybe there is a way to describe this in the DT schema, that we aren't aware of yet. I'm not quite up-to-date with all the DT schema stuff...
Regards,
Lucas