Skip to contentSkip to conversation

dt-bindings: trivial-devices: Document elgin,jg10309-01

PATCH Superseded Fabio Estevam 4 participants 13 messages Jul 19, 2024 – Aug 29, 2024

Subsystems (3)

v2 of 4 Superseded Latest is v4 →

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/3 dt-bindings: trivial-devices: Document elgin,jg10309-01

The rv1108-elgin-r1 board has an LCD controlled via SPI in userspace. The marking on the LCD is JG10309-01.

Add an entry for the "elgin,jg10309-01" compatible string.

---
Changes since v1:
- Use a more specific compatible string. (Conor)

 Documentation/devicetree/bindings/trivial-devices.yaml | 2 ++
 1 file changed, 2 insertions(+)
Documentation/devicetree/bindings/trivial-devices.yaml +2 -0
index 7913ca9b6b54..49dee2a1f6b4 100644
@@ -110,6 +110,8 @@ properties:
           - domintech,dmard09
             # DMARD10: 3-axis Accelerometer
           - domintech,dmard10
+            # Elgin SPI-controlled LCD
+          - elgin,jg10309-01
             # MMA7660FC: 3-Axis Orientation/Motion Detection Sensor
           - fsl,mma7660
             # MMA8450Q: Xtrinsic Low-power, 3-axis Xtrinsic Accelerometer
Signature · 1 line
2.34.1
#1 lore raw

PATCH v2 2/3 spi: spidev: Add an entry for elgin,jg10309-01

The rv1108-elgin-r1 board has an LCD controlled via SPI in userspace. The marking on the LCD is JG10309-01.

Add the "elgin,jg10309-01" compatible string.

---
Changes since v1:
- Use a more specific compatible string. (Conor)

 drivers/spi/spidev.c | 1 +
 1 file changed, 1 insertion(+)
drivers/spi/spidev.c +1 -0
index 05e6d007f9a7..316ed3664cb2 100644
@@ -730,6 +730,7 @@ static int spidev_of_check(struct device *dev)
 static const struct of_device_id spidev_dt_ids[] = {
 	{ .compatible = "cisco,spi-petra", .data = &spidev_of_check },
 	{ .compatible = "dh,dhcom-board", .data = &spidev_of_check },
+	{ .compatible = "elgin,jg10309-01", .data = &spidev_of_check },
 	{ .compatible = "lineartechnology,ltc2488", .data = &spidev_of_check },
 	{ .compatible = "lwn,bk4", .data = &spidev_of_check },
 	{ .compatible = "menlo,m53cpld", .data = &spidev_of_check },
Signature · 1 line
2.34.1
maintainer Reviewed-by on v2 2/3
#2 lore raw

Re: [PATCH v2 2/3] spi: spidev: Add an entry for elgin,jg10309-01

Am Freitag, 19. Juli 2024, 13:12:09 CEST schrieb Fabio Estevam:

Quoted 6 lines

The rv1108-elgin-r1 board has an LCD controlled via SPI in userspace. The marking on the LCD is JG10309-01.

Add the "elgin,jg10309-01" compatible string.

Quoted 20 lines

---
Changes since v1:
- Use a more specific compatible string. (Conor)

 drivers/spi/spidev.c | 1 +
 1 file changed, 1 insertion(+)
drivers/spi/spidev.c +1 -0
index 05e6d007f9a7..316ed3664cb2 100644
@@ -730,6 +730,7 @@ static int spidev_of_check(struct device *dev)
 static const struct of_device_id spidev_dt_ids[] = {
 	{ .compatible = "cisco,spi-petra", .data = &spidev_of_check },
 	{ .compatible = "dh,dhcom-board", .data = &spidev_of_check },
+	{ .compatible = "elgin,jg10309-01", .data = &spidev_of_check },
 	{ .compatible = "lineartechnology,ltc2488", .data = &spidev_of_check },
 	{ .compatible = "lwn,bk4", .data = &spidev_of_check },
 	{ .compatible = "menlo,m53cpld", .data = &spidev_of_check },
#3 lore raw

PATCH v2 3/3 ARM: dts: rockchip: rv1108-elgin-r1: Do not describe unexisting DAC device

In reply to Fabio Estevam

There is no DAC connected to the SPI bus of the Elgin RV1108 R1 board.

There is a JG10309-01 LCD controlled via SPI though.

Properly describe it by adding the "elgin,jg10309-01" compatible string.

---
Changes since v1:
- Use a more specific compatible string. (Conor)

 arch/arm/boot/dts/rockchip/rv1108-elgin-r1.dts | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
arch/arm/boot/dts/rockchip/rv1108-elgin-r1.dts +2 -2
index 2d9994379eb2..971bb617e845 100644
@@ -168,8 +168,8 @@ &spi {
 	pinctrl-0 = <&spim1_clk &spim1_cs0 &spim1_tx &spim1_rx>;
 	status = "okay";
 
-	dh2228fv: dac@0 {
-		compatible = "rohm,dh2228fv";
+	display: display@0 {
+		compatible = "elgin,jg10309-01";
 		reg = <0>;
 		spi-max-frequency = <24000000>;
 		spi-cpha;
Signature · 1 line
2.34.1
maintainer Acked-by on v2 3/3
#4 lore raw

Re: [PATCH v2 3/3] ARM: dts: rockchip: rv1108-elgin-r1: Do not describe unexisting DAC device

Am Freitag, 19. Juli 2024, 13:12:10 CEST schrieb Fabio Estevam:

Quoted 10 lines

There is no DAC connected to the SPI bus of the Elgin RV1108 R1 board.

There is a JG10309-01 LCD controlled via SPI though.

Properly describe it by adding the "elgin,jg10309-01" compatible string.

Mark, do you want to take all 3 patches (fine by me) or just the first two?

Heiko

#5 lore raw

Re: [PATCH v2 3/3] ARM: dts: rockchip: rv1108-elgin-r1: Do not describe unexisting DAC device

Hi Heiko,

Quoted 4 lines · Heiko Stübner

Mark, do you want to take all 3 patches (fine by me) or just the first two?

Mark has applied the spidev patch on his for-6.11 branch:

https://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git/commit/?h=for-6.11&id=5f3eee1eef5d0edd23d8ac0974f56283649a1512

Could you please apply the other two to your tree?

Thanks

maintainer
#6 lore raw

Re: [PATCH v2 3/3] ARM: dts: rockchip: rv1108-elgin-r1: Do not describe unexisting DAC device

Hi Fabio,

Am Donnerstag, 29. August 2024, 19:31:58 CEST schrieb Fabio Estevam:

Quoted 12 lines · Heiko Stübner
Quoted 5 lines

Mark, do you want to take all 3 patches (fine by me) or just the first two?

Mark has applied the spidev patch on his for-6.11 branch:

https://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git/commit/?h=for-6.11&id=5f3eee1eef5d0edd23d8ac0974f56283649a1512

Could you please apply the other two to your tree?

Actually Mark has applied patches 1+2 from v4 it seems, so I grabbed the dts patch from there too :-)

Heiko

Acked-by on v2 1/3
#7 lore raw
In reply to Fabio Estevam
Quoted 6 lines · Fabio Estevam

The rv1108-elgin-r1 board has an LCD controlled via SPI in userspace. The marking on the LCD is JG10309-01.

Add an entry for the "elgin,jg10309-01" compatible string.

Please send cover letter for patch series. The whole lot seems fine, although ideally this wouldn't be in trivial devices - but I think the series is an improvement on lying about what's on the board ;)

maintainer
#8 lore raw

Am Freitag, 19. Juli 2024, 16:45:24 CEST schrieb Conor Dooley:

Quoted 12 lines · Fabio Estevam
Quoted 6 lines

The rv1108-elgin-r1 board has an LCD controlled via SPI in userspace. The marking on the LCD is JG10309-01.

Add an entry for the "elgin,jg10309-01" compatible string.

Please send cover letter for patch series. The whole lot seems fine, although ideally this wouldn't be in trivial devices - but I think the series is an improvement on lying about what's on the board ;)

with the error Rob's bot reported about the usage of spi-cpol and spi-cpha, it really looks like the bindings needs to be more fleshed out.

#9 lore raw

Hi Heiko,

Quoted 2 lines · Heiko Stübner

with the error Rob's bot reported about the usage of spi-cpol and spi-cpha, it really looks like the bindings needs to be more fleshed out.

I just wanted to let you know that the warning reported by Rob's bot is very old.

Running "make dtbs_check DT_SCHEMA_FILES=trivial-devices.yaml" on the existing tree:

DTC [C] arch/arm/boot/dts/rockchip/rv1108-elgin-r1.dtb
rv1108-elgin-r1.dtb: dac@0: 'spi-cpha', 'spi-cpol' do not match any of the regexes: 'pinctrl-[0-9]+'
from schema $id: http://devicetree.org/schemas/trivial-devices.yaml#

So we are not making things worse in this aspect.

I can work on removing the warnings as an incremental patch, if you agree.

Regards,

Fabio Estevam

#10 lore raw
Quoted 13 lines · Fabio Estevam

Hi Heiko,

Quoted 2 lines · Heiko Stübner

with the error Rob's bot reported about the usage of spi-cpol and spi-cpha, it really looks like the bindings needs to be more fleshed out.

I just wanted to let you know that the warning reported by Rob's bot is very old.

Running "make dtbs_check DT_SCHEMA_FILES=trivial-devices.yaml" on the existing tree:

Quoted 8 lines

DTC [C] arch/arm/boot/dts/rockchip/rv1108-elgin-r1.dtb
rv1108-elgin-r1.dtb: dac@0: 'spi-cpha', 'spi-cpol' do not match any of the regexes: 'pinctrl-[0-9]+'
from schema $id: http://devicetree.org/schemas/trivial-devices.yaml#

So we are not making things worse in this aspect.

I can work on removing the warnings as an incremental patch, if you agree.

Yeah, I acked it cos the issue would've been there before so it's not any worse. I think adding a "real" binding can be a follow on.

#11 lore raw
In reply to Fabio Estevam
Quoted 5 lines · Fabio Estevam

The rv1108-elgin-r1 board has an LCD controlled via SPI in userspace. The marking on the LCD is JG10309-01.

Add an entry for the "elgin,jg10309-01" compatible string.

Quoted 8 lines

---
Changes since v1:
- Use a more specific compatible string. (Conor)

 Documentation/devicetree/bindings/trivial-devices.yaml | 2 ++
 1 file changed, 2 insertions(+)

My bot found new DTB warnings on the .dts files added or changed in this series.

Some warnings may be from an existing SoC .dtsi. Or perhaps the warnings are fixed by another series. Ultimately, it is up to the platform maintainer whether these warnings are acceptable or not. No need to reply unless the platform maintainer has comments.

If you already ran DT checks and didn't see these error(s), then make sure dt-schema is up to date:

  pip3 install dtschema --upgrade

New warnings running 'make CHECK_DTBS=y rockchip/rv1108-elgin-r1.dtb' for [email protected]:

arch/arm/boot/dts/rockchip/rv1108-elgin-r1.dtb: display@0: 'spi-cpha', 'spi-cpol' do not match any of the regexes: 'pinctrl-[0-9]+'
from schema $id: http://devicetree.org/schemas/trivial-devices.yaml#

maintainer Acked-by on v2 1/3
#12 lore raw
In reply to Fabio Estevam

Am Freitag, 19. Juli 2024, 13:12:08 CEST schrieb Fabio Estevam:

Quoted 6 lines

The rv1108-elgin-r1 board has an LCD controlled via SPI in userspace. The marking on the LCD is JG10309-01.

Add an entry for the "elgin,jg10309-01" compatible string.

Quoted 21 lines

---
Changes since v1:
- Use a more specific compatible string. (Conor)

 Documentation/devicetree/bindings/trivial-devices.yaml | 2 ++
 1 file changed, 2 insertions(+)
Documentation/devicetree/bindings/trivial-devices.yaml +2 -0
index 7913ca9b6b54..49dee2a1f6b4 100644
@@ -110,6 +110,8 @@ properties:
           - domintech,dmard09
             # DMARD10: 3-axis Accelerometer
           - domintech,dmard10
+            # Elgin SPI-controlled LCD
+          - elgin,jg10309-01
             # MMA7660FC: 3-Axis Orientation/Motion Detection Sensor
           - fsl,mma7660
             # MMA8450Q: Xtrinsic Low-power, 3-axis Xtrinsic Accelerometer