exynos_drm.h 2.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101
  1. /* exynos_drm.h
  2. *
  3. * Copyright (c) 2011 Samsung Electronics Co., Ltd.
  4. * Authors:
  5. * Inki Dae <inki.dae@samsung.com>
  6. * Joonyoung Shim <jy0922.shim@samsung.com>
  7. * Seung-Woo Kim <sw0312.kim@samsung.com>
  8. *
  9. * This program is free software; you can redistribute it and/or modify it
  10. * under the terms of the GNU General Public License as published by the
  11. * Free Software Foundation; either version 2 of the License, or (at your
  12. * option) any later version.
  13. */
  14. #ifndef _EXYNOS_DRM_H_
  15. #define _EXYNOS_DRM_H_
  16. #include <uapi/drm/exynos_drm.h>
  17. #include <video/videomode.h>
  18. /**
  19. * A structure for lcd panel information.
  20. *
  21. * @timing: default video mode for initializing
  22. * @width_mm: physical size of lcd width.
  23. * @height_mm: physical size of lcd height.
  24. */
  25. struct exynos_drm_panel_info {
  26. struct videomode vm;
  27. u32 width_mm;
  28. u32 height_mm;
  29. };
  30. /**
  31. * Platform Specific Structure for DRM based FIMD.
  32. *
  33. * @panel: default panel info for initializing
  34. * @default_win: default window layer number to be used for UI.
  35. * @bpp: default bit per pixel.
  36. */
  37. struct exynos_drm_fimd_pdata {
  38. struct exynos_drm_panel_info panel;
  39. u32 vidcon0;
  40. u32 vidcon1;
  41. unsigned int default_win;
  42. unsigned int bpp;
  43. };
  44. /**
  45. * Platform Specific Structure for DRM based HDMI.
  46. *
  47. * @hdmi_dev: device point to specific hdmi driver.
  48. * @mixer_dev: device point to specific mixer driver.
  49. *
  50. * this structure is used for common hdmi driver and each device object
  51. * would be used to access specific device driver(hdmi or mixer driver)
  52. */
  53. struct exynos_drm_common_hdmi_pd {
  54. struct device *hdmi_dev;
  55. struct device *mixer_dev;
  56. };
  57. /**
  58. * Platform Specific Structure for DRM based HDMI core.
  59. *
  60. * @is_v13: set if hdmi version 13 is.
  61. * @cfg_hpd: function pointer to configure hdmi hotplug detection pin
  62. * @get_hpd: function pointer to get value of hdmi hotplug detection pin
  63. */
  64. struct exynos_drm_hdmi_pdata {
  65. bool is_v13;
  66. void (*cfg_hpd)(bool external);
  67. int (*get_hpd)(void);
  68. };
  69. /**
  70. * Platform Specific Structure for DRM based IPP.
  71. *
  72. * @inv_pclk: if set 1. invert pixel clock
  73. * @inv_vsync: if set 1. invert vsync signal for wb
  74. * @inv_href: if set 1. invert href signal
  75. * @inv_hsync: if set 1. invert hsync signal for wb
  76. */
  77. struct exynos_drm_ipp_pol {
  78. unsigned int inv_pclk;
  79. unsigned int inv_vsync;
  80. unsigned int inv_href;
  81. unsigned int inv_hsync;
  82. };
  83. /**
  84. * Platform Specific Structure for DRM based FIMC.
  85. *
  86. * @pol: current hardware block polarity settings.
  87. * @clk_rate: current hardware clock rate.
  88. */
  89. struct exynos_drm_fimc_pdata {
  90. struct exynos_drm_ipp_pol pol;
  91. int clk_rate;
  92. };
  93. #endif /* _EXYNOS_DRM_H_ */