Ray Zhang | 0d303af | 2015-01-21 10:17:02 +0800 | [diff] [blame] | 1 | /* Copyright (c) 2014-2015, The Linux Foundation. All rights reserved. |
Shuo Yan | 2616adc | 2014-08-13 08:22:27 +0800 | [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_HX8379A_FWVGA_VIDEO_H_ |
| 37 | #define _PANEL_HX8379A_FWVGA_VIDEO_H_ |
| 38 | /*---------------------------------------------------------------------------*/ |
| 39 | /* HEADER files */ |
| 40 | /*---------------------------------------------------------------------------*/ |
| 41 | #include "panel.h" |
| 42 | |
| 43 | /*---------------------------------------------------------------------------*/ |
| 44 | /* Panel configuration */ |
| 45 | /*---------------------------------------------------------------------------*/ |
| 46 | static struct panel_config hx8379a_fwvga_video_panel_data = { |
| 47 | "qcom,mdss_dsi_hx8379a_fwvga_video", "dsi:0:", "qcom,mdss-dsi-panel", |
| 48 | 10, 0, "DISPLAY_1", 0, 0, 60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 |
| 49 | }; |
| 50 | |
| 51 | /*---------------------------------------------------------------------------*/ |
| 52 | /* Panel resolution */ |
| 53 | /*---------------------------------------------------------------------------*/ |
| 54 | static struct panel_resolution hx8379a_fwvga_video_panel_res = { |
| 55 | 480, 854, 100, 94, 40, 0, 6, 4, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0 |
| 56 | }; |
| 57 | |
| 58 | /*---------------------------------------------------------------------------*/ |
| 59 | /* Panel color information */ |
| 60 | /*---------------------------------------------------------------------------*/ |
| 61 | static struct color_info hx8379a_fwvga_video_color = { |
| 62 | 24, 0, 0xff, 0, 0, 0 |
| 63 | }; |
| 64 | |
| 65 | /*---------------------------------------------------------------------------*/ |
| 66 | /* Panel on/off command information */ |
| 67 | /*---------------------------------------------------------------------------*/ |
| 68 | static char hx8379a_fwvga_video_on_cmd0[] = { |
| 69 | 0x04, 0x00, 0x39, 0xC0, |
| 70 | 0xB9, 0xFF, 0x83, 0x79, |
| 71 | }; |
| 72 | |
| 73 | static char hx8379a_fwvga_video_on_cmd1[] = { |
| 74 | 0x03, 0x00, 0x39, 0xC0, |
| 75 | 0xBA, 0x51, 0x93, 0xFF, |
| 76 | }; |
| 77 | |
| 78 | static char hx8379a_fwvga_video_on_cmd2[] = { |
| 79 | 0x14, 0x00, 0x39, 0xC0, |
| 80 | 0xB1, 0x00, 0x50, 0x24, |
| 81 | 0xEA, 0x51, 0x08, 0x11, |
| 82 | 0x10, 0xF0, 0x27, 0x2F, |
| 83 | 0x9A, 0x1A, 0x42, 0x0B, |
| 84 | 0x7A, 0xF1, 0x00, 0xE6, |
| 85 | }; |
| 86 | |
| 87 | static char hx8379a_fwvga_video_on_cmd3[] = { |
| 88 | 0x0E, 0x00, 0x39, 0xC0, |
| 89 | 0xB2, 0x00, 0x00, 0xFE, |
| 90 | 0x07, 0x03, 0x19, 0x44, |
| 91 | 0x00, 0xFF, 0x07, 0x03, |
| 92 | 0x19, 0x20, 0xFF, 0xFF, |
| 93 | }; |
| 94 | |
| 95 | static char hx8379a_fwvga_video_on_cmd4[] = { |
| 96 | 0x20, 0x00, 0x39, 0xC0, |
| 97 | 0xB4, 0x82, 0x08, 0x00, |
| 98 | 0x32, 0x10, 0x03, 0x32, |
| 99 | 0x13, 0x70, 0x32, 0x10, |
| 100 | 0x08, 0x37, 0x01, 0x28, |
| 101 | 0x07, 0x37, 0x08, 0x3C, |
| 102 | 0x08, 0x3E, 0x3E, 0x08, |
| 103 | 0x00, 0x40, 0x08, 0x28, |
| 104 | 0x08, 0x30, 0x30, 0x04, |
| 105 | }; |
| 106 | |
| 107 | static char hx8379a_fwvga_video_on_cmd5[] = { |
| 108 | 0xcc, 0x02, 0x23, 0x80 |
| 109 | }; |
| 110 | |
| 111 | static char hx8379a_fwvga_video_on_cmd6[] = { |
| 112 | 0x30, 0x00, 0x39, 0xC0, |
| 113 | 0xD5, 0x00, 0x00, 0x0A, |
| 114 | 0x00, 0x01, 0x05, 0x00, |
| 115 | 0x03, 0x00, 0x88, 0x88, |
| 116 | 0x88, 0x88, 0x23, 0x01, |
| 117 | 0x67, 0x45, 0x02, 0x13, |
| 118 | 0x88, 0x88, 0x88, 0x88, |
| 119 | 0x88, 0x88, 0x88, 0x88, |
| 120 | 0x88, 0x88, 0x54, 0x76, |
| 121 | 0x10, 0x32, 0x31, 0x20, |
| 122 | 0x88, 0x88, 0x88, 0x88, |
| 123 | 0x88, 0x88, 0x00, 0x00, |
| 124 | 0x00, 0x00, 0x00, 0x00, |
| 125 | }; |
| 126 | |
| 127 | static char hx8379a_fwvga_video_on_cmd7[] = { |
| 128 | 0x24, 0x00, 0x39, 0xC0, |
| 129 | 0xE0, 0x79, 0x00, 0x0F, |
| 130 | 0x14, 0x22, 0x22, 0x39, |
| 131 | 0x2F, 0x43, 0x04, 0x0A, |
| 132 | 0x12, 0x14, 0x17, 0x15, |
| 133 | 0x16, 0x12, 0x16, 0x00, |
| 134 | 0x0F, 0x14, 0x22, 0x22, |
| 135 | 0x39, 0x2F, 0x43, 0x04, |
| 136 | 0x0A, 0x12, 0x14, 0x17, |
| 137 | 0x15, 0x16, 0x12, 0x16, |
| 138 | }; |
| 139 | |
| 140 | static char hx8379a_fwvga_video_on_cmd8[] = { |
| 141 | 0x05, 0x00, 0x39, 0xC0, |
| 142 | 0xB6, 0x00, 0x9C, 0x00, |
| 143 | 0x9C, 0xFF, 0xFF, 0xFF, |
| 144 | }; |
| 145 | |
| 146 | static char hx8379a_fwvga_video_on_cmd9[] = { |
| 147 | 0x11, 0x00, 0x05, 0x80 |
| 148 | }; |
| 149 | |
| 150 | static char hx8379a_fwvga_video_on_cmd10[] = { |
| 151 | 0x29, 0x00, 0x05, 0x80 |
| 152 | }; |
| 153 | |
| 154 | static struct mipi_dsi_cmd hx8379a_fwvga_video_on_command[] = { |
| 155 | {0x8, hx8379a_fwvga_video_on_cmd0, 0x00}, |
| 156 | {0x8, hx8379a_fwvga_video_on_cmd1, 0x00}, |
| 157 | {0x18, hx8379a_fwvga_video_on_cmd2, 0x00}, |
| 158 | {0x14, hx8379a_fwvga_video_on_cmd3, 0x00}, |
| 159 | {0x24, hx8379a_fwvga_video_on_cmd4, 0x00}, |
| 160 | {0x04, hx8379a_fwvga_video_on_cmd5, 0x00}, |
| 161 | {0x34, hx8379a_fwvga_video_on_cmd6, 0x00}, |
| 162 | {0x28, hx8379a_fwvga_video_on_cmd7, 0x00}, |
| 163 | {0xc, hx8379a_fwvga_video_on_cmd8, 0x00}, |
| 164 | {0x4, hx8379a_fwvga_video_on_cmd9, 0x96}, |
| 165 | {0x4, hx8379a_fwvga_video_on_cmd10, 0x78} |
| 166 | }; |
| 167 | |
| 168 | #define HX8379A_FWVGA_VIDEO_ON_COMMAND 11 |
| 169 | |
| 170 | |
| 171 | static char hx8379a_fwvga_videooff_cmd0[] = { |
| 172 | 0x28, 0x00, 0x05, 0x80 |
| 173 | }; |
| 174 | |
| 175 | static char hx8379a_fwvga_videooff_cmd1[] = { |
| 176 | 0x10, 0x00, 0x05, 0x80 |
| 177 | }; |
| 178 | |
| 179 | static struct mipi_dsi_cmd hx8379a_fwvga_video_off_command[] = { |
| 180 | {0x4, hx8379a_fwvga_videooff_cmd0, 0x32}, |
| 181 | {0x4, hx8379a_fwvga_videooff_cmd1, 0x78} |
| 182 | }; |
| 183 | |
| 184 | #define HX8379A_FWVGA_VIDEO_OFF_COMMAND 2 |
| 185 | |
| 186 | |
| 187 | static struct command_state hx8379a_fwvga_video_state = { |
| 188 | 0, 0 |
| 189 | }; |
| 190 | |
| 191 | /*---------------------------------------------------------------------------*/ |
| 192 | /* Command mode panel information */ |
| 193 | /*---------------------------------------------------------------------------*/ |
| 194 | static struct commandpanel_info hx8379a_fwvga_video_command_panel = { |
| 195 | 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 |
| 196 | }; |
| 197 | |
| 198 | /*---------------------------------------------------------------------------*/ |
| 199 | /* Video mode panel information */ |
| 200 | /*---------------------------------------------------------------------------*/ |
| 201 | static struct videopanel_info hx8379a_fwvga_video_video_panel = { |
| 202 | 1, 0, 0, 0, 1, 1, 2, 0, 0x9 |
| 203 | }; |
| 204 | |
| 205 | /*---------------------------------------------------------------------------*/ |
| 206 | /* Lane configuration */ |
| 207 | /*---------------------------------------------------------------------------*/ |
| 208 | static struct lane_configuration hx8379a_fwvga_video_lane_config = { |
Ray Zhang | 0d303af | 2015-01-21 10:17:02 +0800 | [diff] [blame] | 209 | 2, 1, 1, 1, 0, 0, 0 |
Shuo Yan | 2616adc | 2014-08-13 08:22:27 +0800 | [diff] [blame] | 210 | }; |
| 211 | |
| 212 | /*---------------------------------------------------------------------------*/ |
| 213 | /* Panel timing */ |
| 214 | /*---------------------------------------------------------------------------*/ |
| 215 | static const uint32_t hx8379a_fwvga_video_timings[] = { |
| 216 | 0x8B, 0x1f, 0x14, 0x00, 0x45, 0x4A, 0x19, 0x23, 0x23, 0x03, 0x04, 0x00 |
| 217 | }; |
| 218 | |
| 219 | static struct panel_timing hx8379a_fwvga_video_timing_info = { |
| 220 | 0, 4, 0x04, 0x1d |
| 221 | }; |
| 222 | |
| 223 | /*---------------------------------------------------------------------------*/ |
| 224 | /* Panel reset sequence */ |
| 225 | /*---------------------------------------------------------------------------*/ |
| 226 | static struct panel_reset_sequence hx8379a_fwvga_video_reset_seq = { |
| 227 | {1, 0, 1, }, {20, 2, 20, }, 2 |
| 228 | }; |
| 229 | |
| 230 | /*---------------------------------------------------------------------------*/ |
| 231 | /* Backlight setting */ |
| 232 | /*---------------------------------------------------------------------------*/ |
| 233 | static struct backlight hx8379a_fwvga_video_backlight = { |
| 234 | 0, 1, 255, 0, 2, 0 |
| 235 | }; |
| 236 | |
| 237 | #endif /*_PANEL_HX8379A_FWVGA_VIDEO_H_*/ |