xref: /rockchip-linux_mpp/mpp/hal/rkdec/avsd/hal_avsd_vdpu1_reg.h (revision 437bfbeb9567cca9cd9080e3f6954aa9d6a94f18)
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_AVSD_VDPU1_REG_H__
18 #define __HAL_AVSD_VDPU1_REG_H__
19 
20 
21 typedef struct {
22     RK_U32 sw00;
23     struct {
24         RK_U32 dec_e : 1;
25         RK_U32 reserve0 : 3;
26         RK_U32 dec_irq_dis : 1;
27         RK_U32 dec_abort_e : 1;
28         RK_U32 reserve1 : 2;
29         RK_U32 dec_irq : 1;
30         RK_U32 reserve2 : 2;
31         RK_U32 dec_abort_int : 1;
32         RK_U32 dec_rdy_int : 1;
33         RK_U32 dec_bus_int : 1;
34         RK_U32 dec_buffer_int : 1;
35         RK_U32 reserve3 : 1;
36         RK_U32 dec_error_int : 1;
37         RK_U32 reserve4 : 1;
38         RK_U32 dec_timeout : 1;
39         RK_U32 reserve5 : 5;
40         RK_U32 dec_pic_inf : 1;
41         RK_U32 reserve6 : 7;
42     } sw01;
43     union {
44         struct {
45             RK_U32 dec_max_burst : 5;
46             RK_U32 dec_scmd_dis : 1;
47             RK_U32 dec_adv_pre_dis : 1;
48             RK_U32 tiled_mode_lsb : 1;
49             RK_U32 dec_out_endian : 1;
50             RK_U32 dec_in_endian : 1;
51             RK_U32 dec_clk_gate_e : 1;
52             RK_U32 dec_latency : 6;
53             RK_U32 dec_out_tiled_e : 1;
54             RK_U32 dec_data_disc_e : 1;
55             RK_U32 dec_outswap32_e : 1;
56             RK_U32 dec_inswap32_e : 1;
57             RK_U32 dec_strendian_e : 1;
58             RK_U32 dec_strswap32_e : 1;
59             RK_U32 dec_timeout_e : 1;
60             RK_U32 dec_axi_rd_id : 8;
61         };
62         struct {
63             RK_U32 reserve0 : 5;
64             RK_U32 priority_mode : 3;
65             RK_U32 reserve1 : 9;
66             RK_U32 tiled_mode_msb : 1;
67             RK_U32 dec_2chan_dis : 1;
68             RK_U32 reserve2 : 13;
69         };
70     } sw02;
71     struct {
72         RK_U32 dec_axi_wr_id : 8;
73         RK_U32 dec_ahb_hlock_e : 1;
74         RK_U32 picord_count_e : 1;
75         RK_U32 reserve0 : 1;
76         RK_U32 reftopfirst_e : 1;
77         RK_U32 write_mvs_e : 1;
78         RK_U32 pic_fixed_quant : 1;
79         RK_U32 filtering_dis : 1;
80         RK_U32 dec_out_dis : 1;
81         RK_U32 ref_topfield_e : 1;
82         RK_U32 reserve1 : 1;
83         RK_U32 fwd_interlace_e : 1;
84         RK_U32 pic_topfiled_e : 1;
85         RK_U32 pic_inter_e : 1;
86         RK_U32 pic_b_e : 1;
87         RK_U32 pic_fieldmode_e : 1;
88         RK_U32 pic_interlace_e : 1;
89         RK_U32 reserve2 : 2;
90         RK_U32 skip_mode : 1;
91         RK_U32 rlc_mode_e : 1;
92         RK_U32 dec_mode : 4;
93     } sw03;
94     struct {
95         RK_U32 pic_refer_flag : 1;
96         RK_U32 reverse0 : 10;
97         RK_U32 pic_mb_height_p : 8;
98         RK_U32 mb_width_off : 4;
99         RK_U32 pic_mb_width : 9;
100     } sw04;
101     union {
102         struct {
103             RK_U32 fieldpic_flag_e : 1;
104             RK_S32 reserve0 : 31;
105         };
106         struct {
107             RK_U32 beta_offset : 5;
108             RK_U32 alpha_offset : 5;
109             RK_U32 reserve1 : 16;
110             RK_U32 strm_start_bit : 6;
111         };
112     } sw05;
113     struct {
114         RK_U32 stream_len : 24;
115         RK_U32 stream_len_ext : 1;
116         RK_U32 init_qp : 6;
117         RK_U32 start_code_e : 1;
118     } sw06;
119     RK_U32 sw07_11[5];
120     struct {
121         RK_U32 rlc_vlc_base : 32;
122     } sw12;
123     struct {
124         RK_U32 dec_out_base : 32;
125     } sw13;
126     union {
127         RK_U32 refer0_base : 32;
128         struct { //!< left move 10bit
129             RK_U32 reserve0 : 10;
130             RK_U32 refer0_topc_e : 1;
131             RK_U32 refer0_field_e : 1;
132             RK_U32 reserve1 : 20;
133         };
134     } sw14;
135     union {
136         struct {
137             RK_U32 refer1_base : 32;
138         };
139         struct { //!< left move 10bit
140             RK_U32 reserve0 : 10;
141             RK_U32 refer1_topc_e : 1;
142             RK_U32 refer1_field_e : 1;
143             RK_U32 reserve1 : 20;
144         };
145     } sw15;
146     union {
147         struct {
148             RK_U32 refer2_base : 32;
149         };
150         struct { //!< left move 10bit
151             RK_U32 reserve0 : 10;
152             RK_U32 refer2_topc_e : 1;
153             RK_U32 refer2_field_e : 1;
154             RK_U32 reserve1 : 20;
155         };
156     } sw16;
157     union {
158         struct {
159             RK_U32 refer3_base : 32;
160         };
161         struct { //!< left move 10bit
162             RK_U32 reserve0 : 10;
163             RK_U32 refer3_topc_e : 1;
164             RK_U32 refer3_field_e : 1;
165             RK_U32 reserve1 : 20;
166         };
167     } sw17;
168     struct {
169         RK_U32 prev_anc_type : 1;
170         RK_U32 reverse0 : 31;
171     } sw18;
172     RK_U32 sw19_27[9];
173     struct {
174         RK_U32 ref_invd_cur_0 : 16;
175         RK_U32 ref_invd_cur_1 : 16;
176     } sw28;
177     struct {
178         RK_U32 ref_invd_cur_2 : 16;
179         RK_U32 ref_invd_cur_3 : 16;
180     } sw29;
181     struct {
182         RK_U32 ref_dist_cur_0 : 16;
183         RK_U32 ref_dist_cur_1 : 16;
184     } sw30;
185     struct {
186         RK_U32 ref_dist_cur_2 : 16;
187         RK_U32 ref_dist_cur_3 : 16;
188     } sw31;
189     struct {
190         RK_U32 ref_invd_col_0 : 16;
191         RK_U32 ref_invd_col_1 : 16;
192     } sw32;
193     struct {
194         RK_U32 ref_invd_col_2 : 16;
195         RK_U32 ref_invd_col_3 : 16;
196     } sw33;
197     struct {
198         RK_U32 reserve0 : 2;
199         RK_U32 pred_bc_tap_1_1 : 10;
200         RK_U32 pred_bc_tap_1_0 : 10;
201         RK_U32 pred_bc_tap_0_3 : 10;
202     } sw34;
203     struct {
204         RK_U32 reserve0 : 12;
205         RK_U32 pred_bc_tap_1_3 : 10;
206         RK_U32 pred_bc_tap_1_2 : 10;
207     } sw35;
208     RK_U32 sw36_40[5];
209     struct {
210         RK_U32 dir_mv_base : 32;
211     } sw41;
212     RK_U32 sw42_47[6];
213     struct {
214         RK_U32 reserve0 : 14;
215         RK_U32 startmb_y : 9;
216         RK_U32 startmb_x : 9;
217     } sw48;
218     struct {
219         RK_U32 reserve0 : 2;
220         RK_U32 pred_bc_tap_0_2 : 10;
221         RK_U32 pred_bc_tap_0_1 : 10;
222         RK_U32 pred_bc_tap_0_0 : 10;
223     } sw49;
224     RK_U32 sw50_54[5];
225     struct {
226         RK_U32 apf_threshold : 14;
227         RK_U32 refbu2_picid : 5;
228         RK_U32 refbu2_thr : 12;
229         RK_U32 refbu2_buf_e : 1;
230     } sw55;
231     RK_U32 sw56;
232     struct {
233         RK_U32 stream_len_ext : 1;
234         RK_U32 inter_dblspeed : 1;
235         RK_U32 intra_dblspeed : 1;
236         RK_U32 intra_dbl3t : 1;
237         RK_U32 bus_pos_sel : 1;
238         RK_U32 axi_sel : 1;
239         RK_U32 pref_sigchan : 1;
240         RK_U32 cache_en : 1;
241         RK_U32 reserve : 24;
242     } sw57;
243     RK_U32 sw58_59[2];
244     RK_U32 resever[40];
245 } AvsdVdpu1Regs_t;
246 
247 #endif /*__HAL_AVSD_VDPU1_REG_H__*/
248