Home | History | Annotate | Download | only in amdgpu
      1 /*
      2  * Copyright 2015 Advanced Micro Devices, Inc.
      3  *
      4  * Permission is hereby granted, free of charge, to any person obtaining a
      5  * copy of this software and associated documentation files (the "Software"),
      6  * to deal in the Software without restriction, including without limitation
      7  * the rights to use, copy, modify, merge, publish, distribute, sublicense,
      8  * and/or sell copies of the Software, and to permit persons to whom the
      9  * Software is furnished to do so, subject to the following conditions:
     10  *
     11  * The above copyright notice and this permission notice shall be included in
     12  * all copies or substantial portions of the Software.
     13  *
     14  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
     15  * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
     16  * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
     17  * THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR
     18  * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
     19  * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
     20  * OTHER DEALINGS IN THE SOFTWARE.
     21  *
     22 */
     23 
     24 #ifndef _vce_ib_h_
     25 #define _vce_ib_h_
     26 
     27 static const uint32_t vce_session[] = {
     28 	0x0000000c,
     29 	0x00000001,
     30 	0x400c0001,
     31 };
     32 
     33 static uint32_t vce_taskinfo[8] = {
     34 	0x00000020,
     35 	0x00000002,
     36 	0xffffffff,
     37 	0x00000000,
     38 	0x00000000,
     39 	0x00000000,
     40 	0x00000000,
     41 	0x00000000,
     42 };
     43 
     44 static const uint32_t vce_create[] = {
     45 	0x00000030,
     46 	0x01000001,
     47 	0x00000000,
     48 	0x00000042,
     49 	0x0000002a,
     50 	0x00000000,
     51 	0x000000a0,
     52 	0x00000080,
     53 	0x000000a0,
     54 	0x000000a0,
     55 	0x00000010,
     56 	0x00000201,
     57 };
     58 
     59 static const uint32_t vce_rate_ctrl[] = {
     60 	0x00000070,
     61 	0x04000005,
     62 	0x00000000,
     63 	0x00000000,
     64 	0x00000000,
     65 	0x00000000,
     66 	0x00000000,
     67 	0x0000001c,
     68 	0x0000001c,
     69 	0x00000000,
     70 	0x00000000,
     71 	0x00000000,
     72 	0x00000000,
     73 	0x00000000,
     74 	0x00000000,
     75 	0x00000000,
     76 	0x00000000,
     77 	0x00000000,
     78 	0x00000000,
     79 	0x00000033,
     80 	0x00000000,
     81 	0x00000000,
     82 	0x00000000,
     83 	0x00000000,
     84 	0x00000000,
     85 	0x00000000,
     86 	0x00000000,
     87 	0x00000000,
     88 };
     89 
     90 static const uint32_t vce_config_ext[] = {
     91 	0x0000000c,
     92 	0x04000001,
     93 	0x00000003,
     94 };
     95 
     96 static const uint32_t vce_motion_est[] = {
     97 	0x00000068,
     98 	0x04000007,
     99 	0x00000001,
    100 	0x00000001,
    101 	0x00000000,
    102 	0x00000000,
    103 	0x00000000,
    104 	0x00000000,
    105 	0x00000010,
    106 	0x00000010,
    107 	0x00000010,
    108 	0x00000010,
    109 	0x00000000,
    110 	0x00000000,
    111 	0x00000000,
    112 	0x000000fe,
    113 	0x00000000,
    114 	0x00000000,
    115 	0x00000000,
    116 	0x00000000,
    117 	0x00000001,
    118 	0x00000001,
    119 	0x00000000,
    120 	0x00000000,
    121 	0x00000000,
    122 	0x00000000,
    123 };
    124 
    125 static const uint32_t vce_rdo[] = {
    126 	0x0000004c,
    127 	0x04000008,
    128 	0x00000000,
    129 	0x00000000,
    130 	0x00000000,
    131 	0x00000000,
    132 	0x00000000,
    133 	0x00000000,
    134 	0x00000000,
    135 	0x00000000,
    136 	0x00000000,
    137 	0x00000000,
    138 	0x00000000,
    139 	0x00000000,
    140 	0x00000000,
    141 	0x00000000,
    142 	0x00000000,
    143 	0x00000000,
    144 	0x00000000,
    145 };
    146 
    147 static const uint32_t vce_pic_ctrl[] = {
    148 	0x00000074,
    149 	0x04000002,
    150 	0x00000000,
    151 	0x00000000,
    152 	0x00000000,
    153 	0x00000000,
    154 	0x00000000,
    155 	0x00000000,
    156 	0x00000000,
    157 	0x00000000,
    158 	0x00000000,
    159 	0x00000000,
    160 	0x00000aa0,
    161 	0x00000000,
    162 	0x00000000,
    163 	0x00000000,
    164 	0x00000000,
    165 	0x00000000,
    166 	0x00000000,
    167 	0x00000000,
    168 	0x00000040,
    169 	0x00000000,
    170 	0x00000000,
    171 	0x00000001,
    172 	0x00000002,
    173 	0x00000001,
    174 	0x00000001,
    175 	0x00000000,
    176 	0x00000000,
    177 };
    178 
    179 static const uint32_t vce_feedback[] = {
    180 	0x00000014,
    181 	0x05000005,
    182 	0x00000000,
    183 	0xffffffff,
    184 	0x00000001,
    185 };
    186 
    187 static const uint32_t vce_context_buffer[] = {
    188 	0x00000010,
    189 	0x05000001,
    190 	0x00000000,
    191 	0xffffffff,
    192 };
    193 
    194 static const uint32_t vce_bs_buffer[] = {
    195 	0x00000014,
    196 	0x05000004,
    197 	0x00000000,
    198 	0xffffffff,
    199 	0x00154000,
    200 };
    201 
    202 static const uint32_t vce_aux_buffer[] = {
    203 	0x00000048,
    204 	0x05000002,
    205 	0x0000f000,
    206 	0x00016800,
    207 	0x0001e000,
    208 	0x00025800,
    209 	0x0002d000,
    210 	0x00034800,
    211 	0x0003c000,
    212 	0x00043800,
    213 	0x00007800,
    214 	0x00007800,
    215 	0x00007800,
    216 	0x00007800,
    217 	0x00007800,
    218 	0x00007800,
    219 	0x00007800,
    220 	0x00007800,
    221 };
    222 
    223 static uint32_t vce_encode[88] = {
    224 	0x00000160,
    225 	0x03000001,
    226 	0x00000011,
    227 	0x00000000,
    228 	0x00154000,
    229 	0x00000000,
    230 	0x00000000,
    231 	0x00000000,
    232 	0x00000000,
    233 	0x00000000,
    234 	0xffffffff,
    235 	0x00000000,
    236 	0xffffffff,
    237 	0x00000080,
    238 	0x000000a0,
    239 	0x000000a0,
    240 	0x00010000,
    241 	0x00000000,
    242 	0x00000003,
    243 	0x00000001,
    244 	0x00000000,
    245 	0x00000000,
    246 	0x00000001,
    247 	0x00000000,
    248 	0x00000000,
    249 	0x00000000,
    250 	0x00000000,
    251 	0x00000000,
    252 	0x00000000,
    253 	0x00000000,
    254 	0x00000000,
    255 	0x00000000,
    256 	0x00000000,
    257 	0x00000000,
    258 	0x00000000,
    259 	0x00000000,
    260 	0x00000000,
    261 	0x00000000,
    262 	0x00000000,
    263 	0x00000000,
    264 	0x00000000,
    265 	0x00000000,
    266 	0x00000000,
    267 	0x00000000,
    268 	0x00000000,
    269 	0x00000000,
    270 	0x00000000,
    271 	0x00000000,
    272 	0x00000000,
    273 	0x00000000,
    274 	0x00000000,
    275 	0x00000000,
    276 	0x00000000,
    277 	0x00000000,
    278 	0x00000000,
    279 	0x00000000,
    280 	0x00000000,
    281 	0x00000000,
    282 	0x00000000,
    283 	0xffffffff,
    284 	0xffffffff,
    285 	0x00000000,
    286 	0x00000000,
    287 	0x00000000,
    288 	0x00000000,
    289 	0xffffffff,
    290 	0xffffffff,
    291 	0x00000000,
    292 	0x00000000,
    293 	0x00000000,
    294 	0x00000000,
    295 	0xffffffff,
    296 	0xffffffff,
    297 	0xffffffff,
    298 	0xffffffff,
    299 	0x00000000,
    300 	0x00000000,
    301 	0x00000000,
    302 	0x00000000,
    303 	0x00000000,
    304 	0x00000000,
    305 	0x00000000,
    306 	0x00000000,
    307 	0x00000000,
    308 	0x00000000,
    309 	0x00000000,
    310 	0x00000000,
    311 	0x00000000,
    312 };
    313 
    314 static const uint32_t vce_destroy[] = {
    315 	0x00000008,
    316 	0x02000001,
    317 };
    318 #endif /*_vce_ib_h*/
    319