Add display support in u-boot

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Add display support in u-boot

Jump to solution
957 Views
vishnu_motghare
Contributor III

Hello,

I'm trying to add LCD support in u-boot for a custom IMX6 solo board. I have referred mx6sabresd & enabled the following configuration

 

CONFIG_DM_VIDEO=y
CONFIG_VIDEO_IPUV3=y
CONFIG_IMX_VIDEO_SKIP=y

 

Added panel information on board.c file

 

static void enable_lvds(struct display_info_t const *dev)
{
    enable_backlight();
}

struct display_info_t const displays[] = {{
.bus = -1,
.addr = 0,
.pixfmt = IPU_PIX_FMT_RGB666,
.detect = NULL,
.enable = enable_lvds,
.mode = {
.name = "EDT",
.refresh = 60,
.xres = 1024,
.yres = 600,
.pixclock = 15384,
.left_margin = 160,
.right_margin = 24,
.upper_margin = 29,
.lower_margin = 3,
.hsync_len = 136,
.vsync_len = 6,
.sync = FB_SYNC_EXT,
.vmode = FB_VMODE_NONINTERLACED
} } };
size_t display_count = ARRAY_SIZE(displays);

 

 

As mentioned in the document, set the panel environment variable 

 

setenv panel EDT
saveenv

 


I'm using the DTS file from Linux, where the display is already working

I see the "drivers/video/nxp/imx/mxc_ipuv3_fb.c" file is responsible for setting up a display framebuffer

In my case, only the ipuv3_video_bind() function is called & ipuv3_video_probe() probe function never gets called.  

 

static int ipuv3_video_bind(struct udevice *dev)
{
        struct video_uc_plat *plat = dev_get_uclass_plat(dev);

        plat->size = LCD_MAX_WIDTH * LCD_MAX_HEIGHT *
                     (1 << VIDEO_BPP32) / 8;

        return 0;
}

 


My question is under which condition ipuv3_video_probe() function get called? I know the probe function is only called when the device starts using it but I'm not sure how it work here

Labels (2)
Tags (4)
0 Kudos
Reply
1 Solution
865 Views
vishnu_motghare
Contributor III

I'm able to probe the driver by setting stdout to 'vidconsole`, ipu driver will be probed when I actually start using the device

setenv stdout vidconsole

 

I'm also able to probe the driver from board.c file  by calling 

uclass_get_device(UCLASS_VIDEO, 0, &dev);

 

View solution in original post

0 Kudos
Reply
2 Replies
927 Views
Zhiming_Liu
NXP TechSupport
NXP TechSupport

Hi @vishnu_motghare 

Can you check if  IPU driver has been compiled in Uboot build process?

Best Regards

Zhiming

0 Kudos
Reply
866 Views
vishnu_motghare
Contributor III

I'm able to probe the driver by setting stdout to 'vidconsole`, ipu driver will be probed when I actually start using the device

setenv stdout vidconsole

 

I'm also able to probe the driver from board.c file  by calling 

uclass_get_device(UCLASS_VIDEO, 0, &dev);

 

0 Kudos
Reply