1 /* 2 * Copyright (c) 2020 HiSilicon (Shanghai) Technologies CO., LIMITED. 3 * Licensed under the Apache License, Version 2.0 (the "License"); 4 * you may not use this file except in compliance with the License. 5 * You may obtain a copy of the License at 6 * 7 * http://www.apache.org/licenses/LICENSE-2.0 8 * 9 * Unless required by applicable law or agreed to in writing, software 10 * distributed under the License is distributed on an "AS IS" BASIS, 11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 * See the License for the specific language governing permissions and 13 * limitations under the License. 14 */ 15 16 #ifndef MIPI_TX_REG_H 17 #define MIPI_TX_REG_H 18 19 /* Define the union U_PWR_UP */ 20 typedef union { 21 /* Define the struct bits */ 22 struct { 23 unsigned int pwr_up : 1; /* [0] */ 24 unsigned int reserved_0 : 31; /* [31..1] */ 25 } bits; 26 27 /* Define an unsigned member */ 28 unsigned int u32; 29 } U_PWR_UP; 30 31 /* Define the union U_CLKMGR_CFG */ 32 typedef union { 33 /* Define the struct bits */ 34 struct { 35 unsigned int tx_esc_clk_division : 8; /* [7..0] */ 36 unsigned int reserved_0 : 8; /* [15..8] */ 37 unsigned int reserved_1 : 16; /* [31..16] */ 38 } bits; 39 40 /* Define an unsigned member */ 41 unsigned int u32; 42 } U_CLKMGR_CFG; 43 44 /* Define the union U_VCID */ 45 typedef union { 46 /* Define the struct bits */ 47 struct { 48 unsigned int vcid : 2; /* [1..0] */ 49 unsigned int reserved_0 : 30; /* [31..2] */ 50 } bits; 51 52 /* Define an unsigned member */ 53 unsigned int u32; 54 } U_VCID; 55 56 /* Define the union U_COLOR_CODING */ 57 typedef union { 58 /* Define the struct bits */ 59 struct { 60 unsigned int color_coding : 4; /* [3..0] */ 61 unsigned int reserved_0 : 4; /* [7..4] */ 62 unsigned int loosely18_en : 1; /* [8] */ 63 unsigned int reserved_1 : 23; /* [31..9] */ 64 } bits; 65 66 /* Define an unsigned member */ 67 unsigned int u32; 68 } U_COLOR_CODING; 69 70 /* Define the union U_LP_CMD_TIM */ 71 typedef union { 72 /* Define the struct bits */ 73 struct { 74 unsigned int invact_lpcmd_time : 8; /* [7..0] */ 75 unsigned int reserved_0 : 8; /* [15..8] */ 76 unsigned int outvact_lpcmd_time : 8; /* [23..16] */ 77 unsigned int reserved_1 : 8; /* [31..24] */ 78 } bits; 79 80 /* Define an unsigned member */ 81 unsigned int u32; 82 } U_LP_CMD_TIM; 83 84 /* Define the union U_PCKHDL_CFG */ 85 typedef union { 86 /* Define the struct bits */ 87 struct { 88 unsigned int eotp_tx_en : 1; /* [0] */ 89 unsigned int eotp_rx_en : 1; /* [1] */ 90 unsigned int bta_en : 1; /* [2] */ 91 unsigned int ecc_rx_en : 1; /* [3] */ 92 unsigned int crc_rx_en : 1; /* [4] */ 93 unsigned int reserved_0 : 27; /* [31..5] */ 94 } bits; 95 96 /* Define an unsigned member */ 97 unsigned int u32; 98 } U_PCKHDL_CFG; 99 100 /* Define the union U_GEN_VCID */ 101 typedef union { 102 /* Define the struct bits */ 103 struct { 104 unsigned int gen_vcid_rx : 2; /* [1..0] */ 105 unsigned int reserved_0 : 30; /* [31..2] */ 106 } bits; 107 108 /* Define an unsigned member */ 109 unsigned int u32; 110 } U_GEN_VCID; 111 112 /* Define the union U_MODE_CFG */ 113 typedef union { 114 /* Define the struct bits */ 115 struct { 116 unsigned int cmd_video_mode : 1; /* [0] */ 117 unsigned int reserved_0 : 31; /* [31..1] */ 118 } bits; 119 120 /* Define an unsigned member */ 121 unsigned int u32; 122 } U_MODE_CFG; 123 124 /* Define the union U_VID_MODE_CFG */ 125 typedef union { 126 /* Define the struct bits */ 127 struct { 128 unsigned int vid_mode_type : 2; /* [1..0] */ 129 unsigned int reserved_0 : 6; /* [7..2] */ 130 unsigned int lp_vsa_en : 1; /* [8] */ 131 unsigned int lp_vbp_en : 1; /* [9] */ 132 unsigned int lp_vfp_en : 1; /* [10] */ 133 unsigned int lp_vact_en : 1; /* [11] */ 134 unsigned int lp_hbp_en : 1; /* [12] */ 135 unsigned int lp_hfp_en : 1; /* [13] */ 136 unsigned int frame_bta_ack_en : 1; /* [14] */ 137 unsigned int lp_cmd_en : 1; /* [15] */ 138 unsigned int vpg_en : 1; /* [16] */ 139 unsigned int reserved_1 : 3; /* [19..17] */ 140 unsigned int vpg_mode : 1; /* [20] */ 141 unsigned int reserved_2 : 3; /* [23..21] */ 142 unsigned int vpg_orientation : 1; /* [24] */ 143 unsigned int reserved_3 : 7; /* [31..25] */ 144 } bits; 145 146 /* Define an unsigned member */ 147 unsigned int u32; 148 } U_VID_MODE_CFG; 149 150 /* Define the union U_VID_PKT_SIZE */ 151 typedef union { 152 /* Define the struct bits */ 153 struct { 154 unsigned int vid_pkt_size : 14; /* [13..0] */ 155 unsigned int reserved_0 : 18; /* [31..14] */ 156 } bits; 157 158 /* Define an unsigned member */ 159 unsigned int u32; 160 } U_VID_PKT_SIZE; 161 162 /* Define the union U_VID_NUM_CHUNKS */ 163 typedef union { 164 /* Define the struct bits */ 165 struct { 166 unsigned int vid_num_chunks : 13; /* [12..0] */ 167 unsigned int reserved_0 : 19; /* [31..13] */ 168 } bits; 169 170 /* Define an unsigned member */ 171 unsigned int u32; 172 } U_VID_NUM_CHUNKS; 173 174 /* Define the union U_VID_NULL_SIZE */ 175 typedef union { 176 /* Define the struct bits */ 177 struct { 178 unsigned int vid_null_size : 13; /* [12..0] */ 179 unsigned int reserved_0 : 19; /* [31..13] */ 180 } bits; 181 182 /* Define an unsigned member */ 183 unsigned int u32; 184 } U_VID_NULL_SIZE; 185 186 /* Define the union U_VID_HSA_TIME */ 187 typedef union { 188 /* Define the struct bits */ 189 struct { 190 unsigned int vid_hsa_time : 12; /* [11..0] */ 191 unsigned int reserved_0 : 20; /* [31..12] */ 192 } bits; 193 194 /* Define an unsigned member */ 195 unsigned int u32; 196 } U_VID_HSA_TIME; 197 198 /* Define the union U_VID_HBP_TIME */ 199 typedef union { 200 /* Define the struct bits */ 201 struct { 202 unsigned int vid_hbp_time : 12; /* [11..0] */ 203 unsigned int reserved_0 : 20; /* [31..12] */ 204 } bits; 205 206 /* Define an unsigned member */ 207 unsigned int u32; 208 } U_VID_HBP_TIME; 209 210 /* Define the union U_VID_HLINE_TIME */ 211 typedef union { 212 /* Define the struct bits */ 213 struct { 214 unsigned int vid_hline_time : 15; /* [14..0] */ 215 unsigned int reserved_0 : 17; /* [31..15] */ 216 } bits; 217 218 /* Define an unsigned member */ 219 unsigned int u32; 220 } U_VID_HLINE_TIME; 221 222 /* Define the union U_VID_VSA_LINES */ 223 typedef union { 224 /* Define the struct bits */ 225 struct { 226 unsigned int vsa_lines : 10; /* [9..0] */ 227 unsigned int reserved_0 : 22; /* [31..10] */ 228 } bits; 229 230 /* Define an unsigned member */ 231 unsigned int u32; 232 } U_VID_VSA_LINES; 233 234 /* Define the union U_VID_VBP_LINES */ 235 typedef union { 236 /* Define the struct bits */ 237 struct { 238 unsigned int vbp_lines : 10; /* [9..0] */ 239 unsigned int reserved_0 : 22; /* [31..10] */ 240 } bits; 241 242 /* Define an unsigned member */ 243 unsigned int u32; 244 } U_VID_VBP_LINES; 245 246 /* Define the union U_VID_VFP_LINES */ 247 typedef union { 248 /* Define the struct bits */ 249 struct { 250 unsigned int vfp_lines : 10; /* [9..0] */ 251 unsigned int reserved_0 : 22; /* [31..10] */ 252 } bits; 253 254 /* Define an unsigned member */ 255 unsigned int u32; 256 } U_VID_VFP_LINES; 257 258 /* Define the union U_VID_VACTIVE_LINES */ 259 typedef union { 260 /* Define the struct bits */ 261 struct { 262 unsigned int v_active_lines : 14; /* [13..0] */ 263 unsigned int reserved_0 : 18; /* [31..14] */ 264 } bits; 265 266 /* Define an unsigned member */ 267 unsigned int u32; 268 } U_VID_VACTIVE_LINES; 269 270 /* Define the union U_EDPI_CMD_SIZE */ 271 typedef union { 272 /* Define the struct bits */ 273 struct { 274 unsigned int edpi_allowed_cmd_size : 16; /* [15..0] */ 275 unsigned int reserved_0 : 16; /* [31..16] */ 276 } bits; 277 278 /* Define an unsigned member */ 279 unsigned int u32; 280 } U_EDPI_CMD_SIZE; 281 282 /* Define the union U_CMD_MODE_CFG */ 283 typedef union { 284 /* Define the struct bits */ 285 struct { 286 unsigned int reserved_0 : 1; /* [0] */ 287 unsigned int reserved_1 : 1; /* [1] */ 288 unsigned int reserved_2 : 6; /* [7..2] */ 289 unsigned int gen_sw_0p_tx : 1; /* [8] */ 290 unsigned int gen_sw_1p_tx : 1; /* [9] */ 291 unsigned int gen_sw_2p_tx : 1; /* [10] */ 292 unsigned int gen_sr_0p_tx : 1; /* [11] */ 293 unsigned int gen_sr_1p_tx : 1; /* [12] */ 294 unsigned int gen_sr_2p_tx : 1; /* [13] */ 295 unsigned int gen_lw_tx : 1; /* [14] */ 296 unsigned int reserved_3 : 1; /* [15] */ 297 unsigned int dcs_sw_0p_tx : 1; /* [16] */ 298 unsigned int dcs_sw_1p_tx : 1; /* [17] */ 299 unsigned int dcs_sr_0p_tx : 1; /* [18] */ 300 unsigned int dcs_lw_tx : 1; /* [19] */ 301 unsigned int reserved_4 : 4; /* [23..20] */ 302 unsigned int max_rd_pkt_size : 1; /* [24] */ 303 unsigned int reserved_5 : 7; /* [31..25] */ 304 } bits; 305 306 /* Define an unsigned member */ 307 unsigned int u32; 308 } U_CMD_MODE_CFG; 309 310 /* Define the union U_GEN_HDR */ 311 typedef union { 312 /* Define the struct bits */ 313 struct { 314 unsigned int gen_dt : 6; /* [5..0] */ 315 unsigned int gen_vc : 2; /* [7..6] */ 316 unsigned int gen_wc_lsbyte : 8; /* [15..8] */ 317 unsigned int gen_wc_msbyte : 8; /* [23..16] */ 318 unsigned int reserved_0 : 8; /* [31..24] */ 319 } bits; 320 321 /* Define an unsigned member */ 322 unsigned int u32; 323 } U_GEN_HDR; 324 325 /* Define the union U_GEN_PLD_DATA */ 326 typedef union { 327 /* Define the struct bits */ 328 struct { 329 unsigned int gen_pld_b1 : 8; /* [7..0] */ 330 unsigned int gen_pld_b2 : 8; /* [15..8] */ 331 unsigned int gen_pld_b3 : 8; /* [23..16] */ 332 unsigned int gen_pld_b4 : 8; /* [31..24] */ 333 } bits; 334 335 /* Define an unsigned member */ 336 unsigned int u32; 337 } U_GEN_PLD_DATA; 338 339 /* Define the union U_CMD_PKT_STATUS */ 340 typedef union { 341 /* Define the struct bits */ 342 struct { 343 unsigned int gen_cmd_empty : 1; /* [0] */ 344 unsigned int gen_cmd_full : 1; /* [1] */ 345 unsigned int gen_pld_w_empty : 1; /* [2] */ 346 unsigned int gen_pld_w_full : 1; /* [3] */ 347 unsigned int gen_pld_r_empty : 1; /* [4] */ 348 unsigned int gen_pld_r_full : 1; /* [5] */ 349 unsigned int gen_rd_cmd_busy : 1; /* [6] */ 350 unsigned int reserved_0 : 25; /* [31..7] */ 351 } bits; 352 353 /* Define an unsigned member */ 354 unsigned int u32; 355 } U_CMD_PKT_STATUS; 356 357 /* Define the union U_LP_WR_TO_CNT */ 358 typedef union { 359 /* Define the struct bits */ 360 struct { 361 unsigned int lp_wr_to_cnt : 16; /* [15..0] */ 362 unsigned int reserved_0 : 16; /* [31..16] */ 363 } bits; 364 365 /* Define an unsigned member */ 366 unsigned int u32; 367 } U_LP_WR_TO_CNT; 368 369 /* Define the union U_BTA_TO_CNT */ 370 typedef union { 371 /* Define the struct bits */ 372 struct { 373 unsigned int bta_to_cnt : 16; /* [15..0] */ 374 unsigned int reserved_0 : 16; /* [31..16] */ 375 } bits; 376 377 /* Define an unsigned member */ 378 unsigned int u32; 379 } U_BTA_TO_CNT; 380 381 /* Define the union U_LPCLK_CTRL */ 382 typedef union { 383 /* Define the struct bits */ 384 struct { 385 unsigned int phy_txrequestclkhs : 1; /* [0] */ 386 unsigned int auto_clklane_ctrl : 1; /* [1] */ 387 unsigned int reserved_0 : 30; /* [31..2] */ 388 } bits; 389 390 /* Define an unsigned member */ 391 unsigned int u32; 392 } U_LPCLK_CTRL; 393 394 /* Define the union U_PHY_TMR_LPCLK_CFG */ 395 typedef union { 396 /* Define the struct bits */ 397 struct { 398 unsigned int phy_clklp2hs_time : 10; /* [9..0] */ 399 unsigned int reserved_0 : 6; /* [15..10] */ 400 unsigned int phy_clkhs2lp_time : 10; /* [25..16] */ 401 unsigned int reserved_1 : 6; /* [31..26] */ 402 } bits; 403 404 /* Define an unsigned member */ 405 unsigned int u32; 406 } U_PHY_TMR_LPCLK_CFG; 407 408 /* Define the union U_PHY_TMR_CFG */ 409 typedef union { 410 /* Define the struct bits */ 411 struct { 412 unsigned int phy_lp2hs_time : 10; /* [9..0] */ 413 unsigned int reserved_0 : 6; /* [15..10] */ 414 unsigned int phy_hs2lp_time : 10; /* [25..16] */ 415 unsigned int reserved_1 : 6; /* [31..26] */ 416 } bits; 417 418 /* Define an unsigned member */ 419 unsigned int u32; 420 } U_PHY_TMR_CFG; 421 422 /* Define the union U_PHY_RSTZ */ 423 typedef union { 424 /* Define the struct bits */ 425 struct { 426 unsigned int phy_shutdownz : 1; /* [0] */ 427 unsigned int phy_rstz : 1; /* [1] */ 428 unsigned int phy_enableclk : 1; /* [2] */ 429 unsigned int phy_forcepll : 1; /* [3] */ 430 unsigned int reserved_0 : 28; /* [31..4] */ 431 } bits; 432 433 /* Define an unsigned member */ 434 unsigned int u32; 435 } U_PHY_RSTZ; 436 437 /* Define the union U_PHY_IF_CFG */ 438 typedef union { 439 /* Define the struct bits */ 440 struct { 441 unsigned int n_lanes : 2; /* [1..0] */ 442 unsigned int reserved_0 : 6; /* [7..2] */ 443 unsigned int phy_stop_wait_time : 8; /* [15..8] */ 444 unsigned int reserved_1 : 16; /* [31..16] */ 445 } bits; 446 447 /* Define an unsigned member */ 448 unsigned int u32; 449 } U_PHY_IF_CFG; 450 451 /* Define the union U_PHY_ULPS_CTRL */ 452 typedef union { 453 /* Define the struct bits */ 454 struct { 455 unsigned int phy_txrequlpsclk : 1; /* [0] */ 456 unsigned int phy_txexitulpsclk : 1; /* [1] */ 457 unsigned int phy_txrequlpslan : 1; /* [2] */ 458 unsigned int phy_txexitulpslan : 1; /* [3] */ 459 unsigned int reserved_0 : 28; /* [31..4] */ 460 } bits; 461 462 /* Define an unsigned member */ 463 unsigned int u32; 464 } U_PHY_ULPS_CTRL; 465 466 /* Define the union U_PHY_STATUS */ 467 typedef union { 468 /* Define the struct bits */ 469 struct { 470 unsigned int phy_lock : 1; /* [0] */ 471 unsigned int phy_direction : 1; /* [1] */ 472 unsigned int phy_stopstateclklane : 1; /* [2] */ 473 unsigned int phy_ulpsactivenotclk : 1; /* [3] */ 474 unsigned int phy_stopstate0lane : 1; /* [4] */ 475 unsigned int phy_ulpsactivenot0lane : 1; /* [5] */ 476 unsigned int phy_rxulpsesc0lane : 1; /* [6] */ 477 unsigned int phy_stopstate1lane : 1; /* [7] */ 478 unsigned int phy_ulpsactivenot1lane : 1; /* [8] */ 479 unsigned int phy_stopstate2lane : 1; /* [9] */ 480 unsigned int phy_ulpsactivenot2lane : 1; /* [10] */ 481 unsigned int phy_stopstate3lane : 1; /* [11] */ 482 unsigned int phy_ulpsactivenot3lane : 1; /* [12] */ 483 unsigned int reserved_0 : 19; /* [31..13] */ 484 } bits; 485 486 /* Define an unsigned member */ 487 unsigned int u32; 488 } U_PHY_STATUS; 489 490 /* Define the union U_PHY_TST_CTRL0 */ 491 typedef union { 492 /* Define the struct bits */ 493 struct { 494 unsigned int phy_testclr : 1; /* [0] */ 495 unsigned int phy_testclk : 1; /* [1] */ 496 unsigned int reserved_0 : 30; /* [31..2] */ 497 } bits; 498 499 /* Define an unsigned member */ 500 unsigned int u32; 501 } U_PHY_TST_CTRL0; 502 503 /* Define the union U_PHY_TST_CTRL1 */ 504 typedef union { 505 /* Define the struct bits */ 506 struct { 507 unsigned int phy_testdin : 8; /* [7..0] */ 508 unsigned int phy_testdout : 8; /* [15..8] */ 509 unsigned int phy_testen : 1; /* [16] */ 510 unsigned int reserved_0 : 15; /* [31..17] */ 511 } bits; 512 513 /* Define an unsigned member */ 514 unsigned int u32; 515 } U_PHY_TST_CTRL1; 516 517 /* Define the union U_INT_ST0 */ 518 typedef union { 519 /* Define the struct bits */ 520 struct { 521 unsigned int ack_with_err_0 : 1; /* [0] */ 522 unsigned int ack_with_err_1 : 1; /* [1] */ 523 unsigned int ack_with_err_2 : 1; /* [2] */ 524 unsigned int ack_with_err_3 : 1; /* [3] */ 525 unsigned int ack_with_err_4 : 1; /* [4] */ 526 unsigned int ack_with_err_5 : 1; /* [5] */ 527 unsigned int ack_with_err_6 : 1; /* [6] */ 528 unsigned int ack_with_err_7 : 1; /* [7] */ 529 unsigned int ack_with_err_8 : 1; /* [8] */ 530 unsigned int ack_with_err_9 : 1; /* [9] */ 531 unsigned int ack_with_err_10 : 1; /* [10] */ 532 unsigned int ack_with_err_11 : 1; /* [11] */ 533 unsigned int ack_with_err_12 : 1; /* [12] */ 534 unsigned int ack_with_err_13 : 1; /* [13] */ 535 unsigned int ack_with_err_14 : 1; /* [14] */ 536 unsigned int ack_with_err_15 : 1; /* [15] */ 537 unsigned int dphy_errors_0 : 1; /* [16] */ 538 unsigned int dphy_errors_1 : 1; /* [17] */ 539 unsigned int dphy_errors_2 : 1; /* [18] */ 540 unsigned int dphy_errors_3 : 1; /* [19] */ 541 unsigned int dphy_errors_4 : 1; /* [20] */ 542 unsigned int reserved_0 : 11; /* [31..21] */ 543 } bits; 544 545 /* Define an unsigned member */ 546 unsigned int u32; 547 } U_INT_ST0; 548 549 /* Define the union U_INT_ST1 */ 550 typedef union { 551 /* Define the struct bits */ 552 struct { 553 unsigned int to_hs_tx : 1; /* [0] */ 554 unsigned int to_lp_rx : 1; /* [1] */ 555 unsigned int ecc_single_err : 1; /* [2] */ 556 unsigned int ecc_multi_err : 1; /* [3] */ 557 unsigned int crc_err : 1; /* [4] */ 558 unsigned int pkt_size_err : 1; /* [5] */ 559 unsigned int eopt_err : 1; /* [6] */ 560 unsigned int dpi_pld_wr_err : 1; /* [7] */ 561 unsigned int gen_cmd_wr_err : 1; /* [8] */ 562 unsigned int gen_pld_wr_err : 1; /* [9] */ 563 unsigned int gen_pld_send_err : 1; /* [10] */ 564 unsigned int gen_pld_rd_err : 1; /* [11] */ 565 unsigned int gen_pld_recev_err : 1; /* [12] */ 566 unsigned int reserved_0 : 3; /* [15..13] */ 567 unsigned int vsstart : 1; /* [16] */ 568 unsigned int reserved_1 : 3; /* [19..17] */ 569 unsigned int rxtrigger_0 : 1; /* [20] */ 570 unsigned int rxtrigger_1 : 1; /* [21] */ 571 unsigned int rxtrigger_2 : 1; /* [22] */ 572 unsigned int rxtrigger_3 : 1; /* [23] */ 573 unsigned int hss_abnormal : 1; /* [24] */ 574 unsigned int reserved_2 : 7; /* [31..25] */ 575 } bits; 576 577 /* Define an unsigned member */ 578 unsigned int u32; 579 } U_INT_ST1; 580 581 /* Define the union U_INT_MSK0 */ 582 typedef union { 583 /* Define the struct bits */ 584 struct { 585 unsigned int mask_ack_with_err_0 : 1; /* [0] */ 586 unsigned int mask_ack_with_err_1 : 1; /* [1] */ 587 unsigned int mask_ack_with_err_2 : 1; /* [2] */ 588 unsigned int mask_ack_with_err_3 : 1; /* [3] */ 589 unsigned int mask_ack_with_err_4 : 1; /* [4] */ 590 unsigned int mask_ack_with_err_5 : 1; /* [5] */ 591 unsigned int mask_ack_with_err_6 : 1; /* [6] */ 592 unsigned int mask_ack_with_err_7 : 1; /* [7] */ 593 unsigned int mask_ack_with_err_8 : 1; /* [8] */ 594 unsigned int mask_ack_with_err_9 : 1; /* [9] */ 595 unsigned int mask_ack_with_err_10 : 1; /* [10] */ 596 unsigned int mask_ack_with_err_11 : 1; /* [11] */ 597 unsigned int mask_ack_with_err_12 : 1; /* [12] */ 598 unsigned int mask_ack_with_err_13 : 1; /* [13] */ 599 unsigned int mask_ack_with_err_14 : 1; /* [14] */ 600 unsigned int mask_ack_with_err_15 : 1; /* [15] */ 601 unsigned int mask_dphy_errors_0 : 1; /* [16] */ 602 unsigned int mask_dphy_errors_1 : 1; /* [17] */ 603 unsigned int mask_dphy_errors_2 : 1; /* [18] */ 604 unsigned int mask_dphy_errors_3 : 1; /* [19] */ 605 unsigned int mask_dphy_errors_4 : 1; /* [20] */ 606 unsigned int reserved_0 : 11; /* [31..21] */ 607 } bits; 608 609 /* Define an unsigned member */ 610 unsigned int u32; 611 } U_INT_MSK0; 612 613 /* Define the union U_INT_MSK1 */ 614 typedef union { 615 /* Define the struct bits */ 616 struct { 617 unsigned int mask_to_hs_tx : 1; /* [0] */ 618 unsigned int mask_to_lp_rx : 1; /* [1] */ 619 unsigned int mask_ecc_single_err : 1; /* [2] */ 620 unsigned int mask_ecc_multi_err : 1; /* [3] */ 621 unsigned int mask_crc_err : 1; /* [4] */ 622 unsigned int mask_pkt_size_err : 1; /* [5] */ 623 unsigned int mask_eopt_err : 1; /* [6] */ 624 unsigned int mask_dpi_pld_wr_err : 1; /* [7] */ 625 unsigned int mask_gen_cmd_wr_err : 1; /* [8] */ 626 unsigned int mask_gen_pld_wr_err : 1; /* [9] */ 627 unsigned int mask_gen_pld_send_err : 1; /* [10] */ 628 unsigned int mask_gen_pld_rd_err : 1; /* [11] */ 629 unsigned int mask_gen_pld_recev_err : 1; /* [12] */ 630 unsigned int reserved_0 : 3; /* [15..13] */ 631 unsigned int mask_vsstart : 1; /* [16] */ 632 unsigned int reserved_1 : 3; /* [19..17] */ 633 unsigned int mask_trigger_0 : 1; /* [20] */ 634 unsigned int mask_trigger_1 : 1; /* [21] */ 635 unsigned int mask_trigger_2 : 1; /* [22] */ 636 unsigned int mask_trigger_3 : 1; /* [23] */ 637 unsigned int mask_hss_abnormal : 1; /* [24] */ 638 unsigned int reserved_2 : 7; /* [31..25] */ 639 } bits; 640 641 /* Define an unsigned member */ 642 unsigned int u32; 643 } U_INT_MSK1; 644 645 /* Define the union U_PHY_CAL */ 646 typedef union { 647 /* Define the struct bits */ 648 struct { 649 unsigned int txskewcalhs : 1; /* [0] */ 650 unsigned int reserved_0 : 31; /* [31..1] */ 651 } bits; 652 653 /* Define an unsigned member */ 654 unsigned int u32; 655 } U_PHY_CAL; 656 657 /* Define the union U_INT_FORCE1 */ 658 typedef union { 659 /* Define the struct bits */ 660 struct { 661 unsigned int reserved_0 : 1; /* [0] */ 662 unsigned int reserved_1 : 1; /* [1] */ 663 unsigned int reserved_2 : 1; /* [2] */ 664 unsigned int reserved_3 : 1; /* [3] */ 665 unsigned int reserved_4 : 1; /* [4] */ 666 unsigned int reserved_5 : 1; /* [5] */ 667 unsigned int reserved_6 : 1; /* [6] */ 668 unsigned int reserved_7 : 1; /* [7] */ 669 unsigned int reserved_8 : 1; /* [8] */ 670 unsigned int reserved_9 : 1; /* [9] */ 671 unsigned int reserved_10 : 1; /* [10] */ 672 unsigned int reserved_11 : 1; /* [11] */ 673 unsigned int reserved_12 : 1; /* [12] */ 674 unsigned int reserved_13 : 3; /* [15..13] */ 675 unsigned int reserved_14 : 1; /* [16] */ 676 unsigned int reserved_15 : 3; /* [19..17] */ 677 unsigned int reserved_16 : 1; /* [20] */ 678 unsigned int reserved_17 : 1; /* [21] */ 679 unsigned int reserved_18 : 1; /* [22] */ 680 unsigned int reserved_19 : 1; /* [23] */ 681 unsigned int reserved_20 : 1; /* [24] */ 682 unsigned int reserved_21 : 7; /* [31..25] */ 683 } bits; 684 685 /* Define an unsigned member */ 686 unsigned int u32; 687 } U_INT_FORCE1; 688 689 /* Define the union U_OPERATION_MODE */ 690 typedef union { 691 /* Define the struct bits */ 692 struct { 693 unsigned int reserved_0 : 1; /* [0] */ 694 unsigned int mem_ck_en : 1; /* [1] */ 695 unsigned int reserved_1 : 2; /* [3..2] */ 696 unsigned int reserved_2 : 1; /* [4] */ 697 unsigned int init_skew_en : 1; /* [5] */ 698 unsigned int period_skew_en : 1; /* [6] */ 699 unsigned int reserved_3 : 1; /* [7] */ 700 unsigned int reserved_4 : 1; /* [8] */ 701 unsigned int reserved_5 : 1; /* [9] */ 702 unsigned int reserved_6 : 1; /* [10] */ 703 unsigned int reserved_7 : 1; /* [11] */ 704 unsigned int reserved_8 : 1; /* [12] */ 705 unsigned int reserved_9 : 1; /* [13] */ 706 unsigned int reserved_10 : 1; /* [14] */ 707 unsigned int reserved_11 : 1; /* [15] */ 708 unsigned int read_empty_vsync_en : 1; /* [16] */ 709 unsigned int reserved_12 : 1; /* [17] */ 710 unsigned int buf_clr_en : 1; /* [18] */ 711 unsigned int reserved_13 : 1; /* [19] */ 712 unsigned int hss_abnormal_rst : 1; /* [20] */ 713 unsigned int reserved_14 : 3; /* [23..21] */ 714 unsigned int reserved_15 : 1; /* [24] */ 715 unsigned int reserved_16 : 1; /* [25] */ 716 unsigned int reserved_17 : 1; /* [26] */ 717 unsigned int reserved_18 : 1; /* [27] */ 718 unsigned int reserved_19 : 3; /* [30..28] */ 719 unsigned int input_en : 1; /* [31] */ 720 } bits; 721 722 /* Define an unsigned member */ 723 unsigned int u32; 724 } U_OPERATION_MODE; 725 726 /* Define the union U_VERT_DET */ 727 typedef union { 728 /* Define the struct bits */ 729 struct { 730 unsigned int vact_det : 16; /* [15..0] */ 731 unsigned int vall_det : 16; /* [31..16] */ 732 } bits; 733 734 /* Define an unsigned member */ 735 unsigned int u32; 736 } U_VERT_DET; 737 738 /* Define the union U_HORI0_DET */ 739 typedef union { 740 /* Define the struct bits */ 741 struct { 742 unsigned int hact_det : 16; /* [15..0] */ 743 unsigned int hline_det : 16; /* [31..16] */ 744 } bits; 745 746 /* Define an unsigned member */ 747 unsigned int u32; 748 } U_HORI0_DET; 749 750 /* Define the union U_HORI1_DET */ 751 typedef union { 752 /* Define the struct bits */ 753 struct { 754 unsigned int hsa_det : 16; /* [15..0] */ 755 unsigned int hbp_det : 16; /* [31..16] */ 756 } bits; 757 758 /* Define an unsigned member */ 759 unsigned int u32; 760 } U_HORI1_DET; 761 762 /* Define the union U_VSA_DET */ 763 typedef union { 764 /* Define the struct bits */ 765 struct { 766 unsigned int vsa_det : 16; /* [15..0] */ 767 unsigned int reserved_0 : 16; /* [31..16] */ 768 } bits; 769 770 /* Define an unsigned member */ 771 unsigned int u32; 772 } U_VSA_DET; 773 774 /* Define the union U_V_H_SEND */ 775 typedef union { 776 /* Define the struct bits */ 777 struct { 778 unsigned int h_send : 16; /* [15..0] */ 779 unsigned int v_send : 16; /* [31..16] */ 780 } bits; 781 782 /* Define an unsigned member */ 783 unsigned int u32; 784 } U_V_H_SEND; 785 786 /* Define the union U_DATATYPE0 */ 787 typedef union { 788 /* Define the struct bits */ 789 struct { 790 unsigned int reserved_0 : 6; /* [5..0] */ 791 unsigned int reserved_1 : 2; /* [7..6] */ 792 unsigned int dt_hss : 6; /* [13..8] */ 793 unsigned int reserved_2 : 2; /* [15..14] */ 794 unsigned int dt_vse : 6; /* [21..16] */ 795 unsigned int reserved_3 : 2; /* [23..22] */ 796 unsigned int dt_vss : 6; /* [29..24] */ 797 unsigned int reserved_4 : 2; /* [31..30] */ 798 } bits; 799 800 /* Define an unsigned member */ 801 unsigned int u32; 802 } U_DATATYPE0; 803 804 /* Define the union U_CSI_CTRL */ 805 typedef union { 806 /* Define the struct bits */ 807 struct { 808 unsigned int csi_en : 1; /* [0] */ 809 unsigned int reserved_0 : 3; /* [3..1] */ 810 unsigned int reserved_1 : 1; /* [4] */ 811 unsigned int reserved_2 : 3; /* [7..5] */ 812 unsigned int reserved_3 : 1; /* [8] */ 813 unsigned int reserved_4 : 3; /* [11..9] */ 814 unsigned int reserved_5 : 1; /* [12] */ 815 unsigned int reserved_6 : 3; /* [15..13] */ 816 unsigned int reserved_7 : 1; /* [16] */ 817 unsigned int reserved_8 : 15; /* [31..17] */ 818 } bits; 819 820 /* Define an unsigned member */ 821 unsigned int u32; 822 } U_CSI_CTRL; 823 824 /* Define the union U_SKEW_BEGIN */ 825 typedef union { 826 /* Define the struct bits */ 827 struct { 828 unsigned int skew_begin : 32; /* [31..0] */ 829 } bits; 830 831 /* Define an unsigned member */ 832 unsigned int u32; 833 } U_SKEW_BEGIN; 834 /* Define the union U_SKEW_END */ 835 typedef union { 836 /* Define the struct bits */ 837 struct { 838 unsigned int skew_end : 32; /* [31..0] */ 839 } bits; 840 841 /* Define an unsigned member */ 842 unsigned int u32; 843 } U_SKEW_END; 844 /* Define the union U_LANE_ID */ 845 typedef union { 846 /* Define the struct bits */ 847 struct { 848 unsigned int lane0_id : 2; /* [1..0] */ 849 unsigned int reserved_0 : 2; /* [3..2] */ 850 unsigned int lane1_id : 2; /* [5..4] */ 851 unsigned int reserved_1 : 2; /* [7..6] */ 852 unsigned int lane2_id : 2; /* [9..8] */ 853 unsigned int reserved_2 : 2; /* [11..10] */ 854 unsigned int lane3_id : 2; /* [13..12] */ 855 unsigned int reserved_3 : 18; /* [31..14] */ 856 } bits; 857 858 /* Define an unsigned member */ 859 unsigned int u32; 860 } U_LANE_ID; 861 862 863 /* Define the global struct */ 864 typedef struct { 865 unsigned int reserved_0; /* 0x0 */ 866 U_PWR_UP PWR_UP; /* 0x4 */ 867 U_CLKMGR_CFG CLKMGR_CFG; /* 0x8 */ 868 U_VCID VCID; /* 0xc */ 869 U_COLOR_CODING COLOR_CODING; /* 0x10 */ 870 unsigned int reserved_1; /* 0x14 */ 871 U_LP_CMD_TIM LP_CMD_TIM; /* 0x18 */ 872 unsigned int reserved_2[4]; /* 0x1c~0x28 */ 873 U_PCKHDL_CFG PCKHDL_CFG; /* 0x2c */ 874 U_GEN_VCID GEN_VCID; /* 0x30 */ 875 U_MODE_CFG MODE_CFG; /* 0x34 */ 876 U_VID_MODE_CFG VID_MODE_CFG; /* 0x38 */ 877 U_VID_PKT_SIZE VID_PKT_SIZE; /* 0x3c */ 878 U_VID_NUM_CHUNKS VID_NUM_CHUNKS; /* 0x40 */ 879 U_VID_NULL_SIZE VID_NULL_SIZE; /* 0x44 */ 880 U_VID_HSA_TIME VID_HSA_TIME; /* 0x48 */ 881 U_VID_HBP_TIME VID_HBP_TIME; /* 0x4c */ 882 U_VID_HLINE_TIME VID_HLINE_TIME; /* 0x50 */ 883 U_VID_VSA_LINES VID_VSA_LINES; /* 0x54 */ 884 U_VID_VBP_LINES VID_VBP_LINES; /* 0x58 */ 885 U_VID_VFP_LINES VID_VFP_LINES; /* 0x5c */ 886 U_VID_VACTIVE_LINES VID_VACTIVE_LINES; /* 0x60 */ 887 U_EDPI_CMD_SIZE EDPI_CMD_SIZE; /* 0x64 */ 888 U_CMD_MODE_CFG CMD_MODE_CFG; /* 0x68 */ 889 U_GEN_HDR GEN_HDR; /* 0x6c */ 890 U_GEN_PLD_DATA GEN_PLD_DATA; /* 0x70 */ 891 U_CMD_PKT_STATUS CMD_PKT_STATUS; /* 0x74 */ 892 unsigned int reserved_3[4]; /* 0x78~0x84 */ 893 U_LP_WR_TO_CNT LP_WR_TO_CNT; /* 0x88 */ 894 U_BTA_TO_CNT BTA_TO_CNT; /* 0x8c */ 895 unsigned int reserved_4; /* 0x90 */ 896 U_LPCLK_CTRL LPCLK_CTRL; /* 0x94 */ 897 U_PHY_TMR_LPCLK_CFG PHY_TMR_LPCLK_CFG; /* 0x98 */ 898 U_PHY_TMR_CFG PHY_TMR_CFG; /* 0x9c */ 899 U_PHY_RSTZ PHY_RSTZ; /* 0xa0 */ 900 U_PHY_IF_CFG PHY_IF_CFG; /* 0xa4 */ 901 U_PHY_ULPS_CTRL PHY_ULPS_CTRL; /* 0xa8 */ 902 unsigned int reserved_5; /* 0xac */ 903 U_PHY_STATUS PHY_STATUS; /* 0xb0 */ 904 U_PHY_TST_CTRL0 PHY_TST_CTRL0; /* 0xb4 */ 905 U_PHY_TST_CTRL1 PHY_TST_CTRL1; /* 0xb8 */ 906 U_INT_ST0 INT_ST0; /* 0xbc */ 907 U_INT_ST1 INT_ST1; /* 0xc0 */ 908 U_INT_MSK0 INT_MSK0; /* 0xc4 */ 909 U_INT_MSK1 INT_MSK1; /* 0xc8 */ 910 unsigned int reserved_6[79]; /* 0xcc~0x204 */ 911 U_OPERATION_MODE OPERATION_MODE; /* 0x208 */ 912 unsigned int reserved_8[2]; /* 0x20c~0x210 */ 913 volatile U_VERT_DET VERT_DET; /* 0x214 */ 914 volatile U_HORI0_DET HORI0_DET; /* 0x218 */ 915 volatile U_HORI1_DET HORI1_DET; /* 0x21c */ 916 volatile U_VSA_DET VSA_DET; /* 0x220 */ 917 U_V_H_SEND V_H_SEND; /* 0x224 */ 918 unsigned int reserved_9[2]; /* 0x228~0x22c */ 919 U_DATATYPE0 DATATYPE0; /* 0x230 */ 920 unsigned int reserved_10; /* 0x234 */ 921 U_CSI_CTRL CSI_CTRL; /* 0x238 */ 922 unsigned int reserved_11[6]; /* 0x23c~0x250 */ 923 } MipiTxRegsTypeTag; 924 925 #endif /* __MIPI_TX_REG_H__ */ 926