Re: How to specify panel bit order in driver?

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

 



On Sat, Jun 29, 2024 at 02:39:16AM GMT, John Watts wrote:
> Hi Jani,
> 
> On Fri, Jun 28, 2024 at 10:45:48AM +0300, Jani Nikula wrote:
> > Might be helpful to actually point at the source code or commits or
> > something.
> 
> The source code is here: drivers/gpu/drm/panel/panel-newvision-nv3052c.c
> It's just a standard MIPI DBI panel. It reports using an RGB888 bus format.
> 
> > Maybe look at include/uapi/drm/drm_fourcc.h, and how the DRM_FORMAT_*
> > macros are used.
> > 
> > Can't help you with device tree, but maybe this gives you pointers to
> > other places for examples.
> 
> Currently it works like this:
> 
> - DRM uses 24-bit depth
> - CRTC puts out a 24-bit signal
> - This gets output over LCD pins
> - The PCB drops 2 bits per channel by wiring 6 pins to GND
> - The panel is told to only use 18 bits
> 
> Getting DRM to use MEDIA_BUS_FMT_RGB666_1X18 would be nice and allow the panel
> to auto-detect which bits to use. But the bus format is set in the panel :(
> 
> Where is the bus format usually set for cases where a board only supports a
> physical format?

This is usally the panel driver.

We have been discussing adding a proper atomic_* support to the
drm_panel. This should allow panel drivers to actually negotiate what is
going on. Marijn started looking at it, but the patches never hit the
ML.

So, if the static configuration fits you, then just set it in the panel
config. If not, you might have either to implement some hacks (like
having a DT property describing how the panel is actually wired).

> 
> > HTH,
> > Jani.
> > 
> > 
> > -- 
> > Jani Nikula, Intel
> 
> John.

-- 
With best wishes
Dmitry



[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