1. 程式人生 > >linux fb /lcd 驅動

linux fb /lcd 驅動

struct fb_info {
int node;
int flags;
struct mutex lock;/* Lock for open/release/ioctl funcs */互斥鎖
struct fb_var_screeninfo var;/* Current var */當前緩衝區的可變引數
struct fb_fix_screeninfo fix;/* Current fix */固定引數
struct fb_monspecs monspecs;/* Current Monitor specs */當前顯示器標誌
struct work_struct queue;/* Framebuffer event queue */幀緩衝事件佇列
struct fb_pixmap pixmap;/* Image hardware mapper */影象硬體mapper
struct fb_pixmap sprite;/* Cursor hardware mapper */游標硬體mapper
struct fb_cmap cmap;/* Current cmap */當前的調色盤
struct list_head modelist;      /* mode list */
struct fb_videomode *mode;/* current mode */當前的視訊模式


#ifdef CONFIG_FB_BACKLIGHT如果配置了LCD支援背光燈
/* assigned backlight device */
/* set before framebuffer registration, 
  remove after unregister */背光調整
struct backlight_device *bl_dev;


/* Backlight level curve */
struct mutex bl_curve_mutex;
u8 bl_curve[FB_BACKLIGHT_LEVELS];
#endif
#ifdef CONFIG_FB_DEFERRED_IO
struct delayed_work deferred_work;
struct fb_deferred_io *fbdefio;
#endif


struct fb_ops *fbops;幀緩衝操作函式集
struct device *device;/* This is the parent */父裝置
struct device *dev;/* This is this fb device */fb裝置
int class_flag;                    /* private sysfs flags */私有的sysfs標誌
#ifdef CONFIG_FB_TILEBLITTING
struct fb_tile_ops *tileops;    /* Tile Blitting */圖塊blitting
#endif
char __iomem *screen_base;/* Virtual address */虛擬基地址
unsigned long screen_size;/* Amount of ioremapped VRAM or 0 */ ioremap的虛擬記憶體大小
void *pseudo_palette;/* Fake palette of 16 colors */ 偽16位調色盤
#define FBINFO_STATE_RUNNING0
#define FBINFO_STATE_SUSPENDED1
u32 state; /* Hardware state i.e suspend */硬體的狀態
void *fbcon_par;                /* fbcon use-only private area */
/* From here on everything is device dependent */
void *par;
};