imxfb.h 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172
  1. /*
  2. * linux/drivers/video/imxfb.h
  3. *
  4. * Freescale i.MX Frame Buffer device driver
  5. *
  6. * Copyright (C) 2004 S.Hauer, Pengutronix
  7. *
  8. * Copyright (C) 1999 Eric A. Thomas
  9. * Based on acornfb.c Copyright (C) Russell King.
  10. *
  11. * This file is subject to the terms and conditions of the GNU General Public
  12. * License. See the file COPYING in the main directory of this archive
  13. * for more details.
  14. */
  15. /*
  16. * These are the bitfields for each
  17. * display depth that we support.
  18. */
  19. struct imxfb_rgb {
  20. struct fb_bitfield red;
  21. struct fb_bitfield green;
  22. struct fb_bitfield blue;
  23. struct fb_bitfield transp;
  24. };
  25. #define RGB_16 (0)
  26. #define RGB_8 (1)
  27. #define NR_RGB 2
  28. struct imxfb_info {
  29. struct device *dev;
  30. struct imxfb_rgb *rgb[NR_RGB];
  31. u_int max_bpp;
  32. u_int max_xres;
  33. u_int max_yres;
  34. /*
  35. * These are the addresses we mapped
  36. * the framebuffer memory region to.
  37. */
  38. dma_addr_t map_dma;
  39. u_char * map_cpu;
  40. u_int map_size;
  41. u_char * screen_cpu;
  42. dma_addr_t screen_dma;
  43. u_int palette_size;
  44. dma_addr_t dbar1;
  45. dma_addr_t dbar2;
  46. u_int pcr;
  47. u_int pwmr;
  48. u_int lscr1;
  49. u_int cmap_inverse:1,
  50. cmap_static:1,
  51. unused:30;
  52. void (*lcd_power)(int);
  53. void (*backlight_power)(int);
  54. };
  55. #define IMX_NAME "IMX"
  56. /*
  57. * Minimum X and Y resolutions
  58. */
  59. #define MIN_XRES 64
  60. #define MIN_YRES 64