TX2 HDMI problem

1.准备一个已知的256字节EDID。
2. set use_fallback = true; 在edid.c中的tegra_edid_get_monspecs()中。
3.将已知的EDID填入default_720p_edid [256]。

I modified the file, but it does not seem to change.

int tegra_edid_get_monspecs(struct tegra_edid *edid, struct fb_monspecs *specs)
{
	int i;
	int j;
	int ret;
	int extension_blocks;
	struct tegra_edid_pvt *new_data, *old_data;
	u8 checksum = 0;
	u8 *data;
	//bool use_fallback = false;
	bool use_fallback = true;   
	new_data = vzalloc(SZ_32K + sizeof(struct tegra_edid_pvt));
	if (!new_data)
		return -ENOMEM;

	kref_init(&new_data->refcnt);

	if (edid->errors & EDID_ERRORS_READ_FAILED)
		use_fallback = true;

	edid->errors = 0;

	data = new_data->dc_edid.buf;
static const char default_720p_edid[256] = {
		0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 
		0x49, 0xF7, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
		0x01, 0x1A, 0x01, 0x03, 0x80, 0x00, 0x00, 0x00, 
		0x0A, 0xD7, 0xA5, 0xA2, 0x59, 0x4A, 0x96, 0x24,
		0x14, 0x50, 0x54, 0xAF, 0xCE, 0x00, 0x81, 0xC0,
		0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
		0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x12, 0x1B,
		0x00, 0x7B, 0x50, 0x20, 0x15, 0x30, 0x30, 0x20,
		0x36, 0x00, 0x05, 0xA3, 0x10, 0x00, 0x00, 0x18, 
		0x0E, 0x1F, 0x00, 0x80, 0x51, 0x00, 0x1E, 0x30,
	    0x40, 0x80, 0x37, 0x00, 0x20, 0x56, 0x00, 0x00,
		0x00, 0x1C, 0x00, 0x00, 0x00, 0xFD, 0x00, 0x32,
		0x4C, 0x1E, 0x50, 0x10, 0x00, 0x0A, 0x20, 0x20,
		0x20, 0x20, 0x20, 0x20, 0x00, 0x00, 0x00, 0xFC,
		0x00, 0x41, 0x41, 0x41, 0x0A, 0x20, 0x20, 0x20,
		0x20, 0x20, 0x20, 0x20, 0x20, 0x0A, 0x01, 0xFF,
		0x02, 0x03, 0x23, 0x74, 0x4F, 0x10, 0x9F, 0x14,
		0x05, 0x04, 0x13, 0x12, 0x16, 0x11, 0x15, 0x03,
		0x07, 0x02, 0x06, 0x01, 0x23, 0x09, 0x0F, 0x03,
		0x83, 0x01, 0x00, 0x00, 0x66, 0x03, 0x0C, 0x00,
		0x10, 0x00, 0x80, 0x01, 0x1D, 0x00, 0xBC, 0x52,
		0xD0, 0x1E, 0x20, 0xB8, 0x28, 0x55, 0x40, 0xC4,
		0x8E, 0x21, 0x00, 0x00, 0x1E, 0x01, 0x1D, 0x80,
		0xD0, 0x72, 0x1C, 0x16, 0x20, 0x10, 0x2C, 0x25,
		0x80, 0xC4, 0x8E, 0x21, 0x00, 0x00, 0x9E, 0x8C,
		0x0A, 0xD0, 0x8A, 0x20, 0xE0, 0x2D, 0x10, 0x10,
		0x3E, 0x96, 0x00, 0x13, 0x8E, 0x21, 0x00, 0x00,
		0x18, 0x8C, 0x0A, 0xD0, 0x90, 0x20, 0x40, 0x31,
		0x20, 0x0C, 0x40, 0x55, 0x00, 0x13, 0x8E, 0x21,
		0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00,
		0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
		0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x9D
};

This is my dmesg file, if I press the line will cause the HDMI loop to detect until I release the line
dmesg.log (75.8 KB)

This is my original xorg.conf

# Copyright (c) 2011-2013 NVIDIA CORPORATION.  All Rights Reserved.

#
# This is the minimal configuration necessary to use the Tegra driver.
# Please refer to the xorg.conf man page for more configuration
# options provided by the X server, including display-related options
# provided by RandR 1.2 and higher.

# Disable extensions not useful on Tegra.
Section "Module"
    Disable     "dri"
    SubSection  "extmod"
        Option  "omit xfree86-dga"
    EndSubSection
EndSection

Section "Device"
    Identifier  "Tegra0"
    Driver      "nvidia"
# Allow X server to be started even if no display devices are connected.
    Option      "AllowEmptyInitialConfiguration" "true"
EndSection

After modification

# Copyright (c) 2011-2013 NVIDIA CORPORATION.  All Rights Reserved.

#
# This is the minimal configuration necessary to use the Tegra driver.
# Please refer to the xorg.conf man page for more configuration
# options provided by the X server, including display-related options
# provided by RandR 1.2 and higher.

# Disable extensions not useful on Tegra.
Section "Module"
    Disable     "dri"
    SubSection  "extmod"
        Option  "omit xfree86-dga"
    EndSubSection
EndSection

Section "Device"
    Identifier  "Tegra0"
    Driver      "nvidia"
# Allow X server to be started even if no display devices are connected.
    Option      "AllowEmptyInitialConfiguration" "true"
    Option      "ModeDebug"
    Option      "ModeValidation" "AllowNonEdidModes"
EndSection

This is my original xorg.conf.t186_ref

# Copyright (c) 2015, NVIDIA CORPORATION.  All Rights Reserved.
#
# This is the minimal configuration necessary to use the Tegra driver.
# Please refer to the xorg.conf man page for more configuration
# options provided by the X server, including display-related options
# provided by RandR 1.2 and higher.

# Disable extensions not useful on Tegra.
Section "Module"
    Disable     "dri"
    SubSection  "extmod"
    Option  "omit xfree86-dga"
    EndSubSection
EndSection

Section "Device"
    Identifier  "Tegra0"
    Driver      "nvidia"
    Option      "AllowEmptyInitialConfiguration" "true"
    Option      "ModeDebug"
EndSection

Section "Monitor"
   Identifier "DSI-0"
   Option    "Ignore"
EndSection

Nothing changes now, what is the relationship between xorg.conf and xorg.conf.t186_ref?

If it is a hardware issue, please change the board to a good one. I don’t think you can stop the detection because it is triggered by hardware.

This is in the kernel source.

kernel/display/drivers/video/tegra/dc/edid.c.

@WayneWWW Thank you for the reply
I have modified the specific code, but it has no effect.
Can I stop testing or skip this check in the kernel or device tree? It is also possible to set the HDMI startup item to the last so that it will not block the system, let the system skip this section and proceed with the following section.

Unsupported HDMI VIC 82, ignoring
Unsupported HDMI VIC 208, ignoring
Unsupported HDMI VIC 30, ignoring
Unsupported HDMI VIC 32, ignoring
Unsupported HDMI VIC 184, ignoring

What are these and can you avoid?

This should not show under normal usecase. I still cannot understand what is exactly happened to your board.

If you have hardware issue (broken port/cable) on your carrier board, please change a new one.

The same is true when I replace the bottom plate. I use the bottom plate of the P2597.

If I want to output HDMI boot with a resolution of 1280*800, do I need to modify uboot? Where is the change?

Do you mean the issue is still even after you replaced a new carrier board?

Do you want to change the resolution of the console which is shown during boot process?

Is the resolution of the HDMI output

int tegra_edid_get_monspecs(struct tegra_edid *edid, struct fb_monspecs *specs)
{
	int i;
	int j;
	int ret;
	int extension_blocks;
	struct tegra_edid_pvt *new_data, *old_data;
	u8 checksum = 0;
	u8 *data;
	//bool use_fallback = false;
	bool use_fallback = true;
static const char default_720p_edid[256] = {
		0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 
		0x49, 0xF7, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
		0x01, 0x1A, 0x01, 0x03, 0x80, 0x00, 0x00, 0x00, 
		0x0A, 0xD7, 0xA5, 0xA2, 0x59, 0x4A, 0x96, 0x24,
		0x14, 0x50, 0x54, 0xAF, 0xCE, 0x00, 0x81, 0xC0,
		0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
		0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x12, 0x1B,
		0x00, 0x7B, 0x50, 0x20, 0x15, 0x30, 0x30, 0x20,
		0x36, 0x00, 0x05, 0xA3, 0x10, 0x00, 0x00, 0x18, 
		0x0E, 0x1F, 0x00, 0x80, 0x51, 0x00, 0x1E, 0x30,
	    0x40, 0x80, 0x37, 0x00, 0x20, 0x56, 0x00, 0x00,
		0x00, 0x1C, 0x00, 0x00, 0x00, 0xFD, 0x00, 0x32,
		0x4C, 0x1E, 0x50, 0x10, 0x00, 0x0A, 0x20, 0x20,
		0x20, 0x20, 0x20, 0x20, 0x00, 0x00, 0x00, 0xFC,
		0x00, 0x41, 0x41, 0x41, 0x0A, 0x20, 0x20, 0x20,
		0x20, 0x20, 0x20, 0x20, 0x20, 0x0A, 0x01, 0xFF,
		0x02, 0x03, 0x23, 0x74, 0x4F, 0x10, 0x9F, 0x14,
		0x05, 0x04, 0x13, 0x12, 0x16, 0x11, 0x15, 0x03,
		0x07, 0x02, 0x06, 0x01, 0x23, 0x09, 0x0F, 0x03,
		0x83, 0x01, 0x00, 0x00, 0x66, 0x03, 0x0C, 0x00,
		0x10, 0x00, 0x80, 0x01, 0x1D, 0x00, 0xBC, 0x52,
		0xD0, 0x1E, 0x20, 0xB8, 0x28, 0x55, 0x40, 0xC4,
		0x8E, 0x21, 0x00, 0x00, 0x1E, 0x01, 0x1D, 0x80,
		0xD0, 0x72, 0x1C, 0x16, 0x20, 0x10, 0x2C, 0x25,
		0x80, 0xC4, 0x8E, 0x21, 0x00, 0x00, 0x9E, 0x8C,
		0x0A, 0xD0, 0x8A, 0x20, 0xE0, 0x2D, 0x10, 0x10,
		0x3E, 0x96, 0x00, 0x13, 0x8E, 0x21, 0x00, 0x00,
		0x18, 0x8C, 0x0A, 0xD0, 0x90, 0x20, 0x40, 0x31,
		0x20, 0x0C, 0x40, 0x55, 0x00, 0x13, 0x8E, 0x21,
		0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00,
		0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
		0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x9D
};

I changed the EDID
Check it now is 1280x800
Is this fixed resolution?

I know it is the resolution of HDMI output, but which part are you mentioning during the boot? The resolution of that NVIDIA logo? Or the resolution of the console that keeps printing log?

If you monitor supports 1280x800, then it should work. However, I see there is also 1280x720 in your detailed mode.

It has chance that HDMI driver selects that mode.

Should be the console resolution, I have removed the graphical interface
Now the goal is to fix the 1280x800 resolution, because I found that without HDMI boot, after three minutes of reinsertion, the monitor will look like a narrow window in the upper left corner, and four-fifths of the area is black and cannot be displayed.

Console modes and GUI modes are set up differently. Are you working entirely without GUI?

Are you using rel-28.2 or rel-28.2DP?

@linuxdev Removed the graphical interface
@WayneWWW rel-28.1

Calmcar-Bao,

I guess the reinsertion is using VGA mode.

Could you check if modifying this parameter works?

tegra_dc_vga_mode in dc.c.

I am also curious about another issue. If without reinsertion, would you see correct console resolution-1280x800?

#include<stdio.h>
#include<sys/types.h>
#include<sys/stat.h>
#include<sys/mman.h>
#include<sys/ioctl.h>
#include<unistd.h>
#include<fcntl.h>
#include<linux/fb.h>

int main(int argc,char *argv[]){
    int fd;
    struct fb_var_screeninfo screen_info;
    fd = open("/dev/fb0",O_RDWR);
    ioctl(fd,FBIOGET_VSCREENINFO,&screen_info);
    printf("%d*%d\n",screen_info.xres,screen_info.yres);
    close(fd);
    return 0;
}

Yes, even if HDMI is not plugged in, 1280x800 is displayed. This is my program for obtaining resolution