tizen 2.4 release
[kernel/u-boot-tm1.git] / drivers / video / sprdfb / dsi_1_21a / mipi_dsih_hal.h
1 /*\r
2  * @file mipi_dsih_hal.h\r
3  *\r
4  *  Synopsys Inc.\r
5  *  SG DWC PT02\r
6  */\r
7 /*\r
8         The Synopsys Software Driver and documentation (hereinafter "Software")\r
9         is an unsupported proprietary work of Synopsys, Inc. unless otherwise\r
10         expressly agreed to in writing between  Synopsys and you.\r
11 \r
12         The Software IS NOT an item of Licensed Software or Licensed Product under\r
13         any End User Software License Agreement or Agreement for Licensed Product\r
14         with Synopsys or any supplement thereto.  Permission is hereby granted,\r
15         free of charge, to any person obtaining a copy of this software annotated\r
16         with this license and the Software, to deal in the Software without\r
17         restriction, including without limitation the rights to use, copy, modify,\r
18         merge, publish, distribute, sublicense, and/or sell copies of the Software,\r
19         and to permit persons to whom the Software is furnished to do so, subject\r
20         to the following conditions:\r
21 \r
22         The above copyright notice and this permission notice shall be included in\r
23         all copies or substantial portions of the Software.\r
24 \r
25         THIS SOFTWARE IS BEING DISTRIBUTED BY SYNOPSYS SOLELY ON AN "AS IS" BASIS\r
26         AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE\r
27         IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE\r
28         ARE HEREBY DISCLAIMED. IN NO EVENT SHALL SYNOPSYS BE LIABLE FOR ANY DIRECT,\r
29         INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES\r
30         (INCLUDING, BUT NOT     LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR\r
31         SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER\r
32         CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT\r
33         LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY\r
34         OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH\r
35         DAMAGE.\r
36  */\r
37 \r
38 #ifndef MIPI_DSIH_HAL_H_\r
39 #define MIPI_DSIH_HAL_H_\r
40 \r
41 #include "mipi_dsih_local.h"\r
42 \r
43 \r
44 #define R_DSI_HOST_VERSION                      (0x00)\r
45 #define R_DSI_HOST_PWR_UP                       (0x04)\r
46 #define R_DSI_HOST_CLK_MGR                      (0x08)\r
47 #define R_DSI_HOST_DPI_VCID                     (0x0C)\r
48 #define R_DSI_HOST_DPI_COLOR_CODE               (0x10)\r
49 #define R_DSI_HOST_DPI_CFG_POL                  (0x14)\r
50 #define R_DSI_HOST_DPI_LP_CMD_TIM               (0x18)\r
51 #define R_DSI_HOST_DBI_VCID                     (0x1C)\r
52 #define R_DSI_HOST_DBI_CFG                      (0x20)\r
53 #define R_DSI_HOST_DBI_PARTITION_EN     (0x24)\r
54 #define R_DSI_HOST_DBI_CMDSIZE                  (0x28)\r
55 #define R_DSI_HOST_PCKHDL_CFG                   (0x2C)\r
56 #define R_DSI_HOST_GEN_VCID                     (0x30)\r
57 #define R_DSI_HOST_MODE_CFG                             (0x34)\r
58 #define R_DSI_HOST_VID_MODE_CFG                 (0x38)\r
59 #define R_DSI_HOST_VID_PKT_SIZE                 (0x3C)\r
60 #define R_DSI_HOST_VID_NUM_CHUNKS               (0x40)\r
61 #define R_DSI_HOST_VID_NULL_SIZE                (0x44)\r
62 #define R_DSI_HOST_VID_HSA_TIME                 (0x48)\r
63 #define R_DSI_HOST_VID_HBP_TIME                 (0x4C)\r
64 #define R_DSI_HOST_VID_HLINE_TIME               (0x50)\r
65 #define R_DSI_HOST_VID_VSA_LINES                (0x54)\r
66 #define R_DSI_HOST_VID_VBP_LINES                (0x58)\r
67 #define R_DSI_HOST_VID_VFP_LINES                (0x5C)\r
68 #define R_DSI_HOST_VID_VACTIVE_LINES    (0x60)\r
69 #define R_DSI_HOST_EDPI_CMD_SIZE        (0x64)\r
70 #define R_DSI_HOST_CMD_MODE_CFG                 (0x68)\r
71 #define R_DSI_HOST_GEN_HDR                      (0x6C)\r
72 #define R_DSI_HOST_GEN_PLD_DATA                 (0x70)\r
73 #define R_DSI_HOST_CMD_PKT_STATUS               (0x74)\r
74 #define R_DSI_HOST_TO_CNT_CFG                   (0x78)\r
75 #define R_DSI_HOST_HS_RD_TO_CNT                 (0x7C)\r
76 #define R_DSI_HOST_LP_RD_TO_CNT                 (0x80)\r
77 #define R_DSI_HOST_HS_WR_TO_CNT                 (0x84)\r
78 #define R_DSI_HOST_LP_WR_TO_CNT                 (0x88)\r
79 #define R_DSI_HOST_BTA_TO_CNT                   (0x8C)\r
80 \r
81 #define R_DSI_HOST_SDF_3D                               (0x90)\r
82 \r
83 #define R_DSI_HOST_LPCLK_CTRL                   (0x94)\r
84 #define R_DSI_HOST_PHY_TMR_LPCLK_CFG    (0x98)\r
85 #define R_DSI_HOST_PHY_TMR_CFG                  (0x9C)\r
86 #define R_DSI_HOST_INT_ST0                      (0xBC)\r
87 #define R_DSI_HOST_INT_ST1                      (0xC0)\r
88 #define R_DSI_HOST_INT_MSK0                     (0xC4)\r
89 #define R_DSI_HOST_INT_MSK1                     (0xC8)\r
90 #define R_DSI_HOST_PHY_STATUS                   (0xB0)\r
91 \r
92 //base :0x2180 0000\r
93 typedef struct _DSIH1P21A_REG_T_\r
94 {\r
95     union _DSIH1P21A_VERSION_tag_t {\r
96         struct _DSIH1P21A_VERSION_map_t\r
97         {\r
98 volatile unsigned int version :\r
99             32;  //0x3132302A\r
100         }\r
101         mBits;\r
102         volatile  unsigned int   dwVersion;\r
103     }VERSION;// 0x0000\r
104 \r
105     union _DSIH1P21A_PWR_UP_tag_t {\r
106         struct _DSIH1P21A_PWR_UP_map_t\r
107         {\r
108 volatile unsigned int power_up             :\r
109             1;    //[0]  1 power up , 0 reset core\r
110 volatile unsigned int reserved_0                :\r
111             31; //[31:1] Reserved\r
112         }\r
113         mBits;\r
114         volatile unsigned int dValue;\r
115     }PWR_UP;// 0x0004\r
116 \r
117 \r
118     union _DSIH1P21A_CLKMGR_CFG_tag_t {\r
119         struct _DSIH1P21A_CLKMGR_CFG_map_t\r
120         {\r
121 volatile unsigned int tx_esc_clk_division             :\r
122             8;    //[7:0]  This field indicates the division factor for the TX Escape clock source (lanebyteclk). The values 0 and 1 stop the TX_ESC clock generation\r
123 volatile unsigned int to_clk_division             :\r
124             8;    //[15:8]  This field indicates the division factor for the Time Out clock used as the timing unit in the configuration of HS to LP and LP to HS transition error.\r
125 volatile unsigned int reserved_0                :\r
126             16; //[31:16] Reserved\r
127         }\r
128         mBits;\r
129         volatile unsigned int dValue;\r
130     }CLKMGR_CFG;// 0x0008\r
131 \r
132     union _DSIH1P21A_DPI_VCID_tag_t {\r
133         struct _DSIH1P21A_DPI_VCID_map_t\r
134         {\r
135 volatile unsigned int dpi_vcid             :\r
136             2;    //[1:0]  This field configures the DPI virtual channel id that is indexed to the Video mode packets.\r
137 volatile unsigned int reserved_0                :\r
138             30; //[31:2] Reserved\r
139         }\r
140         mBits;\r
141         volatile unsigned int dValue;\r
142     }DPI_VCID;// 0x000C\r
143     //======================\r
144 \r
145     union _DSIH1P21A_DPI_COLOR_CODING_tag_t {\r
146         struct _DSIH1P21A_DPI_COLOR_CODING_map_t\r
147         {\r
148 volatile unsigned int dpi_color_coding             :\r
149             4;    //[3:0]\r
150             /*\r
151             This field configures the DPI color coding as follows:\r
152             0000: 16-bit configuration 1\r
153             0001: 16-bit configuration 2\r
154             0010: 16-bit configuration 3\r
155             0011: 18-bit configuration 1\r
156             0100: 18-bit configuration 2\r
157             0101: 24-bit\r
158             0110: 20-bit YCbCr 4:2:2 loosely packed\r
159             0111: 24-bit YCbCr 4:2:2\r
160             1000: 16-bit YCbCr 4:2:2\r
161             1001: 30-bit\r
162             1010: 36-bit\r
163             1011-1111: 12-bit YCbCr 4:2:0\r
164             Note: If the eDPI interface is chosen and currently works in the\r
165             Command mode (cmd_video_mode = 1), then\r
166             0110-1111: 24-bit\r
167             */\r
168 volatile unsigned int reserved_0                :\r
169             4; //[7:4] Reserved\r
170 volatile unsigned int loosely18_en             :\r
171             1;    //[8] When set to 1, this bit activates loosely packed variant to 18-bit configurations.\r
172 volatile unsigned int reserved_1                :\r
173             23; //[31:9] Reserved\r
174         }\r
175         mBits;\r
176         volatile unsigned int dValue;\r
177     }DPI_COLOR_CODING;// 0x0010\r
178 \r
179 \r
180     union _DSIH1P21A_DPI_CFG_POL_tag_t {\r
181         struct _DSIH1P21A_DPI_CFG_POL_map_t\r
182         {\r
183 volatile unsigned int dataen_active_low             :\r
184             1;    //[0] When set to 1, this bit configures the data enable pin (dpidataen) asactive low.\r
185 volatile unsigned int vsync_active_low             :\r
186             1;    //[1] When set to 1, this bit configures the vertical synchronism pin (dpivsync) as active low.\r
187 volatile unsigned int hsync_active_low             :\r
188             1;    //[2] When set to 1, this bit configures the horizontal synchronism pin (dpihsync) as active low.\r
189 volatile unsigned int shutd_active_low             :\r
190             1;    //[3] When set to 1, this bit configures the shutdown pin (dpishutdn) as active low\r
191 volatile unsigned int colorm_active_low             :\r
192             1;    //[4] When set to 1, this bit configures the color mode pin (dpicolorm) as active low.\r
193 volatile unsigned int reserved_0             :\r
194             27;    //[31:5]\r
195         }\r
196         mBits;\r
197         volatile unsigned int dValue;\r
198     }DPI_CFG_POL;// 0x0014\r
199 \r
200 \r
201     union _DSIH1P21A_DPI_LP_CMD_TIM_tag_t {\r
202         struct _DSIH1P21A_DPI_LP_CMD_TIM_map_t\r
203         {\r
204 volatile unsigned int invact_lpcmd_time             :\r
205             8;    //[7:0] This field is used for the transmission of commands in low-power mode. It defines the size, in bytes, of the largest packet that can fit in a line during the VACT region.\r
206 volatile unsigned int reserved_0                :\r
207             8; //[15:8] Reserved\r
208 volatile unsigned int outvact_lpcmd_time             :\r
209             8;    //[23:16] This field is used for the transmission of commands in low-power mode. It defines the size, in bytes, of the largest packet that can fit in a line during the VSA, VBP, and VFP regions.\r
210 volatile unsigned int reserved_1                :\r
211             8; //[31:24] Reserved\r
212         }\r
213         mBits;\r
214         volatile unsigned int dValue;\r
215     }DPI_LP_CMD_TIM;// 0x0018\r
216 \r
217     union _DSIH1P21A_DBI_VCID_tag_t {\r
218         struct _DSIH1P21A_DBI_VCID_map_t\r
219         {\r
220 volatile unsigned int dbi_vcid             :\r
221             2;    //[1:0] This field configures the virtual channel id that is indexed to the DCS packets from DBI.\r
222 volatile unsigned int reserved_0                :\r
223             30; //[31:2] Reserved\r
224         }\r
225         mBits;\r
226         volatile unsigned int dValue;\r
227     }DBI_VCID;// 0x001C\r
228 \r
229     union _DSIH1P21A_DBI_CFG_tag_t {\r
230         struct _DSIH1P21A_DBI_CFG_map_t\r
231         {\r
232 volatile unsigned int in_dbi_conf             :\r
233             4;    //[3:0]\r
234             /*\r
235             This field configures the DBI input pixel data as follows:\r
236             0000: 8-bit 8 bpp\r
237             0001: 8-bit 12 bpp\r
238             0010: 8-bit 16 bpp\r
239             0011: 8-bit 18 bpp\r
240             0100: 8-bit 24 bpp\r
241             0101: 9-bit 18 bpp\r
242             0110: 16-bit 8 bpp\r
243             0111: 16-bit 12 bpp\r
244             1000: 16-bit 16 bpp\r
245             1001: 16-bit 18 bpp, option 1\r
246             1010: 16-bit 18 bpp, option 2\r
247             1011: 16-bit 24 bpp, option 1\r
248             1100: 16-bit 24 bpp, option 2\r
249             */\r
250 volatile unsigned int reserved_0                :\r
251             4; //[7:4] Reserved\r
252 volatile unsigned int out_dbi_conf             :\r
253             4;    //[11:8]\r
254             /*\r
255             This field configures the DBI output pixel data as follows:\r
256             0000: 8-bit 8 bpp\r
257             0001: 8-bit 12 bpp\r
258             0010: 8-bit 16 bpp\r
259             0011: 8-bit 18 bpp\r
260             0100: 8-bit 24 bpp\r
261             0101: 9-bit 18 bpp\r
262             0110: 16-bit 8 bpp\r
263             0111: 16-bit 12 bpp\r
264             1000: 16-bit 16 bpp\r
265             1001: 16-bit 18 bpp, option 1\r
266             1010: 16-bit 18 bpp, option 2\r
267             1011: 16-bit 24 bpp, option 1\r
268             1100: 16-bit 24 bpp, option 2\r
269             */\r
270 volatile unsigned int reserved_1                :\r
271             4; //[15:12] Reserved\r
272 \r
273 volatile unsigned int lut_size_conf             :\r
274             2;    //[17:16]\r
275             /*\r
276             This field configures the size used to transport the write Lut\r
277             commands as follows:\r
278             00: 16-bit color display\r
279             01: 18-bit color display\r
280             10: 24-bit color display\r
281             11: 16-bit color display\r
282             */\r
283 \r
284 volatile unsigned int reserved_2                :\r
285             14; //[31:18] Reserved\r
286         }\r
287         mBits;\r
288         volatile unsigned int dValue;\r
289     }DBI_CFG;// 0x0020\r
290 \r
291     union _DSIH1P21A_DBI_PARTITIONING_EN_tag_t {\r
292         struct _DSIH1P21A_DBI_PARTITIONING_EN_map_t\r
293         {\r
294 volatile unsigned int partitioning_en             :\r
295             1;    //[0]\r
296             /*\r
297             When set to 1, this bit enables the use of write_memory_continue\r
298             input commands (system needs to ensure correct partitioning of Long\r
299             Write commands). When not set, partitioning is automatically\r
300             performed in the DWC_mipi_dsi_host.\r
301             */\r
302 volatile unsigned int reserved_0                :\r
303             31; //[31:1] Reserved\r
304         }\r
305         mBits;\r
306         volatile unsigned int dValue;\r
307     }DBI_PARTITIONING_EN;// 0x0024\r
308 \r
309     union _DSIH1P21A_DBI_CMDSIZE_tag_t {\r
310         struct _DSIH1P21A_DBI_CMDSIZE_map_t\r
311         {\r
312 volatile unsigned int wr_cmd_size             :\r
313             16;    //[15:0]\r
314             /*\r
315             This field configures the size of the DCS write memory commands.\r
316             The size of DSI packet payload is the actual payload size minus 1,\r
317             because the DCS command is in the DSI packet payload\r
318             */\r
319 volatile unsigned int allowed_cmd_size             :\r
320             16;    //[31:16]\r
321             /*\r
322             This field configures the maximum allowed size for a DCS write\r
323             memory command. This field is used to partition a write memory\r
324             command into one write_memory_start and a variable number of\r
325             write_memory_continue commands. It is only used if the\r
326             partitioning_en bit of the DBI_CFG register is disabled.\r
327             The size of the DSI packet payload is the actual payload size minus 1,\r
328             because the DCS command is in the DSI packet payload.\r
329             */\r
330 \r
331         }\r
332         mBits;\r
333         volatile unsigned int dValue;\r
334     }DBI_CMDSIZE;// 0x0028\r
335 \r
336     union _DSIH1P21A_PCKHDL_CFG_tag_t {\r
337         struct _DSIH1P21A_PCKHDL_CFG_map_t\r
338         {\r
339 volatile unsigned int eotp_tx_en             :\r
340             1;    //[0] When set to 1, this bit enables the EoTp transmission\r
341 volatile unsigned int eotp_rx_en             :\r
342             1;    //[1] When set to 1, this bit enables the EoTp reception.\r
343 volatile unsigned int bta_en             :\r
344             1;    //[2] When set to 1, this bit enables the Bus Turn-Around (BTA) request.\r
345 volatile unsigned int ecc_rx_en             :\r
346             1;    //[3] When set to 1, this bit enables the ECC reception, error correction, and reporting.\r
347 volatile unsigned int crc_rx_en             :\r
348             1;    //[4] When set to 1, this bit enables the CRC reception and error reporting. Dependency: DSI_DATAINTERFACE = 1 or DSI_DATAINTERFACE = 3 or DSI_GENERIC = 1. Otherwise, this bit is reserved.\r
349 volatile unsigned int reserved_0             :\r
350             27;    //[31:5]\r
351         }\r
352         mBits;\r
353         volatile unsigned int dValue;\r
354     }PCKHDL_CFG;// 0x002C\r
355 \r
356     union _DSIH1P21A_GEN_VCID_tag_t {\r
357         struct _DSIH1P21A_GEN_VCID_map_t\r
358         {\r
359 volatile unsigned int gen_vcid_rx             :\r
360             2;    //[1:0]  This field indicates the Generic interface read-back virtual channel  identification.\r
361 volatile unsigned int reserved_0                :\r
362             30; //[31:2] Reserved\r
363         }\r
364         mBits;\r
365         volatile unsigned int dValue;\r
366     }GEN_VCID;// 0x0030\r
367 \r
368     union _DSIH1P21A_MODE_CFG_tag_t {\r
369         struct _DSIH1P21A_MODE_CFG_map_t\r
370         {\r
371 volatile unsigned int cmd_video_mode             :\r
372             1;    //[0]  This bit configures the operation mode:0: Video mode ;   1: Command mode\r
373 volatile unsigned int reserved_0                :\r
374             31; //[31:1] Reserved\r
375         }\r
376         mBits;\r
377         volatile unsigned int dValue;\r
378     }MODE_CFG;// 0x0034\r
379 \r
380     union _DSIH1P21A_VID_MODE_CFG_tag_t {\r
381         struct _DSIH1P21A_VID_MODE_CFG_map_t\r
382         {\r
383 volatile unsigned int vid_mode_type             :\r
384             2;    //[1:0]\r
385             /*\r
386             This field indicates the video mode transmission type as follows:\r
387             00: Non-burst with sync pulses\r
388             01: Non-burst with sync events\r
389             10 and 11: Burst mode\r
390             */\r
391 volatile unsigned int reserved_0             :\r
392             6;    //[7:2]\r
393 volatile unsigned int lp_vsa_en             :\r
394             1;    //[8] When set to 1, this bit enables the return to low-power inside the VSA period when timing allows.\r
395 volatile unsigned int lp_vbp_en             :\r
396             1;    //[9] When set to 1, this bit enables the return to low-power inside the VBP period when timing allows.\r
397 volatile unsigned int lp_vfp_en             :\r
398             1;    //[10] When set to 1, this bit enables the return to low-power inside the VFP period when timing allows.\r
399 volatile unsigned int lp_vact_en             :\r
400             1;    //[11] When set to 1, this bit enables the return to low-power inside the VACT period when timing allows.\r
401 volatile unsigned int lp_hbp_en             :\r
402             1;    //[12] When set to 1, this bit enables the return to low-power inside the HBP period when timing allows.\r
403 volatile unsigned int lp_hfp_en             :\r
404             1;    //[13] When set to 1, this bit enables the return to low-power inside the HFP period when timing allows.\r
405 volatile unsigned int frame_bta_ack_en             :\r
406             1;    //[14] When set to 1, this bit enables the request for an acknowledgeresponse at the end of a frame\r
407 volatile unsigned int lp_cmd_en             :\r
408             1;    //[15] When set to 1, this bit enables the command transmission only in lowpower mode.\r
409 volatile unsigned int reserved_1             :\r
410             16;    //[31:16]\r
411         }\r
412         mBits;\r
413         volatile unsigned int dValue;\r
414     }VID_MODE_CFG;// 0x0038\r
415 \r
416     union _DSIH1P21A_VID_PKT_SIZE_tag_t {\r
417         struct _DSIH1P21A_VID_PKT_SIZE_map_t\r
418         {\r
419 volatile unsigned int vid_pkt_size             :\r
420             14;    //[13:0]  This field configures the number of pixels in a single video packet. For 18-bit not loosely packed data types, this number must be a multiple of 4. For YCbCr data types, it must be a multiple of 2, as described in the DSI specification.\r
421 volatile unsigned int reserved_0                :\r
422             18; //[31:14] Reserved\r
423         }\r
424         mBits;\r
425         volatile unsigned int dValue;\r
426     }VID_PKT_SIZE;// 0x003C\r
427 \r
428     union _DSIH1P21A_VID_NUM_CHUNKS_tag_t {\r
429         struct _DSIH1P21A_VID_NUM_CHUNKS_map_t\r
430         {\r
431 volatile unsigned int vid_num_chunks             :\r
432             13;    //[12:0]\r
433             /*\r
434             This register configures the number of chunks to be transmitted during\r
435             a Line period (a chunk consists of a video packet and a null packet).\r
436             If set to 0 or 1, the video line is transmitted in a single packet.\r
437             If set to 1, the packet is part of a chunk, so a null packet follows it if\r
438             vid_null_size > 0. Otherwise, multiple chunks are used to transmit each video line.\r
439             */\r
440 volatile unsigned int reserved_0                :\r
441             19; //[31:13] Reserved\r
442         }\r
443         mBits;\r
444         volatile unsigned int dValue;\r
445     }VID_NUM_CHUNKS;// 0x0040\r
446 \r
447     union _DSIH1P21A_VID_NULL_SIZE_tag_t {\r
448         struct _DSIH1P21A_VID_NULL_SIZE_map_t\r
449         {\r
450 volatile unsigned int vid_null_size             :\r
451             13;    //[12:0]\r
452             /*\r
453             This register configures the number of bytes inside a null packet.\r
454             Setting it to 0 disables the null packets.\r
455             */\r
456 volatile unsigned int reserved_0                :\r
457             19; //[31:13] Reserved\r
458         }\r
459         mBits;\r
460         volatile unsigned int dValue;\r
461     }VID_NULL_SIZE;// 0x0044\r
462 \r
463     union _DSIH1P21A_VID_HSA_TIME_tag_t {\r
464         struct _DSIH1P21A_VID_HSA_TIME_map_t\r
465         {\r
466 volatile unsigned int vid_hsa_time             :\r
467             12;    //[11:0]  This field configures the Horizontal Synchronism Active period in lane byte clock cycles\r
468 volatile unsigned int reserved_0                :\r
469             20; //[31:12] Reserved\r
470         }\r
471         mBits;\r
472         volatile unsigned int dValue;\r
473     }VID_HSA_TIME;// 0x0048\r
474 \r
475     union _DSIH1P21A_VID_HBP_TIME_tag_t {\r
476         struct _DSIH1P21A_VID_HBP_TIME_map_t\r
477         {\r
478 volatile unsigned int vid_hbp_time             :\r
479             12;    //[11:0]  This field configures the Horizontal Back Porch period in lane byte clock cycles.\r
480 volatile unsigned int reserved_0                :\r
481             20; //[31:12] Reserved\r
482         }\r
483         mBits;\r
484         volatile unsigned int dValue;\r
485     }VID_HBP_TIME;// 0x004C\r
486 \r
487     union _DSIH1P21A_VID_HLINE_TIME_tag_t {\r
488         struct _DSIH1P21A_VID_HLINE_TIME_map_t\r
489         {\r
490 volatile unsigned int vid_hline_time             :\r
491             15;    //[14:0]  This field configures the size of the total line time (HSA+HBP+HACT+HFP) counted in lane byte clock cycles.\r
492 volatile unsigned int reserved_0                :\r
493             17; //[31:15] Reserved\r
494         }\r
495         mBits;\r
496         volatile unsigned int dValue;\r
497     }VID_HLINE_TIME;// 0x0050\r
498 \r
499     union _DSIH1P21A_VID_VSA_LINES_tag_t {\r
500         struct _DSIH1P21A_VID_VSA_LINES_map_t\r
501         {\r
502 volatile unsigned int vsa_lines             :\r
503             10;    //[9:0]  This field configures the Vertical Synchronism Active period measured in number of horizontal lines\r
504 volatile unsigned int reserved_0                :\r
505             22; //[31:10] Reserved\r
506         }\r
507         mBits;\r
508         volatile unsigned int dValue;\r
509     }VID_VSA_LINES;// 0x0054\r
510 \r
511     union _DSIH1P21A_VID_VBP_LINES_tag_t {\r
512         struct _DSIH1P21A_VID_VBP_LINES_map_t\r
513         {\r
514 volatile unsigned int vbp_lines             :\r
515             10;    //[9:0]  This field configures the Vertical Back Porch period measured in number of horizontal lines.\r
516 volatile unsigned int reserved_0                :\r
517             22; //[31:10] Reserved\r
518         }\r
519         mBits;\r
520         volatile unsigned int dValue;\r
521     }VID_VBP_LINES;// 0x0058\r
522 \r
523     union _DSIH1P21A_VID_VFP_LINES_tag_t {\r
524         struct _DSIH1P21A_VID_VFP_LINES_map_t\r
525         {\r
526 volatile unsigned int vfp_lines             :\r
527             10;    //[9:0]  This field configures the Vertical Front Porch period measured in number of horizontal lines.\r
528 volatile unsigned int reserved_0                :\r
529             22; //[31:10] Reserved\r
530         }\r
531         mBits;\r
532         volatile unsigned int dValue;\r
533     }VID_VFP_LINES;// 0x005C\r
534 \r
535     union _DSIH1P21A_VID_VACTIVE_LINES_tag_t {\r
536         struct _DSIH1P21A_VID_VACTIVE_LINES_map_t\r
537         {\r
538 volatile unsigned int v_active_lines             :\r
539             14;    //[13:0]  This field configures the Vertical Active period measured in number of horizontal lines.\r
540 volatile unsigned int reserved_0                :\r
541             18; //[31:14] Reserved\r
542         }\r
543         mBits;\r
544         volatile unsigned int dValue;\r
545     }VID_VACTIVE_LINES;// 0x0060\r
546 \r
547     union _DSIH1P21A_EDPI_CMD_SIZE_tag_t {\r
548         struct _DSIH1P21A_EDPI_CMD_SIZE_map_t\r
549         {\r
550 volatile unsigned int edpi_allowed_cmd_size             :\r
551             16;    //[15:0]  This field configures the maximum allowed size for an eDPI write memory command, measured in pixels. Automatic partitioning of data obtained from eDPI is permanently enabled.\r
552 volatile unsigned int reserved_0                :\r
553             16; //[31:16] Reserved\r
554         }\r
555         mBits;\r
556         volatile unsigned int dValue;\r
557     }EDPI_CMD_SIZE;// 0x0064\r
558 \r
559     union _DSIH1P21A_CMD_MODE_CFG_tag_t {\r
560         struct _DSIH1P21A_CMD_MODE_CFG_map_t\r
561         {\r
562 volatile unsigned int tear_fx_en             :\r
563             1;    //[0] When set to 1, this bit enables the tearing effect acknowledge request.\r
564 volatile unsigned int ack_rqst_en             :\r
565             1;    //[1] When set to 1, this bit enables the acknowledge request after each packet transmission.\r
566 volatile unsigned int reserved_0             :\r
567             6;    //[7:2]\r
568 volatile unsigned int gen_sw_0p_tx             :\r
569             1;    //[8] This bit configures the Generic short write packet with zero parameter command transmission type:0: High-speed 1: Low-power\r
570 volatile unsigned int gen_sw_1p_tx             :\r
571             1;    //[9] This bit configures the Generic short write packet with one parameter command transmission type: 0: High-speed 1: Low-power\r
572 volatile unsigned int gen_sw_2p_tx             :\r
573             1;    //[10] This bit configures the Generic short write packet with two parameters command transmission type:0: High-speed 1: Low-power\r
574 volatile unsigned int gen_sr_0p_tx             :\r
575             1;    //[11] This bit configures the Generic short read packet with zero parameter command transmission type:0: High-speed 1: Low-power\r
576 volatile unsigned int gen_sr_1p_tx             :\r
577             1;    //[12] This bit configures the Generic short read packet with one parameter command transmission type:0: High-speed 1: Low-power\r
578 volatile unsigned int gen_sr_2p_tx             :\r
579             1;    //[13] This bit configures the Generic short read packet with two parameters command transmission type:0: High-speed 1: Low-power\r
580 volatile unsigned int gen_lw_tx             :\r
581             1;    //[14] This bit configures the Generic long write packet command transmission type:0: High-speed 1: Low-power\r
582 volatile unsigned int reserved_1             :\r
583             1;    //[15]\r
584 volatile unsigned int dcs_sw_0p_tx             :\r
585             1;    //[16] This bit configures the DCS short write packet with zero parameter command transmission type:0: High-speed 1: Low-power\r
586 volatile unsigned int dcs_sw_1p_tx             :\r
587             1;    //[17] This bit configures the DCS short write packet with one parameter command transmission type:0: High-speed 1: Low-power\r
588 volatile unsigned int dcs_sr_0p_tx             :\r
589             1;    //[18] This bit configures the DCS short read packet with zero parameter command transmission type:0: High-speed 1: Low-power\r
590 volatile unsigned int dcs_lw_tx             :\r
591             1;    //[19] This bit configures the DCS long write packet command transmission type:0: High-speed 1: Low-power\r
592 volatile unsigned int reserved_2             :\r
593             4;    //[23:20]\r
594 volatile unsigned int max_rd_pkt_size             :\r
595             1;    //[24] This bit configures the maximum read packet size command transmission type:0: High-speed 1: Low-power\r
596 volatile unsigned int reserved_3             :\r
597             7;    //[31:25]\r
598         }\r
599         mBits;\r
600         volatile unsigned int dValue;\r
601     }CMD_MODE_CFG;// 0x0068\r
602 \r
603     union _DSIH1P21A_GEN_HDR_tag_t {\r
604         struct _DSIH1P21A_GEN_HDR_map_t\r
605         {\r
606 volatile unsigned int gen_dt             :\r
607             6;    //[5:0]  This field configures the packet data type of the header packet.\r
608 volatile unsigned int gen_vc                :\r
609             2; //[7:6] Reserved\r
610 volatile unsigned int gen_wc_lsbyte             :\r
611             8;    //[15:8]  This field configures the least significant byte of the header packet's Word count for long packets or data 0 for short packets.\r
612 volatile unsigned int gen_wc_msbyte                :\r
613             8; //[23:16] This field configures the most significant byte of the header packet's word count for long packets or data 1 for short packets.\r
614 volatile unsigned int reserved_0                :\r
615             8; //[31:24] Reserved\r
616         }\r
617         mBits;\r
618         volatile unsigned int dValue;\r
619     }GEN_HDR;// 0x006C\r
620 \r
621     union _DSIH1P21A_GEN_PLD_DATA_tag_t {\r
622         struct _DSIH1P21A_GEN_PLD_DATA_map_t\r
623         {\r
624 volatile unsigned int gen_pld_b1             :\r
625             8;    //[7:0]  This field indicates byte 1 of the packet payload.\r
626 volatile unsigned int gen_pld_b2             :\r
627             8;    //[15:8]  This field indicates byte 2 of the packet payload.\r
628 volatile unsigned int gen_pld_b3             :\r
629             8;    //[23:16]  This field indicates byte 3 of the packet payload.\r
630 volatile unsigned int gen_pld_b4             :\r
631             8;    //[31:24]  This field indicates byte 4 of the packet payload.\r
632         }\r
633         mBits;\r
634         volatile unsigned int dValue;\r
635     }GEN_PLD_DATA;// 0x0070\r
636 \r
637     union _DSIH1P21A_CMD_PKT_STATUS_tag_t {\r
638         struct _DSIH1P21A_CMD_PKT_STATUS_map_t\r
639         {\r
640 volatile unsigned int gen_cmd_empty             :\r
641             1;    //[0]\r
642             /*\r
643             This bit indicates the empty status of the generic command FIFO.\r
644             Dependency: DSI_GENERIC = 1. Otherwise, this bit is reserved.\r
645             Value after reset: 0x1\r
646             */\r
647 volatile unsigned int gen_cmd_full             :\r
648             1;    //[1]\r
649             /*\r
650             This bit indicates the full status of the generic command FIFO.\r
651             Dependency: DSI_GENERIC = 1. Otherwise, this bit is reserved.\r
652             Value after reset: 0x0\r
653             */\r
654 volatile unsigned int gen_pld_w_empty             :\r
655             1;    //[2]\r
656             /*\r
657             This bit indicates the empty status of the generic write payload FIFO.\r
658             Dependency: DSI_GENERIC = 1. Otherwise, this bit is reserved.\r
659             Value after reset: 0x1\r
660             */\r
661 volatile unsigned int gen_pld_w_full             :\r
662             1;    //[3]\r
663             /*\r
664             This bit indicates the full status of the generic write payload FIFO.\r
665             Dependency: DSI_GENERIC = 1. Otherwise, this bit is reserved.\r
666             Value after reset: 0x0\r
667             */\r
668 volatile unsigned int gen_pld_r_empty             :\r
669             1;    //[4]\r
670             /*\r
671             This bit indicates the empty status of the generic read payload FIFO.\r
672             Dependency: DSI_GENERIC = 1. Otherwise, this bit is reserved.\r
673             Value after reset: 0x1\r
674             */\r
675 volatile unsigned int gen_pld_r_full             :\r
676             1;    //[5]\r
677             /*\r
678             This bit indicates the full status of the generic read payload FIFO.\r
679             Dependency: DSI_GENERIC = 1. Otherwise, this bit is reserved.\r
680             Value after reset: 0x0\r
681             */\r
682 volatile unsigned int gen_rd_cmd_busy             :\r
683             1;    //[6]\r
684             /*\r
685             This bit is set when a read command is issued and cleared when the\r
686             entire response is stored in the FIFO.\r
687             Dependency: DSI_GENERIC = 1. Otherwise, this bit is reserved.\r
688             Value after reset: 0x0\r
689             */\r
690 volatile unsigned int reserved_0             :\r
691             1;    //[7]\r
692             /*\r
693             */\r
694 volatile unsigned int dbi_cmd_empy             :\r
695             1;    //[8]\r
696             /*\r
697             This bit indicates the empty status of the DBI command FIFO.\r
698             Dependency: DSI_DATAINTERFACE = 1 or DSI_DATAINTERFACE = 3.\r
699             Otherwise, this bit is reserved.\r
700             Value after reset: 0x1\r
701             */\r
702 volatile unsigned int dbi_cmd_full             :\r
703             1;    //[9]\r
704             /*\r
705             This bit indicates the full status of the DBI command FIFO.\r
706             Dependency: DSI_DATAINTERFACE = 1 or DSI_DATAINTERFACE = 3.\r
707             Otherwise, this bit is reserved.\r
708             Value after reset: 0x0\r
709             */\r
710 volatile unsigned int dbi_pld_w_empty             :\r
711             1;    //[10]\r
712             /*\r
713             This bit indicates the empty status of the DBI write payload FIFO.\r
714             Dependency: DSI_DATAINTERFACE = 1 or DSI_DATAINTERFACE = 3.\r
715             Otherwise, this bit is reserved.\r
716             Value after reset: 0x1\r
717             */\r
718 volatile unsigned int dbi_pld_w_full             :\r
719             1;    //[11]\r
720             /*\r
721             This bit indicates the full status of the DBI write payload FIFO.\r
722             Dependency: DSI_DATAINTERFACE = 1 or DSI_DATAINTERFACE = 3.\r
723             Otherwise, this bit is reserved.\r
724             Value after reset: 0x0\r
725             */\r
726 volatile unsigned int dbi_pld_r_empty             :\r
727             1;    //[12]\r
728             /*\r
729             This bit indicates the empty status of the DBI read payload FIFO.\r
730             Dependency: DSI_DATAINTERFACE = 1 or DSI_DATAINTERFACE = 3.\r
731             Otherwise, this bit is reserved.\r
732             Value after reset: 0x1\r
733             */\r
734 volatile unsigned int dbi_pld_r_full             :\r
735             1;    //[13]\r
736             /*\r
737             This bit indicates the full status of the DBI read payload FIFO.\r
738             Dependency: DSI_DATAINTERFACE = 1 or DSI_DATAINTERFACE = 3.\r
739             Otherwise, this bit is reserved.\r
740             Value after reset: 0x0\r
741             */\r
742 volatile unsigned int dbi_rd_cmd_busy             :\r
743             1;    //[14]\r
744             /*\r
745             This bit is set when a read command is issued and cleared when the\r
746             entire response is stored in the FIFO.\r
747             Dependency: DSI_DATAINTERFACE = 1 or DSI_DATAINTERFACE = 3.\r
748             Otherwise, this bit is reserved.\r
749             Value after reset: 0x0\r
750             */\r
751 volatile unsigned int reserved_1             :\r
752             17;    //[31:15]\r
753         }\r
754         mBits;\r
755         volatile unsigned int dValue;\r
756     }\r
757     CMD_PKT_STATUS;// 0x0074\r
758 \r
759     union _DSIH1P21A_TO_CNT_CFG_tag_t {\r
760         struct _DSIH1P21A_TO_CNT_CFG_map_t\r
761         {\r
762 volatile unsigned int lprx_to_cnt             :\r
763             16;    //[15:0]\r
764             /*\r
765             This field configures the timeout counter that triggers a low-power\r
766             reception timeout contention detection (measured in\r
767             TO_CLK_DIVISION cycles).\r
768             */\r
769 volatile unsigned int hstx_to_cnt                :\r
770             16; //[31:16]\r
771             /*\r
772             This field configures the timeout counter that triggers a high-speed\r
773             transmission timeout contention detection (measured in\r
774             TO_CLK_DIVISION cycles).\r
775             If using the non-burst mode and there is no sufficient time to switch\r
776             from HS to LP and back in the period which is from one line data\r
777             finishing to the next line sync start, the DSI link returns the LP state\r
778             once per frame, then you should configure the TO_CLK_DIVISION\r
779             and hstx_to_cnt to be in accordance with:\r
780             hstx_to_cnt * lanebyteclkperiod * TO_CLK_DIVISION >= the time of\r
781             one FRAME data transmission * (1 + 10%)\r
782             In burst mode, RGB pixel packets are time-compressed, leaving more\r
783             time during a scan line. Therefore, if in burst mode and there is\r
784             sufficient time to switch from HS to LP and back in the period of time\r
785             from one line data finishing to the next line sync start, the DSI link can\r
786             return LP mode and back in this time interval to save power. For this,\r
787             configure the TO_CLK_DIVISION and hstx_to_cnt to be in accordance\r
788             with:\r
789             hstx_to_cnt * lanebyteclkperiod * TO_CLK_DIVISION >= the time of\r
790             one LINE data transmission * (1 + 10%)\r
791             */\r
792         }\r
793         mBits;\r
794         volatile unsigned int dValue;\r
795     }\r
796     TO_CNT_CFG;// 0x0078\r
797 \r
798     union _DSIH1P21A_HS_RD_TO_CNT_tag_t {\r
799         struct _DSIH1P21A_HS_RD_TO_CNT_map_t\r
800         {\r
801 volatile unsigned int hs_rd_to_cnt             :\r
802             16;    //[15:0]\r
803             /*\r
804             This field sets a period for which the DWC_mipi_dsi_host keeps the\r
805             link still, after sending a high-speed read operation. This period is\r
806             measured in cycles of lanebyteclk. The counting starts when the\r
807             D-PHY enters the Stop state and causes no interrupts.\r
808             */\r
809 volatile unsigned int reserved_0                :\r
810             16; //[31:16]\r
811         }\r
812         mBits;\r
813         volatile unsigned int dValue;\r
814     }\r
815     HS_RD_TO_CNT;// 0x007C\r
816 \r
817     union _DSIH1P21A_LP_RD_TO_CNT_tag_t {\r
818         struct _DSIH1P21A_LP_RD_TO_CNT_map_t\r
819         {\r
820 volatile unsigned int lp_rd_to_cnt             :\r
821             16;    //[15:0]\r
822             /*\r
823             This field sets a period for which the DWC_mipi_dsi_host keeps the\r
824             link still, after sending a low-power read operation. This period is\r
825             measured in cycles of lanebyteclk. The counting starts when the\r
826             D-PHY enters the Stop state and causes no interrupts.\r
827             */\r
828 volatile unsigned int reserved_0                :\r
829             16; //[31:16]\r
830         }\r
831         mBits;\r
832         volatile unsigned int dValue;\r
833     }\r
834     LP_RD_TO_CNT;// 0x0080\r
835 \r
836     union _DSIH1P21A_HS_WR_TO_CNT_tag_t {\r
837         struct _DSIH1P21A_HS_WR_TO_CNT_map_t\r
838         {\r
839 volatile unsigned int hs_wr_to_cnt             :\r
840             16;    //[15:0]\r
841             /*\r
842             This field sets a period for which the DWC_mipi_dsi_host keeps the\r
843             link inactive after sending a high-speed write operation. This period is\r
844             measured in cycles of lanebyteclk. The counting starts when the\r
845             D-PHY enters the Stop state and causes no interrupts.\r
846             */\r
847 volatile unsigned int reserved_0                :\r
848             8; //[23:16]\r
849 volatile unsigned int presp_to_mode             :\r
850             1;    //[24]\r
851             /*\r
852             When set to 1, this bit ensures that the peripheral response timeout\r
853             caused by hs_wr_to_cnt is used only once per eDPI frame, when both\r
854             the following conditions are met:\r
855             dpivsync_edpiwms has risen and fallen.\r
856             Packets originated from eDPI have been transmitted and its FIFO\r
857             is empty again.\r
858             In this scenario no non-eDPI requests are sent to the D-PHY, even if\r
859             there is traffic from generic or DBI ready to be sent, making it return to\r
860             stop state. When it does so, PRESP_TO counter is activated and only\r
861             when it finishes does the controller send any other traffic that is ready.\r
862             Dependency: DSI_DATAINTERFACE = 4. Otherwise, this bit is\r
863             reserved.\r
864             */\r
865 volatile unsigned int reserved_1                :\r
866             7; //[31:25]\r
867         }\r
868         mBits;\r
869         volatile unsigned int dValue;\r
870     }\r
871     HS_WR_TO_CNT;// 0x0084\r
872 \r
873     union _DSIH1P21A_LP_WR_TO_CNT_tag_t {\r
874         struct _DSIH1P21A_LP_WR_TO_CNT_map_t\r
875         {\r
876 volatile unsigned int lp_wr_to_cnt             :\r
877             16;    //[15:0]\r
878             /*\r
879             This field sets a period for which the DWC_mipi_dsi_host keeps the\r
880             link still, after sending a low-power write operation. This period is\r
881             measured in cycles of lanebyteclk. The counting starts when the\r
882             D-PHY enters the Stop state and causes no interrupts\r
883             */\r
884 volatile unsigned int reserved_0                :\r
885             16; //[31:16]\r
886         }\r
887         mBits;\r
888         volatile unsigned int dValue;\r
889     }\r
890     LP_WR_TO_CNT;// 0x0088\r
891 \r
892     union _DSIH1P21A_BTA_TO_CNT_tag_t {\r
893         struct _DSIH1P21A_BTA_TO_CNT_map_t\r
894         {\r
895 volatile unsigned int bta_to_cnt             :\r
896             16;    //[15:0]\r
897             /*\r
898             This field sets a period for which the DWC_mipi_dsi_host keeps the\r
899             link still, after completing a Bus Turn-Around. This period is measured\r
900             in cycles of lanebyteclk. The counting starts when the D-PHY enters\r
901             the Stop state and causes no interrupts.\r
902             */\r
903 volatile unsigned int reserved_0                :\r
904             16; //[31:16]\r
905         }\r
906         mBits;\r
907         volatile unsigned int dValue;\r
908     }\r
909     BTA_TO_CNT;// 0x008C\r
910 \r
911     union _DSIH1P21A_SDF_3D_tag_t {\r
912         struct _DSIH1P21A_SDF_3D_map_t\r
913         {\r
914 volatile unsigned int mode_3d             :\r
915             2;    //[1:0]\r
916             /*\r
917             This field defines the 3D mode on/off and display orientation:\r
918             00: 3D mode off (2D mode on)\r
919             01: 3D mode on, portrait orientation\r
920             10: 3D mode on, landscape orientation\r
921             11: Reserved\r
922 \r
923             */\r
924 volatile unsigned int ormat_3d             :\r
925             2;    //[3:2]\r
926             /*\r
927             This field defines the 3D image format:\r
928             00: Line (alternating lines of left and right data)\r
929             01: Frame (alternating frames of left and right data)\r
930             10: Pixel (alternating pixels of left and right data)\r
931             11: Reserved\r
932 \r
933             */\r
934 volatile unsigned int second_vsync             :\r
935             1;    //[4]\r
936             /*\r
937             This field defines whether there is a second VSYNC pulse between\r
938             Left and Right Images, when 3D Image Format is Frame-based:\r
939             0: No sync pulses between left and right data\r
940             1: Sync pulse (HSYNC, VSYNC, blanking) between left and right\r
941             data\r
942             */\r
943 volatile unsigned int right_first             :\r
944             1;    //[5]\r
945             /*\r
946             This bit defines the left or right order:\r
947             0: Left eye data is sent first, and then the right eye data is sent.\r
948             1: Right eye data is sent first, and then the left eye data is sent.\r
949             */\r
950 volatile unsigned int reserved_0             :\r
951             10;    //[15:6]\r
952 volatile unsigned int send_3d_cfg             :\r
953             1;    //[16]\r
954             /*\r
955             When set, causes the next VSS packet to include 3D control payload\r
956             in every VSS packet.\r
957             */\r
958 volatile unsigned int reserved_1                :\r
959             15; //[31:17]\r
960         }\r
961         mBits;\r
962         volatile unsigned int dValue;\r
963     }\r
964     SDF_3D;// 0x0090\r
965 \r
966     union _DSIH1P21A_LPCLK_CTRL_tag_t {\r
967         struct _DSIH1P21A_LPCLK_CTRL_map_t\r
968         {\r
969 volatile unsigned int phy_txrequestclkhs             :\r
970             1;    //[0] This bit controls the D-PHY PPI txrequestclkhs signal\r
971 volatile unsigned int auto_clklane_ctrl             :\r
972             1;    //[0] This bit enables the automatic mechanism to stop providing clock in the clock lane when time allows\r
973 volatile unsigned int reserved_0                :\r
974             30; //[31:2]\r
975         }\r
976         mBits;\r
977         volatile unsigned int dValue;\r
978     }\r
979     LPCLK_CTRL;// 0x0094\r
980 \r
981     union _DSIH1P21A_PHY_TMR_LPCLK_CFG_tag_t {\r
982         struct _DSIH1P21A_PHY_TMR_LPCLK_CFG_map_t\r
983         {\r
984 volatile unsigned int phy_clklp2hs_time             :\r
985             10;    //[9:0]\r
986             /*\r
987             This field configures the maximum time that the D-PHY clock lane\r
988             takes to go from low-power to high-speed transmission measured in\r
989             lane byte clock cycles.\r
990             */\r
991 volatile unsigned int reserved_0                :\r
992             6; //[15:10]\r
993 volatile unsigned int phy_clkhs2lp_time             :\r
994             10;    //[25:16]\r
995             /*\r
996             This field configures the maximum time that the D-PHY clock lane\r
997             takes to go from high-speed to low-power transmission measured in\r
998             lane byte clock cycles.\r
999             */\r
1000 volatile unsigned int reserved_1                :\r
1001             6; //[31:26]\r
1002         }\r
1003         mBits;\r
1004         volatile unsigned int dValue;\r
1005     }\r
1006     PHY_TMR_LPCLK_CFG;// 0x0098\r
1007 \r
1008     union _DSIH1P21A_PHY_TMR_CFG_tag_t {\r
1009         struct _DSIH1P21A_PHY_TMR_CFG_map_t\r
1010         {\r
1011 volatile unsigned int max_rd_time             :\r
1012             15;    //[14:0]\r
1013             /*\r
1014             This field configures the maximum time required to perform a read\r
1015             command in lane byte clock cycles. This register can only be modified\r
1016             when no read command is in progress.\r
1017             */\r
1018 volatile unsigned int reserved_0                :\r
1019             1; //[15]\r
1020 volatile unsigned int phy_lp2hs_time             :\r
1021             8;    //[23:16]\r
1022             /*\r
1023             This field configures the maximum time that the D-PHY data lanes\r
1024             take to go from low-power to high-speed transmission measured in\r
1025             lane byte clock cycles.\r
1026             */\r
1027 volatile unsigned int phy_hs2lp_time                :\r
1028             8; //[31:24]\r
1029             /*\r
1030             This field configures the maximum time that the D-PHY data lanes\r
1031             take to go from high-speed to low-power transmission measured in\r
1032             lane byte clock cycles.\r
1033             */\r
1034         }\r
1035         mBits;\r
1036         volatile unsigned int dValue;\r
1037     }    PHY_TMR_CFG;// 0x009C\r
1038 \r
1039     union _DSIH1P21A_PHY_RSTZ_tag_t {\r
1040         struct _DSIH1P21A_PHY_RSTZ_map_t\r
1041         {\r
1042 volatile unsigned int phy_shutdownz             :\r
1043             1;    //[0] When set to 0, this bit places the D-PHY macro in power-down state\r
1044 volatile unsigned int phy_rstz                :\r
1045             1; //[1] When set to 0, this bit places the digital section of the D-PHY in the reset state.\r
1046 volatile unsigned int phy_enableclk             :\r
1047             1;    //[2] When set to1, this bit enables the D-PHY Clock Lane module.\r
1048 volatile unsigned int phy_forcepll                :\r
1049             1; //[3]\r
1050             /*\r
1051             When the D-PHY is in ULPS, this bit enables the D-PHY PLL.\r
1052             Dependency: DSI_HOST_FPGA = 0. Otherwise, this bit is reserved\r
1053             */\r
1054 volatile unsigned int reserved_0                :\r
1055             28; //[31:4]\r
1056         }\r
1057         mBits;\r
1058         volatile unsigned int dValue;\r
1059 \r
1060     }    PHY_RSTZ;// 0x00A0\r
1061 \r
1062     union _DSIH1P21A_PHY_IF_CFG_tag_t {\r
1063         struct _DSIH1P21A_PHY_IF_CFG_map_t\r
1064         {\r
1065 volatile unsigned int n_lanes             :\r
1066             2;    //[1:0]\r
1067             /*\r
1068             This field configures the number of active data lanes:\r
1069             00: One data lane (lane 0)\r
1070             01: Two data lanes (lanes 0 and 1)\r
1071             10: Three data lanes (lanes 0, 1, and 2)\r
1072             11: Four data lanes (lanes 0, 1, 2, and 3)\r
1073             */\r
1074 volatile unsigned int reserved_0                :\r
1075             6; //[7:2]\r
1076 volatile unsigned int phy_stop_wait_time                :\r
1077             8; //[15:8] This field configures the minimum wait period to request a high-speed transmission after the Stop state.\r
1078 volatile unsigned int reserved_1                :\r
1079             16; //[31:16]\r
1080         }\r
1081         mBits;\r
1082         volatile unsigned int dValue;\r
1083     }PHY_IF_CFG;// 0x00A4\r
1084 \r
1085     union _DSIH1P21A_PHY_ULPS_CTRL_tag_t {\r
1086         struct _DSIH1P21A_PHY_ULPS_CTRL_map_t\r
1087         {\r
1088 volatile unsigned int phy_txrequlpsclk             :\r
1089             1;    //[0] ULPS mode Request on clock lane.\r
1090 volatile unsigned int phy_txexitulpsclk                :\r
1091             1; //[1] ULPS mode Exit on clock lane.\r
1092 volatile unsigned int phy_txrequlpslan             :\r
1093             1;    //[2] ULPS mode Request on all active data lanes.\r
1094 volatile unsigned int phy_txexitulpslan                :\r
1095             1; //[3] ULPS mode Exit on all active data lanes.\r
1096 volatile unsigned int reserved_0                :\r
1097             28; //[31:4]\r
1098         }\r
1099         mBits;\r
1100         volatile unsigned int dValue;\r
1101     }\r
1102     PHY_ULPS_CTRL;// 0x00A8\r
1103 \r
1104     union _DSIH1P21A_PHY_TX_TRIGGERS_tag_t {\r
1105         struct _DSIH1P21A_PHY_TX_TRIGGERS_map_t\r
1106         {\r
1107 volatile unsigned int phy_tx_triggers             :\r
1108             4;    //[3:0] This field controls the trigger transmissions\r
1109 volatile unsigned int reserved_0                :\r
1110             28; //[31:4]\r
1111         }\r
1112         mBits;\r
1113         volatile unsigned int dValue;\r
1114     }\r
1115     PHY_TX_TRIGGERS;// 0x00AC\r
1116 \r
1117     union _DSIH1P21A_PHY_STATUS_tag_t {\r
1118         struct _DSIH1P21A_PHY_STATUS_map_t\r
1119         {\r
1120 volatile unsigned int phy_lock             :\r
1121             1;    //[0] This bit indicates the status of phylock D-PHY signal.\r
1122 volatile unsigned int phy_direction                :\r
1123             1; //[1] This bit indicates the status of phydirection D-PHY signal.\r
1124 volatile unsigned int phy_stopstateclklane             :\r
1125             1;    //[2] This bit indicates the status of phystopstateclklane D-PHY signal.\r
1126 volatile unsigned int phy_ulpsactivenotclk                :\r
1127             1; //[3] This bit indicates the status of phyulpsactivenotclk D-PHY signal.\r
1128 volatile unsigned int phy_stopstate0lane             :\r
1129             1;    //[4] This bit indicates the status of phystopstate0lane D-PHY signal.\r
1130 volatile unsigned int phy_ulpsactivenot0lane                :\r
1131             1; //[5] This bit indicates the status of ulpsactivenot0lane D-PHY signal.\r
1132 volatile unsigned int phy_rxulpsesc0lane             :\r
1133             1;    //[6] This bit indicates the status of rxulpsesc0lane D-PHY signal.\r
1134 volatile unsigned int phy_stopstate1lane                :\r
1135             1; //[7]\r
1136             /*\r
1137             This bit indicates the status of phystopstate1lane D-PHY signal.\r
1138             Dependency: DSI_HOST_NUMBER_OF_LANES > 1\r
1139             If DSI_HOST_NUMBER_OF_LANES <= 1, this bit is reserved.\r
1140             */\r
1141 volatile unsigned int phy_ulpsactivenot1lane             :\r
1142             1;    //[8]\r
1143             /*\r
1144             This bit indicates the status of ulpsactivenot1lane D-PHY signal.\r
1145             Dependency: DSI_HOST_NUMBER_OF_LANES > 1\r
1146             If DSI_HOST_NUMBER_OF_LANES <= 1, this bit is reserved.\r
1147             */\r
1148 volatile unsigned int phy_stopstate2lane                :\r
1149             1; //[9]\r
1150             /*\r
1151             This bit indicates the status of phystopstate2lane D-PHY signal.\r
1152             Dependency: DSI_HOST_NUMBER_OF_LANES > 2\r
1153             If DSI_HOST_NUMBER_OF_LANES <= 2, this bit is reserved.\r
1154             */\r
1155 volatile unsigned int phy_ulpsactivenot2lane             :\r
1156             1;    //[10]\r
1157             /*\r
1158             This bit indicates the status of ulpsactivenot2lane D-PHY signal.\r
1159             Dependency: DSI_HOST_NUMBER_OF_LANES > 2\r
1160             If DSI_HOST_NUMBER_OF_LANES <= 2, this bit is reserved.\r
1161             */\r
1162 volatile unsigned int phy_stopstate3lane                :\r
1163             1; //[11]\r
1164             /*\r
1165             This bit indicates the status of phystopstate3lane D-PHY signal.\r
1166             Dependency: DSI_HOST_NUMBER_OF_LANES > 3\r
1167             If DSI_HOST_NUMBER_OF_LANES <= 3, this bit is reserved\r
1168             */\r
1169 volatile unsigned int phy_ulpsactivenot3lane             :\r
1170             1;    //[12]\r
1171             /*\r
1172             This bit indicates the status of ulpsactivenot3lane D-PHY signal.\r
1173             Dependency: DSI_HOST_NUMBER_OF_LANES > 3\r
1174             If DSI_HOST_NUMBER_OF_LANES <= 3, this bit is reserved\r
1175             */\r
1176 volatile unsigned int reserved_0                :\r
1177             19; //[31:13]\r
1178         }\r
1179         mBits;\r
1180         volatile unsigned int dValue;\r
1181     } PHY_STATUS;// 0x00B0\r
1182 \r
1183     union _DSIH1P21A_PHY_TST_CTRL0_tag_t {\r
1184         struct _DSIH1P21A_PHY_TST_CTRL0_map_t\r
1185         {\r
1186 volatile unsigned int phy_testclr             :\r
1187             1;    //[0] PHY test interface clear (active high).\r
1188 volatile unsigned int phy_testclk             :\r
1189             1;    //[1] This bit is used to clock the TESTDIN bus into the D-PHY.\r
1190 volatile unsigned int reserved_0                :\r
1191             30; //[31:2]\r
1192         }\r
1193         mBits;\r
1194         volatile unsigned int dValue;\r
1195     }\r
1196     PHY_TST_CTRL0;// 0x00B4\r
1197 \r
1198     union _DSIH1P21A_PHY_TST_CTRL1_tag_t {\r
1199         struct _DSIH1P21A_PHY_TST_CTRL1_map_t\r
1200         {\r
1201 volatile unsigned int phy_testdin             :\r
1202             8;    //[7:0] PHY test interface input 8-bit data bus for internal register programming and test functionalities access.\r
1203 volatile unsigned int pht_testdout             :\r
1204             8;    //[15:8] PHY output 8-bit data bus for read-back and internal probing functionalities.\r
1205 volatile unsigned int phy_testen                :\r
1206             1; //[16]\r
1207             /*\r
1208             PHY test interface operation selector:\r
1209             1: The address write operation is set on the falling edge of the testclk signal.\r
1210             0: The data write operation is set on the rising edge of the testclk signal.\r
1211             */\r
1212 volatile unsigned int reserved_0                :\r
1213             15; //[31:17]\r
1214         }\r
1215         mBits;\r
1216         volatile unsigned int dValue;\r
1217     }\r
1218     PHY_TST_CTRL1;// 0x00B8\r
1219 \r
1220     union _DSIH1P21A_INT_ST0_tag_t {\r
1221         struct _DSIH1P21A_INT_ST0_map_t\r
1222         {\r
1223 volatile unsigned int ack_with_err_0             :\r
1224             1;    //[0] This bit retrieves the SoT error from the Acknowledge error report.\r
1225 volatile unsigned int ack_with_err_1                :\r
1226             1; //[1] This bit retrieves the SoT Sync error from the Acknowledge error report.\r
1227 volatile unsigned int ack_with_err_2             :\r
1228             1;    //[2] This bit retrieves the EoT Sync error from the Acknowledge error report.\r
1229 volatile unsigned int ack_with_err_3                :\r
1230             1; //[3] This bit retrieves the Escape Mode Entry Command error from the Acknowledge error report.\r
1231 volatile unsigned int ack_with_err_4             :\r
1232             1;    //[4] This bit retrieves the LP Transmit Sync error from the Acknowledge error report.\r
1233 volatile unsigned int ack_with_err_5                :\r
1234             1; //[5] This bit retrieves the Peripheral Timeout error from the Acknowledge Error report.\r
1235 volatile unsigned int ack_with_err_6             :\r
1236             1;    //[6] This bit retrieves the False Control error from the Acknowledge error report.\r
1237 volatile unsigned int ack_with_err_7                :\r
1238             1; //[7] This bit retrieves the reserved (specific to device) from the Acknowledge error report.\r
1239 volatile unsigned int ack_with_err_8             :\r
1240             1;    //[8] This bit retrieves the ECC error, single-bit (detected and corrected) from the Acknowledge error report.\r
1241 volatile unsigned int ack_with_err_9                :\r
1242             1; //[9] This bit retrieves the ECC error, multi-bit (detected, not corrected) from the Acknowledge error report.\r
1243 volatile unsigned int ack_with_err_10             :\r
1244             1;    //[10]This bit retrieves the checksum error (long packet only) from the Acknowledge error report.\r
1245 volatile unsigned int ack_with_err_11                :\r
1246             1; //[11] This bit retrieves the not recognized DSI data type from the Acknowledge error report.\r
1247 volatile unsigned int ack_with_err_12             :\r
1248             1;    //[12] This bit retrieves the DSI VC ID Invalid from the Acknowledge error report.\r
1249 volatile unsigned int ack_with_err_13                :\r
1250             1; //[13] This bit retrieves the invalid transmission length from the Acknowledge error report.\r
1251 volatile unsigned int ack_with_err_14             :\r
1252             1;    //[14] This bit retrieves the reserved (specific to device) from the Acknowledge error report\r
1253 volatile unsigned int ack_with_err_15                :\r
1254             1; //[15] This bit retrieves the DSI protocol violation from the Acknowledge error report.\r
1255 volatile unsigned int dphy_errors_0             :\r
1256             1;    //[16] This bit indicates ErrEsc escape entry error from Lane 0.\r
1257 volatile unsigned int dphy_errors_1                :\r
1258             1; //[17] This bit indicates ErrSyncEsc low-power data transmission synchronization error from Lane 0.\r
1259 volatile unsigned int dphy_errors_2             :\r
1260             1;    //[18] This bit indicates the ErrControl error from Lane 0.\r
1261 volatile unsigned int dphy_errors_3                :\r
1262             1; //[19] This bit indicates the LP0 contention error ErrContentionLP0 from Lane 0.\r
1263 volatile unsigned int dphy_errors_4             :\r
1264             1;    //[20] This bit indicates the LP1 contention error ErrContentionLP1 from Lane 0.\r
1265 volatile unsigned int reserved_0                :\r
1266             11; //[31:21]\r
1267         }\r
1268         mBits;\r
1269         volatile unsigned int dValue;\r
1270     }\r
1271     INT_ST0;// 0x00BC\r
1272 \r
1273     union _DSIH1P21A_INT_ST1_tag_t {\r
1274         struct _DSIH1P21A_INT_ST1_map_t\r
1275         {\r
1276 volatile unsigned int to_hs_tx             :\r
1277             1;    //[0]\r
1278             /*\r
1279             This bit indicates that the high-speed transmission timeout counter\r
1280             reached the end and contention is detected.\r
1281             */\r
1282 volatile unsigned int to_lp_rx                :\r
1283             1; //[1]\r
1284             /*\r
1285             This bit indicates that the low-power reception timeout counter reached\r
1286             the end and contention is detected.\r
1287             */\r
1288 volatile unsigned int ecc_single_err             :\r
1289             1;    //[2]\r
1290             /*\r
1291             This bit indicates that the ECC single error is detected and corrected in a\r
1292             received packet.\r
1293             */\r
1294 volatile unsigned int ecc_multi_err                :\r
1295             1; //[3]\r
1296             /*\r
1297             This bit indicates that the ECC multiple error is detected in a received\r
1298             packet.\r
1299             */\r
1300 volatile unsigned int crc_err             :\r
1301             1;    //[4]\r
1302             /*\r
1303             This bit indicates that the CRC error is detected in the received packet\r
1304             payload.\r
1305             Dependency: DSI_DATAINTERFACE = 1 or DSI_DATAINTERFACE = 3 or\r
1306             DSI_GENERIC = 1. Otherwise, this bit is reserved.\r
1307             */\r
1308 volatile unsigned int pkt_size_err                :\r
1309             1; //[5]\r
1310             /*\r
1311             This bit indicates that the packet size error is detected during the packet\r
1312             reception.\r
1313             */\r
1314 volatile unsigned int eopt_err             :\r
1315             1;    //[6]\r
1316             /*\r
1317             This bit indicates that the EoTp packet is not received at the end of the\r
1318             incoming peripheral transmission\r
1319             */\r
1320 volatile unsigned int dpi_pld_wr_err                :\r
1321             1; //[7]\r
1322             /*\r
1323             This bit indicates that during a DPI pixel line storage, the payload FIFO\r
1324             becomes full and the data stored is corrupted.\r
1325             Dependency: DSI_DATAINTERFACE = 2 or DSI_DATAINTERFACE = 3 or\r
1326             DSI_DATAINTERFACE = 4. Otherwise, this bit is reserved.\r
1327             */\r
1328 volatile unsigned int gen_cmd_wr_err             :\r
1329             1;    //[8]\r
1330             /*\r
1331             This bit indicates that the system tried to write a command through the\r
1332             Generic interface and the FIFO is full. Therefore, the command is not\r
1333             written.\r
1334             Dependency: DSI_GENERIC = 1. Otherwise, this bit is reserved\r
1335             */\r
1336 volatile unsigned int gen_pld_wr_err                :\r
1337             1; //[9]\r
1338             /*\r
1339             This bit indicates that the system tried to write a payload data through the\r
1340             Generic interface and the FIFO is full. Therefore, the payload is not\r
1341             written.\r
1342             Dependency: DSI_GENERIC = 1. Otherwise, this bit is reserved\r
1343             */\r
1344 volatile unsigned int gen_pld_send_err             :\r
1345             1; //[10]\r
1346             /*\r
1347             This bit indicates that during a Generic interface packet build, the payload\r
1348             FIFO becomes empty and corrupt data is sent.\r
1349             Dependency: DSI_GENERIC = 1. Otherwise, this bit is reserved\r
1350             */\r
1351 volatile unsigned int gen_pld_rd_err                :\r
1352             1; //[11]\r
1353             /*\r
1354             This bit indicates that during a DCS read data, the payload FIFO becomes\r
1355             empty and the data sent to the interface is corrupted.\r
1356             Dependency: DSI_GENERIC = 1. Otherwise, this bit is reserved.\r
1357             */\r
1358 volatile unsigned int gen_pld_recev_err             :\r
1359             1;    //[12]\r
1360             /*\r
1361             This bit indicates that during a generic interface packet read back, the\r
1362             payload FIFO becomes full and the received data is corrupted.\r
1363             Dependency: DSI_GENERIC = 1\r
1364             If DSI_GENERIC = 0, this bit is reserved.\r
1365             */\r
1366 volatile unsigned int dbi_cmd_wr_err                :\r
1367             1; //[13]\r
1368             /*\r
1369             This bit indicates that the system tried to write a command through the\r
1370             DBI but the command FIFO is full. Therefore, the command is not written.\r
1371             Dependency: DSI_DATAINTERFACE = 1 or DSI_DATAINTERFACE = 3.\r
1372             Otherwise, this bit is reserved.\r
1373             */\r
1374 volatile unsigned int dbi_pld_wr_err             :\r
1375             1;    //[14]\r
1376             /*\r
1377             This bit indicates that the system tried to write the payload data through\r
1378             the DBI interface and the FIFO is full. Therefore, the command is not\r
1379             written.\r
1380             Dependency: DSI_DATAINTERFACE = 1 or DSI_DATAINTERFACE = 3.\r
1381             Otherwise, this bit is reserved.\r
1382             */\r
1383 volatile unsigned int dbi_pld_rd_err                :\r
1384             1; //[15]\r
1385             /*\r
1386             This bit indicates that during a DCS read data, the payload FIFO goes\r
1387             empty and the data sent to the interface is corrupted.\r
1388             Dependency: DSI_DATAINTERFACE = 1 or DSI_DATAINTERFACE = 3.\r
1389             Otherwise, this bit is reserved.\r
1390             */\r
1391 volatile unsigned int dbi_pld_recv_err             :\r
1392             1;    //[16]\r
1393             /*\r
1394             This bit indicates that during a DBI read back packet, the payload FIFO\r
1395             becomes full and the received data is corrupted.\r
1396             Dependency: DSI_DATAINTERFACE = 1 or DSI_DATAINTERFACE = 3.\r
1397             Otherwise, this bit is reserved.\r
1398             */\r
1399 \r
1400 volatile unsigned int dbi_ilegal_comm_err                :\r
1401             1; //[17]\r
1402             /*\r
1403             This bit indicates that an attempt to write an illegal command on the DBI\r
1404             interface is made and the core is blocked by transmission.\r
1405             Dependency: DSI_DATAINTERFACE = 1 or DSI_DATAINTERFACE = 3.\r
1406             Otherwise, this bit is reserved.\r
1407             */\r
1408 volatile unsigned int reserved_0                :\r
1409             14; //[31:18]\r
1410         }\r
1411         mBits;\r
1412         volatile unsigned int dValue;\r
1413     }\r
1414     INT_ST1;// 0x00C0\r
1415 \r
1416 \r
1417     union _DSIH1P21A_INT_MSK0_tag_t {\r
1418         struct _DSIH1P21A_INT_MSK0_map_t\r
1419         {\r
1420 volatile unsigned int ack_with_err_0             :\r
1421             1;    //[0] This bit retrieves the SoT error from the Acknowledge error report.\r
1422 volatile unsigned int ack_with_err_1                :\r
1423             1; //[1] This bit retrieves the SoT Sync error from the Acknowledge error report.\r
1424 volatile unsigned int ack_with_err_2             :\r
1425             1;    //[2] This bit retrieves the EoT Sync error from the Acknowledge error report.\r
1426 volatile unsigned int ack_with_err_3                :\r
1427             1; //[3] This bit retrieves the Escape Mode Entry Command error from the Acknowledge error report.\r
1428 volatile unsigned int ack_with_err_4             :\r
1429             1;    //[4] This bit retrieves the LP Transmit Sync error from the Acknowledge error report.\r
1430 volatile unsigned int ack_with_err_5                :\r
1431             1; //[5] This bit retrieves the Peripheral Timeout error from the Acknowledge Error report.\r
1432 volatile unsigned int ack_with_err_6             :\r
1433             1;    //[6] This bit retrieves the False Control error from the Acknowledge error report.\r
1434 volatile unsigned int ack_with_err_7                :\r
1435             1; //[7] This bit retrieves the reserved (specific to device) from the Acknowledge error report.\r
1436 volatile unsigned int ack_with_err_8             :\r
1437             1;    //[8] This bit retrieves the ECC error, single-bit (detected and corrected) from the Acknowledge error report.\r
1438 volatile unsigned int ack_with_err_9                :\r
1439             1; //[9] This bit retrieves the ECC error, multi-bit (detected, not corrected) from the Acknowledge error report.\r
1440 volatile unsigned int ack_with_err_10             :\r
1441             1;    //[10]This bit retrieves the checksum error (long packet only) from the Acknowledge error report.\r
1442 volatile unsigned int ack_with_err_11                :\r
1443             1; //[11] This bit retrieves the not recognized DSI data type from the Acknowledge error report.\r
1444 volatile unsigned int ack_with_err_12             :\r
1445             1;    //[12] This bit retrieves the DSI VC ID Invalid from the Acknowledge error report.\r
1446 volatile unsigned int ack_with_err_13                :\r
1447             1; //[13] This bit retrieves the invalid transmission length from the Acknowledge error report.\r
1448 volatile unsigned int ack_with_err_14             :\r
1449             1;    //[14] This bit retrieves the reserved (specific to device) from the Acknowledge error report\r
1450 volatile unsigned int ack_with_err_15                :\r
1451             1; //[15] This bit retrieves the DSI protocol violation from the Acknowledge error report.\r
1452 volatile unsigned int dphy_errors_0             :\r
1453             1;    //[16] This bit indicates ErrEsc escape entry error from Lane 0.\r
1454 volatile unsigned int dphy_errors_1                :\r
1455             1; //[17] This bit indicates ErrSyncEsc low-power data transmission synchronization error from Lane 0.\r
1456 volatile unsigned int dphy_errors_2             :\r
1457             1;    //[18] This bit indicates the ErrControl error from Lane 0.\r
1458 volatile unsigned int dphy_errors_3                :\r
1459             1; //[19] This bit indicates the LP0 contention error ErrContentionLP0 from Lane 0.\r
1460 volatile unsigned int dphy_errors_4             :\r
1461             1;    //[20] This bit indicates the LP1 contention error ErrContentionLP1 from Lane 0.\r
1462 volatile unsigned int reserved_0                :\r
1463             11; //[31:21]\r
1464         }\r
1465         mBits;\r
1466         volatile unsigned int dValue;\r
1467     }\r
1468     INT_MSK0;// 0x00C4\r
1469 \r
1470 \r
1471     union _DSIH1P21A_INT_MSK1_tag_t {\r
1472         struct _DSIH1P21A_INT_MSK1_map_t\r
1473         {\r
1474 volatile unsigned int to_hs_tx             :\r
1475             1;    //[0]\r
1476             /*\r
1477             This bit indicates that the high-speed transmission timeout counter\r
1478             reached the end and contention is detected.\r
1479             */\r
1480 volatile unsigned int to_lp_rx                :\r
1481             1; //[1]\r
1482             /*\r
1483             This bit indicates that the low-power reception timeout counter reached\r
1484             the end and contention is detected.\r
1485             */\r
1486 volatile unsigned int ecc_single_err             :\r
1487             1;    //[2]\r
1488             /*\r
1489             This bit indicates that the ECC single error is detected and corrected in a\r
1490             received packet.\r
1491             */\r
1492 volatile unsigned int ecc_multi_err                :\r
1493             1; //[3]\r
1494             /*\r
1495             This bit indicates that the ECC multiple error is detected in a received\r
1496             packet.\r
1497             */\r
1498 volatile unsigned int crc_err             :\r
1499             1;    //[4]\r
1500             /*\r
1501             This bit indicates that the CRC error is detected in the received packet\r
1502             payload.\r
1503             Dependency: DSI_DATAINTERFACE = 1 or DSI_DATAINTERFACE = 3 or\r
1504             DSI_GENERIC = 1. Otherwise, this bit is reserved.\r
1505             */\r
1506 volatile unsigned int pkt_size_err                :\r
1507             1; //[5]\r
1508             /*\r
1509             This bit indicates that the packet size error is detected during the packet\r
1510             reception.\r
1511             */\r
1512 volatile unsigned int eopt_err             :\r
1513             1;    //[6]\r
1514             /*\r
1515             This bit indicates that the EoTp packet is not received at the end of the\r
1516             incoming peripheral transmission\r
1517             */\r
1518 volatile unsigned int dpi_pld_wr_err                :\r
1519             1; //[7]\r
1520             /*\r
1521             This bit indicates that during a DPI pixel line storage, the payload FIFO\r
1522             becomes full and the data stored is corrupted.\r
1523             Dependency: DSI_DATAINTERFACE = 2 or DSI_DATAINTERFACE = 3 or\r
1524             DSI_DATAINTERFACE = 4. Otherwise, this bit is reserved.\r
1525             */\r
1526 volatile unsigned int gen_cmd_wr_err             :\r
1527             1;    //[8]\r
1528             /*\r
1529             This bit indicates that the system tried to write a command through the\r
1530             Generic interface and the FIFO is full. Therefore, the command is not\r
1531             written.\r
1532             Dependency: DSI_GENERIC = 1. Otherwise, this bit is reserved\r
1533             */\r
1534 volatile unsigned int gen_pld_wr_err                :\r
1535             1; //[9]\r
1536             /*\r
1537             This bit indicates that the system tried to write a payload data through the\r
1538             Generic interface and the FIFO is full. Therefore, the payload is not\r
1539             written.\r
1540             Dependency: DSI_GENERIC = 1. Otherwise, this bit is reserved\r
1541             */\r
1542 volatile unsigned int gen_pld_send_err             :\r
1543             1; //[10]\r
1544             /*\r
1545             This bit indicates that during a Generic interface packet build, the payload\r
1546             FIFO becomes empty and corrupt data is sent.\r
1547             Dependency: DSI_GENERIC = 1. Otherwise, this bit is reserved\r
1548             */\r
1549 volatile unsigned int gen_pld_rd_err                :\r
1550             1; //[11]\r
1551             /*\r
1552             This bit indicates that during a DCS read data, the payload FIFO becomes\r
1553             empty and the data sent to the interface is corrupted.\r
1554             Dependency: DSI_GENERIC = 1. Otherwise, this bit is reserved.\r
1555             */\r
1556 volatile unsigned int gen_pld_recev_err             :\r
1557             1;    //[12]\r
1558             /*\r
1559             This bit indicates that during a generic interface packet read back, the\r
1560             payload FIFO becomes full and the received data is corrupted.\r
1561             Dependency: DSI_GENERIC = 1\r
1562             If DSI_GENERIC = 0, this bit is reserved.\r
1563             */\r
1564 volatile unsigned int dbi_cmd_wr_err                :\r
1565             1; //[13]\r
1566             /*\r
1567             This bit indicates that the system tried to write a command through the\r
1568             DBI but the command FIFO is full. Therefore, the command is not written.\r
1569             Dependency: DSI_DATAINTERFACE = 1 or DSI_DATAINTERFACE = 3.\r
1570             Otherwise, this bit is reserved.\r
1571             */\r
1572 volatile unsigned int dbi_pld_wr_err             :\r
1573             1;    //[14]\r
1574             /*\r
1575             This bit indicates that the system tried to write the payload data through\r
1576             the DBI interface and the FIFO is full. Therefore, the command is not\r
1577             written.\r
1578             Dependency: DSI_DATAINTERFACE = 1 or DSI_DATAINTERFACE = 3.\r
1579             Otherwise, this bit is reserved.\r
1580             */\r
1581 volatile unsigned int dbi_pld_rd_err                :\r
1582             1; //[15]\r
1583             /*\r
1584             This bit indicates that during a DCS read data, the payload FIFO goes\r
1585             empty and the data sent to the interface is corrupted.\r
1586             Dependency: DSI_DATAINTERFACE = 1 or DSI_DATAINTERFACE = 3.\r
1587             Otherwise, this bit is reserved.\r
1588             */\r
1589 volatile unsigned int dbi_pld_recv_err             :\r
1590             1;    //[16]\r
1591             /*\r
1592             This bit indicates that during a DBI read back packet, the payload FIFO\r
1593             becomes full and the received data is corrupted.\r
1594             Dependency: DSI_DATAINTERFACE = 1 or DSI_DATAINTERFACE = 3.\r
1595             Otherwise, this bit is reserved.\r
1596             */\r
1597 \r
1598 volatile unsigned int dbi_ilegal_comm_err                :\r
1599             1; //[17]\r
1600             /*\r
1601             This bit indicates that an attempt to write an illegal command on the DBI\r
1602             interface is made and the core is blocked by transmission.\r
1603             Dependency: DSI_DATAINTERFACE = 1 or DSI_DATAINTERFACE = 3.\r
1604             Otherwise, this bit is reserved.\r
1605             */\r
1606 volatile unsigned int reserved_0                :\r
1607             14; //[31:18]\r
1608         }\r
1609         mBits;\r
1610         volatile unsigned int dValue;\r
1611     }\r
1612     INT_MSK1;// 0x00C8\r
1613 }DSIH1P21A_REG_T;\r
1614 uint32_t mipi_dsih_hal_get_version(dsih_ctrl_t * instance);\r
1615 \r
1616 void mipi_dsih_hal_power(dsih_ctrl_t * instance, int on);\r
1617 \r
1618 int mipi_dsih_hal_get_power(dsih_ctrl_t * instance);\r
1619 \r
1620 void mipi_dsih_hal_tx_escape_division(dsih_ctrl_t * instance, uint8_t tx_escape_division);\r
1621 \r
1622 void mipi_dsih_hal_dpi_video_vc(dsih_ctrl_t * instance, uint8_t vc);\r
1623 \r
1624 uint8_t mipi_dsih_hal_dpi_get_video_vc(dsih_ctrl_t * instance);\r
1625 \r
1626 dsih_error_t mipi_dsih_hal_dpi_color_coding(dsih_ctrl_t * instance, dsih_color_coding_t color_coding);\r
1627 dsih_color_coding_t mipi_dsih_hal_dpi_get_color_coding(dsih_ctrl_t * instance);\r
1628 uint8_t mipi_dsih_hal_dpi_get_color_depth(dsih_ctrl_t * instance);\r
1629 uint8_t mipi_dsih_hal_dpi_get_color_config(dsih_ctrl_t * instance);\r
1630 void mipi_dsih_hal_dpi_18_loosely_packet_en(dsih_ctrl_t * instance, int enable);\r
1631 void mipi_dsih_hal_dpi_color_mode_pol(dsih_ctrl_t * instance, int active_low);\r
1632 void mipi_dsih_hal_dpi_shut_down_pol(dsih_ctrl_t * instance, int active_low);\r
1633 void mipi_dsih_hal_dpi_hsync_pol(dsih_ctrl_t * instance, int active_low);\r
1634 void mipi_dsih_hal_dpi_vsync_pol(dsih_ctrl_t * instance, int active_low);\r
1635 void mipi_dsih_hal_dpi_dataen_pol(dsih_ctrl_t * instance, int active_low);\r
1636 void mipi_dsih_hal_dpi_frame_ack_en(dsih_ctrl_t * instance, int enable);\r
1637 void mipi_dsih_hal_dpi_null_packet_en(dsih_ctrl_t * instance, int enable);\r
1638 void mipi_dsih_hal_dpi_multi_packet_en(dsih_ctrl_t * instance, int enable);\r
1639 void mipi_dsih_hal_dpi_lp_during_hfp(dsih_ctrl_t * instance, int enable);\r
1640 void mipi_dsih_hal_dpi_lp_during_hbp(dsih_ctrl_t * instance, int enable);\r
1641 void mipi_dsih_hal_dpi_lp_during_vactive(dsih_ctrl_t * instance, int enable);\r
1642 void mipi_dsih_hal_dpi_lp_during_vfp(dsih_ctrl_t * instance, int enable);\r
1643 void mipi_dsih_hal_dpi_lp_during_vbp(dsih_ctrl_t * instance, int enable);\r
1644 void mipi_dsih_hal_dpi_lp_during_vsync(dsih_ctrl_t * instance, int enable);\r
1645 \r
1646 dsih_error_t mipi_dsih_hal_dpi_video_mode_type(dsih_ctrl_t * instance, dsih_video_mode_t type);\r
1647 void mipi_dsih_hal_dpi_video_mode_en(dsih_ctrl_t * instance, int enable);\r
1648 int mipi_dsih_hal_dpi_is_video_mode(dsih_ctrl_t * instance);\r
1649 dsih_error_t mipi_dsih_hal_dpi_null_packet_size(dsih_ctrl_t * instance, uint16_t size);\r
1650 dsih_error_t mipi_dsih_hal_dpi_chunks_no(dsih_ctrl_t * instance, uint16_t no);\r
1651 dsih_error_t mipi_dsih_hal_dpi_video_packet_size(dsih_ctrl_t * instance, uint16_t size);\r
1652 \r
1653 void mipi_dsih_hal_tear_effect_ack_en(dsih_ctrl_t * instance, int enable);\r
1654 \r
1655 void mipi_dsih_hal_cmd_ack_en(dsih_ctrl_t * instance, int enable);\r
1656 dsih_error_t mipi_dsih_hal_dcs_wr_tx_type(dsih_ctrl_t * instance, unsigned no_of_param, int lp);\r
1657 dsih_error_t mipi_dsih_hal_dcs_rd_tx_type(dsih_ctrl_t * instance, unsigned no_of_param, int lp);\r
1658 /*Jessica add to support max rd packet size command*/\r
1659 dsih_error_t mipi_dsih_hal_max_rd_packet_size_type(dsih_ctrl_t * instance, int lp);\r
1660 dsih_error_t mipi_dsih_hal_gen_wr_tx_type(dsih_ctrl_t * instance, unsigned no_of_param, int lp);\r
1661 dsih_error_t mipi_dsih_hal_gen_rd_tx_type(dsih_ctrl_t * instance, unsigned no_of_param, int lp);\r
1662 void mipi_dsih_hal_max_rd_size_type(dsih_ctrl_t * instance, int lp);\r
1663 void mipi_dsih_hal_gen_cmd_mode_en(dsih_ctrl_t * instance, int enable);\r
1664 int mipi_dsih_hal_gen_is_cmd_mode(dsih_ctrl_t * instance);\r
1665 \r
1666 void mipi_dsih_hal_dpi_hline(dsih_ctrl_t * instance, uint16_t time);\r
1667 void mipi_dsih_hal_dpi_hbp(dsih_ctrl_t * instance, uint16_t time);\r
1668 void mipi_dsih_hal_dpi_hsa(dsih_ctrl_t * instance, uint16_t time);\r
1669 void mipi_dsih_hal_dpi_vactive(dsih_ctrl_t * instance, uint16_t lines);\r
1670 void mipi_dsih_hal_dpi_vfp(dsih_ctrl_t * instance, uint16_t lines);\r
1671 void mipi_dsih_hal_dpi_vbp(dsih_ctrl_t * instance, uint16_t lines);\r
1672 void mipi_dsih_hal_dpi_vsync(dsih_ctrl_t * instance, uint16_t lines);\r
1673 \r
1674 void mipi_dsih_hal_edpi_max_allowed_size(dsih_ctrl_t * instance, uint16_t size);\r
1675 \r
1676 dsih_error_t mipi_dsih_hal_gen_packet_header(dsih_ctrl_t * instance, uint8_t vc, uint8_t packet_type, uint8_t ms_byte, uint8_t ls_byte);\r
1677 dsih_error_t mipi_dsih_hal_gen_packet_payload(dsih_ctrl_t * instance, uint32_t payload);\r
1678 dsih_error_t mipi_dsih_hal_gen_read_payload(dsih_ctrl_t * instance, uint32_t* payload);\r
1679 \r
1680 void mipi_dsih_hal_timeout_clock_division(dsih_ctrl_t * instance, uint8_t byte_clk_division_factor);\r
1681 void mipi_dsih_hal_lp_rx_timeout(dsih_ctrl_t * instance, uint16_t count);\r
1682 void mipi_dsih_hal_hs_tx_timeout(dsih_ctrl_t * instance, uint16_t count);\r
1683 \r
1684 uint32_t mipi_dsih_hal_int_status_0(dsih_ctrl_t * instance, uint32_t mask);\r
1685 uint32_t mipi_dsih_hal_int_status_1(dsih_ctrl_t * instance, uint32_t mask);\r
1686 void mipi_dsih_hal_int_mask_0(dsih_ctrl_t * instance, uint32_t mask);\r
1687 void mipi_dsih_hal_int_mask_1(dsih_ctrl_t * instance, uint32_t mask);\r
1688 uint32_t mipi_dsih_hal_int_get_mask_0(dsih_ctrl_t * instance, uint32_t mask);\r
1689 uint32_t mipi_dsih_hal_int_get_mask_1(dsih_ctrl_t * instance, uint32_t mask);\r
1690 /* DBI command interface */\r
1691 void mipi_dsih_hal_dbi_out_color_coding(dsih_ctrl_t * instance, uint8_t color_depth, uint8_t option);\r
1692 void mipi_dsih_hal_dbi_in_color_coding(dsih_ctrl_t * instance, uint8_t color_depth, uint8_t option);\r
1693 void mipi_dsih_hal_dbi_lut_size(dsih_ctrl_t * instance, uint8_t size);\r
1694 void mipi_dsih_hal_dbi_partitioning_en(dsih_ctrl_t * instance, int enable);\r
1695 void mipi_dsih_hal_dbi_dcs_vc(dsih_ctrl_t * instance, uint8_t vc);\r
1696 \r
1697 void mipi_dsih_hal_dbi_cmd_size(dsih_ctrl_t * instance, uint16_t size);\r
1698 void mipi_dsih_hal_dbi_max_cmd_size(dsih_ctrl_t * instance, uint16_t size);\r
1699 int mipi_dsih_hal_dbi_rd_cmd_busy(dsih_ctrl_t * instance);\r
1700 int mipi_dsih_hal_dbi_read_fifo_full(dsih_ctrl_t * instance);\r
1701 int mipi_dsih_hal_dbi_read_fifo_empty(dsih_ctrl_t * instance);\r
1702 int mipi_dsih_hal_dbi_write_fifo_full(dsih_ctrl_t * instance);\r
1703 int mipi_dsih_hal_dbi_write_fifo_empty(dsih_ctrl_t * instance);\r
1704 int mipi_dsih_hal_dbi_cmd_fifo_full(dsih_ctrl_t * instance);\r
1705 int mipi_dsih_hal_dbi_cmd_fifo_empty(dsih_ctrl_t * instance);\r
1706 /* Generic command interface */\r
1707 void mipi_dsih_hal_gen_rd_vc(dsih_ctrl_t * instance, uint8_t vc);\r
1708 void mipi_dsih_hal_gen_eotp_rx_en(dsih_ctrl_t * instance, int enable);\r
1709 void mipi_dsih_hal_gen_eotp_tx_en(dsih_ctrl_t * instance, int enable);\r
1710 void mipi_dsih_hal_bta_en(dsih_ctrl_t * instance, int enable);\r
1711 void mipi_dsih_hal_gen_ecc_rx_en(dsih_ctrl_t * instance, int enable);\r
1712 void mipi_dsih_hal_gen_crc_rx_en(dsih_ctrl_t * instance, int enable);\r
1713 int mipi_dsih_hal_gen_rd_cmd_busy(dsih_ctrl_t * instance);\r
1714 int mipi_dsih_hal_gen_read_fifo_full(dsih_ctrl_t * instance);\r
1715 int mipi_dsih_hal_gen_read_fifo_empty(dsih_ctrl_t * instance);\r
1716 int mipi_dsih_hal_gen_write_fifo_full(dsih_ctrl_t * instance);\r
1717 int mipi_dsih_hal_gen_write_fifo_empty(dsih_ctrl_t * instance);\r
1718 int mipi_dsih_hal_gen_cmd_fifo_full(dsih_ctrl_t * instance);\r
1719 int mipi_dsih_hal_gen_cmd_fifo_empty(dsih_ctrl_t * instance);\r
1720 \r
1721 /* only if DPI */\r
1722 dsih_error_t mipi_dsih_phy_hs2lp_config(dsih_ctrl_t * instance, uint8_t no_of_byte_cycles);\r
1723 dsih_error_t mipi_dsih_phy_lp2hs_config(dsih_ctrl_t * instance, uint8_t no_of_byte_cycles);\r
1724 dsih_error_t mipi_dsih_phy_clk_lp2hs_config(dsih_ctrl_t * instance, uint8_t no_of_byte_cycles);\r
1725 dsih_error_t mipi_dsih_phy_clk_hs2lp_config(dsih_ctrl_t * instance, uint8_t no_of_byte_cycles);\r
1726 dsih_error_t mipi_dsih_phy_bta_time(dsih_ctrl_t * instance, uint16_t no_of_byte_cycles);\r
1727 void mipi_dsih_non_continuous_clock(dsih_ctrl_t * instance, int enable);\r
1728 int mipi_dsih_non_continuous_clock_status(dsih_ctrl_t * instance);\r
1729 /* PRESP Time outs */\r
1730 void mipi_dsih_hal_presp_timeout_low_power_write(dsih_ctrl_t * instance, uint16_t no_of_byte_cycles);\r
1731 void mipi_dsih_hal_presp_timeout_low_power_read(dsih_ctrl_t * instance, uint16_t no_of_byte_cycles);\r
1732 void mipi_dsih_hal_presp_timeout_high_speed_write(dsih_ctrl_t * instance, uint16_t no_of_byte_cycles);\r
1733 void mipi_dsih_hal_presp_timeout_high_speed_read(dsih_ctrl_t * instance, uint16_t no_of_byte_cycles);\r
1734 void mipi_dsih_hal_presp_timeout_bta(dsih_ctrl_t * instance, uint16_t no_of_byte_cycles);\r
1735 /* bsp abstraction */\r
1736 void mipi_dsih_write_word(dsih_ctrl_t * instance, uint32_t reg_address, uint32_t data);\r
1737 void mipi_dsih_write_part(dsih_ctrl_t * instance, uint32_t reg_address, uint32_t data, uint8_t shift, uint8_t width);\r
1738 uint32_t mipi_dsih_read_word(dsih_ctrl_t * instance, uint32_t reg_address);\r
1739 uint32_t mipi_dsih_read_part(dsih_ctrl_t * instance, uint32_t reg_address, uint8_t shift, uint8_t width);\r
1740 \r
1741 #endif /* MIPI_DSI_API_H_ */\r