Re: [PATCH 1/3] drm/mxsfb: use bus_format to determine pixel RGB component order

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 2/1/19 18:02, Ahmad Fatoum wrote:

> -	reg &= ~CTRL_BUS_WIDTH_MASK;
> +	ctrl &= ~CTRL_BUS_WIDTH_MASK;
>  	switch (bus_format) {

>  	default:
> +		pattern = CTRL2_PATTERN_RGB;
>  		dev_err(drm->dev, "Unknown media bus format %d\n", bus_format);
>  		break;
>  	}
> -	writel(reg, mxsfb->base + LCDC_CTRL);
> +	writel(ctrl, mxsfb->base + LCDC_CTRL);

Should the default case explicitly set a value for ctrl?
So far, the appropriate bits stay at zero after the &= ~CTRL_BUS_WIDTH_MASK
which is STMLCDIF_16BIT.

Or maybe skip the LCDC_CTRL register write altogether if dev_err is reached?

-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |
_______________________________________________
dri-devel mailing list
dri-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/dri-devel




[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux