Back to home page

OSCL-LXR

 
 

    


0001 /*-*- linux-c -*-
0002  *  linux/drivers/video/i810fb_main.h -- Intel 810 frame buffer device 
0003  *                                       main header file
0004  *
0005  *      Copyright (C) 2001 Antonino Daplas<adaplas@pol.net>
0006  *      All Rights Reserved      
0007  *
0008  *
0009  *  This file is subject to the terms and conditions of the GNU General Public
0010  *  License. See the file COPYING in the main directory of this archive for
0011  *  more details.
0012  */
0013 
0014 #ifndef __I810_MAIN_H__
0015 #define __I810_MAIN_H__
0016 
0017 /* Video Timings */
0018 extern void round_off_xres         (u32 *xres);
0019 extern void round_off_yres         (u32 *xres, u32 *yres);
0020 extern u32 i810_get_watermark      (const struct fb_var_screeninfo *var,
0021                         struct i810fb_par *par);
0022 extern void i810fb_encode_registers(const struct fb_var_screeninfo *var,
0023                     struct i810fb_par *par, u32 xres, u32 yres);
0024 extern void i810fb_fill_var_timings(struct fb_var_screeninfo *var);
0025                     
0026 /* Accelerated Functions */
0027 extern void i810fb_fillrect (struct fb_info *p, 
0028                  const struct fb_fillrect *rect);
0029 extern void i810fb_copyarea (struct fb_info *p, 
0030                  const struct fb_copyarea *region);
0031 extern void i810fb_imageblit(struct fb_info *p, const struct fb_image *image);
0032 extern int  i810fb_sync     (struct fb_info *p);
0033 
0034 extern void i810fb_init_ringbuffer(struct fb_info *info);
0035 extern void i810fb_load_front     (u32 offset, struct fb_info *info);
0036 
0037 #ifdef CONFIG_FB_I810_I2C
0038 /* I2C */
0039 extern int i810_probe_i2c_connector(struct fb_info *info, u8 **out_edid,
0040                     int conn);
0041 extern void i810_create_i2c_busses(struct i810fb_par *par);
0042 extern void i810_delete_i2c_busses(struct i810fb_par *par);
0043 #else
0044 static inline int i810_probe_i2c_connector(struct fb_info *info, u8 **out_edid,
0045                     int conn)
0046 {
0047     return 1;
0048 }
0049 static inline void i810_create_i2c_busses(struct i810fb_par *par) { }
0050 static inline void i810_delete_i2c_busses(struct i810fb_par *par) { }
0051 #endif
0052 
0053 /* Conditionals */
0054 #ifdef CONFIG_X86
0055 static inline void flush_cache(void)
0056 {
0057     asm volatile ("wbinvd":::"memory");
0058 }
0059 #else
0060 #define flush_cache() do { } while(0)
0061 #endif 
0062 
0063 #ifdef CONFIG_FB_I810_GTF
0064 #define IS_DVT (0)
0065 #else
0066 #define IS_DVT (1)
0067 #endif
0068 
0069 #endif /* __I810_MAIN_H__ */