Hi:
We are currently debuging the DSI output of our custom tx1 board. The dts is as follows.
dsi {
compatible = "nvidia,tegra210-dsi";
reg = <0x0 0x54300000 0x0 0x40000 0x0 0x54400000 0x0 0x40000>;
clocks = <0x41 0x30 0x41 0x93 0x41 0x52 0x41 0x94 0x41 0xf6 0x41 0xb1>;
clock-names = "dsi", "dsia_lp", "dsib", "dsib_lp", "pll_p_out3", "clk72mhz";
resets = <0x41 0x30 0x41 0x52>;
reset-names = "dsia", "dsib";
pad-controllers = <0x5b 0xf 0x5b 0x10 0x5b 0x11 0x5b 0x12>;
pad-names = "dsia", "dsib", "dsic", "dsid";
status = "okay";
nvidia,dsi-controller-vs = <0x1>;
panel-dsi-1080p-p2382 {
status = "okay";
compatible = "dsi,1080p";
nvidia,dsi-instance = <0x0>;
nvidia,dsi-n-data-lanes = <0x4>;
nvidia,dsi-pixel-format = <0x3>;
nvidia,dsi-refresh-rate = <0x3c>;
nvidia,dsi-video-data-type = <0x0>;
nvidia,dsi-video-clock-mode = <0x0>;
nvidia,dsi-video-burst-mode = <0x1>;
nvidia,dsi-virtual-channel = <0x0>;
nvidia,dsi-panel-reset = <0x1>;
nvidia,dsi-power-saving-suspend = <0x1>;
nvidia,dsi-ulpm-not-support = <0x1>;
nvidia,dsi-init-cmd = <0x0 0x5 0x11 0x0 0x0 0x3 0x5 0x1 0x14 0x0 0x5 0x29 0x0 0x0 0x1 0x14>;
nvidia,dsi-n-init-cmd = <0x5>;
nvidia,dsi-suspend-cmd = <0x0 0x5 0x28 0x0 0x0 0x0 0x5 0x10 0x0 0x0 0x1 0x50>;
nvidia,dsi-n-suspend-cmd = <0x3>;
nvidia,dsi-dpd-pads = <0x4 0x8>;
nvidia,panel-rst-gpio = <0x7b 0xaa 0x0>;
nvidia,panel-bl-pwm-gpio = <0x7b 0xa8 0x0>;
disp-default-out {
nvidia,out-type = <0x2>;
nvidia,out-width = <0x780>;
nvidia,out-height = <0x438>;
nvidia,out-flags = <0x0>;
nvidia,out-xres = <0x780>;
nvidia,out-yres = <0x438>;
};
display-timings {
1920x1080-p60 {
clock-frequency = <0x8D9EE20>;//148500000
hactive = <0x780>;
vactive = <0x438>;
hfront-porch = <0x58>;
hback-porch = <0x94>;
hsync-len = <0x2c>;
vfront-porch = <0x4>;
vback-porch = <0x24>;
vsync-len = <0x5>;
nvidia,h-ref-to-sync = <0x1>;
nvidia,v-ref-to-sync = <0x1>;
};
};
};
we are using a ADV7535 connected on the DSI-0 output which is to achieve the function of dsi transfer to hdmi.
The DSI output is works and I can get video image from the hdmi output of ADV7535.
First problem: We set the video format of DSI output is 1080P60, but video refresh of DSI output can’t reach 60HZ, the pixel clock can’t reach 148500000.
I check the code of kernel and get the reason which leads to pixel clock not 148500000 but 148333326. the reason is the code as follows, this code can be find in the file of dsi.c
static void tegra_dsi_set_dsi_clk(struct tegra_dc *dc,
struct tegra_dc_dsi_data *dsi, u32 clk)
{
u32 rm;
u32 pclk_khz;
/* Round up to MHz */
rm = clk % 1000;
if (rm != 0)
clk -= rm;
/* refer to source code */
}
I wonder how to aviod this problem.
Second problem: I modify the dts to set video format of DSI output to 1080P60 and 1080P30 and 1080P25, The DSI output all can works and I can get video image.
but I modify the dts to set video format of DSI output to 1080P50, I can’t get the video image. I wonder how to get the 1080P50 image from DSI.
1920x1080-p50 {
clock-frequency = <0x8D9EE20>;//148500000
hactive = <0x780>;
vactive = <0x438>;
hfront-porch = <0x210>;
hback-porch = <0x94>;
hsync-len = <0x2c>;
vfront-porch = <0x4>;
vback-porch = <0x24>;
vsync-len = <0x5>;
nvidia,h-ref-to-sync = <0x1>;
nvidia,v-ref-to-sync = <0x1>;
};
1920x1080-p30 {
clock-frequency = <0x46CF710>;//74250000
hactive = <0x780>;
vactive = <0x438>;
hfront-porch = <0x58>;
hback-porch = <0x94>;
hsync-len = <0x2c>;
vfront-porch = <0x4>;
vback-porch = <0x24>;
vsync-len = <0x5>;
nvidia,h-ref-to-sync = <0x1>;
nvidia,v-ref-to-sync = <0x1>;
};
1920x1080-p25 {
clock-frequency = <0x46CF710>;//74250000
hactive = <0x780>;
vactive = <0x438>;
hfront-porch = <0x210>;
hback-porch = <0x94>;
hsync-len = <0x2c>;
vfront-porch = <0x4>;
vback-porch = <0x24>;
vsync-len = <0x5>;
nvidia,h-ref-to-sync = <0x1>;
nvidia,v-ref-to-sync = <0x1>;
};
Third problem: how to modify the dts to get the 1080I50 image from DSI.
thanks!