1 /* 2 * Copyright 2015 Rockchip Electronics Co. LTD 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * http://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 17 #ifndef __HAL_JPEGD_VDPU2_REG_H__ 18 #define __HAL_JPEGD_VDPU2_REG_H__ 19 20 #include "vcodec_service.h" 21 22 #define JPEGD_REG_NUM (159) 23 24 #define DEC_MODE_JPEG (3) 25 #define DEC_LITTLE_ENDIAN (1) 26 #define DEC_BIG_ENDIAN (0) 27 28 #define DEC_BUS_BURST_LENGTH_16 (16) 29 #define DEC_SCMD_DISABLE (0) 30 #define DEC_LATENCY_COMPENSATION (0) 31 #define DEC_DATA_DISCARD_ENABLE (0) 32 33 typedef struct JpegRegSet { 34 struct { 35 RK_U32 sw_pp_max_burst : 5; 36 RK_U32 sw_pp_scmd_dis : 1; 37 RK_U32 sw_reserved_1 : 2; 38 RK_U32 sw_pp_axi_rd_id : 8; 39 RK_U32 sw_pp_axi_wr_id : 8; 40 } reg0; 41 42 struct { 43 RK_U32 sw_color_coeffa1 : 10; 44 RK_U32 sw_color_coeffa2 : 10; 45 RK_U32 sw_color_coeffb : 10; 46 } reg1; 47 48 struct { 49 RK_U32 sw_color_coeffc : 10; 50 RK_U32 sw_color_coeffd : 10; 51 RK_U32 sw_color_coeffe : 10; 52 } reg2; 53 54 struct { 55 RK_U32 sw_pp_color_coefff : 8; 56 } reg3; 57 58 struct { 59 RK_U32 sw_scale_wratio : 18; 60 RK_U32 sw_hor_scale_mode : 2; 61 RK_U32 sw_ver_scale_mode : 2; 62 } reg4; 63 64 struct { 65 RK_U32 sw_scale_hratio : 18; 66 } reg5; 67 68 struct { 69 RK_U32 sw_wscale_invra : 16; 70 RK_U32 sw_hscale_invra : 16; 71 } reg6; 72 73 RK_U32 reg7; 74 RK_U32 reg8; 75 RK_U32 reg9_r_mask; 76 RK_U32 reg10_g_mask; 77 RK_U32 reg11_b_mask; 78 RK_U32 reg12_pp_bot_yin_base; 79 RK_U32 reg13_pp_bot_cin_base; 80 81 struct { 82 RK_U32 sw_crop_startx : 9; 83 RK_U32 sw_crop_starty_ext : 3; 84 RK_U32 sw_reserved_1 : 4; 85 RK_U32 sw_crop_starty : 8; 86 RK_U32 sw_crop_startx_ext : 3; 87 RK_U32 sw_reserved_2 : 1; 88 RK_U32 sw_pp_crop8_d_e : 1; 89 RK_U32 sw_pp_crop8_r_e : 1; 90 } reg14; 91 92 struct { 93 RK_U32 sw_rangemap_coef_y : 5; 94 RK_U32 sw_ycbcr_range : 1; 95 RK_U32 sw_reserved_1 : 2; 96 RK_U32 sw_rangemap_coef_c : 5; 97 } reg15; 98 99 struct { 100 RK_U32 sw_rgb_r_padd : 5; 101 RK_U32 sw_reserved_1 : 3; 102 RK_U32 sw_rgb_g_padd : 5; 103 RK_U32 sw_reserved_2 : 3; 104 RK_U32 sw_rgb_b_padd : 5; 105 } reg16; 106 107 RK_U32 reg17; 108 RK_U32 reg18_pp_in_lu_base; 109 RK_U32 reg19; 110 RK_U32 reg20; 111 RK_U32 reg21_pp_out_lu_base; 112 RK_U32 reg22_pp_out_ch_base; 113 RK_U32 reg23; 114 RK_U32 reg24; 115 RK_U32 reg25; 116 RK_U32 reg26; 117 RK_U32 reg27; 118 RK_U32 reg28; 119 RK_U32 reg29; 120 RK_U32 reg30; 121 122 struct { 123 RK_U32 sw_contrast_thr1 : 8; 124 RK_U32 sw_contrast_thr2 : 8; 125 } reg31; 126 127 struct { 128 RK_U32 sw_contrast_off1 : 10; 129 RK_U32 sw_reserved_1 : 6; 130 RK_U32 sw_contrast_off2 : 10; 131 } reg32; 132 133 RK_U32 reg33; 134 135 struct { 136 RK_U32 sw_pp_in_width : 9; 137 RK_U32 sw_pp_in_w_ext : 3; 138 RK_U32 sw_ext_orig_width : 9; 139 RK_U32 sw_pp_in_height : 8; 140 RK_U32 sw_pp_in_h_ext : 3; 141 } reg34; 142 143 struct { 144 RK_U32 sw_pp_out_width : 11; 145 RK_U32 sw_reserved_1 : 5; 146 RK_U32 sw_pp_out_height : 11; 147 } reg35; 148 149 struct { 150 RK_U32 sw_dither_select_r : 2; 151 RK_U32 sw_dither_select_g : 2; 152 RK_U32 sw_dither_select_b : 2; 153 } reg36; 154 155 struct { 156 RK_U32 sw_pp_in_endian : 1; 157 RK_U32 sw_pp_in_a1_endian : 1; 158 RK_U32 sw_pp_in_a2_endsel : 1; 159 RK_U32 sw_pp_out_endian : 1; 160 RK_U32 sw_rgb_pix_in32 : 1; 161 RK_U32 sw_reserved_1 : 3; 162 RK_U32 sw_pp_in_swap32_e : 1; 163 RK_U32 sw_pp_in_a1_swap32 : 1; 164 RK_U32 sw_pp_out_swap16_e : 1; 165 RK_U32 sw_pp_out_swap32_e : 1; 166 RK_U32 sw_reserved_2 : 4; 167 RK_U32 sw_pp_in_start_ch : 1; 168 RK_U32 sw_pp_out_start_ch : 1; 169 RK_U32 sw_pp_in_cr_first : 1; 170 RK_U32 sw_pp_out_cr_first : 1; 171 RK_U32 sw_reserved_3 : 4; 172 RK_U32 sw_pp_in_struct : 3; 173 } reg37; 174 175 struct { 176 RK_U32 sw_rotation_mode : 3; 177 RK_U32 sw_reserved_1 : 5; 178 RK_U32 sw_pp_in_format : 3; 179 RK_U32 sw_pp_out_format : 3; 180 RK_U32 sw_reserved_2 : 2; 181 RK_U32 sw_pp_in_format_es : 3; 182 } reg38; 183 184 struct { 185 RK_U32 sw_display_width : 12; 186 } reg39; 187 188 RK_U32 reg40; 189 190 struct { 191 RK_U32 sw_pp_e : 1; 192 RK_U32 sw_deint_blend_e : 1; 193 RK_U32 sw_deint_e : 1; 194 RK_U32 sw_pp_clk_gate_e : 1; 195 RK_U32 sw_pp_pipeline_e : 1; 196 RK_U32 sw_reserved_1 : 3; 197 RK_U32 sw_rangemap_y_e : 1; 198 RK_U32 sw_rangemap_c_e : 1; 199 RK_U32 sw_reserved_2 : 6; 200 RK_U32 sw_pp_data_disc_e : 1; 201 RK_U32 sw_reserved_3 : 3; 202 RK_U32 sw_mask1_e : 1; 203 RK_U32 sw_mask2_e : 1; 204 RK_U32 sw_mask1_ablend_e : 1; 205 RK_U32 sw_mask2_ablend_e : 1; 206 RK_U32 sw_up_cross_e : 1; 207 RK_U32 sw_down_cross_e : 1; 208 RK_U32 sw_left_cross_e : 1; 209 RK_U32 sw_right_cross_e : 1; 210 RK_U32 sw_pp_ahb_hlock_e : 1; 211 } reg41; 212 213 RK_U32 ppReg2[8]; 214 struct { 215 RK_U32 sw_dec_out_tiled_e : 1; 216 RK_U32 sw_dec_latency : 6; 217 RK_U32 sw_pic_fixed_quant : 1; 218 RK_U32 sw_filtering_dis : 1; 219 RK_U32 sw_skip_mode : 1; 220 RK_U32 sw_dec_scmd_dis : 1; 221 RK_U32 sw_dec_adv_pre_dis : 1; 222 RK_U32 sw_priority_mode : 1; 223 RK_U32 sw_refbu2_thr : 12; 224 RK_U32 sw_refbu2_picid : 5; 225 RK_U32 reserve1 : 2; 226 } reg50_dec_ctrl; 227 228 struct { 229 RK_U32 sw_stream_len : 24; 230 RK_U32 reserve1 : 1; 231 RK_U32 sw_init_qp : 6; 232 RK_U32 reserve2 : 1; 233 } reg51_stream_info; 234 235 struct { 236 RK_U32 sw_startmb_y : 8; 237 RK_U32 sw_startmb_x : 9; 238 RK_U32 sw_apf_threshold : 14; 239 RK_U32 sw_reserve : 1; 240 } reg52_error_concealment; 241 242 RK_U32 reg53_dec_mode; 243 244 struct { 245 RK_U32 sw_dec_in_endian : 1; 246 RK_U32 sw_dec_out_endian : 1; 247 RK_U32 sw_dec_inswap32_e : 1; 248 RK_U32 sw_dec_outswap32_e : 1; 249 RK_U32 sw_dec_strswap32_e : 1; 250 RK_U32 sw_dec_strendian_e : 1; 251 RK_U32 reserve3 : 26; 252 } reg54_endian; 253 254 struct { 255 RK_U32 sw_dec_irq : 1; 256 RK_U32 sw_dec_irq_dis : 1; 257 RK_U32 reserve0 : 2; 258 RK_U32 sw_dec_rdy_int : 1; 259 RK_U32 sw_dec_bus_int : 1; 260 RK_U32 sw_dec_buffer_int : 1; 261 RK_U32 reserve1 : 1; 262 RK_U32 sw_dec_aso_int : 1; 263 RK_U32 sw_dec_slice_int : 1; 264 RK_U32 sw_dec_pic_inf : 1; 265 RK_U32 reserve2 : 1; 266 RK_U32 sw_dec_error_int : 1; 267 RK_U32 sw_dec_timeout : 1; 268 RK_U32 reserve3 : 18; 269 } reg55_Interrupt; 270 271 struct { 272 RK_U32 sw_dec_axi_rn_id : 8; 273 RK_U32 sw_dec_axi_wr_id : 8; 274 RK_U32 sw_dec_max_burst : 5; 275 RK_U32 resever : 1; 276 RK_U32 sw_dec_data_disc_e : 1; 277 RK_U32 resever1 : 9; 278 } reg56_axi_ctrl; 279 280 struct { 281 RK_U32 sw_dec_e : 1; 282 RK_U32 sw_refbu2_buf_e : 1; 283 RK_U32 sw_dec_out_dis : 1; 284 RK_U32 resever : 1; 285 RK_U32 sw_dec_clk_gate_e : 1; 286 RK_U32 sw_dec_timeout_e : 1; 287 RK_U32 sw_picord_count_e : 1; 288 RK_U32 sw_seq_mbaff_e : 1; 289 RK_U32 sw_reftopfirst_e : 1; 290 RK_U32 sw_ref_topfield_e : 1; 291 RK_U32 sw_write_mvs_e : 1; 292 RK_U32 sw_sorenson_e : 1; 293 RK_U32 sw_fwd_interlace_e : 1; 294 RK_U32 sw_pic_topfield_e : 1; 295 RK_U32 sw_pic_inter_e : 1; 296 RK_U32 sw_pic_b_e : 1; 297 RK_U32 sw_pic_fieldmode_e : 1; 298 RK_U32 sw_pic_interlace_e : 1; 299 RK_U32 sw_pjpeg_e : 1; 300 RK_U32 sw_divx3_e : 1; 301 RK_U32 sw_rlc_mode_e : 1; 302 RK_U32 sw_ch_8pix_ileav_e : 1; 303 RK_U32 sw_start_code_e : 1; 304 RK_U32 resever1 : 8; 305 RK_U32 sw_dec_ahb_hlock_e : 1; 306 } reg57_enable_ctrl; 307 308 RK_U32 reg58_soft_rest; 309 310 struct { 311 RK_U32 resever : 2; 312 RK_U32 sw_pred_bc_tap_0_2 : 10; 313 RK_U32 sw_pred_bc_tap_0_1 : 10; 314 RK_U32 sw_pred_bc_tap_0_0 : 10; 315 } reg59; 316 317 RK_U32 reg60_addit_ch_st_base; 318 RK_U32 reg61_qtable_base; 319 RK_U32 reg62_directmv_base; 320 RK_U32 reg63_dec_out_base; 321 RK_U32 reg64_rlc_vlc_base; 322 323 struct { 324 RK_U32 sw_refbu_y_offset : 9; 325 RK_U32 sw_reserve : 3; 326 RK_U32 sw_refbu_fparmod_e : 1; 327 RK_U32 sw_refbu_eval_e : 1; 328 RK_U32 sw_refbu_picid : 5; 329 RK_U32 sw_refbu_thr : 12; 330 RK_U32 sw_refbu_e : 1; 331 } reg65_refpicbuf_ctrl; 332 333 struct { 334 RK_U32 build_version : 3; 335 RK_U32 product_IDen : 1; 336 RK_U32 minor_version : 8; 337 RK_U32 major_version : 4; 338 RK_U32 product_numer : 16; 339 } reg66_id; 340 341 struct { 342 RK_U32 sw_reserve : 25; 343 RK_U32 sw_dec_rtl_rom : 1; 344 RK_U32 sw_dec_rv_prof : 2; 345 RK_U32 sw_ref_buff2_exist : 1; 346 RK_U32 sw_dec_divx_prof : 1; 347 RK_U32 sw_dec_refbu_ilace : 1; 348 RK_U32 sw_dec_jpeg_exten : 1; 349 } reg67_synthesis_cfg; 350 351 struct { 352 RK_U32 sw_refbu_top_sum : 16; 353 RK_U32 sw_refbu_bot_sum : 16; 354 } reg68_sum_of_partitions; 355 356 struct { 357 RK_U32 sw_refbu_intra_sum : 16; 358 RK_U32 sw_refbu_hit_sum : 16; 359 } reg69_sum_inf; 360 361 struct { 362 RK_U32 sw_refbu_mv_sum : 22; 363 RK_U32 sw_reserve : 10; 364 } reg70_sum_mv; 365 366 RK_U32 reg71_119_reserve[49]; 367 368 struct { 369 RK_U32 sw_pic_mb_h_ext : 3; 370 RK_U32 sw_pic_mb_w_ext : 3; 371 RK_U32 sw_alt_scan_e : 1; 372 RK_U32 sw_mb_height_off : 4; 373 RK_U32 sw_pic_mb_hight_p : 8; 374 RK_U32 sw_mb_width_off : 4; 375 RK_U32 sw_pic_mb_width : 9; 376 } reg120; 377 378 struct { 379 RK_U32 sw_pjpeg_se : 8; 380 RK_U32 sw_pjpeg_ss : 8; 381 RK_U32 sw_pjpeg_al : 4; 382 RK_U32 sw_pjpeg_ah : 4; 383 RK_U32 sw_pjpeg_hdiv8 : 1; 384 RK_U32 sw_pjpeg_wdiv8 : 1; 385 RK_U32 sw_pjpeg_fildown_e : 1; 386 } reg121; 387 388 struct { 389 RK_U32 sw_cb_dc_vlctable3 : 1; 390 RK_U32 sw_cr_dc_vlctable3 : 1; 391 RK_U32 sw_cb_dc_vlctable : 1; 392 RK_U32 sw_cr_dc_vlctable : 1; 393 RK_U32 sw_cb_ac_vlctable : 1; 394 RK_U32 sw_cr_ac_vlctable : 1; 395 RK_U32 sw_jpeg_stream_all : 1; 396 RK_U32 sw_jpeg_filright_e : 1; 397 RK_U32 sw_jpeg_mode : 3; 398 RK_U32 sw_jpeg_qtables : 2; 399 RK_U32 sw_reserved_1 : 12; 400 RK_U32 sw_sync_marker_e : 1; 401 RK_U32 sw_strm_start_bit : 6; 402 } reg122; 403 404 struct { 405 RK_U32 sw_pjpeg_rest_freq : 16; 406 } reg123; 407 408 struct { 409 RK_U32 sw_stream1_len : 24; 410 RK_U32 sw_coeffs_part_am : 4; 411 RK_U32 sw_reserved : 4; 412 } reg124; 413 414 struct { 415 RK_U32 resever : 2; 416 RK_U32 sw_pred_bc_tap_5_3 : 10; 417 RK_U32 sw_pred_bc_tap_5_2 : 10; 418 RK_U32 sw_pred_bc_tap_5_1 : 10; 419 } reg125; 420 421 struct { 422 RK_U32 resever : 2; 423 RK_U32 sw_pred_bc_tap_6_2 : 10; 424 RK_U32 sw_pred_bc_tap_6_1 : 10; 425 RK_U32 sw_pred_bc_tap_6_0 : 10; 426 } reg126; 427 428 struct { 429 RK_U32 resever : 2; 430 RK_U32 sw_pred_bc_tap_7_1 : 10; 431 RK_U32 sw_pred_bc_tap_7_0 : 10; 432 RK_U32 sw_pred_bc_tap_6_3 : 10; 433 } reg127; 434 435 struct { 436 RK_U32 sw_pred_tap_6_4 : 2; 437 RK_U32 sw_pred_tap_6_M1 : 2; 438 RK_U32 sw_pred_tap_4_4 : 2; 439 RK_U32 sw_pred_tap_4_M1 : 2; 440 RK_U32 sw_pred_tap_2_4 : 2; 441 RK_U32 sw_pred_tap_2_M1 : 2; 442 RK_U32 sw_pred_bc_tap_7_3 : 10; 443 RK_U32 sw_pred_bc_tap_7_2 : 10; 444 } reg128; 445 446 struct { 447 RK_U32 sw_filt_level_3 : 6; 448 RK_U32 sw_filt_level_2 : 6; 449 RK_U32 sw_filt_level_1 : 6; 450 RK_U32 sw_filt_level_0 : 6; 451 RK_U32 resever : 8; 452 } reg129; 453 454 struct { 455 RK_U32 sw_quant_1 : 11; 456 RK_U32 sw_quant_0 : 11; 457 RK_U32 sw_quant_delta_1 : 5; 458 RK_U32 sw_quant_delta_0 : 5; 459 } reg130; 460 461 462 RK_U32 reg131_jpg_ch_out_base; 463 464 struct { 465 RK_U32 sw_filt_mb_adj_3 : 7; 466 RK_U32 sw_filt_mb_adj_2 : 7; 467 RK_U32 sw_filt_mb_adj_1 : 7; 468 RK_U32 sw_filt_mb_adj_0 : 7; 469 RK_U32 sw_filt_sharpness : 3; 470 RK_U32 sw_filt_type : 1; 471 } reg132; 472 473 474 struct { 475 RK_U32 sw_filt_ref_adj_3 : 7; 476 RK_U32 sw_filt_ref_adj_2 : 7; 477 RK_U32 sw_filt_ref_adj_1 : 7; 478 RK_U32 sw_filt_ref_adj_0 : 7; 479 RK_U32 sw_reserved : 4; 480 } reg133; 481 482 struct { 483 RK_U32 sw_ac1_code1_cnt : 2; 484 RK_U32 sw_reserved_1 : 1; 485 RK_U32 sw_ac1_code2_cnt : 3; 486 RK_U32 sw_reserved_2 : 1; 487 RK_U32 sw_ac1_code3_cnt : 4; 488 RK_U32 sw_ac1_code4_cnt : 5; 489 RK_U32 sw_ac1_code5_cnt : 6; 490 RK_U32 sw_reserved_3 : 2; 491 RK_U32 sw_ac1_code6_cnt : 7; 492 } reg134; 493 494 struct { 495 RK_U32 sw_ac1_code7_cnt : 8; 496 RK_U32 sw_ac1_code8_cnt : 8; 497 RK_U32 sw_ac1_code9_cnt : 8; 498 RK_U32 sw_ac1_code10_cnt : 8; 499 } reg135; 500 501 struct { 502 RK_U32 sw_ac1_code11_cnt : 8; 503 RK_U32 sw_ac1_code12_cnt : 8; 504 RK_U32 sw_ac1_code13_cnt : 8; 505 RK_U32 sw_ac1_code14_cnt : 8; 506 } reg136; 507 508 struct { 509 RK_U32 sw_ac1_code15_cnt : 8; 510 RK_U32 sw_ac1_code16_cnt : 8; 511 RK_U32 sw_ac2_code1_cnt : 2; 512 RK_U32 sw_reserved_1 : 1; 513 RK_U32 sw_ac2_code2_cnt : 3; 514 RK_U32 sw_reserved_2 : 1; 515 RK_U32 sw_ac2_code3_cnt : 4; 516 RK_U32 sw_ac2_code4_cnt : 5; 517 } reg137; 518 519 struct { 520 RK_U32 sw_ac2_code5_cnt : 6; 521 RK_U32 sw_reserved_1 : 2; 522 RK_U32 sw_ac2_code6_cnt : 7; 523 RK_U32 sw_reserved_2 : 1; 524 RK_U32 sw_ac2_code7_cnt : 8; 525 RK_U32 sw_ac2_code8_cnt : 8; 526 } reg138; 527 528 struct { 529 RK_U32 sw_ac2_code9_cnt : 8; 530 RK_U32 sw_ac2_code10_cnt : 8; 531 RK_U32 sw_ac2_code11_cnt : 8; 532 RK_U32 sw_ac2_code12_cnt : 8; 533 } reg139; 534 535 struct { 536 RK_U32 sw_ac2_code13_cnt : 8; 537 RK_U32 sw_ac2_code14_cnt : 8; 538 RK_U32 sw_ac2_code15_cnt : 8; 539 RK_U32 sw_ac2_code16_cnt : 8; 540 } reg140; 541 542 struct { 543 RK_U32 sw_dc1_code1_cnt : 2; 544 RK_U32 sw_reserved_1 : 2; 545 RK_U32 sw_dc1_code2_cnt : 3; 546 RK_U32 sw_reserved_2 : 1; 547 RK_U32 sw_dc1_code3_cnt : 4; 548 RK_U32 sw_dc1_code4_cnt : 4; 549 RK_U32 sw_dc1_code5_cnt : 4; 550 RK_U32 sw_dc1_code6_cnt : 4; 551 RK_U32 sw_dc1_code7_cnt : 4; 552 RK_U32 sw_dc1_code8_cnt : 4; 553 } reg141; 554 555 struct { 556 RK_U32 sw_dc1_code9_cnt : 4; 557 RK_U32 sw_dc1_code10_cnt : 4; 558 RK_U32 sw_dc1_code11_cnt : 4; 559 RK_U32 sw_dc1_code12_cnt : 4; 560 RK_U32 sw_dc1_code13_cnt : 4; 561 RK_U32 sw_dc1_code14_cnt : 4; 562 RK_U32 sw_dc1_code15_cnt : 4; 563 RK_U32 sw_dc1_code16_cnt : 4; 564 } reg142; 565 566 struct { 567 RK_U32 sw_dc2_code1_cnt : 2; 568 RK_U32 sw_reserved_1 : 2; 569 RK_U32 sw_dc2_code2_cnt : 3; 570 RK_U32 sw_reserved_2 : 1; 571 RK_U32 sw_dc2_code3_cnt : 4; 572 RK_U32 sw_dc2_code4_cnt : 4; 573 RK_U32 sw_dc2_code5_cnt : 4; 574 RK_U32 sw_dc2_code6_cnt : 4; 575 RK_U32 sw_dc2_code7_cnt : 4; 576 RK_U32 sw_dc2_code8_cnt : 4; 577 } reg143; 578 579 struct { 580 RK_U32 sw_dc2_code9_cnt : 4; 581 RK_U32 sw_dc2_code10_cnt : 4; 582 RK_U32 sw_dc2_code11_cnt : 4; 583 RK_U32 sw_dc2_code12_cnt : 4; 584 RK_U32 sw_dc2_code13_cnt : 4; 585 RK_U32 sw_dc2_code14_cnt : 4; 586 RK_U32 sw_dc2_code15_cnt : 4; 587 RK_U32 sw_dc2_code16_cnt : 4; 588 } reg144; 589 590 RK_U32 reg145_bitpl_ctrl_base; 591 RK_U32 reg_dct_strm1_base[2]; 592 593 struct { 594 RK_U32 sw_slice_h : 8; 595 RK_U32 sw_reserved_1 : 12; 596 RK_U32 sw_jpeg_height8_flag : 1; 597 RK_U32 sw_syn_marker_e : 1; 598 RK_U32 sw_reserved_2 : 10; 599 } reg148; 600 601 RK_U32 reg149_segment_map_base; 602 603 struct { 604 RK_U32 sw_dct_start_bit_7 : 6; 605 RK_U32 sw_dct_start_bit_6 : 6; 606 RK_U32 sw_dct_start_bit_5 : 6; 607 RK_U32 sw_dct_start_bit_4 : 6; 608 RK_U32 sw_dct_start_bit_3 : 6; 609 RK_U32 sw_reserved : 2; 610 } reg150; 611 612 struct { 613 RK_U32 sw_quant_3 : 11; 614 RK_U32 sw_quant_2 : 11; 615 RK_U32 sw_quant_delta_3 : 5; 616 RK_U32 sw_quant_delta_2 : 5; 617 } reg151; 618 619 struct { 620 RK_U32 sw_quant_5 : 11; 621 RK_U32 sw_quant_4 : 11; 622 RK_U32 sw_quant_delta_4 : 5; 623 RK_U32 sw_reserved : 5; 624 } reg152; 625 626 struct { 627 RK_U32 resever : 2; 628 RK_U32 sw_pred_bc_tap_1_1 : 10; 629 RK_U32 sw_pred_bc_tap_1_0 : 10; 630 RK_U32 sw_pred_bc_tap_0_3 : 10; 631 } reg153; 632 633 struct { 634 RK_U32 resever : 2; 635 RK_U32 sw_pred_bc_tap_2_0 : 10; 636 RK_U32 sw_pred_bc_tap_1_3 : 10; 637 RK_U32 sw_pred_bc_tap_1_2 : 10; 638 } reg154; 639 640 struct { 641 RK_U32 resever : 2; 642 RK_U32 sw_pred_bc_tap_2_3 : 10; 643 RK_U32 sw_pred_bc_tap_2_2 : 10; 644 RK_U32 sw_pred_bc_tap_2_1 : 10; 645 } reg155; 646 647 struct { 648 RK_U32 resever : 2; 649 RK_U32 sw_pred_bc_tap_3_2 : 10; 650 RK_U32 sw_pred_bc_tap_3_1 : 10; 651 RK_U32 sw_pred_bc_tap_3_0 : 10; 652 } reg156; 653 654 struct { 655 RK_U32 resever : 2; 656 RK_U32 sw_pred_bc_tap_4_1 : 10; 657 RK_U32 sw_pred_bc_tap_4_0 : 10; 658 RK_U32 sw_pred_bc_tap_3_3 : 10; 659 } reg157; 660 661 struct { 662 RK_U32 resever : 2; 663 RK_U32 sw_pred_bc_tap_5_0 : 10; 664 RK_U32 sw_pred_bc_tap_4_3 : 10; 665 RK_U32 sw_pred_bc_tap_4_2 : 10; 666 } reg158; 667 } JpegRegSet; 668 669 typedef struct JpegdIocRegInfo_t { 670 JpegRegSet regs; 671 672 /* vepu_reg_num - vdpu_reg_num */ 673 RK_U32 regs_diff[184 - JPEGD_REG_NUM]; 674 RK_U8 extra_info[EXTRA_INFO_SIZE]; 675 } JpegdIocRegInfo; 676 677 #endif /* __HAL_JPEGD_VDPU2_REG_H__ */ 678