Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

arm64: dts: qcom: msm8953-10or-g: Add initial device tree #204

Open
wants to merge 2 commits into
base: 6.9.1/main
Choose a base branch
from

Conversation

MarvelMathesh
Copy link

10or G is a handset using the MSM8953 SoC released in 2017

Add a device tree with initial support for:

  • GPIO keys
  • SDHCI (internal and external storage)
  • USB Device Mode
  • WCNSS (WiFi/BT)
  • Regulators

@MarvelMathesh
Copy link
Author

MarvelMathesh commented Jun 14, 2024

I've attempted various solutions to boot with display by referencing similar msm8953 devices, but I still can't get it to work. I'm looking for any possible workarounds to resolve this issue.

In lsmod, I can see these modules are built, but they are not being used.

I've tried these workarounds, but the screen is still blank after the penguin logo.

	chosen {
		#address-cells = <2>;
		#size-cells = <2>;
		ranges;

		framebuffer@90001000 {
			compatible = "simple-framebuffer";
			reg = <0 0x90001000 0 (1920 * 1080 * 3)>;

			width = <1080>;
			height = <1920>;
			stride = <(1080 * 3)>;
			format = "r8g8b8";

			power-domains = <&gcc MDSS_GDSC>;

			clocks = <&gcc GCC_MDSS_AHB_CLK>,
				 <&gcc GCC_MDSS_AXI_CLK>,
				 <&gcc GCC_MDSS_VSYNC_CLK>,
				 <&gcc GCC_MDSS_MDP_CLK>,
				 <&gcc GCC_MDSS_BYTE0_CLK>,
				 <&gcc GCC_MDSS_PCLK0_CLK>,
				 <&gcc GCC_MDSS_ESC0_CLK>;
		};
	};
	
&mdss_dsi0 {
	vdda-supply = <&pm8953_s3>;
	vddio-supply = <&pm8953_l6>;
	status = "okay";

	panel: panel@0 {
		compatible = "10or,g-panel";
		reg = <0>;

		backlight = <&pmi8950_wled>;

		reset-gpios = <&tlmm 61 GPIO_ACTIVE_LOW>;

		pinctrl-names = "default", "sleep";
		pinctrl-0 = <&pmx_mdss_default &mdss_te_default>;
		pinctrl-1 = <&pmx_mdss_sleep &mdss_te_default>;

		vsp-supply = <&lab_vreg>;
		vsn-supply = <&ibb_vreg>;

		port {
			panel_in: endpoint {
				remote-endpoint = <&mdss_dsi0_out>;
			};
		};
	};
};

&mdss_dsi0_out {
	data-lanes = <0 1 2 3>;
	remote-endpoint = <&panel_in>;
};

&mdss_dsi0_phy {
	vddio-supply = <&pm8953_l6>;
	vcca-supply = <&pm8953_l3>;

	status = "okay";
};
	
&mdss {
	status = "okay";
};

&pmi8950_wled {
	qcom,current-limit-microamp = <20000>;
	qcom,ovp-millivolt = <29600>;
	qcom,num-strings = <2>;

	status = "okay";
};	

@M0Rf30
Copy link

M0Rf30 commented Jun 27, 2024

Avoid a third commit. newline fix commit belongs to the first one. You should have a commit for the dts and one for the panel

@barni2000
Copy link
Member

barni2000 commented Jun 27, 2024

I've attempted various solutions to boot with display by referencing similar msm8953 devices, but I still can't get it to work. I'm looking for any possible workarounds to resolve this issue.

In lsmod, I can see these modules are built, but they are not being used.

I've tried these workarounds, but the screen is still blank after the penguin logo.

	chosen {
		#address-cells = <2>;
		#size-cells = <2>;
		ranges;

		framebuffer@90001000 {
			compatible = "simple-framebuffer";
			reg = <0 0x90001000 0 (1920 * 1080 * 3)>;

			width = <1080>;
			height = <1920>;
			stride = <(1080 * 3)>;
			format = "r8g8b8";

			power-domains = <&gcc MDSS_GDSC>;

			clocks = <&gcc GCC_MDSS_AHB_CLK>,
				 <&gcc GCC_MDSS_AXI_CLK>,
				 <&gcc GCC_MDSS_VSYNC_CLK>,
				 <&gcc GCC_MDSS_MDP_CLK>,
				 <&gcc GCC_MDSS_BYTE0_CLK>,
				 <&gcc GCC_MDSS_PCLK0_CLK>,
				 <&gcc GCC_MDSS_ESC0_CLK>;
		};
	};
	
&mdss_dsi0 {
	vdda-supply = <&pm8953_s3>;
	vddio-supply = <&pm8953_l6>;
	status = "okay";

	panel: panel@0 {
		compatible = "10or,g-panel";
		reg = <0>;

		backlight = <&pmi8950_wled>;

		reset-gpios = <&tlmm 61 GPIO_ACTIVE_LOW>;

		pinctrl-names = "default", "sleep";
		pinctrl-0 = <&pmx_mdss_default &mdss_te_default>;
		pinctrl-1 = <&pmx_mdss_sleep &mdss_te_default>;

		vsp-supply = <&lab_vreg>;
		vsn-supply = <&ibb_vreg>;

		port {
			panel_in: endpoint {
				remote-endpoint = <&mdss_dsi0_out>;
			};
		};
	};
};

&mdss_dsi0_out {
	data-lanes = <0 1 2 3>;
	remote-endpoint = <&panel_in>;
};

&mdss_dsi0_phy {
	vddio-supply = <&pm8953_l6>;
	vcca-supply = <&pm8953_l3>;

	status = "okay";
};
	
&mdss {
	status = "okay";
};

&pmi8950_wled {
	qcom,current-limit-microamp = <20000>;
	qcom,ovp-millivolt = <29600>;
	qcom,num-strings = <2>;

	status = "okay";
};	

Can you show a dmesg dump?
And a /sys/firmware/fdt dump from mainline

@MarvelMathesh
Copy link
Author

dmesg.log
I rebuilt this using the main branch today, but I'm now unable to locate any logs in the fdt or panel module lsmod. Right now, I see brief blue screen flashing following the Linux logo (I think so it was because of stdout-path = "serial0";).

I've attempted various solutions to boot with display by referencing similar msm8953 devices, but I still can't get it to work. I'm looking for any possible workarounds to resolve this issue.
In lsmod, I can see these modules are built, but they are not being used.
I've tried these workarounds, but the screen is still blank after the penguin logo.

	chosen {
		#address-cells = <2>;
		#size-cells = <2>;
		ranges;

		framebuffer@90001000 {
			compatible = "simple-framebuffer";
			reg = <0 0x90001000 0 (1920 * 1080 * 3)>;

			width = <1080>;
			height = <1920>;
			stride = <(1080 * 3)>;
			format = "r8g8b8";

			power-domains = <&gcc MDSS_GDSC>;

			clocks = <&gcc GCC_MDSS_AHB_CLK>,
				 <&gcc GCC_MDSS_AXI_CLK>,
				 <&gcc GCC_MDSS_VSYNC_CLK>,
				 <&gcc GCC_MDSS_MDP_CLK>,
				 <&gcc GCC_MDSS_BYTE0_CLK>,
				 <&gcc GCC_MDSS_PCLK0_CLK>,
				 <&gcc GCC_MDSS_ESC0_CLK>;
		};
	};
	
&mdss_dsi0 {
	vdda-supply = <&pm8953_s3>;
	vddio-supply = <&pm8953_l6>;
	status = "okay";

	panel: panel@0 {
		compatible = "10or,g-panel";
		reg = <0>;

		backlight = <&pmi8950_wled>;

		reset-gpios = <&tlmm 61 GPIO_ACTIVE_LOW>;

		pinctrl-names = "default", "sleep";
		pinctrl-0 = <&pmx_mdss_default &mdss_te_default>;
		pinctrl-1 = <&pmx_mdss_sleep &mdss_te_default>;

		vsp-supply = <&lab_vreg>;
		vsn-supply = <&ibb_vreg>;

		port {
			panel_in: endpoint {
				remote-endpoint = <&mdss_dsi0_out>;
			};
		};
	};
};

&mdss_dsi0_out {
	data-lanes = <0 1 2 3>;
	remote-endpoint = <&panel_in>;
};

&mdss_dsi0_phy {
	vddio-supply = <&pm8953_l6>;
	vcca-supply = <&pm8953_l3>;

	status = "okay";
};
	
&mdss {
	status = "okay";
};

&pmi8950_wled {
	qcom,current-limit-microamp = <20000>;
	qcom,ovp-millivolt = <29600>;
	qcom,num-strings = <2>;

	status = "okay";
};	

Can you show a dmesg dump? And a /sys/firmware/fdt dump from mainline

@barni2000
Copy link
Member

dmesg.log I rebuilt this using the main branch today, but I'm now unable to locate any logs in the fdt or panel module lsmod. Right now, I see brief blue screen flashing following the Linux logo (I think so it was because of stdout-path = "serial0";).

I've attempted various solutions to boot with display by referencing similar msm8953 devices, but I still can't get it to work. I'm looking for any possible workarounds to resolve this issue.
In lsmod, I can see these modules are built, but they are not being used.
I've tried these workarounds, but the screen is still blank after the penguin logo.

	chosen {
		#address-cells = <2>;
		#size-cells = <2>;
		ranges;

		framebuffer@90001000 {
			compatible = "simple-framebuffer";
			reg = <0 0x90001000 0 (1920 * 1080 * 3)>;

			width = <1080>;
			height = <1920>;
			stride = <(1080 * 3)>;
			format = "r8g8b8";

			power-domains = <&gcc MDSS_GDSC>;

			clocks = <&gcc GCC_MDSS_AHB_CLK>,
				 <&gcc GCC_MDSS_AXI_CLK>,
				 <&gcc GCC_MDSS_VSYNC_CLK>,
				 <&gcc GCC_MDSS_MDP_CLK>,
				 <&gcc GCC_MDSS_BYTE0_CLK>,
				 <&gcc GCC_MDSS_PCLK0_CLK>,
				 <&gcc GCC_MDSS_ESC0_CLK>;
		};
	};
	
&mdss_dsi0 {
	vdda-supply = <&pm8953_s3>;
	vddio-supply = <&pm8953_l6>;
	status = "okay";

	panel: panel@0 {
		compatible = "10or,g-panel";
		reg = <0>;

		backlight = <&pmi8950_wled>;

		reset-gpios = <&tlmm 61 GPIO_ACTIVE_LOW>;

		pinctrl-names = "default", "sleep";
		pinctrl-0 = <&pmx_mdss_default &mdss_te_default>;
		pinctrl-1 = <&pmx_mdss_sleep &mdss_te_default>;

		vsp-supply = <&lab_vreg>;
		vsn-supply = <&ibb_vreg>;

		port {
			panel_in: endpoint {
				remote-endpoint = <&mdss_dsi0_out>;
			};
		};
	};
};

&mdss_dsi0_out {
	data-lanes = <0 1 2 3>;
	remote-endpoint = <&panel_in>;
};

&mdss_dsi0_phy {
	vddio-supply = <&pm8953_l6>;
	vcca-supply = <&pm8953_l3>;

	status = "okay";
};
	
&mdss {
	status = "okay";
};

&pmi8950_wled {
	qcom,current-limit-microamp = <20000>;
	qcom,ovp-millivolt = <29600>;
	qcom,num-strings = <2>;

	status = "okay";
};	

Can you show a dmesg dump? And a /sys/firmware/fdt dump from mainline

[ 31.711562] ibb: disabling
I think something is not enabled, do you see your panel driver in the lsmod.
Can you run this?
sudo dtc /sys/firmware/fdt | grep panel

@MarvelMathesh
Copy link
Author

@barni2000 I don't see my panel driver in the lsmod even after forcing

fdt

: Warning (simple_bus_reg): /soc@0/camss@1b00000: simple-bus unit address format error, expected "1b34000"
: Warning (unique_unit_address): /reserved-memory/mba@92000000: duplicate unit-address (also used in node /reserved-memory/gps@92000000)
: Warning (unique_unit_address): /soc@0/i2c@78b7000: duplicate unit-address (also used in node /soc@0/spi@78b7000)
: Warning (unique_unit_address): /soc@0/i2c@7af5000: duplicate unit-address (also used in node /soc@0/spi@7af5000)
: Warning (unique_unit_address): /soc@0/i2c@7af6000: duplicate unit-address (also used in node /soc@0/spi@7af6000)
panel@0 {
compatible = "10or,g-panel";

@barni2000
Copy link
Member

barni2000 commented Sep 21, 2024

panel@0 {
compatible = "10or,g-panel"

lk2nd panel selection is not fine.
If it works it will look like this compatible = "xiaomi,td4310-fhdplus-e7-g55\0xiaomi,vince-panel"; check panel selection in lk2nd dt.

@MarvelMathesh
Copy link
Author

panel@0 {
compatible = "10or,g-panel"

lk2nd panel selection is not fine. If it works it will look like this compatible = "xiaomi,td4310-fhdplus-e7-g55\0xiaomi,vince-panel"; check panel selection in lk2nd dt.

Thank you for your patience and the workaround. I was able to find it now in lsmod, but the panel is still not functioning (is it because of wrong gpu firmware? I inherited the gpu blobs from daisy btw). Is it possible to force using modprobe? How do I identify what touchscreen model do I have? from downstream kernel I found my device has FT5435 and GT9XX_v28 variant.

image

fdt.tar.gz

dmesg.log

@barni2000
Copy link
Member

panel@0 {
compatible = "10or,g-panel"

lk2nd panel selection is not fine. If it works it will look like this compatible = "xiaomi,td4310-fhdplus-e7-g55\0xiaomi,vince-panel"; check panel selection in lk2nd dt.

Thank you for your patience and the workaround. I was able to find it now in lsmod, but the panel is still not functioning (is it because of wrong gpu firmware? I inherited the gpu blobs from daisy btw). Is it possible to force using modprobe? How do I identify what touchscreen model do I have? from downstream kernel I found my device has FT5435 and GT9XX_v28 variant.

image

fdt.tar.gz

dmesg.log

Your panel selection still not working, check your lk2nd again and please rebase your work on 6.11/main branch.

@MarvelMathesh
Copy link
Author

MarvelMathesh commented Sep 26, 2024

panel@0 {
compatible = "10or,g-panel"

lk2nd panel selection is not fine. If it works it will look like this compatible = "xiaomi,td4310-fhdplus-e7-g55\0xiaomi,vince-panel"; check panel selection in lk2nd dt.

Thank you for your patience and the workaround. I was able to find it now in lsmod, but the panel is still not functioning (is it because of wrong gpu firmware? I inherited the gpu blobs from daisy btw). Is it possible to force using modprobe? How do I identify what touchscreen model do I have? from downstream kernel I found my device has FT5435 and GT9XX_v28 variant.
image
fdt.tar.gz
dmesg.log

Your panel selection still not working, check your lk2nd again and please rebase your work on 6.11/main branch.

I am not sure what is preventing the panel selection...everything seems fine ;/
Temporary changes are here - https://github.com/10or-G/linx/commits/6.10/main
I will rebase on 6.11 soon
I found something fishy in my lk2nd logs. is it common?

image

output.txt

@barni2000
Copy link
Member

panel@0 {
compatible = "10or,g-panel"

lk2nd panel selection is not fine. If it works it will look like this compatible = "xiaomi,td4310-fhdplus-e7-g55\0xiaomi,vince-panel"; check panel selection in lk2nd dt.

Thank you for your patience and the workaround. I was able to find it now in lsmod, but the panel is still not functioning (is it because of wrong gpu firmware? I inherited the gpu blobs from daisy btw). Is it possible to force using modprobe? How do I identify what touchscreen model do I have? from downstream kernel I found my device has FT5435 and GT9XX_v28 variant.
image
fdt.tar.gz
dmesg.log

Your panel selection still not working, check your lk2nd again and please rebase your work on 6.11/main branch.

I am not sure what is preventing the panel selection...everything seems fine ;/ Temporary changes are here - https://github.com/10or-G/linx/commits/6.10/main I will rebase on 6.11 soon I found something fishy in my lk2nd logs. is it common?

image

output.txt

try to set your panel compatible explicitly for test 10or,g-hx8399c-auo, check if your lk2nd matching for the right device.

@MarvelMathesh
Copy link
Author

panel@0 {
compatible = "10or,g-panel"

lk2nd panel selection is not fine. If it works it will look like this compatible = "xiaomi,td4310-fhdplus-e7-g55\0xiaomi,vince-panel"; check panel selection in lk2nd dt.

Thank you for your patience and the workaround. I was able to find it now in lsmod, but the panel is still not functioning (is it because of wrong gpu firmware? I inherited the gpu blobs from daisy btw). Is it possible to force using modprobe? How do I identify what touchscreen model do I have? from downstream kernel I found my device has FT5435 and GT9XX_v28 variant.
image
fdt.tar.gz
dmesg.log

Your panel selection still not working, check your lk2nd again and please rebase your work on 6.11/main branch.

I am not sure what is preventing the panel selection...everything seems fine ;/ Temporary changes are here - https://github.com/10or-G/linx/commits/6.10/main I will rebase on 6.11 soon I found something fishy in my lk2nd logs. is it common?
image
output.txt

try to set your panel compatible explicitly for test 10or,g-hx8399c-auo, check if your lk2nd matching for the right device.

where am I supposed to change this? mainline kernel or lk2nd dt?

@barni2000
Copy link
Member

panel@0 {
compatible = "10or,g-panel"

lk2nd panel selection is not fine. If it works it will look like this compatible = "xiaomi,td4310-fhdplus-e7-g55\0xiaomi,vince-panel"; check panel selection in lk2nd dt.

Thank you for your patience and the workaround. I was able to find it now in lsmod, but the panel is still not functioning (is it because of wrong gpu firmware? I inherited the gpu blobs from daisy btw). Is it possible to force using modprobe? How do I identify what touchscreen model do I have? from downstream kernel I found my device has FT5435 and GT9XX_v28 variant.
image
fdt.tar.gz
dmesg.log

Your panel selection still not working, check your lk2nd again and please rebase your work on 6.11/main branch.

I am not sure what is preventing the panel selection...everything seems fine ;/ Temporary changes are here - https://github.com/10or-G/linx/commits/6.10/main I will rebase on 6.11 soon I found something fishy in my lk2nd logs. is it common?
image
output.txt

try to set your panel compatible explicitly for test 10or,g-hx8399c-auo, check if your lk2nd matching for the right device.

where am I supposed to change this? mainline kernel or lk2nd dt?

kernel

@MarvelMathesh
Copy link
Author

It booted with display working when the panel compatible option was explicitly set, as you mentioned. So panel selection in lk2nd did not operate as expected.

@MarvelMathesh
Copy link
Author

image

@barni2000
Copy link
Member

It booted with display working when the panel compatible option was explicitly set, as you mentioned. So panel selection in lk2nd did not operate as expected.

Try to port your device to msm8916-mainline/lk2nd every other devices are there already.

@MarvelMathesh
Copy link
Author

MarvelMathesh commented Dec 18, 2024

Tried msm8916-mainline/lk2nd, still same result...only explicit selection works
image

@barni2000
Copy link
Member

@MarvelMathesh can you get downstream cmdline?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants