Back to home page

OSCL-LXR

 
 

    


0001 /*
0002  * Copyright 2014 Advanced Micro Devices, Inc.
0003  *
0004  * Permission is hereby granted, free of charge, to any person obtaining a
0005  * copy of this software and associated documentation files (the "Software"),
0006  * to deal in the Software without restriction, including without limitation
0007  * the rights to use, copy, modify, merge, publish, distribute, sublicense,
0008  * and/or sell copies of the Software, and to permit persons to whom the
0009  * Software is furnished to do so, subject to the following conditions:
0010  *
0011  * The above copyright notice and this permission notice shall be included in
0012  * all copies or substantial portions of the Software.
0013  *
0014  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
0015  * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
0016  * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
0017  * THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR
0018  * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
0019  * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
0020  * OTHER DEALINGS IN THE SOFTWARE.
0021  *
0022  */
0023 #ifndef SOC15_H
0024 #define SOC15_H
0025 
0026 #define GFX9_NUM_GFX_RINGS     1
0027 #define GFX9_NUM_COMPUTE_RINGS 8
0028 
0029 /*
0030  * PM4
0031  */
0032 #define PACKET_TYPE0    0
0033 #define PACKET_TYPE1    1
0034 #define PACKET_TYPE2    2
0035 #define PACKET_TYPE3    3
0036 
0037 #define CP_PACKET_GET_TYPE(h) (((h) >> 30) & 3)
0038 #define CP_PACKET_GET_COUNT(h) (((h) >> 16) & 0x3FFF)
0039 #define CP_PACKET0_GET_REG(h) ((h) & 0xFFFF)
0040 #define CP_PACKET3_GET_OPCODE(h) (((h) >> 8) & 0xFF)
0041 #define PACKET0(reg, n) ((PACKET_TYPE0 << 30) |             \
0042              ((reg) & 0xFFFF) |         \
0043              ((n) & 0x3FFF) << 16)
0044 #define CP_PACKET2          0x80000000
0045 #define     PACKET2_PAD_SHIFT       0
0046 #define     PACKET2_PAD_MASK        (0x3fffffff << 0)
0047 
0048 #define PACKET2(v)  (CP_PACKET2 | REG_SET(PACKET2_PAD, (v)))
0049 
0050 #define PACKET3(op, n)  ((PACKET_TYPE3 << 30) |             \
0051              (((op) & 0xFF) << 8) |             \
0052              ((n) & 0x3FFF) << 16)
0053 
0054 #define PACKET3_COMPUTE(op, n) (PACKET3(op, n) | 1 << 1)
0055 
0056 #define PACKETJ_CONDITION_CHECK0    0
0057 #define PACKETJ_CONDITION_CHECK1    1
0058 #define PACKETJ_CONDITION_CHECK2    2
0059 #define PACKETJ_CONDITION_CHECK3    3
0060 #define PACKETJ_CONDITION_CHECK4    4
0061 #define PACKETJ_CONDITION_CHECK5    5
0062 #define PACKETJ_CONDITION_CHECK6    6
0063 #define PACKETJ_CONDITION_CHECK7    7
0064 
0065 #define PACKETJ_TYPE0   0
0066 #define PACKETJ_TYPE1   1
0067 #define PACKETJ_TYPE2   2
0068 #define PACKETJ_TYPE3   3
0069 #define PACKETJ_TYPE4   4
0070 #define PACKETJ_TYPE5   5
0071 #define PACKETJ_TYPE6   6
0072 #define PACKETJ_TYPE7   7
0073 
0074 #define PACKETJ(reg, r, cond, type) ((reg & 0x3FFFF) |          \
0075              ((r & 0x3F) << 18) |           \
0076              ((cond & 0xF) << 24) |             \
0077              ((type & 0xF) << 28))
0078 
0079 /* Packet 3 types */
0080 #define PACKET3_NOP                 0x10
0081 #define PACKET3_SET_BASE                0x11
0082 #define     PACKET3_BASE_INDEX(x)                  ((x) << 0)
0083 #define         CE_PARTITION_BASE       3
0084 #define PACKET3_CLEAR_STATE             0x12
0085 #define PACKET3_INDEX_BUFFER_SIZE           0x13
0086 #define PACKET3_DISPATCH_DIRECT             0x15
0087 #define PACKET3_DISPATCH_INDIRECT           0x16
0088 #define PACKET3_ATOMIC_GDS              0x1D
0089 #define PACKET3_ATOMIC_MEM              0x1E
0090 #define PACKET3_OCCLUSION_QUERY             0x1F
0091 #define PACKET3_SET_PREDICATION             0x20
0092 #define PACKET3_REG_RMW                 0x21
0093 #define PACKET3_COND_EXEC               0x22
0094 #define PACKET3_PRED_EXEC               0x23
0095 #define PACKET3_DRAW_INDIRECT               0x24
0096 #define PACKET3_DRAW_INDEX_INDIRECT         0x25
0097 #define PACKET3_INDEX_BASE              0x26
0098 #define PACKET3_DRAW_INDEX_2                0x27
0099 #define PACKET3_CONTEXT_CONTROL             0x28
0100 #define PACKET3_INDEX_TYPE              0x2A
0101 #define PACKET3_DRAW_INDIRECT_MULTI         0x2C
0102 #define PACKET3_DRAW_INDEX_AUTO             0x2D
0103 #define PACKET3_NUM_INSTANCES               0x2F
0104 #define PACKET3_DRAW_INDEX_MULTI_AUTO           0x30
0105 #define PACKET3_INDIRECT_BUFFER_CONST           0x33
0106 #define PACKET3_STRMOUT_BUFFER_UPDATE           0x34
0107 #define PACKET3_DRAW_INDEX_OFFSET_2         0x35
0108 #define PACKET3_DRAW_PREAMBLE               0x36
0109 #define PACKET3_WRITE_DATA              0x37
0110 #define     WRITE_DATA_DST_SEL(x)                   ((x) << 8)
0111         /* 0 - register
0112          * 1 - memory (sync - via GRBM)
0113          * 2 - gl2
0114          * 3 - gds
0115          * 4 - reserved
0116          * 5 - memory (async - direct)
0117          */
0118 #define     WR_ONE_ADDR                             (1 << 16)
0119 #define     WR_CONFIRM                              (1 << 20)
0120 #define     WRITE_DATA_CACHE_POLICY(x)              ((x) << 25)
0121         /* 0 - LRU
0122          * 1 - Stream
0123          */
0124 #define     WRITE_DATA_ENGINE_SEL(x)                ((x) << 30)
0125         /* 0 - me
0126          * 1 - pfp
0127          * 2 - ce
0128          */
0129 #define PACKET3_DRAW_INDEX_INDIRECT_MULTI       0x38
0130 #define PACKET3_MEM_SEMAPHORE               0x39
0131 #              define PACKET3_SEM_USE_MAILBOX       (0x1 << 16)
0132 #              define PACKET3_SEM_SEL_SIGNAL_TYPE   (0x1 << 20) /* 0 = increment, 1 = write 1 */
0133 #              define PACKET3_SEM_SEL_SIGNAL        (0x6 << 29)
0134 #              define PACKET3_SEM_SEL_WAIT      (0x7 << 29)
0135 #define PACKET3_WAIT_REG_MEM                0x3C
0136 #define     WAIT_REG_MEM_FUNCTION(x)                ((x) << 0)
0137         /* 0 - always
0138          * 1 - <
0139          * 2 - <=
0140          * 3 - ==
0141          * 4 - !=
0142          * 5 - >=
0143          * 6 - >
0144          */
0145 #define     WAIT_REG_MEM_MEM_SPACE(x)               ((x) << 4)
0146         /* 0 - reg
0147          * 1 - mem
0148          */
0149 #define     WAIT_REG_MEM_OPERATION(x)               ((x) << 6)
0150         /* 0 - wait_reg_mem
0151          * 1 - wr_wait_wr_reg
0152          */
0153 #define     WAIT_REG_MEM_ENGINE(x)                  ((x) << 8)
0154         /* 0 - me
0155          * 1 - pfp
0156          */
0157 #define PACKET3_INDIRECT_BUFFER             0x3F
0158 #define     INDIRECT_BUFFER_VALID                   (1 << 23)
0159 #define     INDIRECT_BUFFER_CACHE_POLICY(x)         ((x) << 28)
0160         /* 0 - LRU
0161          * 1 - Stream
0162          * 2 - Bypass
0163          */
0164 #define     INDIRECT_BUFFER_PRE_ENB(x)       ((x) << 21)
0165 #define PACKET3_COPY_DATA               0x40
0166 #define PACKET3_PFP_SYNC_ME             0x42
0167 #define PACKET3_COND_WRITE              0x45
0168 #define PACKET3_EVENT_WRITE             0x46
0169 #define     EVENT_TYPE(x)                           ((x) << 0)
0170 #define     EVENT_INDEX(x)                          ((x) << 8)
0171         /* 0 - any non-TS event
0172          * 1 - ZPASS_DONE, PIXEL_PIPE_STAT_*
0173          * 2 - SAMPLE_PIPELINESTAT
0174          * 3 - SAMPLE_STREAMOUTSTAT*
0175          * 4 - *S_PARTIAL_FLUSH
0176          */
0177 #define PACKET3_RELEASE_MEM             0x49
0178 #define     EVENT_TYPE(x)                           ((x) << 0)
0179 #define     EVENT_INDEX(x)                          ((x) << 8)
0180 #define     EOP_TCL1_VOL_ACTION_EN                  (1 << 12)
0181 #define     EOP_TC_VOL_ACTION_EN                    (1 << 13) /* L2 */
0182 #define     EOP_TC_WB_ACTION_EN                     (1 << 15) /* L2 */
0183 #define     EOP_TCL1_ACTION_EN                      (1 << 16)
0184 #define     EOP_TC_ACTION_EN                        (1 << 17) /* L2 */
0185 #define     EOP_TC_NC_ACTION_EN         (1 << 19)
0186 #define     EOP_TC_MD_ACTION_EN         (1 << 21) /* L2 metadata */
0187 
0188 #define     DATA_SEL(x)                             ((x) << 29)
0189         /* 0 - discard
0190          * 1 - send low 32bit data
0191          * 2 - send 64bit data
0192          * 3 - send 64bit GPU counter value
0193          * 4 - send 64bit sys counter value
0194          */
0195 #define     INT_SEL(x)                              ((x) << 24)
0196         /* 0 - none
0197          * 1 - interrupt only (DATA_SEL = 0)
0198          * 2 - interrupt when data write is confirmed
0199          */
0200 #define     DST_SEL(x)                              ((x) << 16)
0201         /* 0 - MC
0202          * 1 - TC/L2
0203          */
0204 
0205 
0206 
0207 #define PACKET3_PREAMBLE_CNTL               0x4A
0208 #              define PACKET3_PREAMBLE_BEGIN_CLEAR_STATE     (2 << 28)
0209 #              define PACKET3_PREAMBLE_END_CLEAR_STATE       (3 << 28)
0210 #define PACKET3_DMA_DATA                0x50
0211 /* 1. header
0212  * 2. CONTROL
0213  * 3. SRC_ADDR_LO or DATA [31:0]
0214  * 4. SRC_ADDR_HI [31:0]
0215  * 5. DST_ADDR_LO [31:0]
0216  * 6. DST_ADDR_HI [7:0]
0217  * 7. COMMAND [30:21] | BYTE_COUNT [20:0]
0218  */
0219 /* CONTROL */
0220 #              define PACKET3_DMA_DATA_ENGINE(x)     ((x) << 0)
0221         /* 0 - ME
0222          * 1 - PFP
0223          */
0224 #              define PACKET3_DMA_DATA_SRC_CACHE_POLICY(x) ((x) << 13)
0225         /* 0 - LRU
0226          * 1 - Stream
0227          */
0228 #              define PACKET3_DMA_DATA_DST_SEL(x)  ((x) << 20)
0229         /* 0 - DST_ADDR using DAS
0230          * 1 - GDS
0231          * 3 - DST_ADDR using L2
0232          */
0233 #              define PACKET3_DMA_DATA_DST_CACHE_POLICY(x) ((x) << 25)
0234         /* 0 - LRU
0235          * 1 - Stream
0236          */
0237 #              define PACKET3_DMA_DATA_SRC_SEL(x)  ((x) << 29)
0238         /* 0 - SRC_ADDR using SAS
0239          * 1 - GDS
0240          * 2 - DATA
0241          * 3 - SRC_ADDR using L2
0242          */
0243 #              define PACKET3_DMA_DATA_CP_SYNC     (1 << 31)
0244 /* COMMAND */
0245 #              define PACKET3_DMA_DATA_CMD_SAS     (1 << 26)
0246         /* 0 - memory
0247          * 1 - register
0248          */
0249 #              define PACKET3_DMA_DATA_CMD_DAS     (1 << 27)
0250         /* 0 - memory
0251          * 1 - register
0252          */
0253 #              define PACKET3_DMA_DATA_CMD_SAIC    (1 << 28)
0254 #              define PACKET3_DMA_DATA_CMD_DAIC    (1 << 29)
0255 #              define PACKET3_DMA_DATA_CMD_RAW_WAIT  (1 << 30)
0256 #define PACKET3_ACQUIRE_MEM             0x58
0257 /* 1.  HEADER
0258  * 2.  COHER_CNTL [30:0]
0259  * 2.1 ENGINE_SEL [31:31]
0260  * 3.  COHER_SIZE [31:0]
0261  * 4.  COHER_SIZE_HI [7:0]
0262  * 5.  COHER_BASE_LO [31:0]
0263  * 6.  COHER_BASE_HI [23:0]
0264  * 7.  POLL_INTERVAL [15:0]
0265  */
0266 /* COHER_CNTL fields for CP_COHER_CNTL */
0267 #define     PACKET3_ACQUIRE_MEM_CP_COHER_CNTL_TC_NC_ACTION_ENA(x) ((x) << 3)
0268 #define     PACKET3_ACQUIRE_MEM_CP_COHER_CNTL_TC_WC_ACTION_ENA(x) ((x) << 4)
0269 #define     PACKET3_ACQUIRE_MEM_CP_COHER_CNTL_TC_INV_METADATA_ACTION_ENA(x) ((x) << 5)
0270 #define     PACKET3_ACQUIRE_MEM_CP_COHER_CNTL_TCL1_VOL_ACTION_ENA(x) ((x) << 15)
0271 #define     PACKET3_ACQUIRE_MEM_CP_COHER_CNTL_TC_WB_ACTION_ENA(x) ((x) << 18)
0272 #define     PACKET3_ACQUIRE_MEM_CP_COHER_CNTL_TCL1_ACTION_ENA(x) ((x) << 22)
0273 #define     PACKET3_ACQUIRE_MEM_CP_COHER_CNTL_TC_ACTION_ENA(x) ((x) << 23)
0274 #define     PACKET3_ACQUIRE_MEM_CP_COHER_CNTL_CB_ACTION_ENA(x) ((x) << 25)
0275 #define     PACKET3_ACQUIRE_MEM_CP_COHER_CNTL_DB_ACTION_ENA(x) ((x) << 26)
0276 #define     PACKET3_ACQUIRE_MEM_CP_COHER_CNTL_SH_KCACHE_ACTION_ENA(x) ((x) << 27)
0277 #define     PACKET3_ACQUIRE_MEM_CP_COHER_CNTL_SH_KCACHE_VOL_ACTION_ENA(x) ((x) << 28)
0278 #define     PACKET3_ACQUIRE_MEM_CP_COHER_CNTL_SH_ICACHE_ACTION_ENA(x) ((x) << 29)
0279 #define     PACKET3_ACQUIRE_MEM_CP_COHER_CNTL_SH_KCACHE_WB_ACTION_ENA(x) ((x) << 30)
0280 #define PACKET3_REWIND                  0x59
0281 #define PACKET3_LOAD_UCONFIG_REG            0x5E
0282 #define PACKET3_LOAD_SH_REG             0x5F
0283 #define PACKET3_LOAD_CONFIG_REG             0x60
0284 #define PACKET3_LOAD_CONTEXT_REG            0x61
0285 #define PACKET3_SET_CONFIG_REG              0x68
0286 #define     PACKET3_SET_CONFIG_REG_START            0x00002000
0287 #define     PACKET3_SET_CONFIG_REG_END          0x00002c00
0288 #define PACKET3_SET_CONTEXT_REG             0x69
0289 #define     PACKET3_SET_CONTEXT_REG_START           0x0000a000
0290 #define     PACKET3_SET_CONTEXT_REG_END         0x0000a400
0291 #define PACKET3_SET_CONTEXT_REG_INDIRECT        0x73
0292 #define PACKET3_SET_SH_REG              0x76
0293 #define     PACKET3_SET_SH_REG_START            0x00002c00
0294 #define     PACKET3_SET_SH_REG_END              0x00003000
0295 #define PACKET3_SET_SH_REG_OFFSET           0x77
0296 #define PACKET3_SET_QUEUE_REG               0x78
0297 #define PACKET3_SET_UCONFIG_REG             0x79
0298 #define     PACKET3_SET_UCONFIG_REG_START           0x0000c000
0299 #define     PACKET3_SET_UCONFIG_REG_END         0x0000c400
0300 #define     PACKET3_SET_UCONFIG_REG_INDEX_TYPE      (2 << 28)
0301 #define PACKET3_SCRATCH_RAM_WRITE           0x7D
0302 #define PACKET3_SCRATCH_RAM_READ            0x7E
0303 #define PACKET3_LOAD_CONST_RAM              0x80
0304 #define PACKET3_WRITE_CONST_RAM             0x81
0305 #define PACKET3_DUMP_CONST_RAM              0x83
0306 #define PACKET3_INCREMENT_CE_COUNTER            0x84
0307 #define PACKET3_INCREMENT_DE_COUNTER            0x85
0308 #define PACKET3_WAIT_ON_CE_COUNTER          0x86
0309 #define PACKET3_WAIT_ON_DE_COUNTER_DIFF         0x88
0310 #define PACKET3_SWITCH_BUFFER               0x8B
0311 #define PACKET3_FRAME_CONTROL               0x90
0312 #           define FRAME_TMZ    (1 << 0)
0313 #           define FRAME_CMD(x) ((x) << 28)
0314             /*
0315              * x=0: tmz_begin
0316              * x=1: tmz_end
0317              */
0318 
0319 #define PACKET3_INVALIDATE_TLBS             0x98
0320 #              define PACKET3_INVALIDATE_TLBS_DST_SEL(x)     ((x) << 0)
0321 #              define PACKET3_INVALIDATE_TLBS_ALL_HUB(x)     ((x) << 4)
0322 #              define PACKET3_INVALIDATE_TLBS_PASID(x)       ((x) << 5)
0323 #              define PACKET3_INVALIDATE_TLBS_FLUSH_TYPE(x)  ((x) << 29)
0324 #define PACKET3_SET_RESOURCES               0xA0
0325 /* 1. header
0326  * 2. CONTROL
0327  * 3. QUEUE_MASK_LO [31:0]
0328  * 4. QUEUE_MASK_HI [31:0]
0329  * 5. GWS_MASK_LO [31:0]
0330  * 6. GWS_MASK_HI [31:0]
0331  * 7. OAC_MASK [15:0]
0332  * 8. GDS_HEAP_SIZE [16:11] | GDS_HEAP_BASE [5:0]
0333  */
0334 #              define PACKET3_SET_RESOURCES_VMID_MASK(x)     ((x) << 0)
0335 #              define PACKET3_SET_RESOURCES_UNMAP_LATENTY(x) ((x) << 16)
0336 #              define PACKET3_SET_RESOURCES_QUEUE_TYPE(x)    ((x) << 29)
0337 #define PACKET3_MAP_QUEUES              0xA2
0338 /* 1. header
0339  * 2. CONTROL
0340  * 3. CONTROL2
0341  * 4. MQD_ADDR_LO [31:0]
0342  * 5. MQD_ADDR_HI [31:0]
0343  * 6. WPTR_ADDR_LO [31:0]
0344  * 7. WPTR_ADDR_HI [31:0]
0345  */
0346 /* CONTROL */
0347 #              define PACKET3_MAP_QUEUES_QUEUE_SEL(x)       ((x) << 4)
0348 #              define PACKET3_MAP_QUEUES_VMID(x)            ((x) << 8)
0349 #              define PACKET3_MAP_QUEUES_QUEUE(x)           ((x) << 13)
0350 #              define PACKET3_MAP_QUEUES_PIPE(x)            ((x) << 16)
0351 #              define PACKET3_MAP_QUEUES_ME(x)              ((x) << 18)
0352 #              define PACKET3_MAP_QUEUES_QUEUE_TYPE(x)      ((x) << 21)
0353 #              define PACKET3_MAP_QUEUES_ALLOC_FORMAT(x)    ((x) << 24)
0354 #              define PACKET3_MAP_QUEUES_ENGINE_SEL(x)      ((x) << 26)
0355 #              define PACKET3_MAP_QUEUES_NUM_QUEUES(x)      ((x) << 29)
0356 /* CONTROL2 */
0357 #              define PACKET3_MAP_QUEUES_CHECK_DISABLE(x)   ((x) << 1)
0358 #              define PACKET3_MAP_QUEUES_DOORBELL_OFFSET(x) ((x) << 2)
0359 #define PACKET3_UNMAP_QUEUES                0xA3
0360 /* 1. header
0361  * 2. CONTROL
0362  * 3. CONTROL2
0363  * 4. CONTROL3
0364  * 5. CONTROL4
0365  * 6. CONTROL5
0366  */
0367 /* CONTROL */
0368 #              define PACKET3_UNMAP_QUEUES_ACTION(x)           ((x) << 0)
0369         /* 0 - PREEMPT_QUEUES
0370          * 1 - RESET_QUEUES
0371          * 2 - DISABLE_PROCESS_QUEUES
0372          * 3 - PREEMPT_QUEUES_NO_UNMAP
0373          */
0374 #              define PACKET3_UNMAP_QUEUES_QUEUE_SEL(x)        ((x) << 4)
0375 #              define PACKET3_UNMAP_QUEUES_ENGINE_SEL(x)       ((x) << 26)
0376 #              define PACKET3_UNMAP_QUEUES_NUM_QUEUES(x)       ((x) << 29)
0377 /* CONTROL2a */
0378 #              define PACKET3_UNMAP_QUEUES_PASID(x)            ((x) << 0)
0379 /* CONTROL2b */
0380 #              define PACKET3_UNMAP_QUEUES_DOORBELL_OFFSET0(x) ((x) << 2)
0381 /* CONTROL3a */
0382 #              define PACKET3_UNMAP_QUEUES_DOORBELL_OFFSET1(x) ((x) << 2)
0383 /* CONTROL3b */
0384 #              define PACKET3_UNMAP_QUEUES_RB_WPTR(x)          ((x) << 0)
0385 /* CONTROL4 */
0386 #              define PACKET3_UNMAP_QUEUES_DOORBELL_OFFSET2(x) ((x) << 2)
0387 /* CONTROL5 */
0388 #              define PACKET3_UNMAP_QUEUES_DOORBELL_OFFSET3(x) ((x) << 2)
0389 #define PACKET3_QUERY_STATUS                0xA4
0390 /* 1. header
0391  * 2. CONTROL
0392  * 3. CONTROL2
0393  * 4. ADDR_LO [31:0]
0394  * 5. ADDR_HI [31:0]
0395  * 6. DATA_LO [31:0]
0396  * 7. DATA_HI [31:0]
0397  */
0398 /* CONTROL */
0399 #              define PACKET3_QUERY_STATUS_CONTEXT_ID(x)       ((x) << 0)
0400 #              define PACKET3_QUERY_STATUS_INTERRUPT_SEL(x)    ((x) << 28)
0401 #              define PACKET3_QUERY_STATUS_COMMAND(x)          ((x) << 30)
0402 /* CONTROL2a */
0403 #              define PACKET3_QUERY_STATUS_PASID(x)            ((x) << 0)
0404 /* CONTROL2b */
0405 #              define PACKET3_QUERY_STATUS_DOORBELL_OFFSET(x)  ((x) << 2)
0406 #              define PACKET3_QUERY_STATUS_ENG_SEL(x)          ((x) << 25)
0407 
0408 
0409 #define VCE_CMD_NO_OP       0x00000000
0410 #define VCE_CMD_END     0x00000001
0411 #define VCE_CMD_IB      0x00000002
0412 #define VCE_CMD_FENCE       0x00000003
0413 #define VCE_CMD_TRAP        0x00000004
0414 #define VCE_CMD_IB_AUTO     0x00000005
0415 #define VCE_CMD_SEMAPHORE   0x00000006
0416 
0417 #define VCE_CMD_IB_VM           0x00000102
0418 #define VCE_CMD_WAIT_GE         0x00000106
0419 #define VCE_CMD_UPDATE_PTB      0x00000107
0420 #define VCE_CMD_FLUSH_TLB       0x00000108
0421 #define VCE_CMD_REG_WRITE       0x00000109
0422 #define VCE_CMD_REG_WAIT        0x0000010a
0423 
0424 #define HEVC_ENC_CMD_NO_OP      0x00000000
0425 #define HEVC_ENC_CMD_END        0x00000001
0426 #define HEVC_ENC_CMD_FENCE      0x00000003
0427 #define HEVC_ENC_CMD_TRAP       0x00000004
0428 #define HEVC_ENC_CMD_IB_VM      0x00000102
0429 #define HEVC_ENC_CMD_REG_WRITE      0x00000109
0430 #define HEVC_ENC_CMD_REG_WAIT       0x0000010a
0431 
0432 #endif