English
Language : 

UM0851 Datasheet, PDF (195/245 Pages) STMicroelectronics – SPEAr is a family of highly customizable ARM-based embedded
UM0851
Audio/video drivers
void (*fb_fillrect)(struct fb_info *info, const struct fb_fillrect *rect);
/*Accelerated method to copy a rectangular area from one screen region to another
*/
void (*fb_copyarea)(struct fb_info *info,const struct fb_copyarea *region);
/* Ioctl interface to support device-specific commands */
int (*fb_ioctl)(struct fb_info *info, unsigned int cmd, unsigned long arg);
/* ... */
};
Framebuffer sources
/dev/fb0 also allows several IOCTLs on it, by which a lot of information about the hardware
can be queried and set. The color map handling works via IOCTLs, too. Look into
<linux/fb.h> for more information on what IOCTLs exist and on which data structures they
work. Here's just a brief overview:
Table 50. Framebuffer information in source code
Directory or resource
Purpose
drivers/video/
include/linux/fb.h
include/video/
drivers/video/fbmem.c
The frame buffer core layer and low-level frame buffer driversreside in this
directory
Generic frame buffer structures are defined in this directory
Chipset-specific headers stay inside this directory
Creates the /dev/fbX character devices and is the front end for handling
frame buffer ioctl commands issued by user applications
8.1.4
8.1.5
How to support a new CLCD panel
There is a separate application note (AN2641) which discusses this in detail. However in
short, for a new CLCD panel at least following needs to be checked in the device driver:
Step 1: CLCD panel information should be defined in platform/amba device of arch.
Step 2: CLCD panel should be supported by ARM PL110 Controller. The types of panels
supported by controller are listed in the corresponding SPEAr user manual).
CLCD driver usage
A framebuffer device is a memory device like /dev/mem and it has the same features. You
can read it, write it, seek to some location in it and mmap () it (the main usage). The
difference is just that the memory that appears in the special file is not the whole memory,
but the frame buffer of the video hardware.
Data structures for using Framebuffer
The following three structures must be understood, because they are needed for any user
application that uses framebuffer.
1. Variable information pertaining to the video card is held in struct fb_var_screeninfo.
This structure contains fields such as the X-resolution, Y-resolution, bits required to
Doc ID 16604 Rev 2
195/245