imxfb.h 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273
  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 dmacr;
  50. u_int cmap_inverse:1,
  51. cmap_static:1,
  52. unused:30;
  53. void (*lcd_power)(int);
  54. void (*backlight_power)(int);
  55. };
  56. #define IMX_NAME "IMX"
  57. /*
  58. * Minimum X and Y resolutions
  59. */
  60. #define MIN_XRES 64
  61. #define MIN_YRES 64