setup.c 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. /*
  2. * ATSTK1000 board-specific setup code.
  3. *
  4. * Copyright (C) 2005-2006 Atmel Corporation
  5. *
  6. * This program is free software; you can redistribute it and/or modify
  7. * it under the terms of the GNU General Public License version 2 as
  8. * published by the Free Software Foundation.
  9. */
  10. #include <linux/bootmem.h>
  11. #include <linux/fb.h>
  12. #include <linux/init.h>
  13. #include <linux/types.h>
  14. #include <linux/linkage.h>
  15. #include <video/atmel_lcdc.h>
  16. #include <asm/setup.h>
  17. #include <asm/arch/board.h>
  18. #include "atstk1000.h"
  19. /* Initialized by bootloader-specific startup code. */
  20. struct tag *bootloader_tags __initdata;
  21. static struct fb_videomode __initdata ltv350qv_modes[] = {
  22. {
  23. .name = "320x240 @ 75",
  24. .refresh = 75,
  25. .xres = 320, .yres = 240,
  26. .pixclock = KHZ2PICOS(6891),
  27. .left_margin = 17, .right_margin = 33,
  28. .upper_margin = 10, .lower_margin = 10,
  29. .hsync_len = 16, .vsync_len = 1,
  30. .sync = 0,
  31. .vmode = FB_VMODE_NONINTERLACED,
  32. },
  33. };
  34. static struct fb_monspecs __initdata atstk1000_default_monspecs = {
  35. .manufacturer = "SNG",
  36. .monitor = "LTV350QV",
  37. .modedb = ltv350qv_modes,
  38. .modedb_len = ARRAY_SIZE(ltv350qv_modes),
  39. .hfmin = 14820,
  40. .hfmax = 22230,
  41. .vfmin = 60,
  42. .vfmax = 90,
  43. .dclkmax = 30000000,
  44. };
  45. struct atmel_lcdfb_info __initdata atstk1000_lcdc_data = {
  46. .default_bpp = 24,
  47. .default_dmacon = ATMEL_LCDC_DMAEN | ATMEL_LCDC_DMA2DEN,
  48. .default_lcdcon2 = (ATMEL_LCDC_DISTYPE_TFT
  49. | ATMEL_LCDC_INVCLK
  50. | ATMEL_LCDC_CLKMOD_ALWAYSACTIVE
  51. | ATMEL_LCDC_MEMOR_BIG),
  52. .default_monspecs = &atstk1000_default_monspecs,
  53. .guard_time = 2,
  54. };