Title: Modify kernel for VGA-OUT only [Print This Page] Author: return0 Time: 6/26/2015 13:01 Title: Modify kernel for VGA-OUT only Hi everyone,
I am trying to work out exactly how to obtain video output only from the VGA port, by modifying the kernel accordingly.
I would like the HDMI out to be completely disabled.
First of all, looking at the board schematics I seem to understand that the VGA port is routed to the RK3288 LVDS domain (LCDC0_Dx) while the HDMI port is routed to the RK3288 HDMI pinouts - can someone confirm this?
Then, looking at the relevant kernel device tree section (firefly-rk3288.dts):
The first thing that I find rather confusing, is this comment in the code (see above):
/*lcdc0 as PRMRY(HDMI),lcdc1 as EXTEND(RK1000)*/
Copy the code
What does this mean? How can lcdc0 be HDMI if HDMI itself has its own dedicated node in the DT? Does it mean that lcdc0 is routed to the HDMI port on the board?
Again, carefully looking at the code (see above for full snippet):
vga_ddc@50 {
compatible = "firefly,vga_ddc";
reg = <0x50>;
gpio-pwn = <&gpio0 GPIO_C1 GPIO_ACTIVE_HIGH>;
rockchip,source = <0>; //0: LCDC0; 1: LCDC1
rockchip,prop = <PRMRY>;//<EXTEND>
status = "okay";
};
Copy the code
My interpretation is that
rockchip,source = <0>; //0: LCDC0; 1: LCDC1
Copy the code
can select two different sources.
So by default lcdc0 is selected as VGA source and according to the above code lcdc0 is HDMI (?) - when I change the VGA source to 1 (RK1000?) what is supposed to happen?
I tried various (somewhat logical) combinations by enabling/disabling the relevant nodes but all I've obtained was the board booting with no video out at all (no VGA, no HDMI) - best case was only the HDMI out working.
I suspect that there's more involved than just modifying the kernel DT - for example, the Firefly VGA driver itself (firefly_vga.c) has this function:
I appreciate any suggestion! Author: return0 Time: 6/29/2015 12:01 Last edited by return0 In 6/29/2015 12:03 Editor
UPDATE - I seem to have (sadly) overlooked the simplicity of what I am trying to achieve.
The first thing that I have tried initially, was the following trivial change in the kernel DT:
&hdmi {
status = "disabled";
rockchips,hdmi_audio_source = <0>;
hdmi_cec = <0>;
};
Copy the code
As I compiled the kernel the first time with such change, I found that no HDMI or VGA outputs were working anymore, although the board was booting fine - this led me to think that something else was involved so I got sidetracked with other related attempts.
I was about to give up, when I thought about starting from scratch - all I did was
make distclean
Copy the code
followed by kernel recompilation with just this change in the DT:
&hdmi {
status = "disabled";
rockchips,hdmi_audio_source = <0>;
hdmi_cec = <0>;
};
Copy the code
It works!
Moral of the story: if you are convinced that something should just work but it doesn't, try cleaning up and start from scratch!Author: qthanh_le Time: 10/5/2015 18:23
thank for your post, it very helpfull!
Could you please guide me to display only on LVDS LCD only!
Thank you!Author: XCLR8 Time: 9/6/2017 06:20
Is there a way to use this to force the HDMI into DVI mode?
Welcome Firefly Open Source Community (https://bbs.t-firefly.com/)