Ray Zhang | 0d303af | 2015-01-21 10:17:02 +0800 | [diff] [blame] | 1 | /* Copyright (c) 2013-2015, The Linux Foundation. All rights reserved. |
Dhaval Patel | 7e724ab | 2013-10-25 10:02:54 -0700 | [diff] [blame] | 2 | * |
| 3 | * Redistribution and use in source and binary forms, with or without |
| 4 | * modification, are permitted provided that the following conditions |
| 5 | * are met: |
| 6 | * * Redistributions of source code must retain the above copyright |
| 7 | * notice, this list of conditions and the following disclaimer. |
| 8 | * * Redistributions in binary form must reproduce the above copyright |
| 9 | * notice, this list of conditions and the following disclaimer in |
| 10 | * the documentation and/or other materials provided with the |
| 11 | * distribution. |
| 12 | * * Neither the name of The Linux Foundation nor the names of its |
| 13 | * contributors may be used to endorse or promote products derived |
| 14 | * from this software without specific prior written permission. |
| 15 | * |
| 16 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS |
| 17 | * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT |
| 18 | * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS |
| 19 | * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE |
| 20 | * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, |
| 21 | * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, |
| 22 | * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS |
| 23 | * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED |
| 24 | * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, |
| 25 | * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT |
| 26 | * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF |
| 27 | * SUCH DAMAGE. |
| 28 | */ |
| 29 | |
| 30 | /*--------------------------------------------------------------------------- |
| 31 | * This file is autogenerated file using gcdb parser. Please do not edit it. |
| 32 | * Update input XML file to add a new entry or update variable in this file |
| 33 | * VERSION = "1.0" |
| 34 | *---------------------------------------------------------------------------*/ |
| 35 | |
| 36 | #ifndef _PANEL_JDI_QHD_DUALDSI_VIDEO_H_ |
| 37 | #define _PANEL_JDI_QHD_DUALDSI_VIDEO_H_ |
| 38 | /*---------------------------------------------------------------------------*/ |
| 39 | /* HEADER files */ |
| 40 | /*---------------------------------------------------------------------------*/ |
| 41 | #include "panel.h" |
| 42 | |
| 43 | /*---------------------------------------------------------------------------*/ |
| 44 | /* Panel configuration */ |
| 45 | /*---------------------------------------------------------------------------*/ |
| 46 | static struct panel_config jdi_qhd_dualdsi_video_panel_data = { |
Padmanabhan Komanduru | 9ae0a54 | 2015-04-27 13:57:03 -0700 | [diff] [blame] | 47 | "qcom,dsi_jdi_qhd_video", "dsi:0:", "qcom,mdss-dsi-panel", |
Dhaval Patel | 8f230ea | 2014-01-03 13:37:12 -0800 | [diff] [blame] | 48 | 10, 0, "DISPLAY_1", 0, 0, 60, 0, 0, 1, 0, 0, 0, 0, 0, 11, 0, 0, |
Padmanabhan Komanduru | 9ae0a54 | 2015-04-27 13:57:03 -0700 | [diff] [blame] | 49 | "qcom,dsi_jdi_qhd_video", |
Dhaval Patel | 7e724ab | 2013-10-25 10:02:54 -0700 | [diff] [blame] | 50 | }; |
| 51 | |
| 52 | /*---------------------------------------------------------------------------*/ |
| 53 | /* Panel resolution */ |
| 54 | /*---------------------------------------------------------------------------*/ |
| 55 | static struct panel_resolution jdi_qhd_dualdsi_video_panel_res = { |
| 56 | 2560, 1440, 120, 44, 16, 0, 8, 4, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0 |
| 57 | }; |
| 58 | |
| 59 | /*---------------------------------------------------------------------------*/ |
| 60 | /* Panel color information */ |
| 61 | /*---------------------------------------------------------------------------*/ |
| 62 | static struct color_info jdi_qhd_dualdsi_video_color = { |
| 63 | 24, 0, 0xff, 0, 0, 0 |
| 64 | }; |
| 65 | |
| 66 | /*---------------------------------------------------------------------------*/ |
| 67 | /* Panel on/off command information */ |
| 68 | /*---------------------------------------------------------------------------*/ |
| 69 | static char jdi_qhd_dualdsi_video_on_cmd0[] = { |
| 70 | 0x00, 0xFF, 0x05, 0x80 |
| 71 | }; |
| 72 | |
| 73 | static char jdi_qhd_dualdsi_video_on_cmd1[] = { |
| 74 | 0x3a, 0x77, 0x15, 0x80 |
| 75 | }; |
| 76 | |
| 77 | static char jdi_qhd_dualdsi_video_on_cmd2[] = { |
| 78 | 0x05, 0x00, 0x39, 0xC0, |
| 79 | 0x2a, 0x00, 0x00, 0x04, |
| 80 | 0xff, 0xFF, 0xFF, 0xFF, |
| 81 | }; |
| 82 | |
| 83 | static char jdi_qhd_dualdsi_video_on_cmd3[] = { |
| 84 | 0x05, 0x00, 0x39, 0xC0, |
| 85 | 0x2b, 0x00, 0x00, 0x05, |
| 86 | 0x9f, 0xFF, 0xFF, 0xFF, |
| 87 | }; |
| 88 | |
| 89 | static char jdi_qhd_dualdsi_video_on_cmd4[] = { |
| 90 | 0x35, 0x00, 0x15, 0x80 |
| 91 | }; |
| 92 | |
| 93 | static char jdi_qhd_dualdsi_video_on_cmd5[] = { |
| 94 | 0x03, 0x00, 0x39, 0xC0, |
| 95 | 0x44, 0x00, 0x00, 0xFF, |
| 96 | }; |
| 97 | |
| 98 | static char jdi_qhd_dualdsi_video_on_cmd6[] = { |
| 99 | 0x51, 0xff, 0x15, 0x80 |
| 100 | }; |
| 101 | |
| 102 | static char jdi_qhd_dualdsi_video_on_cmd7[] = { |
| 103 | 0x53, 0x24, 0x15, 0x80 |
| 104 | }; |
| 105 | |
| 106 | static char jdi_qhd_dualdsi_video_on_cmd8[] = { |
| 107 | 0x55, 0x00, 0x15, 0x80 |
| 108 | }; |
| 109 | |
| 110 | static char jdi_qhd_dualdsi_video_on_cmd9[] = { |
| 111 | 0x11, 0xFF, 0x05, 0x80 |
| 112 | }; |
| 113 | |
| 114 | static char jdi_qhd_dualdsi_video_on_cmd10[] = { |
| 115 | 0xb0, 0x00, 0x23, 0x80 |
| 116 | }; |
| 117 | |
| 118 | static char jdi_qhd_dualdsi_video_on_cmd11[] = { |
| 119 | 0x02, 0x00, 0x29, 0xC0, |
| 120 | 0xb3, 0x14, 0xFF, 0xFF, |
| 121 | }; |
| 122 | |
| 123 | static char jdi_qhd_dualdsi_video_on_cmd12[] = { |
| 124 | 0x14, 0x00, 0x29, 0xC0, |
| 125 | 0xce, 0x7d, 0x40, 0x48, |
| 126 | 0x56, 0x67, 0x78, 0x88, |
| 127 | 0x98, 0xa7, 0xb5, 0xc3, |
| 128 | 0xd1, 0xde, 0xe9, 0xf2, |
| 129 | 0xfa, 0xff, 0x04, 0x00, |
| 130 | }; |
| 131 | |
| 132 | static char jdi_qhd_dualdsi_video_on_cmd13[] = { |
| 133 | 0xb0, 0x03, 0x23, 0x80 |
| 134 | }; |
| 135 | |
| 136 | static char jdi_qhd_dualdsi_video_on_cmd14[] = { |
| 137 | 0x29, 0xFF, 0x05, 0x80 |
| 138 | }; |
| 139 | |
| 140 | static struct mipi_dsi_cmd jdi_qhd_dualdsi_video_on_command[] = { |
| 141 | {0x4, jdi_qhd_dualdsi_video_on_cmd0, 0x0a}, |
| 142 | {0x4, jdi_qhd_dualdsi_video_on_cmd1, 0x0a}, |
| 143 | {0xc, jdi_qhd_dualdsi_video_on_cmd2, 0x0a}, |
| 144 | {0xc, jdi_qhd_dualdsi_video_on_cmd3, 0x0a}, |
| 145 | {0x4, jdi_qhd_dualdsi_video_on_cmd4, 0x0a}, |
| 146 | {0x8, jdi_qhd_dualdsi_video_on_cmd5, 0x0a}, |
| 147 | {0x4, jdi_qhd_dualdsi_video_on_cmd6, 0x0a}, |
| 148 | {0x4, jdi_qhd_dualdsi_video_on_cmd7, 0x0a}, |
| 149 | {0x4, jdi_qhd_dualdsi_video_on_cmd8, 0x0a}, |
| 150 | {0x4, jdi_qhd_dualdsi_video_on_cmd9, 0x78}, |
| 151 | {0x4, jdi_qhd_dualdsi_video_on_cmd10, 0x0a}, |
| 152 | {0x8, jdi_qhd_dualdsi_video_on_cmd11, 0x0a}, |
| 153 | {0x18, jdi_qhd_dualdsi_video_on_cmd12, 0x0a}, |
| 154 | {0x4, jdi_qhd_dualdsi_video_on_cmd13, 0x0a}, |
| 155 | {0x4, jdi_qhd_dualdsi_video_on_cmd14, 0x32} |
| 156 | }; |
| 157 | |
| 158 | #define JDI_QHD_DUALDSI_VIDEO_ON_COMMAND 15 |
| 159 | |
| 160 | |
| 161 | static char jdi_qhd_dualdsi_videooff_cmd0[] = { |
| 162 | 0x28, 0x00, 0x05, 0x80 |
| 163 | }; |
| 164 | |
| 165 | static char jdi_qhd_dualdsi_videooff_cmd1[] = { |
| 166 | 0x10, 0x00, 0x05, 0x80 |
| 167 | }; |
| 168 | |
| 169 | static struct mipi_dsi_cmd jdi_qhd_dualdsi_video_off_command[] = { |
| 170 | {0x4, jdi_qhd_dualdsi_videooff_cmd0, 0x32}, |
| 171 | {0x4, jdi_qhd_dualdsi_videooff_cmd1, 0x78} |
| 172 | }; |
| 173 | |
| 174 | #define JDI_QHD_DUALDSI_VIDEO_OFF_COMMAND 2 |
| 175 | |
| 176 | |
| 177 | static struct command_state jdi_qhd_dualdsi_video_state = { |
| 178 | 0, 1 |
| 179 | }; |
| 180 | |
| 181 | /*---------------------------------------------------------------------------*/ |
| 182 | /* Command mode panel information */ |
| 183 | /*---------------------------------------------------------------------------*/ |
| 184 | static struct commandpanel_info jdi_qhd_dualdsi_video_command_panel = { |
| 185 | 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 |
| 186 | }; |
| 187 | |
| 188 | /*---------------------------------------------------------------------------*/ |
| 189 | /* Video mode panel information */ |
| 190 | /*---------------------------------------------------------------------------*/ |
| 191 | static struct videopanel_info jdi_qhd_dualdsi_video_video_panel = { |
| 192 | 0, 0, 0, 0, 1, 1, 1, 0, 0x9 |
| 193 | }; |
| 194 | |
| 195 | /*---------------------------------------------------------------------------*/ |
| 196 | /* Lane configuration */ |
| 197 | /*---------------------------------------------------------------------------*/ |
| 198 | static struct lane_configuration jdi_qhd_dualdsi_video_lane_config = { |
Ray Zhang | 0d303af | 2015-01-21 10:17:02 +0800 | [diff] [blame] | 199 | 4, 0, 1, 1, 1, 1, 0 |
Dhaval Patel | 7e724ab | 2013-10-25 10:02:54 -0700 | [diff] [blame] | 200 | }; |
| 201 | |
| 202 | /*---------------------------------------------------------------------------*/ |
| 203 | /* Panel timing */ |
| 204 | /*---------------------------------------------------------------------------*/ |
| 205 | static const uint32_t jdi_qhd_dualdsi_video_timings[] = { |
| 206 | 0xcd, 0x32, 0x22, 0x00, 0x60, 0x64, 0x26, 0x34, 0x29, 0x03, 0x04, 0x00 |
| 207 | }; |
| 208 | |
Dhaval Patel | 5657da9 | 2015-03-16 11:11:23 -0700 | [diff] [blame] | 209 | static const uint32_t jdi_qhd_dualdsi_thulium_video_timings[] = { |
| 210 | 0x22, 0x1e, 0x06, 0x08, 0x04, 0x03, 0x04, 0xa0, |
| 211 | 0x22, 0x1e, 0x06, 0x08, 0x04, 0x03, 0x04, 0xa0, |
| 212 | 0x22, 0x1e, 0x06, 0x08, 0x04, 0x03, 0x04, 0xa0, |
| 213 | 0x22, 0x1e, 0x06, 0x08, 0x04, 0x03, 0x04, 0xa0, |
| 214 | 0x22, 0x2c, 0x05, 0x08, 0x04, 0x03, 0x04, 0xa0, |
| 215 | }; |
| 216 | |
Dhaval Patel | 7e724ab | 2013-10-25 10:02:54 -0700 | [diff] [blame] | 217 | static struct panel_timing jdi_qhd_dualdsi_video_timing_info = { |
| 218 | 0x0, 0x04, 0x03, 0x27 |
| 219 | }; |
| 220 | |
| 221 | /*---------------------------------------------------------------------------*/ |
| 222 | /* Panel reset sequence */ |
| 223 | /*---------------------------------------------------------------------------*/ |
| 224 | static struct panel_reset_sequence jdi_qhd_dualdsi_video_reset_seq = { |
Dhaval Patel | 79efc34 | 2014-03-20 16:05:23 -0700 | [diff] [blame] | 225 | {1, 0, 1, }, {10, 10, 10, }, 2 |
Dhaval Patel | 7e724ab | 2013-10-25 10:02:54 -0700 | [diff] [blame] | 226 | }; |
| 227 | |
| 228 | /*---------------------------------------------------------------------------*/ |
| 229 | /* Backlight setting */ |
| 230 | /*---------------------------------------------------------------------------*/ |
| 231 | static struct backlight jdi_qhd_dualdsi_video_backlight = { |
Dhaval Patel | 47ed7bc | 2014-01-07 21:47:46 -0800 | [diff] [blame] | 232 | 0, 1, 4095, 100, 1, "PMIC_8941" |
Dhaval Patel | 7e724ab | 2013-10-25 10:02:54 -0700 | [diff] [blame] | 233 | }; |
| 234 | |
| 235 | #endif /*_PANEL_JDI_QHD_DUALDSI_VIDEO_H_*/ |